Documentation
¶
Index ¶
- func GetDocument(documentURL string, resolveRefs bool) (map[string]interface{}, error)
- func GetEventTimeSeriesData(value interface{}, serviceSchemaUri, event string) ([]model.TimeSeriesDatapoint, error)
- func GetSchema(documentURL string) (*gojsonschema.JsonSchemaDocument, error)
- func GetServiceMethods(service string) ([]string, error)
- func Validate(schema string, obj interface{}) (*string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetDocument ¶
func GetEventTimeSeriesData ¶
func GetEventTimeSeriesData(value interface{}, serviceSchemaUri, event string) ([]model.TimeSeriesDatapoint, error)
* GetEventTimeSeriesData converts an event payload to 0..n time series data points. * NOTE: The payload must already have been validated. No validation is done here. * NOTE: This accepts the json payload. So either a simple type or map[string]interface{} * * @param value {interface{}} The payload of the event. Can be null if there is no payload * @param eventSchemaUri {string} The URI of the schema defining the event (usually ends with #/events/{name}) * @returns {Array} An array of records that need to be saved to a time series db
func GetSchema ¶
func GetSchema(documentURL string) (*gojsonschema.JsonSchemaDocument, error)
func GetServiceMethods ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.