Class GenericSubscriptionQueryMessage<Q,I,U>

java.lang.Object
org.axonframework.messaging.MessageDecorator<Q>
org.axonframework.queryhandling.GenericQueryMessage<Q,I>
org.axonframework.queryhandling.GenericSubscriptionQueryMessage<Q,I,U>
Type Parameters:
Q - The type of payload expressing the query in this message
I - The type of initial response expected from this query
U - The type of incremental updates expected from this query
All Implemented Interfaces:
Serializable, Message<Q>, QueryMessage<Q,I>, SubscriptionQueryMessage<Q,I,U>

public class GenericSubscriptionQueryMessage<Q,I,U> extends GenericQueryMessage<Q,I> implements SubscriptionQueryMessage<Q,I,U>
Generic implementation of the SubscriptionQueryMessage. Unless explicitly provided, it assumes the queryName of the message is the fully qualified class name of the message's payload.
Since:
3.3
Author:
Allard Buijze
See Also:
  • Constructor Details

    • GenericSubscriptionQueryMessage

      public GenericSubscriptionQueryMessage(Q payload, ResponseType<I> responseType, ResponseType<U> updateResponseType)
      Initializes the message with the given payload, expected responseType and expected updateResponseType. The query name is set to the fully qualified class name of the payload.
      Parameters:
      payload - The payload expressing the query
      responseType - The expected response type
      updateResponseType - The expected type of incremental updates
    • GenericSubscriptionQueryMessage

      public GenericSubscriptionQueryMessage(Q payload, String queryName, ResponseType<I> responseType, ResponseType<U> updateResponseType)
      Initializes the message with the given payload, queryName, expected responseType and expected updateResponseType.
      Parameters:
      payload - The payload expressing the query
      queryName - The name identifying the query to execute
      responseType - The expected response type
      updateResponseType - The expected type of incremental updates
    • GenericSubscriptionQueryMessage

      public GenericSubscriptionQueryMessage(Message<Q> delegate, String queryName, ResponseType<I> responseType, ResponseType<U> updateResponseType)
      Initializes the message, using given delegate as the carrier of payload and metadata and given queryName, expected responseType and expected updateResponseType.
      Parameters:
      delegate - The message containing the payload and meta data for this message
      queryName - The name identifying the query to execute
      responseType - The expected response type
      updateResponseType - The expected type of incremental updates
  • Method Details