geopb

package module
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: May 24, 2020 License: MIT Imports: 7 Imported by: 0

README

geopb

Go

Google Protocol Buffers definition for simple geo types using field options for verification and validation

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FeatureCollection_PoiFeature_Marker_Size_name = map[int32]string{
		0: "SIZE_UNSPECIFIED",
		1: "SIZE_SMALL",
		2: "SIZE_MEDIUM",
		3: "SIZE_LARGE",
	}
	FeatureCollection_PoiFeature_Marker_Size_value = map[string]int32{
		"SIZE_UNSPECIFIED": 0,
		"SIZE_SMALL":       1,
		"SIZE_MEDIUM":      2,
		"SIZE_LARGE":       3,
	}
)

Enum value maps for FeatureCollection_PoiFeature_Marker_Size.

View Source
var (
	// Field is valid.
	//
	// optional bool valid = 50000;
	E_Valid = &file_field_options_proto_extTypes[0]
	// Double range lower bound min inclusive [min,].
	//
	// Mutually exclusive to double_min_exclusive.
	//
	// optional double double_min_inclusive = 50010;
	E_DoubleMinInclusive = &file_field_options_proto_extTypes[1]
	// Double range lower bound min exclusive (min,].
	//
	// Mutually exclusive to double_min_inclusive.
	//
	// optional double double_min_exclusive = 50011;
	E_DoubleMinExclusive = &file_field_options_proto_extTypes[2]
	// Double range upper bound max inclusive [, max].
	//
	// Mutually exclusive to double_max_exclusive.
	//
	// optional double double_max_inclusive = 50012;
	E_DoubleMaxInclusive = &file_field_options_proto_extTypes[3]
	// Double range upper bound max exclusive [, max).
	//
	// Mutually exclusive to double_max_inclusive.
	//
	// optional double double_max_exclusive = 50013;
	E_DoubleMaxExclusive = &file_field_options_proto_extTypes[4]
	// Float range lower bound min inclusive [min,].
	//
	// Mutually exclusive to float_min_exclusive.
	//
	// optional float float_min_inclusive = 50020;
	E_FloatMinInclusive = &file_field_options_proto_extTypes[5]
	// Float range lower bound min exclusive (min,].
	//
	// Mutually exclusive to float_min_inclusive.
	//
	// optional float float_min_exclusive = 50021;
	E_FloatMinExclusive = &file_field_options_proto_extTypes[6]
	// Float range upper bound max inclusive [, max].
	//
	// Mutually exclusive to float_max_exclusive.
	//
	// optional float float_max_inclusive = 50022;
	E_FloatMaxInclusive = &file_field_options_proto_extTypes[7]
	// Float range upper bound max exclusive [, max).
	//
	// Mutually exclusive to float_max_inclusive.
	//
	// optional float float_max_exclusive = 50023;
	E_FloatMaxExclusive = &file_field_options_proto_extTypes[8]
	// Int32 value.
	//
	// Mutually exclusive to int32_min and int32_max.
	//
	// optional int32 int32_value = 50030;
	E_Int32Value = &file_field_options_proto_extTypes[9]
	// Int32 min inclusive [min,].
	//
	// Mutually exclusive to int32_value.
	//
	// optional int32 int32_min = 50031;
	E_Int32Min = &file_field_options_proto_extTypes[10]
	// Int32 max inclusive [,max].
	//
	// Mutually exclusive to int32_value.
	//
	// optional int32 int32_max = 50032;
	E_Int32Max = &file_field_options_proto_extTypes[11]
	// Int64 value.
	//
	// Mutually exclusive to int64_min and int64_max.
	//
	// optional int64 int64_value = 50040;
	E_Int64Value = &file_field_options_proto_extTypes[12]
	// Int64 min inclusive [min,].
	//
	// Mutually exclusive to int64_value.
	//
	// optional int64 int64_min = 50041;
	E_Int64Min = &file_field_options_proto_extTypes[13]
	// Int64 max inclusive [,max].
	//
	// Mutually exclusive to int64_value.
	//
	// optional int64 int64_max = 50042;
	E_Int64Max = &file_field_options_proto_extTypes[14]
	// String value.
	//
	// Mutually exclusive to string_regex.
	//
	// optional string string_value = 50060;
	E_StringValue = &file_field_options_proto_extTypes[15]
	// String regular expression.
	//
	// Mutually exclusive to string_value.
	//
	// optional string string_regex = 50061;
	E_StringRegex = &file_field_options_proto_extTypes[16]
	// String length.
	//
	// Mutually exclusive to string_min_length and string_max_length.
	//
	// optional int32 string_length = 50062;
	E_StringLength = &file_field_options_proto_extTypes[17]
	// String min length inclusive [min,].
	//
	// Mutually exclusive to string_length.
	//
	// optional int32 string_min_length = 50063;
	E_StringMinLength = &file_field_options_proto_extTypes[18]
	// String max length inclusive [,max].
	//
	// Mutually exclusive to string_length.
	//
	// optional int32 string_max_length = 50064;
	E_StringMaxLength = &file_field_options_proto_extTypes[19]
	// Bytes length.
	//
	// Mutually exclusive to bytes_min_length and bytes_max_length.
	//
	// optional int32 bytes_length = 50070;
	E_BytesLength = &file_field_options_proto_extTypes[20]
	// Bytes min length inclusive [min,].
	//
	// Mutually exclusive to bytes_length.
	//
	// optional int32 bytes_min_length = 50071;
	E_BytesMinLength = &file_field_options_proto_extTypes[21]
	// Bytes max length inclusive [,max].
	//
	// Mutually exclusive to bytes_length.
	//
	// optional int32 bytes_max_length = 50072;
	E_BytesMaxLength = &file_field_options_proto_extTypes[22]
	// List elements length.
	//
	// Mutually exclusive to list_min_length and list_max_length.
	//
	// optional int32 list_length = 50100;
	E_ListLength = &file_field_options_proto_extTypes[23]
	// List elements min length inclusive [min,].
	//
	// Mutually exclusive to list_length.
	//
	// optional int32 list_min_length = 50101;
	E_ListMinLength = &file_field_options_proto_extTypes[24]
	// List elements max length inclusive [,max].
	//
	// Mutually exclusive to list_length.
	//
	// optional int32 list_max_length = 50102;
	E_ListMaxLength = &file_field_options_proto_extTypes[25]
)

