Search
ctrl/
Ask AI
Light
Dark
System

Datatypes

DateDuration represents the elapsed time between two dates in a fuzzy human way.

Copy
type DateDuration struct {
    // contains filtered or unexported fields
}
Copy
func NewDateDuration(months int32, days int32) DateDuration

NewDateDuration returns a new DateDuration

Copy
func (dd DateDuration) MarshalText() ([]byte, error)

MarshalText returns dd marshaled as text.

Copy
func (dd DateDuration) String() string
Copy
func (dd *DateDuration) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *dd.

Duration represents the elapsed time between two instants as an int64 microsecond count.

Copy
type Duration int64
Copy
func DurationFromNanoseconds(d time.Duration) Duration

DurationFromNanoseconds creates a Duration represented as microseconds from a time.Duration represented as nanoseconds.

Copy
func ParseDuration(s string) (Duration, error)

ParseDuration parses an EdgeDB duration string.

Copy
func (d Duration) AsNanoseconds() (time.Duration, error)

AsNanoseconds returns time.Duration represented as nanoseconds, after transforming from Duration microsecond representation. Returns an error if the Duration is too long and would cause an overflow of the internal int64 representation.

Copy
func (d Duration) String() string

LocalDate is a date without a time zone. docs/stdlib/datetime#type::cal::local_date

Copy
type LocalDate struct {
    // contains filtered or unexported fields
}
Copy
func NewLocalDate(year int, month time.Month, day int) LocalDate

NewLocalDate returns a new LocalDate

Copy
func (d LocalDate) MarshalText() ([]byte, error)

MarshalText returns d marshaled as text.

Copy
func (d LocalDate) String() string
Copy
func (d *LocalDate) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *d.

LocalDateTime is a date and time without timezone. docs/stdlib/datetime#type::cal::local_datetime

Copy
type LocalDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewLocalDateTime(
    year int, month time.Month, day, hour, minute, second, microsecond int,
) LocalDateTime

NewLocalDateTime returns a new LocalDateTime

Copy
func (dt LocalDateTime) MarshalText() ([]byte, error)

MarshalText returns dt marshaled as text.

Copy
func (dt LocalDateTime) String() string
Copy
func (dt *LocalDateTime) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *dt.

LocalTime is a time without a time zone. docs/stdlib/datetime#type::cal::local_time

Copy
type LocalTime struct {
    // contains filtered or unexported fields
}
Copy
func NewLocalTime(hour, minute, second, microsecond int) LocalTime

NewLocalTime returns a new LocalTime

Copy
func (t LocalTime) MarshalText() ([]byte, error)

MarshalText returns t marshaled as text.

Copy
func (t LocalTime) String() string
Copy
func (t *LocalTime) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *t.

Memory represents memory in bytes.

Copy
type Memory int64
Copy
func (m Memory) MarshalText() ([]byte, error)

MarshalText returns m marshaled as text.

Copy
func (m Memory) String() string
Copy
func (m *Memory) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *m.

MultiRangeDateTime is a type alias for a slice of RangeDateTime values.

Copy
type MultiRangeDateTime = []RangeDateTime

MultiRangeFloat32 is a type alias for a slice of RangeFloat32 values.

Copy
type MultiRangeFloat32 = []RangeFloat32

MultiRangeFloat64 is a type alias for a slice of RangeFloat64 values.

Copy
type MultiRangeFloat64 = []RangeFloat64

MultiRangeInt32 is a type alias for a slice of RangeInt32 values.

Copy
type MultiRangeInt32 = []RangeInt32

MultiRangeInt64 is a type alias for a slice of RangeInt64 values.

Copy
type MultiRangeInt64 = []RangeInt64

MultiRangeLocalDate is a type alias for a slice of RangeLocalDate values.

Copy
type MultiRangeLocalDate = []RangeLocalDate

MultiRangeLocalDateTime is a type alias for a slice of RangeLocalDateTime values.

Copy
type MultiRangeLocalDateTime = []RangeLocalDateTime

Optional represents a shape field that is not required. Optional is embedded in structs to make them optional. For example:

Copy
type User struct {
    edgedb.Optional
    Name string `edgedb:"name"`
}
Copy
type Optional struct {
    // contains filtered or unexported fields
}
Copy
func (o *Optional) Missing() bool

Missing returns true if the value is missing.

Copy
func (o *Optional) SetMissing(missing bool)

SetMissing sets the structs missing status. true means missing and false means present.

