Documentation
¶
Overview ¶
Package home composes the cockpit's home and decision queues from the profile's views, the decisions each task waits on and the words of the profile and its plugins.
Index ¶
Constants ¶
const ( ActionGate = "gate" // resolve the item's gate with the intent ID ActionAction = "action" // run the catalog action ID on the item's unit ActionOpen = "open" // open the item's unit at its source )
The kinds of a queue item's primary action.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Count ¶
type Count struct {
ID string
Kind decision.Kind
View task.View
N int
Label string
Nouns []PluginNoun
}
Count is a counter's count and its words.
type Counter ¶
Counter counts a decision kind's decisions (Kind), one per item of its queue, or a view's tasks (View, with its own Noun and Clause).
type Decisions ¶
Decisions are the decisions a task waits on, as the profile maps its open gates and its units' states.
type Forms ¶
Forms are a text's plural forms by CLDR category; "other" is required.
type Home ¶
type Home struct {
Template string
Sentences [][]Part
Counts []Count
Empty string
Sections []Rows
CaptureHint string
}
Home is the briefing, the sections and the capture hint.
type Item ¶
Item is one decision: a task's open gate (Found.Gate), or a state of one of its units (Found.Unit, with Situation how the unit's situation reads).
type KindWords ¶
KindWords are a decision kind's view and words; Primary is the gate intent a queue offers first.
type Lists ¶
type Lists interface {
Sets(ctx context.Context, views []task.View, keep coretasks.Keep) (map[task.View][]task.Task, error)
}
Lists are the tasks of several views in one pass (coretasks.Service).
type Part ¶
Part is a sentence's text, or with Counter at least 0 the count of that index in Home.Counts.
type PluginKind ¶
PluginKind are a plugin's words of a decision kind, each empty when the kind's own stand.
type PluginNoun ¶
type PluginNoun struct {
Plugin unit.ProviderID
N int
Noun string
}
PluginNoun is a plugin's share of a count.
type PluginWords ¶
type PluginWords struct {
Noun Forms
Kinds map[decision.Kind]PluginKind
Primary map[decision.Kind]string
// Situations are how the plugin's situations read, by situation.
Situations map[string]string
}
PluginWords are a plugin's noun, its words of each decision kind and what its queue offers first on each.
type Profile ¶
type Profile struct {
Template, Join, LastJoin, End, Count, Empty string
PerSentence int
Counters []Counter
Sections []Section
CaptureHint string
}
Profile is home.toml: the briefing's words and counters, the sections and the capture hint.
type Queue ¶
Queue is a decision kind's items, the oldest decision first, and View, the view its items are drawn as rows of.