annotated_struct

package
v1.2.14 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Float32s

type Float32s []float32

func (Float32s) IsNil

func (a Float32s) IsNil() bool

IsNil checks if array is nil

func (Float32s) MarshalJSONArray

func (a Float32s) MarshalJSONArray(enc *gojay.Encoder)

MarshalJSONArray encodes arrays into JSON

func (*Float32s) UnmarshalJSONArray

func (a *Float32s) UnmarshalJSONArray(dec *gojay.Decoder) error

UnmarshalJSONArray decodes JSON array elements into slice

type Ints

type Ints []int

func (Ints) IsNil

func (a Ints) IsNil() bool

IsNil checks if array is nil

func (Ints) MarshalJSONArray

func (a Ints) MarshalJSONArray(enc *gojay.Encoder)

MarshalJSONArray encodes arrays into JSON

func (*Ints) UnmarshalJSONArray

func (a *Ints) UnmarshalJSONArray(dec *gojay.Decoder) error

UnmarshalJSONArray decodes JSON array elements into slice

type Message

type Message struct {
	Id            int           `json:"id"`
	Name          string        `json:"name"`
	Price         float64       `json:"price"`
	Ints          []int         `json:"ints"`
	Floats        []float32     `json:"floats"`
	SubMessageX   *SubMessage   `json:"subMessageX"`
	MessagesX     []*SubMessage `json:"messagesX"`
	SubMessageY   SubMessage
	MessagesY     []SubMessage
	IsTrue        *bool           `json:"enabled"`
	Payload       Payload         `json:"data"`
	Ignore        string          `json:"-"`
	SQLNullString *sql.NullString `json:"sqlNullString"`
}

func (*Message) IsNil

func (m *Message) IsNil() bool

IsNil checks if instance is nil

func (*Message) MarshalJSONObject

func (m *Message) MarshalJSONObject(enc *gojay.Encoder)

MarshalJSONObject implements MarshalerJSONObject

func (*Message) NKeys

func (m *Message) NKeys() int

NKeys returns the number of keys to unmarshal

func (*Message) UnmarshalJSONObject

func (m *Message) UnmarshalJSONObject(dec *gojay.Decoder, k string) error

UnmarshalJSONObject implements gojay's UnmarshalerJSONObject

type Payload

type Payload []byte

func (*Payload) IsNil

func (p *Payload) IsNil() bool

IsNil checks if instance is nil

func (*Payload) MarshalJSONObject

func (p *Payload) MarshalJSONObject(enc *gojay.Encoder)

MarshalJSONObject implements MarshalerJSONObject

func (*Payload) NKeys

func (p *Payload) NKeys() int

NKeys returns the number of keys to unmarshal

func (*Payload) UnmarshalJSONObject

func (p *Payload) UnmarshalJSONObject(dec *gojay.Decoder, k string) error

UnmarshalJSONObject implements gojay's UnmarshalerJSONObject

type SubMessage

type SubMessage struct {
	Id          int        `json:"id"`
	Description string     `json:"description"`
	StartTime   time.Time  `json:"startDate" timeFormat:"yyyy-MM-dd HH:mm:ss"`
	EndTime     *time.Time `json:"endDate" timeLayout:"2006-01-02 15:04:05"`
}

func (*SubMessage) IsNil

func (m *SubMessage) IsNil() bool

IsNil checks if instance is nil

func (*SubMessage) MarshalJSONObject

func (m *SubMessage) MarshalJSONObject(enc *gojay.Encoder)

MarshalJSONObject implements MarshalerJSONObject

func (*SubMessage) NKeys

func (m *SubMessage) NKeys() int

NKeys returns the number of keys to unmarshal

func (*SubMessage) UnmarshalJSONObject

func (m *SubMessage) UnmarshalJSONObject(dec *gojay.Decoder, k string) error

UnmarshalJSONObject implements gojay's UnmarshalerJSONObject

type SubMessages

type SubMessages []SubMessage

func (SubMessages) IsNil

func (s SubMessages) IsNil() bool

func (SubMessages) MarshalJSONArray

func (s SubMessages) MarshalJSONArray(enc *gojay.Encoder)

func (*SubMessages) UnmarshalJSONArray

func (s *SubMessages) UnmarshalJSONArray(dec *gojay.Decoder) error

type SubMessagesPtr

type SubMessagesPtr []*SubMessage

func (SubMessagesPtr) IsNil

func (s SubMessagesPtr) IsNil() bool

func (SubMessagesPtr) MarshalJSONArray

func (s SubMessagesPtr) MarshalJSONArray(enc *gojay.Encoder)

func (*SubMessagesPtr) UnmarshalJSONArray

func (s *SubMessagesPtr) UnmarshalJSONArray(dec *gojay.Decoder) error

Jump to

Keyboard shortcuts

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