Documentation
¶
Index ¶
- func NewRequest(requestString string, maxResults int) *requestBody
- type GeoCoder
- type GeoObject
- func (g GeoObject) Address() string
- func (g GeoObject) AdministrativeArea() string
- func (g GeoObject) Country() string
- func (g GeoObject) CountryCode() string
- func (g GeoObject) GeoPoint() (*GeoPoint, error)
- func (g GeoObject) Kind() string
- func (g GeoObject) Locality() string
- func (g GeoObject) Premise() string
- func (g GeoObject) Scope() *Scope
- func (g GeoObject) SubAdministrativeArea() string
- func (g GeoObject) Thoroughfare() string
- type GeoPoint
- type PremiseType
- type Scope
- type ScopeSize
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRequest ¶
NewRequest create a new request to server
Types ¶
type GeoCoder ¶
type GeoCoder struct {
// contains filtered or unexported fields
}
GeoCoder - base structure to work with package. It help you to store configuration between requests.
func (GeoCoder) FindOneFromScope ¶
FindOneFromScope send request to server and retern only one result placed in scope.
type GeoObject ¶
type GeoObject struct { MetaDataProperty metaDataPropertyType `xml:"metaDataProperty"` Description string `xml:"description"` Name string `xml:"name"` BoundedBy boundedByType `xml:"boundedBy"` Point pointType `xml:"Point"` }
func Find ¶
Find send request to server and retern results. Argument maxResults set maximum number of results.
func FindOneFromScope ¶
FindOneFromScope send request to server and retern only one result placed in scope.
func FindOneReverse ¶
FindOneReverse send reverse request to server and retern only one result.
func (GeoObject) AdministrativeArea ¶
AdministrativeArea return administrative area of GeoObject
func (GeoObject) CountryCode ¶
CountryCode return country code of GeoObject
func (GeoObject) SubAdministrativeArea ¶
SubAdministrativeArea return subadministrative area of GeoObject
func (GeoObject) Thoroughfare ¶
Thoroughfare return thoroughfare of GeoObject
type GeoPoint ¶
type GeoPoint struct {
// contains filtered or unexported fields
}
GeoPoint represent point on map.
func NewGeoPoint ¶
NewGeoPoint - create a new point. Function get as argument string with geo coordinates, for example "55.753514 37.621202". number 55.753514 is latitude, and 37.621202 is longitude.
type PremiseType ¶
type PremiseType struct {
PremiseNumber string `xml:"PremiseNumber"`
}