Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Gateway-Server/model/data_point.go
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
34 lines (26 sloc)
655 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Code generated by github.com/actgardner/gogen-avro. DO NOT EDIT. | |
/* | |
* SOURCE: | |
* datapackage.avsc | |
*/ | |
package avro | |
import ( | |
"io" | |
) | |
type DataPoint struct { | |
Timestamp int64 | |
Value UnionLongDouble | |
} | |
func DeserializeDataPoint(r io.Reader) (*DataPoint, error) { | |
return readDataPoint(r) | |
} | |
func NewDataPoint() *DataPoint { | |
v := &DataPoint{} | |
return v | |
} | |
func (r *DataPoint) Schema() string { | |
return "{\"fields\":[{\"name\":\"timestamp\",\"type\":\"long\"},{\"name\":\"value\",\"type\":[\"long\",\"double\"]}],\"name\":\"DataPoint\",\"type\":\"record\"}" | |
} | |
func (r *DataPoint) Serialize(w io.Writer) error { | |
return writeDataPoint(r, w) | |
} |