Class FilterFactory


  • public final class FilterFactory
    extends java.lang.Object
    FilterFactory is a factory class which is intended to create different types of AISMessage filters. Currently it supports the creation of ExpressionFilters, which are AISMessage filters based on a grammar of free-text expressions, and DoubletFilters which rejects doublet messages inside a sliding time window.
    Author:
    Thomas Borg Salling
    See Also:
    ExpressionFilter
    • Constructor Summary

      Constructors 
      Constructor Description
      FilterFactory()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newDoubletFilter()  
      static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newDoubletFilter​(long duration, java.util.concurrent.TimeUnit unit)  
      static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newExpressionFilter​(java.lang.String expression)  
      • Methods inherited from class java.lang.Object

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

      • FilterFactory

        public FilterFactory()
    • Method Detail

      • newExpressionFilter

        public static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newExpressionFilter​(java.lang.String expression)
      • newDoubletFilter

        public static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newDoubletFilter()
      • newDoubletFilter

        public static java.util.function.Predicate<dk.tbsalling.aismessages.ais.messages.AISMessage> newDoubletFilter​(long duration,
                                                                                                                      java.util.concurrent.TimeUnit unit)