Documentation
¶
Overview ¶
Copyright (c) 2023 the go-mongr8 Authors and Contributors [@see Authors file]
Licensed under the MIT License (https://opensource.org/licenses/MIT)
Copyright (c) 2023 the go-mongr8 Authors and Contributors [@see Authors file]
Licensed under the MIT License (https://opensource.org/licenses/MIT)
Index ¶
- func LegacyCoordinateEmbeddedDocField(name string) *legacyCoordinateEmbeddedDocSpec
- type FieldSpec
- func ArrayField(name string, fields ...*FieldSpec) *FieldSpec
- func BooleanField(name string) *FieldSpec
- func DoubleField(name string) *FieldSpec
- func FromFieldSpec(spec *Spec) *FieldSpec
- func GeoJSONGeometryCollectionField(name string) *FieldSpec
- func GeoJSONLineStringField(name string) *FieldSpec
- func GeoJSONMultiLineStringField(name string) *FieldSpec
- func GeoJSONMultiPointField(name string) *FieldSpec
- func GeoJSONMultiPolygonField(name string) *FieldSpec
- func GeoJSONPointField(name string) *FieldSpec
- func GeoJSONPolygonMultipleRingField(name string) *FieldSpec
- func GeoJSONPolygonSingleRingField(name string) *FieldSpec
- func Int32Field(name string) *FieldSpec
- func Int64Field(name string) *FieldSpec
- func LegacyCoordinateArrayField(name string) *FieldSpec
- func ObjectField(name string, fields ...*FieldSpec) *FieldSpec
- func StringField(name string) *FieldSpec
- func TimestampField(name string) *FieldSpec
- type FieldType
- type Spec
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LegacyCoordinateEmbeddedDocField ¶
func LegacyCoordinateEmbeddedDocField(name string) *legacyCoordinateEmbeddedDocSpec
Types ¶
type FieldSpec ¶
type FieldSpec struct {
// contains filtered or unexported fields
}
func ArrayField ¶
func BooleanField ¶
func DoubleField ¶
func FromFieldSpec ¶
func GeoJSONLineStringField ¶
func GeoJSONMultiPointField ¶
func GeoJSONPointField ¶
func Int32Field ¶
func Int64Field ¶
func ObjectField ¶
func StringField ¶
func TimestampField ¶
func (*FieldSpec) ObjectHasKey ¶
func (*FieldSpec) SetNullable ¶
type FieldType ¶
type FieldType string
const ( TypeString FieldType = "TypeString" TypeInt32 FieldType = "TypeInt32" TypeInt64 FieldType = "TypeInt64" TypeDouble FieldType = "TypeDouble" TypeBoolean FieldType = "TypeBoolean" TypeArray FieldType = "TypeArray" TypeObject FieldType = "TypeObject" TypeTimestamp FieldType = "TypeTimestamp" TypeGeoJSONPoint FieldType = "TypeGeoJSONPoint" TypeGeoJSONLineString FieldType = "TypeGeoJSONLineString" TypeGeoJSONPolygonSingleRing FieldType = "TypeGeoJSONPolygonSingleRing" TypeGeoJSONPolygonMultipleRing FieldType = "TypeGeoJSONPolygonMultipleRing" TypeGeoJSONMultiPoint FieldType = "TypeGeoJSONMultiPoint" TypeGeoJSONMultiLineString FieldType = "TypeGeoJSONMultiLineString" TypeGeoJSONMultiPolygon FieldType = "TypeGeoJSONMultiPolygon" TypeGeoJSONGeometryCollection FieldType = "TypeGeoJSONGeometryCollection" TypeLegacyCoordinateArray FieldType = "TypeLegacyCoordinateArray" TypeLegacyCoordinateEmbeddedDoc FieldType = "TypeLegacyCoordinateEmbeddedDoc" )
make sure constant name is exactly same as it's value
func GetTypePointer ¶
type Spec ¶
type Spec struct { Name string // Type of the field Type FieldType // Array items, if current type is an array // this can be any field type ArrayFields *[]Spec // Children of object, if current type is an object Object *[]Spec // Nullable flag Nullable bool // contains filtered or unexported fields }
Click to show internal directories.
Click to hide internal directories.