Documentation
¶
Index ¶
- type Client
- type Dataview
- func (d Dataview) AddColumn(name string) (err error)
- func (d Dataview) AddRow(name string) (err error)
- func (d Dataview) Close() (err error)
- func (d Dataview) ColumnNames() (columnnames []string, err error)
- func (d Dataview) CountColumns() (int, error)
- func (d Dataview) CountHeadlines() (int, error)
- func (d Dataview) CountRows() (int, error)
- func (d Dataview) DataviewGroupNames() (string, string)
- func (d Dataview) DataviewName() string
- func (d Dataview) Headline(name string, args ...string) (err error)
- func (d Dataview) HeadlineNames() (headlinenames []string, err error)
- func (d Dataview) IsValid() bool
- func (d Dataview) RemoveHeadline(name string) (err error)
- func (d Dataview) RemoveRow(name string) (err error)
- func (d Dataview) RowNames() (rownames []string, err error)
- func (d Dataview) RowNamesOlderThan(datetime time.Time) (rownames []string, err error)
- func (d *Dataview) SetDataviewName(dataview string, groupname string)
- func (d Dataview) String() string
- func (d Dataview) UpdateCell(rowname string, columnname string, value interface{}) (err error)
- func (d Dataview) UpdateRow(name string, args ...interface{}) (err error)
- func (d Dataview) UpdateTable(columns []string, values ...[]string) (err error)
- type Sampler
- func (s Sampler) CreateDataview(dataviewName string, groupName string) (d *Dataview, err error)
- func (s Sampler) EntityName() string
- func (s Sampler) Heartbeat() error
- func (s Sampler) HeartbeatStream(streamname string) error
- func (s *Sampler) IsValid() bool
- func (s Sampler) NewDataview(dataviewName string, groupName string, args ...[]string) (d *Dataview, err error)
- func (s Sampler) Parameter(name string) (string, error)
- func (s Sampler) SamplerName() string
- func (s *Sampler) SignOff() error
- func (s Sampler) SignOffStream(streamname string) error
- func (s *Sampler) SignOn(interval time.Duration) error
- func (s Sampler) SignOnStream(streamname string, heartbeat time.Duration) error
- func (s Sampler) String() string
- func (s Sampler) WriteMessage(streamname string, message string) (err error)
- type XMLRPC
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
The Client struct carries the http Client and the url down to successive layers
func (*Client) AllowUnverifiedCertificates ¶
func (c *Client) AllowUnverifiedCertificates()
func (Client) IsValid ¶
IsValid returns a boolean based on the semantics of the layer it's call against.
At the top Client level it checks if the Gateway is connected to the Netprobe, but further levels will test if the appropriate objects exist in the Netprobe
func (Client) NewSampler ¶
Sampler creates and returns a new Sampler struct from the lower level.
XXX At the moment there is no error checking or validation
type Dataview ¶
type Dataview struct {
Sampler
// contains filtered or unexported fields
}
Dataview struct encapsulates the Sampler it belongs to and adds the name. The name is the aggregated for of [group]-name the "-" is always present
func (Dataview) Close ¶
Close removes the dataview from the sampler It does not cleanup the data structure
func (Dataview) ColumnNames ¶
func (Dataview) CountColumns ¶
func (Dataview) CountHeadlines ¶
func (Dataview) DataviewGroupNames ¶
DataviewGroupNames returns the dataview name and group as two strings, the group may be empty
func (Dataview) DataviewName ¶
DataviewName returns to aggregated dataview name (including the optional group)
func (Dataview) HeadlineNames ¶
func (Dataview) RemoveHeadline ¶
func (Dataview) RowNamesOlderThan ¶
func (*Dataview) SetDataviewName ¶
SetDataviewName sets the aggregated dataview name given the name and group XXX No validation or checking is done
func (Dataview) String ¶
String returns a human readable string to identify the dataview, mainly for debugging
func (Dataview) UpdateCell ¶
UpdateCell sets the value of an existing dataview cell given the row and column name The value is formatted using %v so this can be passed any concrete value
No validation is done on args
func (Dataview) UpdateTable ¶
UpdateTable replaces the contents of the dataview table but will not work if the column names have changed. The underlying API requires the caller to remove the original dataview unless you are simply adding new columns
The arguments are a mandatory slice of column names followed by any number of rows in the form of a variadic list of slices of strings
type Sampler ¶
type Sampler struct {
Client
// contains filtered or unexported fields
}
func (Sampler) CreateDataview ¶
CreateDataview creates a new dataview struct and calls the API to create one on the Netprobe. It does NOT check for an existing dataview or remove it if one exists
func (Sampler) EntityName ¶
EntityName returns the Entuty name as a string
func (Sampler) Heartbeat ¶
Heartbeat sends a heartbeat to reset the watchdog timer activated by SignOn
func (Sampler) HeartbeatStream ¶
func (Sampler) NewDataview ¶
func (s Sampler) NewDataview(dataviewName string, groupName string, args ...[]string) (d *Dataview, err error)
NewDataview - Create a new Dataview on the Sampler with an optional initial table of data.
If supplied the data is in the form of rows, each of which is a slice of strings containing cell data. The first row must be the column names and the first string in each row must be the rowname (including the first row of column names).
The underlying API appears to accept incomplete data so you can just send a row of column names followed by each row only contains the first N columns each.
func (Sampler) Parameter ¶
Parameter - Get a parameter from the Geneos sampler config as a string It would not be difficult to add numeric and other type getters
func (Sampler) SamplerName ¶
SamplerName returns the Sampler name as a string