diff --git a/DataStructures/ExtractorStructs.h b/DataStructures/ExtractorStructs.h index 0cbd7d7f4..864b05761 100644 --- a/DataStructures/ExtractorStructs.h +++ b/DataStructures/ExtractorStructs.h @@ -64,6 +64,13 @@ struct _Coordinate { bool isSet() const { return (INT_MIN != lat) && (INT_MIN != lon); } + inline bool isValid() const { + if(lat > 90*100000 || lat < -90*100000 || lon > 180*100000 || lon <-180*100000) { + return false; + } + return true; + } + }; inline ostream & operator<<(ostream & out, const _Coordinate & c){