Documentation
¶
Index ¶
- Constants
- func DirectoryRead(dir string, glob string) ([]string, error)
- func FileRead(fn string, ref interface{}) error
- func FileRemove(fn string) error
- func FileWrite(fn string, ref interface{}, perm os.FileMode) error
- func GetAsString(r interface{}) string
- func GetEndPointString(r interface{}) string
- func GetRequestString(r interface{}) string
- func PlainFileRead(fn string) ([]byte, error)
- func PlainFileWrite(fn string, data []byte, perm os.FileMode) error
- func SetFloat(v float64) *float64
- func SetInteger(v int) *int
- func SetString(v string) *string
- type Chart
- func (c *Chart) Generate() error
- func (c *Chart) SetFilename(fn string) error
- func (c *Chart) SetGraphSearch(req GraphRequest) bool
- func (c *Chart) SetHeight(v *int)
- func (c *Chart) SetRangeY(min *float64, max *float64) bool
- func (c *Chart) SetTitle(fn string) error
- func (c *Chart) SetWidth(v *int)
- func (c *Chart) SetX(name string, values ...time.Time) error
- func (c *Chart) SetY(name string, values ...float64) error
- func (c *Chart) SetY2(name string, values ...float64) error
- type DataRow
- type DataSet
- type GraphRequest
- type Json
- type OutputType
- func (out *OutputType) IsFile() bool
- func (out *OutputType) IsGraph() bool
- func (out *OutputType) IsHuman() bool
- func (out *OutputType) IsJson() bool
- func (out *OutputType) IsNone() bool
- func (out *OutputType) IsRaw() bool
- func (out *OutputType) IsStrFile(t string) bool
- func (out *OutputType) IsStrGraph(t string) bool
- func (out *OutputType) IsStrHuman(t string) bool
- func (out *OutputType) IsStrJson(t string) bool
- func (out *OutputType) IsStrNone(t string) bool
- func (out *OutputType) IsStrRaw(t string) bool
- func (out *OutputType) SetFile()
- func (out *OutputType) SetGraph()
- func (out *OutputType) SetHuman()
- func (out *OutputType) SetJson()
- func (out *OutputType) SetNone()
- func (out *OutputType) SetRaw()
- type SearchStrings
- type Table
- func (t Table) AddRow(row ...interface{}) error
- func (t *Table) AllRows() []*tabular.Row
- func (t *Table) CreateGraph() error
- func (t *Table) FindSearchStrings() error
- func (t *Table) GetData()
- func (t *Table) GetHeaders() []tabular.Cell
- func (t *Table) GetSearchColumn() SearchStrings
- func (t *Table) InitGraph(req GraphRequest)
- func (t *Table) Print()
- func (t *Table) ProcessGraphData() error
- func (t *Table) SearchStrings() SearchStrings
- func (t *Table) SetFilePrefix(prefix string) error
- func (t *Table) SetGraph(req GraphRequest) error
- func (t *Table) SetGraphFromJson(j Json) error
- func (t *Table) SetHeader(header ...interface{}) error
- func (t *Table) SetTitle(title string) error
- func (t *Table) String() string
- func (t *Table) WriteCsvFile() error
- func (t *Table) WriteFile(fn string, perm os.FileMode) error
Constants ¶
View Source
const ( DefaultFileMode = 0644 DateTimeLayout = "2006/01/02 15:04:05" DateTimeSearchLayout = "2006-01-02 15:04:05" )
Variables ¶
This section is empty.
Functions ¶
func GetAsString ¶
func GetAsString(r interface{}) string
func GetEndPointString ¶
func GetEndPointString(r interface{}) string
func GetRequestString ¶
func GetRequestString(r interface{}) string
func PlainFileRead ¶
PlainFileRead Retrieves data from a local file.
func PlainFileWrite ¶
PlainFileWrite Saves data to a file path.
func SetInteger ¶
Types ¶
type Chart ¶
type Chart struct {
Error error `json:"-"`
// contains filtered or unexported fields
}
func (*Chart) SetFilename ¶
func (*Chart) SetGraphSearch ¶
func (c *Chart) SetGraphSearch(req GraphRequest) bool
type GraphRequest ¶
type GraphRequest struct {
Title string `json:"title"`
TimeColumn *int `json:"time_column"`
ValueColumn *int `json:"value_column"`
UnitsColumn *int `json:"units_column"`
NameColumn *int `json:"name_column"`
SearchColumn *int `json:"search_column"`
SearchString *string `json:"search_string"`
MinLeftAxis *float64 `json:"min_left_axis"`
MaxLeftAxis *float64 `json:"max_left_axis"`
Width *int `json:"width"`
Height *int `json:"height"`
Error error `json:"-"`
}
func JsonToGraphRequest ¶
func JsonToGraphRequest(j Json) GraphRequest
type OutputType ¶
type OutputType int
func (*OutputType) IsFile ¶
func (out *OutputType) IsFile() bool
func (*OutputType) IsGraph ¶
func (out *OutputType) IsGraph() bool
func (*OutputType) IsHuman ¶
func (out *OutputType) IsHuman() bool
func (*OutputType) IsJson ¶
func (out *OutputType) IsJson() bool
func (*OutputType) IsNone ¶
func (out *OutputType) IsNone() bool
func (*OutputType) IsRaw ¶
func (out *OutputType) IsRaw() bool
func (*OutputType) IsStrFile ¶
func (out *OutputType) IsStrFile(t string) bool
func (*OutputType) IsStrGraph ¶
func (out *OutputType) IsStrGraph(t string) bool
func (*OutputType) IsStrHuman ¶
func (out *OutputType) IsStrHuman(t string) bool
func (*OutputType) IsStrJson ¶
func (out *OutputType) IsStrJson(t string) bool
func (*OutputType) IsStrNone ¶
func (out *OutputType) IsStrNone(t string) bool
func (*OutputType) IsStrRaw ¶
func (out *OutputType) IsStrRaw(t string) bool
func (*OutputType) SetFile ¶
func (out *OutputType) SetFile()
func (*OutputType) SetGraph ¶
func (out *OutputType) SetGraph()
func (*OutputType) SetHuman ¶
func (out *OutputType) SetHuman()
func (*OutputType) SetJson ¶
func (out *OutputType) SetJson()
func (*OutputType) SetNone ¶
func (out *OutputType) SetNone()
func (*OutputType) SetRaw ¶
func (out *OutputType) SetRaw()
type SearchStrings ¶
type Table ¶
type Table struct {
Error error
// contains filtered or unexported fields
}
func (*Table) CreateGraph ¶
func (*Table) FindSearchStrings ¶
func (*Table) GetHeaders ¶
func (*Table) GetSearchColumn ¶
func (t *Table) GetSearchColumn() SearchStrings
func (*Table) InitGraph ¶
func (t *Table) InitGraph(req GraphRequest)
func (*Table) ProcessGraphData ¶
func (*Table) SearchStrings ¶
func (t *Table) SearchStrings() SearchStrings
func (*Table) SetFilePrefix ¶
func (*Table) SetGraph ¶
func (t *Table) SetGraph(req GraphRequest) error
func (*Table) SetGraphFromJson ¶
func (*Table) WriteCsvFile ¶
Click to show internal directories.
Click to hide internal directories.