Documentation ¶
Index ¶
- Constants
- func FormatTimestamp(timestamp time.Time) string
- func ParseTimestamp(str string) (time.Time, error)
- type Client
- type Error
- type Event
- type Property
- type Table
- func (t *Table) AddEvent(objectId string, event *Event, method string) error
- func (t *Table) CreateProperty(property *Property) error
- func (t *Table) DeleteEvent(objectId string, event *Event) error
- func (t *Table) DeleteProperty(property *Property) error
- func (t *Table) GetEvent(objectId string, timestamp time.Time) (*Event, error)
- func (t *Table) GetEvents(objectId string) ([]*Event, error)
- func (t *Table) GetProperties() ([]*Property, error)
- func (t *Table) GetProperty(name string) (*Property, error)
- func (t *Table) RawQuery(q map[string]interface{}) (map[string]interface{}, error)
- func (t *Table) UpdateProperty(name string, property *Property) error
Constants ¶
View Source
const ( String = "string" Integer = "integer" Float = "float" Boolean = "boolean" Factor = "factor" )
View Source
const ( Replace = "replace" Merge = "merge" )
View Source
const (
DefaultPort = 8585
)
View Source
const (
Version = "0.3.0"
)
Variables ¶
This section is empty.
Functions ¶
func FormatTimestamp ¶
Formats a time into ISO8601 format with fractional seconds.
Types ¶
type Client ¶
A Client is what communicates command to the server.
func (*Client) CreateTable ¶
Creates a table on the server.
func (*Client) DeleteTable ¶
Deletes a table on the server.
type Error ¶
type Error struct {
// contains filtered or unexported fields
}
An error generated from the Sky server.
type Event ¶
An Event is a timestamped hash of data.
func (*Event) Deserialize ¶
Decodes an event from an untyped map.
type Property ¶
type Property struct { Id int `json:"id"` Name string `json:"name"` Transient bool `json:"transient"` DataType string `json:"dataType"` }
A Property is part of the table's schema.
type Table ¶
type Table struct { Name string `json:"name"` // contains filtered or unexported fields }
A Table is a container for objects and events.
func (*Table) CreateProperty ¶
Creates a property on the table.
func (*Table) DeleteEvent ¶
Deletes an event on the table.
func (*Table) DeleteProperty ¶
Deletes a property on the table.
func (*Table) GetProperties ¶
Retrieves a list of all properties on the table.
func (*Table) GetProperty ¶
Retrieves a single property from the server.
Click to show internal directories.
Click to hide internal directories.