Documentation ¶
Index ¶
- type Chronicle
- func (ct *Chronicle) Describe(verbose bool) (result string)
- func (ct *Chronicle) DescribeParams(verbose bool) (result string)
- func (ct *Chronicle) GenerateCsvFile(filename string, separator rune, argStore *args.Store, cmdFlags [][]string) (err error)
- func (ct *Chronicle) GenerateOutput(stamp *stamp.Stamp, argStore *args.Store) (err error)
- func (ct *Chronicle) GetExampleArguments() (result []string)
- func (ct *Chronicle) IsValid() (err error)
- type Store
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Chronicle ¶
type Chronicle struct { ID string Description string Parent string DisplayParent string Aspectratio string Flags []string Parameters param.Store Presets preset.Store Canvas canvas.Store Content content.ListStore // contains filtered or unexported fields }
Chronicle is the new approach for the Chronicle Template
func NewChronicleTemplate ¶
NewChronicleTemplate returns a new ChronicleTemplate object.
func (*Chronicle) Describe ¶
Describe returns a short textual description of a single chronicle template. It returns the description as a multi-line string.
func (*Chronicle) DescribeParams ¶
DescribeParams returns a textual description of the parameters expected by this chronicle template. It returns the description as a multi-line string.
func (*Chronicle) GenerateCsvFile ¶
func (ct *Chronicle) GenerateCsvFile(filename string, separator rune, argStore *args.Store, cmdFlags [][]string) (err error)
GenerateCsvFile creates a CSV file out of the current chronicle template than can be used as input for the "batch fill" command
func (*Chronicle) GenerateOutput ¶
GenerateOutput adds the content of this chronicle template to the provided stamp.
func (*Chronicle) GetExampleArguments ¶
GetExampleArguments returns an array containing all keys and example values for all parameters. The result can be passed to the ArgStore.
type Store ¶
type Store map[string]*Chronicle // Store as ptrs so that it is easier to modify them do things like aliasing
Store stores multiple ChronicleTemplates and provides means to retrieve them by name.
func GetStore ¶
GetStore returns a template store that is already filled with all templates contained in the main template directory. If some error showed up during reading and parsing files, resolving dependencies etc, then nil is returned together with an error.
func (*Store) ListTemplates ¶
ListTemplates lists the available templates. Result is returned as multi-line string.
func (*Store) SearchForTemplates ¶
SearchForTemplates takes one or multiple keywords and searches for templates where all these keywords are included in the description or the id. The search is case-insensitive. Result is returned as multi-line string.