edgedbtypes

package
v0.17.1 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DateDuration added in v0.12.0

type DateDuration struct {
	// contains filtered or unexported fields
}

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

func NewDateDuration added in v0.12.0

func NewDateDuration(months int32, days int32) DateDuration

NewDateDuration returns a new DateDuration

func (DateDuration) MarshalText added in v0.12.0

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

MarshalText returns dd marshaled as text.

func (DateDuration) String added in v0.12.0

func (dd DateDuration) String() string

func (*DateDuration) UnmarshalText added in v0.12.0

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

UnmarshalText unmarshals bytes into *dd.

type Duration

type Duration int64

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

func DurationFromNanoseconds added in v0.17.0

func DurationFromNanoseconds(d time.Duration) Duration

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

func ParseDuration added in v0.11.0

func ParseDuration(s string) (Duration, error)

ParseDuration parses an EdgeDB duration string.

func (Duration) AsNanoseconds added in v0.17.0

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.

func (Duration) String

func (d Duration) String() string

type LocalDate

type LocalDate struct {
	// contains filtered or unexported fields
}

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

func NewLocalDate

func NewLocalDate(year int, month time.Month, day int) LocalDate

NewLocalDate returns a new LocalDate

func (LocalDate) MarshalText added in v0.9.0

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

MarshalText returns d marshaled as text.

func (LocalDate) String

func (d LocalDate) String() string

func (*LocalDate) UnmarshalText added in v0.9.0

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

UnmarshalText unmarshals bytes into *d.

type LocalDateTime

type LocalDateTime struct {
	// contains filtered or unexported fields
}

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

func NewLocalDateTime

func NewLocalDateTime(
	year int, month time.Month, day, hour, minute, second, microsecond int,
) LocalDateTime

NewLocalDateTime returns a new LocalDateTime

func (LocalDateTime) MarshalText added in v0.9.0

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

MarshalText returns dt marshaled as text.

func (LocalDateTime) String

func (dt LocalDateTime) String() string

func (*LocalDateTime) UnmarshalText added in v0.9.0

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

UnmarshalText unmarshals bytes into *dt.

type LocalTime

type LocalTime struct {
	// contains filtered or unexported fields
}

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

func NewLocalTime

func NewLocalTime(hour, minute, second, microsecond int) LocalTime

NewLocalTime returns a new LocalTime

func (LocalTime) MarshalText added in v0.9.0

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

MarshalText returns t marshaled as text.

func (LocalTime) String

func (t LocalTime) String() string

func (*LocalTime) UnmarshalText added in v0.9.0

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

UnmarshalText unmarshals bytes into *t.

type Memory added in v0.9.0

type Memory int64

Memory represents memory in bytes.

func (Memory) MarshalText added in v0.9.0

func (m Memory) MarshalText() ([]byte, error)

MarshalText returns m marshaled as text.

func (Memory) String added in v0.9.0

func (m Memory) String() string

func (*Memory) UnmarshalText added in v0.9.0

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

UnmarshalText unmarshals bytes into *m.

type MultiRangeDateTime added in v0.17.1

type MultiRangeDateTime = []RangeDateTime

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

type MultiRangeFloat32 added in v0.17.1

type MultiRangeFloat32 = []RangeFloat32

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

type MultiRangeFloat64 added in v0.17.1

type MultiRangeFloat64 = []RangeFloat64

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

type MultiRangeInt32 added in v0.17.1

type MultiRangeInt32 = []RangeInt32

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

type MultiRangeInt64 added in v0.17.1

type MultiRangeInt64 = []RangeInt64

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

type MultiRangeLocalDate added in v0.17.1

type MultiRangeLocalDate = []RangeLocalDate

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

type MultiRangeLocalDateTime added in v0.17.1

type MultiRangeLocalDateTime = []RangeLocalDateTime

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

type Optional added in v0.8.0

type Optional struct {
	// contains filtered or unexported fields
}

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

type User struct {
    edgedb.Optional
    Name string `edgedb:"name"`
}

