org.apache.olingo.odata2.jpa.processor.api.jpql

## Interface JPQLSelectContextView

- All Superinterfaces:
    JPQLContextView
  All Known Subinterfaces:
    JPQLJoinContextView

      public interface JPQLSelectContextView
      extends JPQLContextView

  The interface provide a view on JPQL select context.The interface provides methods for accessing the clauses of a JPQL SELECT statement like "SELECT", "ORDERBY", "WHERE". The clauses are built from OData read entity set request views. The clauses thus built can be used for building JPQL Statements.
  See Also:
    `JPQLStatement`

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getOrderByCollection()` The method returns an JPQL ORDERBY clause.
    `Map<String,Map<Integer,Object>>` | `getParameterizedQueryMap()` Key in the map is the JPA query and value is a map with key being index and value being parameter value
    `String` | `getSelectExpression()` The method returns a JPQL SELECT clause.
    `String` | `getWhereExpression()` The method returns a JPQL WHERE condition as string.

    - ### Methods inherited from interface org.apache.olingo.odata2.jpa.processor.api.jpql.JPQLContextView

      `getJPAEntityAlias, getJPAEntityName, getJPQLStatement, getType, setJPQLStatement`

- - ### Method Detail

    - #### getSelectExpression

          String getSelectExpression()

      The method returns a JPQL SELECT clause. The SELECT clause is built from $select OData system Query option.
      Returns:
        a String representing a SELECT clause in JPQL

    - #### getOrderByCollection

          String getOrderByCollection()

      The method returns an JPQL ORDERBY clause. The ORDERBY clause is built from $orderby OData system query option. The hash map contains
      1. Key - JPA Entity Property name to be ordered
      2. Value - Sort Order in JPQL (desc,asc)
      in the order based on the expression specified (accessible with `Map.entrySet(..)`). https://issues.apache.org/jira/browse/OLINGO-606
      Returns:
        an ordered map of (JPA Property Name,Sort Order)

    - #### getWhereExpression

          String getWhereExpression()

      The method returns a JPQL WHERE condition as string. The WHERE condition can be built from $filter OData System Query Option and/or Key predicates of an OData Request.
      Returns:
        a String representing a WHERE condition in JPQL

    - #### getParameterizedQueryMap

          Map<String,Map<Integer,Object>> getParameterizedQueryMap()

      Key in the map is the JPA query and value is a map with key being index and value being parameter value
      Returns:
        a map of String and value is another map of Integer and Object

Copyright © 2013-2023 The Apache Software Foundation. All Rights Reserved.