26 #ifndef XAPIAN_INCLUDED_GEOENCODE_H 27 #define XAPIAN_INCLUDED_GEOENCODE_H 47 encode(
double lat,
double lon, std::string & result);
64 decode(
const char * value,
size_t len,
double & lat_ref,
double & lon_ref);
80 decode(
const std::string & value,
double & lat_ref,
double & lon_ref)
153 bool decode(
const std::string & value,
154 double & lat_ref,
double & lon_ref)
const;
double max_lat
Maximum latitude in bounding box.
void decode(const char *value, size_t len, double &lat_ref, double &lon_ref)
Decode a coordinate from a buffer.
double min_lat
Minimum latitude in bounding box.
bool encode(double lat, double lon, std::string &result)
Encode a coordinate and append it to a string.
bool decode(const std::string &value, double &lat_ref, double &lon_ref) const
Decode a coordinate.
unsigned char start1
First byte of encoded form of coordinates with lon1.
double lon1
Longitude at western edge of bounding box.
unsigned char start2
First byte of encoded form of coordinates with lon2.
double lon2
Longitude at eastern edge of bounding box.
bool include_poles
True if either of the poles are included in the range.
bool discontinuous_longitude_range
Flag; true if the longitude range is discontinuous (ie, goes over the boundary at which longitudes wr...
A class for decoding coordinates within a bounding box.
DecoderWithBoundingBox(double lat1, double lon1, double lat2, double lon2)
Create a decoder with a bounding box.