Extension fields to descriptor.FieldOptions.

View Source
var (
	// Fields that shall be set.
	//
	// optional string fields_set = 51000;
	E_FieldsSet = &file_message_options_proto_extTypes[0]
	// Fields that shall not be set.
	//
	// optional string fields_not_set = 51001;
	E_FieldsNotSet = &file_message_options_proto_extTypes[1]
)

Extension fields to descriptor.MessageOptions.

View Source
var File_feature_collection_proto protoreflect.FileDescriptor
View Source
var File_field_options_proto protoreflect.FileDescriptor
View Source
var File_message_options_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type FeatureCollection

type FeatureCollection struct {

	// Points of Interest (POI).
	Pois []*FeatureCollection_PoiFeature `protobuf:"bytes,1,rep,name=pois,proto3" json:"pois,omitempty"`
	// Tracks.
	Tracks []*FeatureCollection_TrackFeature `protobuf:"bytes,2,rep,name=tracks,proto3" json:"tracks,omitempty"`
	// Hidden sites.
	HiddenSites []*FeatureCollection_PoiFeature `protobuf:"bytes,3,rep,name=hidden_sites,json=hiddenSites,proto3" json:"hidden_sites,omitempty"`
	// contains filtered or unexported fields
}

Feature collection.

func (*FeatureCollection) Descriptor deprecated

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

Deprecated: Use FeatureCollection.ProtoReflect.Descriptor instead.

func (*FeatureCollection) GetHiddenSites added in v0.0.7

func (x *FeatureCollection) GetHiddenSites() []*FeatureCollection_PoiFeature

func (*FeatureCollection) GetPois

func (*FeatureCollection) GetTracks

func (*FeatureCollection) ProtoMessage

func (*FeatureCollection) ProtoMessage()

func (*FeatureCollection) ProtoReflect

func (x *FeatureCollection) ProtoReflect() protoreflect.Message

func (*FeatureCollection) Reset

func (x *FeatureCollection) Reset()

func (*FeatureCollection) String

func (x *FeatureCollection) String() string

type FeatureCollection_Coordinate

type FeatureCollection_Coordinate struct {

	// Longitude.
	Longitude *wrappers.DoubleValue `protobuf:"bytes,1,opt,name=longitude,proto3" json:"longitude,omitempty"`
	// Latitude.
	Latitude *wrappers.DoubleValue `protobuf:"bytes,2,opt,name=latitude,proto3" json:"latitude,omitempty"`
	// contains filtered or unexported fields
}

Geographic coordinate in WGS84 reference system.

func (*FeatureCollection_Coordinate) Descriptor deprecated

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

Deprecated: Use FeatureCollection_Coordinate.ProtoReflect.Descriptor instead.

func (*FeatureCollection_Coordinate) GetLatitude

func (*FeatureCollection_Coordinate) GetLongitude

func (*FeatureCollection_Coordinate) ProtoMessage

func (*FeatureCollection_Coordinate) ProtoMessage()

func (*FeatureCollection_Coordinate) ProtoReflect

func (*FeatureCollection_Coordinate) Reset

func (x *FeatureCollection_Coordinate) Reset()

func (*FeatureCollection_Coordinate) String

type FeatureCollection_PoiFeature

type FeatureCollection_PoiFeature struct {

	// Name.
	Name *wrappers.StringValue `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Foreign names.
	ForeignNames []*wrappers.StringValue `protobuf:"bytes,2,rep,name=foreign_names,json=foreignNames,proto3" json:"foreign_names,omitempty"`
	// Geographic coordinate in WGS84 reference system.
	Coordinate *FeatureCollection_Coordinate `protobuf:"bytes,3,opt,name=coordinate,proto3" json:"coordinate,omitempty"`
	// Marker.
	Marker *FeatureCollection_PoiFeature_Marker `protobuf:"bytes,4,opt,name=marker,proto3" json:"marker,omitempty"`
	// contains filtered or unexported fields
}

Point of Interest feature with point geometry.

func (*FeatureCollection_PoiFeature) Descriptor deprecated

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

Deprecated: Use FeatureCollection_PoiFeature.ProtoReflect.Descriptor instead.

func (*FeatureCollection_PoiFeature) GetCoordinate

func (*FeatureCollection_PoiFeature) GetForeignNames added in v0.0.2

func (x *FeatureCollection_PoiFeature) GetForeignNames() []*wrappers.StringValue

func (*FeatureCollection_PoiFeature) GetMarker

func (*FeatureCollection_PoiFeature) GetName

func (*FeatureCollection_PoiFeature) ProtoMessage

func (*FeatureCollection_PoiFeature) ProtoMessage()

func (*FeatureCollection_PoiFeature) ProtoReflect

func (*FeatureCollection_PoiFeature) Reset

func (x *FeatureCollection_PoiFeature) Reset()

func (*FeatureCollection_PoiFeature) String

type FeatureCollection_PoiFeature_Marker

type FeatureCollection_PoiFeature_Marker struct {

	// Color as RGB in hex.
	Color *wrappers.StringValue `protobuf:"bytes,1,opt,name=color,proto3" json:"color,omitempty"`
	// Size.
	Size FeatureCollection_PoiFeature_Marker_Size `protobuf:"varint,2,opt,name=size,proto3,enum=geopb.FeatureCollection_PoiFeature_Marker_Size" json:"size,omitempty"`
	// contains filtered or unexported fields
}

Marker.

func (*FeatureCollection_PoiFeature_Marker) Descriptor deprecated

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

Deprecated: Use FeatureCollection_PoiFeature_Marker.ProtoReflect.Descriptor instead.

func (*FeatureCollection_PoiFeature_Marker) GetColor

func (*FeatureCollection_PoiFeature_Marker) GetSize

func (*FeatureCollection_PoiFeature_Marker) ProtoMessage

func (*FeatureCollection_PoiFeature_Marker) ProtoMessage()

func (*FeatureCollection_PoiFeature_Marker) ProtoReflect

func (*FeatureCollection_PoiFeature_Marker) Reset

func (*FeatureCollection_PoiFeature_Marker) String

type FeatureCollection_PoiFeature_Marker_Size

type FeatureCollection_PoiFeature_Marker_Size int32

Size.

const (
	FeatureCollection_PoiFeature_Marker_SIZE_UNSPECIFIED FeatureCollection_PoiFeature_Marker_Size = 0
	FeatureCollection_PoiFeature_Marker_SIZE_SMALL       FeatureCollection_PoiFeature_Marker_Size = 1
	FeatureCollection_PoiFeature_Marker_SIZE_MEDIUM      FeatureCollection_PoiFeature_Marker_Size = 2
	FeatureCollection_PoiFeature_Marker_SIZE_LARGE       FeatureCollection_PoiFeature_Marker_Size = 3
)

func (FeatureCollection_PoiFeature_Marker_Size) Descriptor

func (FeatureCollection_PoiFeature_Marker_Size) Enum

func (FeatureCollection_PoiFeature_Marker_Size) EnumDescriptor deprecated

func (FeatureCollection_PoiFeature_Marker_Size) EnumDescriptor() ([]byte, []int)

Deprecated: Use FeatureCollection_PoiFeature_Marker_Size.Descriptor instead.

func (FeatureCollection_PoiFeature_Marker_Size) Number

func (FeatureCollection_PoiFeature_Marker_Size) String

func (FeatureCollection_PoiFeature_Marker_Size) Type

type FeatureCollection_TrackFeature

type FeatureCollection_TrackFeature struct {

	// Name.
	Name *wrappers.StringValue `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Geographic coordinates in WGS84 reference system.
	Coordinates []*FeatureCollection_Coordinate `protobuf:"bytes,2,rep,name=coordinates,proto3" json:"coordinates,omitempty"`
	// Stroke.
	Stroke *FeatureCollection_TrackFeature_Stroke `protobuf:"bytes,3,opt,name=stroke,proto3" json:"stroke,omitempty"`
	// contains filtered or unexported fields
}

Track feature with linestring geometry.

func (*FeatureCollection_TrackFeature) Descriptor deprecated

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

Deprecated: Use FeatureCollection_TrackFeature.ProtoReflect.Descriptor instead.

func (*FeatureCollection_TrackFeature) GetCoordinates

func (*FeatureCollection_TrackFeature) GetName

func (*FeatureCollection_TrackFeature) GetStroke

func (*FeatureCollection_TrackFeature) ProtoMessage

func (*FeatureCollection_TrackFeature) ProtoMessage()

func (*FeatureCollection_TrackFeature) ProtoReflect

func (*FeatureCollection_TrackFeature) Reset

func (x *FeatureCollection_TrackFeature) Reset()

func (*FeatureCollection_TrackFeature) String

type FeatureCollection_TrackFeature_Stroke

type FeatureCollection_TrackFeature_Stroke struct {

	// Color as RGB in hex.
	Color *wrappers.StringValue `protobuf:"bytes,1,opt,name=color,proto3" json:"color,omitempty"`
	// Width.
	Width *wrappers.Int32Value `protobuf:"bytes,2,opt,name=width,proto3" json:"width,omitempty"`
	// contains filtered or unexported fields
}

Stroke.

func (*FeatureCollection_TrackFeature_Stroke) Descriptor deprecated

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

Deprecated: Use FeatureCollection_TrackFeature_Stroke.ProtoReflect.Descriptor instead.

func (*FeatureCollection_TrackFeature_Stroke) GetColor

func (*FeatureCollection_TrackFeature_Stroke) GetWidth

func (*FeatureCollection_TrackFeature_Stroke) ProtoMessage

func (*FeatureCollection_TrackFeature_Stroke) ProtoMessage()

func (*FeatureCollection_TrackFeature_Stroke) ProtoReflect

func (*FeatureCollection_TrackFeature_Stroke) Reset

func (*FeatureCollection_TrackFeature_Stroke) String

Jump to

Keyboard shortcuts

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