timestamp

package
v0.0.0-...-19b05fa Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 10, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package timestamp is a generated protocol buffer package.

It is generated from these files:

timestamp.proto

It has these top-level messages:

Timestamp

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Timestamp

type Timestamp struct {
	// Represents seconds of UTC time since Unix epoch
	// 1970-01-01T00:00:00Z
	Milliseconds int64 `protobuf:"varint,1,opt,name=milliseconds" json:"milliseconds,omitempty"`
	// is set to true if the timestamp is null
	IsNotNull bool `protobuf:"varint,2,opt,name=is_not_null,json=isNotNull" json:"is_not_null,omitempty"`
}

Timestamp ...

func (*Timestamp) Descriptor

func (*Timestamp) Descriptor() ([]byte, []int)

func (*Timestamp) GetIsNotNull

func (m *Timestamp) GetIsNotNull() bool

func (*Timestamp) GetMilliseconds

func (m *Timestamp) GetMilliseconds() int64

func (*Timestamp) ImplementsGraphQLType

func (ts *Timestamp) ImplementsGraphQLType(name string) bool

ImplementsGraphQLType is required by the graphql custom scalar interface this defines the name used in the schema to declare a null time type

func (*Timestamp) IsNull

func (ts *Timestamp) IsNull() bool

IsNull will return if the current timestamp is null

func (Timestamp) MarshalJSON

func (ts Timestamp) MarshalJSON() ([]byte, error)

MarshalJSON will return the content as json value, this is also called by graphql to generate the response

func (*Timestamp) ProtoMessage

func (*Timestamp) ProtoMessage()

func (*Timestamp) Reset

func (m *Timestamp) Reset()

func (*Timestamp) Scan

func (ts *Timestamp) Scan(value interface{}) error

Scan implements the Scanner interface of the database driver

func (*Timestamp) Set

func (ts *Timestamp) Set(value time.Time)

Set will set the timestamp to the given time

func (*Timestamp) SetNull

func (ts *Timestamp) SetNull()

SetNull will clear the timestamp

func (*Timestamp) String

func (m *Timestamp) String() string

func (*Timestamp) Time

func (ts *Timestamp) Time() time.Time

Time returns a golang time object

func (*Timestamp) UnmarshalGraphQL

func (ts *Timestamp) UnmarshalGraphQL(input interface{}) error

UnmarshalGraphQL is required by the graphql custom scalar interface this wraps the null time

func (*Timestamp) UnmarshalJSON

func (ts *Timestamp) UnmarshalJSON(input []byte) error

UnmarshalJSON is used to convert the json representation into a timestamp

func (Timestamp) Value

func (ts Timestamp) Value() (driver.Value, error)

Value implements the db driver Valuer interface

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL