Class ContinuousQuery


  • public class ContinuousQuery
    extends java.lang.Object
    Class to hold Object query and values, intended for notifications.
    • Constructor Detail

      • ContinuousQuery

        public ContinuousQuery​(QueryCommand command)
        Initializes a new instance of the ContinuousQuery class.
        Parameters:
        command - QueryCommand containing query text and values.
    • Method Detail

      • getQueryCommand

        public QueryCommand getQueryCommand()
        Gets the query command for the Continuous Query.
        Returns:
        The QueryCommand instance.
      • setQueryCommand

        public void setQueryCommand​(QueryCommand value)
        Sets the query command for the Continuous Query.
        Parameters:
        value - The QueryCommand instance.
      • addDataModificationListener

        public void addDataModificationListener​(QueryDataModificationListener listener,
                                                java.util.EnumSet<EventType> eventEnumSet,
                                                EventDataFilter datafilter)
                                         throws java.lang.IllegalArgumentException
        This method registers a custom listener that is fired on change in dataset of a Continuous Query.
        Parameters:
        listener - The listener that is invoked whenever there is a change in dataset of Continuous Query.
        eventEnumSet - Registers the listener with the specified event types in the enumset.
        datafilter - This enum is to describe when registering an event, upon raise how much data is retrieved from cache when the event is raised.
        Throws:
        java.lang.IllegalArgumentException
      • removeDataModificationListener

        public void removeDataModificationListener​(QueryDataModificationListener listener,
                                                   java.util.EnumSet<EventType> eventEnumSet)
                                            throws java.lang.IllegalArgumentException
        This method unregisters a custom listener that is fired on change in dataset of a Continuous Query.
        Parameters:
        listener - The listener that was registered with Continuous Query.
        eventEnumSet - Unregisters the listener with the specified event types in the enumset.
        Throws:
        java.lang.IllegalArgumentException
      • equals

        public boolean equals​(java.lang.Object obj)
        Compares two instances of ContinuousQuery for equality.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        obj - An instance of ContinuousQuery.
        Returns:
        True, if both ContinuousQuery instances are the same. Otherwise false.
        See Also:
        hashCode(), HashMap
      • hashCode

        public int hashCode()
        Computes the hash code for the current object. This method is supported for the benefit of hash tables such as those provided by HashMap.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        Hash code for the current object.
        See Also:
        Object.equals(java.lang.Object), System.identityHashCode(java.lang.Object)