Copy
func (o *Optional) Unset()

Unset marks the value as missing

OptionalBigInt is an optional *big.Int. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalBigInt struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalBigInt(v *big.Int) OptionalBigInt

NewOptionalBigInt is a convenience function for creating an OptionalBigInt with its value set to v.

Copy
func (o OptionalBigInt) Get() (*big.Int, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalBigInt) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalBigInt) Set(val *big.Int)

Set sets the value.

Copy
func (o *OptionalBigInt) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalBigInt) Unset()

Unset marks the value as missing.

OptionalBool is an optional bool. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalBool struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalBool(v bool) OptionalBool

NewOptionalBool is a convenience function for creating an OptionalBool with its value set to v.

Copy
func (o OptionalBool) Get() (bool, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalBool) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalBool) Set(val bool)

Set sets the value.

Copy
func (o *OptionalBool) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalBool) Unset()

Unset marks the value as missing.

OptionalBytes is an optional []byte. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalBytes struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalBytes(v []byte) OptionalBytes

NewOptionalBytes is a convenience function for creating an OptionalBytes with its value set to v.

Copy
func (o OptionalBytes) Get() ([]byte, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalBytes) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalBytes) Set(val []byte)

Set sets the value.

Copy
func (o *OptionalBytes) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalBytes) Unset()

Unset marks the value as missing.

OptionalDateDuration is an optional DateDuration. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalDateDuration struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalDateDuration(v DateDuration) OptionalDateDuration

NewOptionalDateDuration is a convenience function for creating an OptionalDateDuration with its value set to v.

Copy
func (o *OptionalDateDuration) Get() (DateDuration, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalDateDuration) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalDateDuration) Set(val DateDuration)

Set sets the value.

Copy
func (o *OptionalDateDuration) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalDateDuration) Unset()

Unset marks the value as missing.

OptionalDateTime is an optional time.Time. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalDateTime(v time.Time) OptionalDateTime

NewOptionalDateTime is a convenience function for creating an OptionalDateTime with its value set to v.

Copy
func (o OptionalDateTime) Get() (time.Time, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalDateTime) Set(val time.Time)

Set sets the value.

Copy
func (o *OptionalDateTime) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalDateTime) Unset()

Unset marks the value as missing.

OptionalDuration is an optional Duration. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalDuration struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalDuration(v Duration) OptionalDuration

NewOptionalDuration is a convenience function for creating an OptionalDuration with its value set to v.

Copy
func (o OptionalDuration) Get() (Duration, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalDuration) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalDuration) Set(val Duration)

Set sets the value.

Copy
func (o *OptionalDuration) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalDuration) Unset()

Unset marks the value as missing.

OptionalFloat32 is an optional float32. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalFloat32 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalFloat32(v float32) OptionalFloat32

NewOptionalFloat32 is a convenience function for creating an OptionalFloat32 with its value set to v.

Copy
func (o OptionalFloat32) Get() (float32, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalFloat32) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalFloat32) Set(val float32)

Set sets the value.

Copy
func (o *OptionalFloat32) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalFloat32) Unset()

Unset marks the value as missing.

OptionalFloat64 is an optional float64. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalFloat64 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalFloat64(v float64) OptionalFloat64

NewOptionalFloat64 is a convenience function for creating an OptionalFloat64 with its value set to v.

Copy
func (o OptionalFloat64) Get() (float64, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalFloat64) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalFloat64) Set(val float64)

Set sets the value.

Copy
func (o *OptionalFloat64) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalFloat64) Unset()

Unset marks the value as missing.

OptionalInt16 is an optional int16. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalInt16 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalInt16(v int16) OptionalInt16

NewOptionalInt16 is a convenience function for creating an OptionalInt16 with its value set to v.

Copy
func (o OptionalInt16) Get() (int16, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalInt16) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalInt16) Set(val int16)

Set sets the value.

Copy
func (o *OptionalInt16) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalInt16) Unset()

Unset marks the value as missing.

OptionalInt32 is an optional int32. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalInt32 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalInt32(v int32) OptionalInt32

NewOptionalInt32 is a convenience function for creating an OptionalInt32 with its value set to v.

Copy
func (o OptionalInt32) Get() (int32, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalInt32) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalInt32) Set(val int32)

Set sets the value.

Copy
func (o *OptionalInt32) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalInt32) Unset()

Unset marks the value as missing.

OptionalInt64 is an optional int64. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalInt64 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalInt64(v int64) OptionalInt64

