Class DMSFilter

  • All Implemented Interfaces:
    GeocoordMatchFilter

    public class DMSFilter
    extends java.lang.Object
    implements GeocoordMatchFilter
    DMS Filters include ignoring these patterns: dd-dd-dd HH:MM:ss (where dd-dd-dd HH-MM-ss would be a valid coordinate as the field separators for lat/lon are the same). Assumption: Date fields are separated by / and -; Time fields are separated by : So if you have a lat/lon with a [date] [time] pattern it is most likely not a [lat] [lon] pattern. As of 2012 Fall -- DMS-02 is very open ended pattern and matches parts of dates
    Author:
    ubaldino
    • Field Summary

      Fields 
      Modifier and Type Field Description
      java.util.List<java.text.DateFormat> general_dates  
      static java.lang.String[] general_formats  
    • Constructor Summary

      Constructors 
      Constructor Description
      DMSFilter()  
    • Method Summary

      Modifier and Type Method Description
      boolean pass​(GeocoordMatch m)
      pass a match
      boolean stop​(GeocoordMatch m)
      stop a match if it is a bad DMS pattern, e.g., date or date/time.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • general_formats

        public static final java.lang.String[] general_formats
      • general_dates

        public java.util.List<java.text.DateFormat> general_dates
    • Constructor Detail

      • DMSFilter

        public DMSFilter()
    • Method Detail

      • pass

        public boolean pass​(GeocoordMatch m)
        pass a match
        Specified by:
        pass in interface GeocoordMatchFilter
        Parameters:
        m - coord match
        Returns:
        true if match is not filtered
      • stop

        public boolean stop​(GeocoordMatch m)
        stop a match if it is a bad DMS pattern, e.g., date or date/time.
        Specified by:
        stop in interface GeocoordMatchFilter
        Parameters:
        m - coord match
        Returns:
        true if match is filtered out