func (*Optional) Missing added in v0.8.0

func (o *Optional) Missing() bool

Missing returns true if the value is missing.

func (*Optional) SetMissing added in v0.8.0

func (o *Optional) SetMissing(missing bool)

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

func (*Optional) Unset added in v0.9.0

func (o *Optional) Unset()

Unset marks the value as missing

type OptionalBigInt added in v0.8.0

type OptionalBigInt struct {
	// contains filtered or unexported fields
}

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

func NewOptionalBigInt added in v0.13.0

func NewOptionalBigInt(v *big.Int) OptionalBigInt

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

func (OptionalBigInt) Get added in v0.8.0

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

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

func (OptionalBigInt) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalBigInt) Set added in v0.8.0

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

Set sets the value.

func (*OptionalBigInt) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalBigInt) Unset added in v0.8.0

func (o *OptionalBigInt) Unset()

Unset marks the value as missing.

type OptionalBool added in v0.8.0

type OptionalBool struct {
	// contains filtered or unexported fields
}

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

func NewOptionalBool added in v0.13.0

func NewOptionalBool(v bool) OptionalBool

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

func (OptionalBool) Get added in v0.8.0

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

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

func (OptionalBool) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalBool) Set added in v0.8.0

func (o *OptionalBool) Set(val bool)

Set sets the value.

func (*OptionalBool) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalBool) Unset added in v0.8.0

func (o *OptionalBool) Unset()

Unset marks the value as missing.

type OptionalBytes added in v0.8.0

type OptionalBytes struct {
	// contains filtered or unexported fields
}

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

func NewOptionalBytes added in v0.13.0

func NewOptionalBytes(v []byte) OptionalBytes

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

func (OptionalBytes) Get added in v0.8.0

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

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

func (OptionalBytes) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalBytes) Set added in v0.8.0

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

Set sets the value.

func (*OptionalBytes) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalBytes) Unset added in v0.8.0

func (o *OptionalBytes) Unset()

Unset marks the value as missing.

type OptionalDateDuration added in v0.12.0

type OptionalDateDuration struct {
	// contains filtered or unexported fields
}

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

func NewOptionalDateDuration added in v0.13.0

func NewOptionalDateDuration(v DateDuration) OptionalDateDuration

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

func (*OptionalDateDuration) Get added in v0.12.0

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

func (OptionalDateDuration) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalDateDuration) Set added in v0.12.0

func (o *OptionalDateDuration) Set(val DateDuration)

Set sets the value.

func (*OptionalDateDuration) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalDateDuration) Unset added in v0.12.0

func (o *OptionalDateDuration) Unset()

Unset marks the value as missing.

type OptionalDateTime added in v0.8.0

type OptionalDateTime struct {
	// contains filtered or unexported fields
}

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

func NewOptionalDateTime added in v0.13.0

func NewOptionalDateTime(v time.Time) OptionalDateTime

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

func (OptionalDateTime) Get added in v0.8.0

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

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

func (OptionalDateTime) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalDateTime) Set added in v0.8.0

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

Set sets the value.

func (*OptionalDateTime) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalDateTime) Unset added in v0.8.0

func (o *OptionalDateTime) Unset()

Unset marks the value as missing.

type OptionalDuration added in v0.8.0

type OptionalDuration struct {
	// contains filtered or unexported fields
}

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

func NewOptionalDuration added in v0.13.0

func NewOptionalDuration(v Duration) OptionalDuration

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

func (OptionalDuration) Get added in v0.8.0

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

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

func (OptionalDuration) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalDuration) Set added in v0.8.0

func (o *OptionalDuration) Set(val Duration)

Set sets the value.

func (*OptionalDuration) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalDuration) Unset added in v0.8.0

func (o *OptionalDuration) Unset()

Unset marks the value as missing.

type OptionalFloat32 added in v0.8.0

type OptionalFloat32 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalFloat32 added in v0.13.0

func NewOptionalFloat32(v float32) OptionalFloat32

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

func (OptionalFloat32) Get added in v0.8.0

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

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

func (OptionalFloat32) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalFloat32) Set added in v0.8.0

func (o *OptionalFloat32) Set(val float32)

Set sets the value.

func (*OptionalFloat32) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalFloat32) Unset added in v0.8.0

func (o *OptionalFloat32) Unset()

Unset marks the value as missing.

type OptionalFloat64 added in v0.8.0

type OptionalFloat64 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalFloat64 added in v0.13.0

func NewOptionalFloat64(v float64) OptionalFloat64

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

func (OptionalFloat64) Get added in v0.8.0

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

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

func (OptionalFloat64) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalFloat64) Set added in v0.8.0

func (o *OptionalFloat64) Set(val float64)

Set sets the value.

func (*OptionalFloat64) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalFloat64) Unset added in v0.8.0

func (o *OptionalFloat64) Unset()

Unset marks the value as missing.

type OptionalInt16 added in v0.8.0

type OptionalInt16 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalInt16 added in v0.13.0

func NewOptionalInt16(v int16) OptionalInt16

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

func (OptionalInt16) Get added in v0.8.0

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

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

func (OptionalInt16) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalInt16) Set added in v0.8.0

func (o *OptionalInt16) Set(val int16)

Set sets the value.

func (*OptionalInt16) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalInt16) Unset added in v0.8.0

func (o *OptionalInt16) Unset()

Unset marks the value as missing.

type OptionalInt32 added in v0.8.0

type OptionalInt32 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalInt32 added in v0.13.0

func NewOptionalInt32(v int32) OptionalInt32

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

func (OptionalInt32) Get added in v0.8.0

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

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

func (OptionalInt32) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalInt32) Set added in v0.8.0

func (o *OptionalInt32) Set(val int32)

Set sets the value.

func (*OptionalInt32) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalInt32) Unset added in v0.8.0

func (o *OptionalInt32) Unset()

Unset marks the value as missing.

type OptionalInt64 added in v0.8.0

type OptionalInt64 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalInt64 added in v0.13.0

func NewOptionalInt64(v int64) OptionalInt64

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

func (OptionalInt64) Get added in v0.8.0

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

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

func (OptionalInt64) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalInt64) Set added in v0.8.0

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

Set sets the value.

func (*OptionalInt64) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalInt64) Unset added in v0.8.0

func (o *OptionalInt64) Unset() *OptionalInt64

Unset marks the value as missing.

type OptionalLocalDate added in v0.8.0

type OptionalLocalDate struct {
	// contains filtered or unexported fields
}

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

func NewOptionalLocalDate added in v0.13.0

func NewOptionalLocalDate(v LocalDate) OptionalLocalDate

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

func (OptionalLocalDate) Get added in v0.8.0

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

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

func (OptionalLocalDate) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalLocalDate) Set added in v0.8.0

func (o *OptionalLocalDate) Set(val LocalDate)

Set sets the value.

func (*OptionalLocalDate) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalLocalDate) Unset added in v0.8.0

func (o *OptionalLocalDate) Unset()

Unset marks the value as missing.

type OptionalLocalDateTime added in v0.8.0

type OptionalLocalDateTime struct {
	// contains filtered or unexported fields
}

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

func NewOptionalLocalDateTime added in v0.13.0

func NewOptionalLocalDateTime(v LocalDateTime) OptionalLocalDateTime

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

func (OptionalLocalDateTime) Get added in v0.8.0

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

func (OptionalLocalDateTime) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalLocalDateTime) Set added in v0.8.0

Set sets the value.

func (*OptionalLocalDateTime) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalLocalDateTime) Unset added in v0.8.0

func (o *OptionalLocalDateTime) Unset()

Unset marks the value as missing.

type OptionalLocalTime added in v0.8.0

type OptionalLocalTime struct {
	// contains filtered or unexported fields
}

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

func NewOptionalLocalTime added in v0.13.0

func NewOptionalLocalTime(v LocalTime) OptionalLocalTime

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

