Annotation Interface QueryResponse


@Retention(RUNTIME) @Target({TYPE,ANNOTATION_TYPE}) public @interface QueryResponse
Annotation used to mark an object as a query response.

Allows for specifying the business/domain name() of the query and the version() of the query response. The fields are used to map an annotated-query to a QueryResponseMessage.

Since:
5.0.0
Author:
Simon Zambrovski
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    The business or domain name of the query response.
    The namespace or (bounded) context of the query response.
    The version of the query response.
  • Element Details

    • namespace

      String namespace
      The namespace or (bounded) context of the query response.

      Is used to define the QualifiedName.namespace() of a fully qualified name.

      Defaults to the package name of the annotated class.

      Returns:
      The namespace or (bounded) context of the query response.
      Default:
      ""
    • name

      String name
      The business or domain name of the query response.

      Is used to define the QualifiedName.localName() of a fully qualified name.

      Defaults to the simple name of the annotated class. Note that when an inner class is annotated, the simple name does not include the names of the enclosing classes.

      Returns:
      The business or domain name of the query response.
      Default:
      ""
    • version

      String version
      The version of the query response.

      Will typically be mapped to the MessageType.version(). Defaults to MessageType.DEFAULT_VERSION.

      Returns:
      The version of the query response.
      Default:
      "0.0.1"