NewOptionalInt64 is a convenience function for creating an OptionalInt64 with its value set to v.

Copy
func (o OptionalInt64) Get() (int64, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalInt64) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalInt64) Set(val int64) *OptionalInt64

Set sets the value.

Copy
func (o *OptionalInt64) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalInt64) Unset() *OptionalInt64

Unset marks the value as missing.

OptionalLocalDate is an optional LocalDate. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalLocalDate struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalLocalDate(v LocalDate) OptionalLocalDate

NewOptionalLocalDate is a convenience function for creating an OptionalLocalDate with its value set to v.

Copy
func (o OptionalLocalDate) Get() (LocalDate, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalLocalDate) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalLocalDate) Set(val LocalDate)

Set sets the value.

Copy
func (o *OptionalLocalDate) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalLocalDate) Unset()

Unset marks the value as missing.

OptionalLocalDateTime is an optional LocalDateTime. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalLocalDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalLocalDateTime(v LocalDateTime) OptionalLocalDateTime

NewOptionalLocalDateTime is a convenience function for creating an OptionalLocalDateTime with its value set to v.

Copy
func (o OptionalLocalDateTime) Get() (LocalDateTime, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalLocalDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalLocalDateTime) Set(val LocalDateTime)

Set sets the value.

Copy
func (o *OptionalLocalDateTime) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalLocalDateTime) Unset()

Unset marks the value as missing.

OptionalLocalTime is an optional LocalTime. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalLocalTime struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalLocalTime(v LocalTime) OptionalLocalTime

NewOptionalLocalTime is a convenience function for creating an OptionalLocalTime with its value set to v.

Copy
func (o OptionalLocalTime) Get() (LocalTime, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalLocalTime) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalLocalTime) Set(val LocalTime)

Set sets the value.

Copy
func (o *OptionalLocalTime) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalLocalTime) Unset()

Unset marks the value as missing.

OptionalMemory is an optional Memory. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalMemory struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalMemory(v Memory) OptionalMemory

NewOptionalMemory is a convenience function for creating an OptionalMemory with its value set to v.

Copy
func (o OptionalMemory) Get() (Memory, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalMemory) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalMemory) Set(val Memory)

Set sets the value.

Copy
func (o *OptionalMemory) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalMemory) Unset()

Unset marks the value as missing.

OptionalRangeDateTime is an optional RangeDateTime. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeDateTime(v RangeDateTime) OptionalRangeDateTime

NewOptionalRangeDateTime is a convenience function for creating an OptionalRangeDateTime with its value set to v.

Copy
func (o *OptionalRangeDateTime) Get() (RangeDateTime, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o *OptionalRangeDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeDateTime) Set(val RangeDateTime)

Set sets the value.

Copy
func (o *OptionalRangeDateTime) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeDateTime) Unset()

Unset marks the value as missing.

OptionalRangeFloat32 is an optional RangeFloat32. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeFloat32 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeFloat32(v RangeFloat32) OptionalRangeFloat32

NewOptionalRangeFloat32 is a convenience function for creating an OptionalRangeFloat32 with its value set to v.

Copy
func (o OptionalRangeFloat32) Get() (RangeFloat32, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeFloat32) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeFloat32) Set(val RangeFloat32)

Set sets the value.

Copy
func (o *OptionalRangeFloat32) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeFloat32) Unset()

Unset marks the value as missing.

OptionalRangeFloat64 is an optional RangeFloat64. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeFloat64 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeFloat64(v RangeFloat64) OptionalRangeFloat64

NewOptionalRangeFloat64 is a convenience function for creating an OptionalRangeFloat64 with its value set to v.

Copy
func (o OptionalRangeFloat64) Get() (RangeFloat64, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeFloat64) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeFloat64) Set(val RangeFloat64)

Set sets the value.

Copy
func (o *OptionalRangeFloat64) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeFloat64) Unset()

Unset marks the value as missing.

OptionalRangeInt32 is an optional RangeInt32. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeInt32 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeInt32(v RangeInt32) OptionalRangeInt32

NewOptionalRangeInt32 is a convenience function for creating an OptionalRangeInt32 with its value set to v.

Copy
func (o OptionalRangeInt32) Get() (RangeInt32, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeInt32) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeInt32) Set(val RangeInt32)

Set sets the value.

Copy
func (o *OptionalRangeInt32) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeInt32) Unset()

Unset marks the value as missing.

OptionalRangeInt64 is an optional RangeInt64. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeInt64 struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeInt64(v RangeInt64) OptionalRangeInt64

