Class UnimplementedFilterDao

  • All Implemented Interfaces:
    FilterDao

    public abstract class UnimplementedFilterDao
    extends java.lang.Object
    implements FilterDao
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void flushActiveIpAddressListCache()  
      java.util.List<java.net.InetAddress> getActiveIPAddressList​(java.lang.String rule)
      Get the (non-deleted) IP addresses that match the specified rule.
      java.util.List<java.net.InetAddress> getIPAddressList​(java.lang.String rule)
      Get the IP addresses (including deleted) that match the specified rule.
      java.util.Map<java.net.InetAddress,​java.util.Set<java.lang.String>> getIPAddressServiceMap​(java.lang.String rule)
      getIPServiceMap
      java.util.Map<java.lang.Integer,​java.util.Map<java.net.InetAddress,​java.util.Set<java.lang.String>>> getNodeIPAddressServiceMap​(java.lang.String rule)
      Retrieve a mapping of IP-services scoped by node that match the given rule.
      java.util.SortedMap<java.lang.Integer,​java.lang.String> getNodeMap​(java.lang.String rule)
      This method returns a map of all node IDs and node labels that match the rule that is passed in, sorted by node ID.
      boolean isRuleMatching​(java.lang.String rule)
      Does this rule match anything in the database? In particular, does it return at least one record from the database?
      boolean isValid​(java.lang.String addr, java.lang.String rule)
      isValid
      void validateRule​(java.lang.String rule)
      validateRule
      • Methods inherited from class java.lang.Object

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

      • UnimplementedFilterDao

        public UnimplementedFilterDao()
    • Method Detail

      • getNodeMap

        public java.util.SortedMap<java.lang.Integer,​java.lang.String> getNodeMap​(java.lang.String rule)
                                                                                 throws FilterParseException
        Description copied from interface: FilterDao
        This method returns a map of all node IDs and node labels that match the rule that is passed in, sorted by node ID.
        Specified by:
        getNodeMap in interface FilterDao
        Parameters:
        rule - an expression rule to be parsed and executed.
        Returns:
        SortedMap containing all node IDs and node labels selected by the rule.
        Throws:
        FilterParseException - if a rule is syntactically incorrect or failed in executing the SQL statement
      • getIPAddressServiceMap

        public java.util.Map<java.net.InetAddress,​java.util.Set<java.lang.String>> getIPAddressServiceMap​(java.lang.String rule)
                                                                                                         throws FilterParseException
        Description copied from interface: FilterDao

        getIPServiceMap

        Specified by:
        getIPAddressServiceMap in interface FilterDao
        Parameters:
        rule - a String object.
        Returns:
        a Map object.
        Throws:
        FilterParseException - if any.
      • getNodeIPAddressServiceMap

        public java.util.Map<java.lang.Integer,​java.util.Map<java.net.InetAddress,​java.util.Set<java.lang.String>>> getNodeIPAddressServiceMap​(java.lang.String rule)
                                                                                                                                                    throws FilterParseException
        Description copied from interface: FilterDao
        Retrieve a mapping of IP-services scoped by node that match the given rule.
        Specified by:
        getNodeIPAddressServiceMap in interface FilterDao
        Parameters:
        rule - filter rule to evaluate
        Returns:
        map of IP-services
        Throws:
        FilterParseException - if the rule is invalid
      • getActiveIPAddressList

        public java.util.List<java.net.InetAddress> getActiveIPAddressList​(java.lang.String rule)
                                                                    throws FilterParseException
        Description copied from interface: FilterDao
        Get the (non-deleted) IP addresses that match the specified rule.
        Specified by:
        getActiveIPAddressList in interface FilterDao
        Parameters:
        rule - the filter rule
        Returns:
        a List of IP addresses.
        Throws:
        FilterParseException - if a rule is syntactically incorrect or failed in executing the SQL statement.
      • getIPAddressList

        public java.util.List<java.net.InetAddress> getIPAddressList​(java.lang.String rule)
                                                              throws FilterParseException
        Description copied from interface: FilterDao
        Get the IP addresses (including deleted) that match the specified rule.
        Specified by:
        getIPAddressList in interface FilterDao
        Parameters:
        rule - the filter rule
        Returns:
        a List of IP addresses.
        Throws:
        FilterParseException - if a rule is syntactically incorrect or failed in executing the SQL statement.
      • isValid

        public boolean isValid​(java.lang.String addr,
                               java.lang.String rule)
                        throws FilterParseException
        Description copied from interface: FilterDao

        isValid

        Specified by:
        isValid in interface FilterDao
        Parameters:
        addr - a String object.
        rule - a String object.
        Returns:
        a boolean.
        Throws:
        FilterParseException - if any.
      • isRuleMatching

        public boolean isRuleMatching​(java.lang.String rule)
                               throws FilterParseException
        Description copied from interface: FilterDao
        Does this rule match anything in the database? In particular, does it return at least one record from the database?
        Specified by:
        isRuleMatching in interface FilterDao
        Parameters:
        rule - rule to match on
        Returns:
        true if there is at least one match, false otherwise
        Throws:
        FilterParseException - if any.