Record Class QueryCapabilities

java.lang.Object
java.lang.Record
com.axelor.meta.query.dataset.QueryCapabilities
Record Components:
serverSort - whether the source can sort server-side, so sorting is not limited to the returned window
querySummary - whether the source can produce query-scope aggregates over the filtered set
fullExport - whether the source can export beyond the returned window

public record QueryCapabilities(boolean serverSort, boolean querySummary, boolean fullExport) extends Record
What a query source supports, so a client disables what is unsupported instead of inventing an endpoint or approximating an answer.

This is what keeps a page total from being captioned as an overall total: a client that knows querySummary is false knows the total it can compute is a page total.

  • Constructor Summary

    Constructors
    Constructor
    Description
    QueryCapabilities(boolean serverSort, boolean querySummary, boolean fullExport)
    Creates an instance of a QueryCapabilities record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    boolean
    Returns the value of the fullExport record component.
    final int
    Returns a hash code value for this object.
    boolean
    Returns the value of the querySummary record component.
    boolean
    Returns the value of the serverSort record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • QueryCapabilities

      public QueryCapabilities(boolean serverSort, boolean querySummary, boolean fullExport)
      Creates an instance of a QueryCapabilities record class.
      Parameters:
      serverSort - the value for the serverSort record component
      querySummary - the value for the querySummary record component
      fullExport - the value for the fullExport record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • serverSort

      public boolean serverSort()
      Returns the value of the serverSort record component.
      Returns:
      the value of the serverSort record component
    • querySummary

      public boolean querySummary()
      Returns the value of the querySummary record component.
      Returns:
      the value of the querySummary record component
    • fullExport

      public boolean fullExport()
      Returns the value of the fullExport record component.
      Returns:
      the value of the fullExport record component