Class IckleFilterAndConverter<K,​V>

    • Field Detail

      • matcherImplClass

        protected Class<? extends Matcher> matcherImplClass
        The implementation class of the Matcher component to lookup and use.
    • Constructor Detail

      • IckleFilterAndConverter

        public IckleFilterAndConverter​(String queryString,
                                       Map<String,​Object> namedParameters,
                                       Class<? extends Matcher> matcherImplClass)
    • Method Detail

      • injectDependencies

        protected void injectDependencies​(ComponentRegistry componentRegistry,
                                          QueryCache queryCache)
        Acquires a Matcher instance from the ComponentRegistry of the given Cache object.
      • getQueryString

        public String getQueryString()
      • getMatcher

        public Matcher getMatcher()
      • filterAndConvert

        public ObjectFilter.FilterResult filterAndConvert​(K key,
                                                          V value,
                                                          Metadata metadata)
        Description copied from interface: KeyValueFilterConverter
        Will both filter the entry and if passed subsequently convert the value to a new value. A returned value of null will symbolize the value not passing the filter, so ensure your conversion will not return null if you want this entry to be returned.
        Specified by:
        filterAndConvert in interface KeyValueFilterConverter<K,​V,​ObjectFilter.FilterResult>
        Parameters:
        key - The key of the entry to filter
        value - The value of the entry to filter and then convert
        metadata - The metadata attached to the entry
        Returns:
        The converted value or null if the filter didn't pass