With nothing numbered of the builder's own, the tool answered that a floor would be asked at the next claim and looked again, doing nothing. Builds: design 47 H H-A-159, G §369
38 lines
2.0 KiB
Go
38 lines
2.0 KiB
Go
package versions
|
|
|
|
import (
|
|
"context"
|
|
"fmt"
|
|
"time"
|
|
)
|
|
|
|
// The tools' descriptions.
|
|
const (
|
|
FloorAgainDescription = "Refused for every name: the builder numbers nothing of its own and asks no floor (design 47 H H-A-159); " +
|
|
"a version is numbered by the reservation (design 47 G §369, builder_reserved). Kept until design 47 G §372 removes it with " +
|
|
"the state versions."
|
|
)
|
|
|
|
// Acts are the builder's hand acts on its versions, answered by its program (the tools bundle writes them to reasks).
|
|
type Acts struct {
|
|
Numberer *Numberer
|
|
// Reconsider looks at every module again, so a claim asks a name's floor.
|
|
Reconsider func(ctx context.Context)
|
|
// Republish queues the reserved versions builder_publish_again names (design 47 G §588): the versions it queued.
|
|
Republish func(ctx context.Context, module, version string) ([]string, error)
|
|
// DropOldForm drops a retired node from the old form's count by hand (builder_old_form): its answer, or why not.
|
|
DropOldForm func(ctx context.Context, node, by, why string, at time.Time) (string, error)
|
|
// ReserveDone reserves the next version for a done trunk build that reserved none and queues its publish (builder_reserve_done):
|
|
// its answer, or why not.
|
|
ReserveDone func(ctx context.Context, module, fp, by, why string, at time.Time) (string, error)
|
|
// DropReserved drops a module's reservation of one MAJOR.MINOR by hand (builder_reserved_drop): its answer, or why not.
|
|
DropReserved func(ctx context.Context, module, series, by, why string, at time.Time) (string, error)
|
|
}
|
|
|
|
// FloorAgain is builder_floor_again of name: refused, since the builder numbers nothing of its own and no claim asks a floor
|
|
// (design 47 H H-A-159; the reservation numbers, G §369). The tool stays until G §372 removes it with the state versions.
|
|
func (a Acts) FloorAgain(_ context.Context, name string) (string, error) {
|
|
return "", fmt.Errorf("the floor of %s is not asked: the builder numbers nothing of its own and asks no floor (design 47 H H-A-159); "+
|
|
"a version is numbered by the reservation (G §369, builder_reserved)", name)
|
|
}
|