func (OptionalLocalTime) Get added in v0.8.0

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

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

func (OptionalLocalTime) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalLocalTime) Set added in v0.8.0

func (o *OptionalLocalTime) Set(val LocalTime)

Set sets the value.

func (*OptionalLocalTime) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalLocalTime) Unset added in v0.8.0

func (o *OptionalLocalTime) Unset()

Unset marks the value as missing.

type OptionalMemory added in v0.9.0

type OptionalMemory struct {
	// contains filtered or unexported fields
}

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

func NewOptionalMemory added in v0.13.0

func NewOptionalMemory(v Memory) OptionalMemory

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

func (OptionalMemory) Get added in v0.9.0

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

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

func (OptionalMemory) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalMemory) Set added in v0.9.0

func (o *OptionalMemory) Set(val Memory)

Set sets the value.

func (*OptionalMemory) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalMemory) Unset added in v0.9.0

func (o *OptionalMemory) Unset()

Unset marks the value as missing.

type OptionalRangeDateTime added in v0.12.0

type OptionalRangeDateTime struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeDateTime added in v0.13.0

func NewOptionalRangeDateTime(v RangeDateTime) OptionalRangeDateTime

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

func (*OptionalRangeDateTime) Get added in v0.12.0

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

func (*OptionalRangeDateTime) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeDateTime) Set added in v0.12.0

Set sets the value.

func (*OptionalRangeDateTime) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeDateTime) Unset added in v0.12.0

func (o *OptionalRangeDateTime) Unset()

Unset marks the value as missing.

type OptionalRangeFloat32 added in v0.12.0

type OptionalRangeFloat32 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeFloat32 added in v0.13.0

func NewOptionalRangeFloat32(v RangeFloat32) OptionalRangeFloat32

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

func (OptionalRangeFloat32) Get added in v0.12.0

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

func (OptionalRangeFloat32) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeFloat32) Set added in v0.12.0

func (o *OptionalRangeFloat32) Set(val RangeFloat32)

Set sets the value.

func (*OptionalRangeFloat32) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeFloat32) Unset added in v0.12.0

func (o *OptionalRangeFloat32) Unset()

Unset marks the value as missing.

type OptionalRangeFloat64 added in v0.12.0

type OptionalRangeFloat64 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeFloat64 added in v0.13.0

func NewOptionalRangeFloat64(v RangeFloat64) OptionalRangeFloat64

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

func (OptionalRangeFloat64) Get added in v0.12.0

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

func (OptionalRangeFloat64) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeFloat64) Set added in v0.12.0

func (o *OptionalRangeFloat64) Set(val RangeFloat64)

Set sets the value.

func (*OptionalRangeFloat64) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeFloat64) Unset added in v0.12.0

func (o *OptionalRangeFloat64) Unset()

Unset marks the value as missing.

type OptionalRangeInt32 added in v0.12.0

type OptionalRangeInt32 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeInt32 added in v0.13.0

func NewOptionalRangeInt32(v RangeInt32) OptionalRangeInt32

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

func (OptionalRangeInt32) Get added in v0.12.0

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

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

func (OptionalRangeInt32) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeInt32) Set added in v0.12.0

func (o *OptionalRangeInt32) Set(val RangeInt32)

Set sets the value.

func (*OptionalRangeInt32) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeInt32) Unset added in v0.12.0

func (o *OptionalRangeInt32) Unset()

Unset marks the value as missing.

type OptionalRangeInt64 added in v0.12.0

type OptionalRangeInt64 struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeInt64 added in v0.13.0

func NewOptionalRangeInt64(v RangeInt64) OptionalRangeInt64

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

func (OptionalRangeInt64) Get added in v0.12.0

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

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

func (OptionalRangeInt64) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeInt64) Set added in v0.12.0

func (o *OptionalRangeInt64) Set(val RangeInt64)

Set sets the value.

func (*OptionalRangeInt64) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeInt64) Unset added in v0.12.0

