cached

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FormulaNamesFile   = "formula_names.txt"   // FormulaAliasesFile is the name of the formula name cache.
	FormulaAliasesFile = "formula_aliases.txt" // FormulaAliasesFile is the name of the formula aliases cache.
	FormulaRenamesFile = "formula_renames.txt" // FormulaAliasesFile is the name of the formula aliases cache.
)

Variables

This section is empty.

Functions

func WriteFormulaAliases

func WriteFormulaAliases(fa FormulaAliases, file string) error

WriteFormulaNames writes the formula names to file.

func WriteFormulaNames

func WriteFormulaNames(fn FormulaNames, file string) error

WriteFormulaNames writes the formula names to file.

Types

type FormulaAliases

type FormulaAliases map[string]string

FormulaAliases represents the cached formula aliases file. Sorted by the second element (the target name).

func LoadFormulaAliases

func LoadFormulaAliases(file string) (FormulaAliases, error)

LoadFormulaAliases loads a formula aliases list from a file.

func (FormulaAliases) MarshalCSV

func (fa FormulaAliases) MarshalCSV() ([]byte, error)

MarshalCSV returns the aliases marshaled to a pipe-delimited CSV.

type FormulaNames

type FormulaNames []string

FormulaNames represents the contents of the formula names file.

func LoadFormulaNames

func LoadFormulaNames(file string) (FormulaNames, error)

LoadFormulaNames loads a formula names list from a file.

func (FormulaNames) Has

func (fn FormulaNames) Has(name string) bool

Has reports if the name is found in the formula name list.

func (FormulaNames) Index

func (fn FormulaNames) Index(name string) int

Index reports the index of name in the formula name list, -1 if not found.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL