Documentation
¶
Index ¶
- Variables
- func ToTime(t uint64) time.Time
- type Timestamp
- func (t *Timestamp) Clone() *Timestamp
- func (*Timestamp) Descriptor() ([]byte, []int)
- func (t *Timestamp) Equals(ot *Timestamp) bool
- func (m *Timestamp) GetTimeUnixMs() uint64
- func (*Timestamp) ProtoMessage()
- func (m *Timestamp) Reset()
- func (m *Timestamp) String() string
- func (t *Timestamp) ToTime() time.Time
- func (t *Timestamp) Validate(allowEmpty bool) error
- func (m *Timestamp) XXX_DiscardUnknown()
- func (m *Timestamp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Timestamp) XXX_Merge(src proto.Message)
- func (m *Timestamp) XXX_Size() int
- func (m *Timestamp) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrEmptyTimestamp is returned if the timestamp was empty. ErrEmptyTimestamp = errors.New("timestamp is empty") )
Functions ¶
Types ¶
type Timestamp ¶
type Timestamp struct { // TimeUnixMs timestamp in unix milliseconds. TimeUnixMs uint64 `protobuf:"varint,1,opt,name=time_unix_ms,json=timeUnixMs,proto3" json:"time_unix_ms,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Timestamp contains a cross-platform timestamp.
func ToTimestamp ¶
ToTimestamp generates a millisecond timestamp from the time object.
func (*Timestamp) Descriptor ¶
func (*Timestamp) GetTimeUnixMs ¶
func (*Timestamp) ProtoMessage ¶
func (*Timestamp) ProtoMessage()
func (*Timestamp) XXX_DiscardUnknown ¶ added in v0.4.0
func (m *Timestamp) XXX_DiscardUnknown()
func (*Timestamp) XXX_Marshal ¶ added in v0.4.0
func (*Timestamp) XXX_Unmarshal ¶ added in v0.4.0
Click to show internal directories.
Click to hide internal directories.