func (o *OptionalRangeInt64) Unset()

Unset marks the value as missing.

type OptionalRangeLocalDate added in v0.12.0

type OptionalRangeLocalDate struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeLocalDate added in v0.13.0

func NewOptionalRangeLocalDate(v RangeLocalDate) OptionalRangeLocalDate

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

func (OptionalRangeLocalDate) Get added in v0.12.0

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

func (OptionalRangeLocalDate) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeLocalDate) Set added in v0.12.0

Set sets the value.

func (*OptionalRangeLocalDate) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeLocalDate) Unset added in v0.12.0

func (o *OptionalRangeLocalDate) Unset()

Unset marks the value as missing.

type OptionalRangeLocalDateTime added in v0.12.0

type OptionalRangeLocalDateTime struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRangeLocalDateTime added in v0.13.0

func NewOptionalRangeLocalDateTime(
	v RangeLocalDateTime,
) OptionalRangeLocalDateTime

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

func (OptionalRangeLocalDateTime) Get added in v0.12.0

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

func (OptionalRangeLocalDateTime) MarshalJSON added in v0.12.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRangeLocalDateTime) Set added in v0.12.0

Set sets the value.

func (*OptionalRangeLocalDateTime) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRangeLocalDateTime) Unset added in v0.12.0

func (o *OptionalRangeLocalDateTime) Unset()

Unset marks the value as missing.

type OptionalRelativeDuration added in v0.8.0

type OptionalRelativeDuration struct {
	// contains filtered or unexported fields
}

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

func NewOptionalRelativeDuration added in v0.13.0

func NewOptionalRelativeDuration(v RelativeDuration) OptionalRelativeDuration

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

func (OptionalRelativeDuration) Get added in v0.8.0

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

func (OptionalRelativeDuration) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalRelativeDuration) Set added in v0.8.0

Set sets the value.

func (*OptionalRelativeDuration) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalRelativeDuration) Unset added in v0.8.0

func (o *OptionalRelativeDuration) Unset()

Unset marks the value as missing.

type OptionalStr added in v0.8.0

type OptionalStr struct {
	// contains filtered or unexported fields
}

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

func NewOptionalStr added in v0.13.0

func NewOptionalStr(v string) OptionalStr

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

func (OptionalStr) Get added in v0.8.0

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

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

func (OptionalStr) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalStr) Set added in v0.8.0

func (o *OptionalStr) Set(val string)

Set sets the value.

func (*OptionalStr) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o.

func (*OptionalStr) Unset added in v0.8.0

func (o *OptionalStr) Unset()

Unset marks the value as missing.

type OptionalUUID added in v0.8.0

type OptionalUUID struct {
	// contains filtered or unexported fields
}

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

func NewOptionalUUID added in v0.13.0

func NewOptionalUUID(v UUID) OptionalUUID

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

func (OptionalUUID) Get added in v0.8.0

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

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

func (OptionalUUID) MarshalJSON added in v0.9.0

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

MarshalJSON returns o marshaled as json.

func (*OptionalUUID) Set added in v0.8.0

func (o *OptionalUUID) Set(val UUID)

Set sets the value.

func (*OptionalUUID) UnmarshalJSON added in v0.9.0

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

UnmarshalJSON unmarshals bytes into *o

func (*OptionalUUID) Unset added in v0.8.0

func (o *OptionalUUID) Unset()

Unset marks the value as missing.

type RangeDateTime added in v0.12.0

type RangeDateTime struct {
	// contains filtered or unexported fields
}

RangeDateTime is an interval of time.Time values.

func NewRangeDateTime added in v0.12.0

func NewRangeDateTime(
	lower, upper OptionalDateTime,
	incLower, incUpper bool,
) RangeDateTime

NewRangeDateTime creates a new RangeDateTime value.

func (RangeDateTime) Empty added in v0.12.0

func (r RangeDateTime) Empty() bool

Empty returns true if the range is empty.

func (RangeDateTime) IncLower added in v0.12.0

