Class SubstringFilter

    • Method Detail

      • startsWith

        public static SubstringFilter startsWith​(String attribute,
                                                 String... parts)
        Create a SubstringFilter based on the filter elements. Such a filter has a form like Attribute=initial*([any]*)*. We don't expect any final String.
        Parameters:
        attribute - The AttributeType for this filter
        parts - The parts that are the initial string and zero to N any strings
        Returns:
        An instance of a SubstringFilter
      • endsWith

        public static SubstringFilter endsWith​(String attribute,
                                               String... parts)
        Create a SubstringFilter based on the filter elements. Such a filter has a form like Attribute=*([any]*)*final. We don't expect any initial String.
        Parameters:
        attribute - The AttributeType for this filter
        parts - The parts that are zero to N any strings followed by a final string
        Returns:
        An instance of a SubstringFilter
      • contains

        public static SubstringFilter contains​(String attribute,
                                               String... parts)
        Create a SubstringFilter based on the filter elements. Such a filter has a form like Attribute=*([any]*)*. We don't expect any initialor final Strings.
        Parameters:
        attribute - The AttributeType for this filter
        parts - The parts that are zero to N any strings with no initial nor final Strings
        Returns:
        An instance of a SubstringFilter
      • substring

        public static SubstringFilter substring​(String attribute,
                                                String... parts)
        Create a SubstringFilter based on the filter elements. Such a filter has a form like Attribute=initial*([any]*)*final.
        Parameters:
        attribute - The AttributeType for this filter
        parts - The parts that are zero to N any strings starting with an initial String and followed by a final string
        Returns:
        An instance of a SubstringFilter
      • build

        public StringBuilder build​(StringBuilder builder)
        Constructs a String representation of a Filter
        Parameters:
        builder - The current buffer containing the on going representation of the filter
        Returns:
        The constructed String