NewOptionalRangeInt64 is a convenience function for creating an OptionalRangeInt64 with its value set to v.

Copy
func (o OptionalRangeInt64) Get() (RangeInt64, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeInt64) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeInt64) Set(val RangeInt64)

Set sets the value.

Copy
func (o *OptionalRangeInt64) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeInt64) Unset()

Unset marks the value as missing.

OptionalRangeLocalDate is an optional RangeLocalDate. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeLocalDate struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeLocalDate(v RangeLocalDate) OptionalRangeLocalDate

NewOptionalRangeLocalDate is a convenience function for creating an OptionalRangeLocalDate with its value set to v.

Copy
func (o OptionalRangeLocalDate) Get() (RangeLocalDate, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeLocalDate) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeLocalDate) Set(val RangeLocalDate)

Set sets the value.

Copy
func (o *OptionalRangeLocalDate) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeLocalDate) Unset()

Unset marks the value as missing.

OptionalRangeLocalDateTime is an optional RangeLocalDateTime. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRangeLocalDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRangeLocalDateTime(
    v RangeLocalDateTime,
) OptionalRangeLocalDateTime

NewOptionalRangeLocalDateTime is a convenience function for creating an OptionalRangeLocalDateTime with its value set to v.

Copy
func (o OptionalRangeLocalDateTime) Get() (RangeLocalDateTime, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRangeLocalDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRangeLocalDateTime) Set(val RangeLocalDateTime)

Set sets the value.

Copy
func (o *OptionalRangeLocalDateTime) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRangeLocalDateTime) Unset()

Unset marks the value as missing.

OptionalRelativeDuration is an optional RelativeDuration. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalRelativeDuration struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalRelativeDuration(v RelativeDuration) OptionalRelativeDuration

NewOptionalRelativeDuration is a convenience function for creating an OptionalRelativeDuration with its value set to v.

Copy
func (o OptionalRelativeDuration) Get() (RelativeDuration, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalRelativeDuration) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalRelativeDuration) Set(val RelativeDuration)

Set sets the value.

Copy
func (o *OptionalRelativeDuration) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalRelativeDuration) Unset()

Unset marks the value as missing.

OptionalStr is an optional string. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalStr struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalStr(v string) OptionalStr

NewOptionalStr is a convenience function for creating an OptionalStr with its value set to v.

Copy
func (o OptionalStr) Get() (string, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalStr) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalStr) Set(val string)

Set sets the value.

Copy
func (o *OptionalStr) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o.

Copy
func (o *OptionalStr) Unset()

Unset marks the value as missing.

OptionalUUID is an optional UUID. Optional types must be used for out parameters when a shape field is not required.

Copy
type OptionalUUID struct {
    // contains filtered or unexported fields
}
Copy
func NewOptionalUUID(v UUID) OptionalUUID

NewOptionalUUID is a convenience function for creating an OptionalUUID with its value set to v.

Copy
func (o OptionalUUID) Get() (UUID, bool)

Get returns the value and a boolean indicating if the value is present.

Copy
func (o OptionalUUID) MarshalJSON() ([]byte, error)

MarshalJSON returns o marshaled as json.

Copy
func (o *OptionalUUID) Set(val UUID)

Set sets the value.

Copy
func (o *OptionalUUID) UnmarshalJSON(bytes []byte) error

UnmarshalJSON unmarshals bytes into *o

Copy
func (o *OptionalUUID) Unset()

Unset marks the value as missing.

RangeDateTime is an interval of time.Time values.

Copy
type RangeDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeDateTime(
    lower, upper OptionalDateTime,
    incLower, incUpper bool,
) RangeDateTime

NewRangeDateTime creates a new RangeDateTime value.

Copy
func (r RangeDateTime) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeDateTime) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeDateTime) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeDateTime) Lower() OptionalDateTime

Lower returns the lower bound.

Copy
func (r RangeDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeDateTime) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeDateTime) Upper() OptionalDateTime

Upper returns the upper bound.

RangeFloat32 is an interval of float32 values.

Copy
type RangeFloat32 struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeFloat32(
    lower, upper OptionalFloat32,
    incLower, incUpper bool,
) RangeFloat32

NewRangeFloat32 creates a new RangeFloat32 value.

Copy
func (r RangeFloat32) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeFloat32) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeFloat32) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeFloat32) Lower() OptionalFloat32

Lower returns the lower bound.