func (r RangeDateTime) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeDateTime) IncUpper added in v0.12.0

func (r RangeDateTime) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeDateTime) Lower added in v0.12.0

func (r RangeDateTime) Lower() OptionalDateTime

Lower returns the lower bound.

func (RangeDateTime) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeDateTime) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeDateTime) Upper added in v0.12.0

func (r RangeDateTime) Upper() OptionalDateTime

Upper returns the upper bound.

type RangeFloat32 added in v0.12.0

type RangeFloat32 struct {
	// contains filtered or unexported fields
}

RangeFloat32 is an interval of float32 values.

func NewRangeFloat32 added in v0.12.0

func NewRangeFloat32(
	lower, upper OptionalFloat32,
	incLower, incUpper bool,
) RangeFloat32

NewRangeFloat32 creates a new RangeFloat32 value.

func (RangeFloat32) Empty added in v0.12.0

func (r RangeFloat32) Empty() bool

Empty returns true if the range is empty.

func (RangeFloat32) IncLower added in v0.12.0

func (r RangeFloat32) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeFloat32) IncUpper added in v0.12.0

func (r RangeFloat32) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeFloat32) Lower added in v0.12.0

func (r RangeFloat32) Lower() OptionalFloat32

Lower returns the lower bound.

func (RangeFloat32) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeFloat32) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeFloat32) Upper added in v0.12.0

func (r RangeFloat32) Upper() OptionalFloat32

Upper returns the upper bound.

type RangeFloat64 added in v0.12.0

type RangeFloat64 struct {
	// contains filtered or unexported fields
}

RangeFloat64 is an interval of float64 values.

func NewRangeFloat64 added in v0.12.0

func NewRangeFloat64(
	lower, upper OptionalFloat64,
	incLower, incUpper bool,
) RangeFloat64

NewRangeFloat64 creates a new RangeFloat64 value.

func (RangeFloat64) Empty added in v0.12.0

func (r RangeFloat64) Empty() bool

Empty returns true if the range is empty.

func (RangeFloat64) IncLower added in v0.12.0

func (r RangeFloat64) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeFloat64) IncUpper added in v0.12.0

func (r RangeFloat64) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeFloat64) Lower added in v0.12.0

func (r RangeFloat64) Lower() OptionalFloat64

Lower returns the lower bound.

func (RangeFloat64) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeFloat64) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeFloat64) Upper added in v0.12.0

func (r RangeFloat64) Upper() OptionalFloat64

Upper returns the upper bound.

type RangeInt32 added in v0.12.0

type RangeInt32 struct {
	// contains filtered or unexported fields
}

RangeInt32 is an interval of int32 values.

func NewRangeInt32 added in v0.12.0

func NewRangeInt32(
	lower, upper OptionalInt32,
	incLower, incUpper bool,
) RangeInt32

NewRangeInt32 creates a new RangeInt32 value.

func (RangeInt32) Empty added in v0.12.0

func (r RangeInt32) Empty() bool

Empty returns true if the range is empty.

func (RangeInt32) IncLower added in v0.12.0

func (r RangeInt32) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeInt32) IncUpper added in v0.12.0

func (r RangeInt32) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeInt32) Lower added in v0.12.0

func (r RangeInt32) Lower() OptionalInt32

Lower returns the lower bound.

func (RangeInt32) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeInt32) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeInt32) Upper added in v0.12.0

func (r RangeInt32) Upper() OptionalInt32

Upper returns the upper bound.

type RangeInt64 added in v0.12.0

type RangeInt64 struct {
	// contains filtered or unexported fields
}

RangeInt64 is an interval of int64 values.

func NewRangeInt64 added in v0.12.0

func NewRangeInt64(
	lower, upper OptionalInt64,
	incLower, incUpper bool,
) RangeInt64

NewRangeInt64 creates a new RangeInt64 value.

func (RangeInt64) Empty added in v0.12.0

func (r RangeInt64) Empty() bool

Empty returns true if the range is empty.

