Record Class RenderedQuery.QueryTemplate

java.lang.Object
java.lang.Record
com.axelor.meta.query.render.RenderedQuery.QueryTemplate
Enclosing class:
RenderedQuery

public static record RenderedQuery.QueryTemplate(String selectClause, String fromClause, String joinsClause, String whereClause, String groupByClause, String havingClause, String orderByClause) extends Record
  • Constructor Details

    • QueryTemplate

      public QueryTemplate(String selectClause, String fromClause, String joinsClause, String whereClause, String groupByClause, String havingClause, String orderByClause)
      Creates an instance of a QueryTemplate record class.
      Parameters:
      selectClause - the value for the selectClause record component
      fromClause - the value for the fromClause record component
      joinsClause - the value for the joinsClause record component
      whereClause - the value for the whereClause record component
      groupByClause - the value for the groupByClause record component
      havingClause - the value for the havingClause record component
      orderByClause - the value for the orderByClause record component
  • Method Details

    • toJpql

      public String toJpql()
    • toJpql

      public String toJpql(String extraPredicate)
    • 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 Objects::equals(Object,Object).
      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.
    • selectClause

      public String selectClause()
      Returns the value of the selectClause record component.
      Returns:
      the value of the selectClause record component
    • fromClause

      public String fromClause()
      Returns the value of the fromClause record component.
      Returns:
      the value of the fromClause record component
    • joinsClause

      public String joinsClause()
      Returns the value of the joinsClause record component.
      Returns:
      the value of the joinsClause record component
    • whereClause

      public String whereClause()
      Returns the value of the whereClause record component.
      Returns:
      the value of the whereClause record component
    • groupByClause

      public String groupByClause()
      Returns the value of the groupByClause record component.
      Returns:
      the value of the groupByClause record component
    • havingClause

      public String havingClause()
      Returns the value of the havingClause record component.
      Returns:
      the value of the havingClause record component
    • orderByClause

      public String orderByClause()
      Returns the value of the orderByClause record component.
      Returns:
      the value of the orderByClause record component