Copy
func (r RangeFloat32) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeFloat32) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeFloat32) Upper() OptionalFloat32

Upper returns the upper bound.

RangeFloat64 is an interval of float64 values.

Copy
type RangeFloat64 struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeFloat64(
    lower, upper OptionalFloat64,
    incLower, incUpper bool,
) RangeFloat64

NewRangeFloat64 creates a new RangeFloat64 value.

Copy
func (r RangeFloat64) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeFloat64) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeFloat64) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeFloat64) Lower() OptionalFloat64

Lower returns the lower bound.

Copy
func (r RangeFloat64) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeFloat64) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeFloat64) Upper() OptionalFloat64

Upper returns the upper bound.

RangeInt32 is an interval of int32 values.

Copy
type RangeInt32 struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeInt32(
    lower, upper OptionalInt32,
    incLower, incUpper bool,
) RangeInt32

NewRangeInt32 creates a new RangeInt32 value.

Copy
func (r RangeInt32) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeInt32) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeInt32) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeInt32) Lower() OptionalInt32

Lower returns the lower bound.

Copy
func (r RangeInt32) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeInt32) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeInt32) Upper() OptionalInt32

Upper returns the upper bound.

RangeInt64 is an interval of int64 values.

Copy
type RangeInt64 struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeInt64(
    lower, upper OptionalInt64,
    incLower, incUpper bool,
) RangeInt64

NewRangeInt64 creates a new RangeInt64 value.

Copy
func (r RangeInt64) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeInt64) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeInt64) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeInt64) Lower() OptionalInt64

Lower returns the lower bound.

Copy
func (r RangeInt64) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeInt64) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeInt64) Upper() OptionalInt64

Upper returns the upper bound.

RangeLocalDate is an interval of LocalDate values.

Copy
type RangeLocalDate struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeLocalDate(
    lower, upper OptionalLocalDate,
    incLower, incUpper bool,
) RangeLocalDate

NewRangeLocalDate creates a new RangeLocalDate value.

Copy
func (r RangeLocalDate) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeLocalDate) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeLocalDate) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeLocalDate) Lower() OptionalLocalDate

Lower returns the lower bound.

Copy
func (r RangeLocalDate) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeLocalDate) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeLocalDate) Upper() OptionalLocalDate

Upper returns the upper bound.

RangeLocalDateTime is an interval of LocalDateTime values.

Copy
type RangeLocalDateTime struct {
    // contains filtered or unexported fields
}
Copy
func NewRangeLocalDateTime(
    lower, upper OptionalLocalDateTime,
    incLower, incUpper bool,
) RangeLocalDateTime

NewRangeLocalDateTime creates a new RangeLocalDateTime value.

Copy
func (r RangeLocalDateTime) Empty() bool

Empty returns true if the range is empty.

Copy
func (r RangeLocalDateTime) IncLower() bool

IncLower returns true if the lower bound is inclusive.

Copy
func (r RangeLocalDateTime) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

Copy
func (r RangeLocalDateTime) Lower() OptionalLocalDateTime

Lower returns the lower bound.

Copy
func (r RangeLocalDateTime) MarshalJSON() ([]byte, error)

MarshalJSON returns r marshaled as json.

Copy
func (r *RangeLocalDateTime) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshals bytes into *r.

Copy
func (r RangeLocalDateTime) Upper() OptionalLocalDateTime

Upper returns the upper bound.

RelativeDuration represents the elapsed time between two instants in a fuzzy human way.

Copy
type RelativeDuration struct {
    // contains filtered or unexported fields
}
Copy
func NewRelativeDuration(
    months, days int32,
    microseconds int64,
) RelativeDuration

NewRelativeDuration returns a new RelativeDuration

Copy
func (rd RelativeDuration) MarshalText() ([]byte, error)

MarshalText returns rd marshaled as text.

Copy
func (rd RelativeDuration) String() string
Copy
func (rd *RelativeDuration) UnmarshalText(b []byte) error

UnmarshalText unmarshals bytes into *rd.

UUID is a universally unique identifier docs/stdlib/uuid

Copy
type UUID [16]byte
Copy
func ParseUUID(s string) (UUID, error)

ParseUUID parses s into a UUID or returns an error.

Copy
func (id UUID) MarshalText() ([]byte, error)

MarshalText returns the id as a byte string.

Copy
func (id UUID) String() string
Copy
func (id *UUID) UnmarshalText(b []byte) error

UnmarshalText unmarshals the id from a string.