func (RangeInt64) IncLower added in v0.12.0

func (r RangeInt64) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeInt64) IncUpper added in v0.12.0

func (r RangeInt64) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeInt64) Lower added in v0.12.0

func (r RangeInt64) Lower() OptionalInt64

Lower returns the lower bound.

func (RangeInt64) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeInt64) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeInt64) Upper added in v0.12.0

func (r RangeInt64) Upper() OptionalInt64

Upper returns the upper bound.

type RangeLocalDate added in v0.12.0

type RangeLocalDate struct {
	// contains filtered or unexported fields
}

RangeLocalDate is an interval of LocalDate values.

func NewRangeLocalDate added in v0.12.0

func NewRangeLocalDate(
	lower, upper OptionalLocalDate,
	incLower, incUpper bool,
) RangeLocalDate

NewRangeLocalDate creates a new RangeLocalDate value.

func (RangeLocalDate) Empty added in v0.12.0

func (r RangeLocalDate) Empty() bool

Empty returns true if the range is empty.

func (RangeLocalDate) IncLower added in v0.12.0

func (r RangeLocalDate) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeLocalDate) IncUpper added in v0.12.0

func (r RangeLocalDate) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeLocalDate) Lower added in v0.12.0

Lower returns the lower bound.

func (RangeLocalDate) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeLocalDate) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeLocalDate) Upper added in v0.12.0

Upper returns the upper bound.

type RangeLocalDateTime added in v0.12.0

type RangeLocalDateTime struct {
	// contains filtered or unexported fields
}

RangeLocalDateTime is an interval of LocalDateTime values.

func NewRangeLocalDateTime added in v0.12.0

func NewRangeLocalDateTime(
	lower, upper OptionalLocalDateTime,
	incLower, incUpper bool,
) RangeLocalDateTime

NewRangeLocalDateTime creates a new RangeLocalDateTime value.

func (RangeLocalDateTime) Empty added in v0.12.0

func (r RangeLocalDateTime) Empty() bool

Empty returns true if the range is empty.

func (RangeLocalDateTime) IncLower added in v0.12.0

func (r RangeLocalDateTime) IncLower() bool

IncLower returns true if the lower bound is inclusive.

func (RangeLocalDateTime) IncUpper added in v0.12.0

func (r RangeLocalDateTime) IncUpper() bool

IncUpper returns true if the upper bound is inclusive.

func (RangeLocalDateTime) Lower added in v0.12.0

Lower returns the lower bound.

func (RangeLocalDateTime) MarshalJSON added in v0.12.0

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

MarshalJSON returns r marshaled as json.

func (*RangeLocalDateTime) UnmarshalJSON added in v0.12.0

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

UnmarshalJSON unmarshals bytes into *r.

func (RangeLocalDateTime) Upper added in v0.12.0

Upper returns the upper bound.

type RelativeDuration added in v0.7.0

type RelativeDuration struct {
	// contains filtered or unexported fields
}

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

func NewRelativeDuration added in v0.7.0

func NewRelativeDuration(
	months, days int32,
	microseconds int64,
) RelativeDuration

NewRelativeDuration returns a new RelativeDuration

func (RelativeDuration) MarshalText added in v0.9.0

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

MarshalText returns rd marshaled as text.

func (RelativeDuration) String added in v0.7.0

func (rd RelativeDuration) String() string

func (*RelativeDuration) UnmarshalText added in v0.9.0

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

UnmarshalText unmarshals bytes into *rd.

type UUID

type UUID [16]byte

UUID is a universally unique identifier https://www.edgedb.com/docs/stdlib/uuid

func ParseUUID added in v0.6.0

func ParseUUID(s string) (UUID, error)

ParseUUID parses s into a UUID or returns an error.

func (UUID) MarshalText

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

MarshalText returns the id as a byte string.

func (UUID) String

func (id UUID) String() string

func (*UUID) UnmarshalText

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

UnmarshalText unmarshals the id from a string.

Jump to

Keyboard shortcuts

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