Interface IJPQLQueryBuilder

    • Method Detail

      • buildStateObject

        JPQLQueryStateObject buildStateObject​(IManagedTypeProvider provider,
                                              java.lang.CharSequence jpqlQuery,
                                              boolean tolerant)
        Creates a state model representation of a JPQL query that can be edited.
        Parameters:
        provider - The provider of managed types
        jpqlQuery - The JPQL query to parse into a StateObject model
        tolerant - Determines if the parsing system should be tolerant, meaning if it should try to parse invalid or incomplete queries
        Returns:
        The root of the StateObject model that represents the edited form of the JPQL query
      • buildStateObject

        JPQLQueryStateObject buildStateObject​(IManagedTypeProvider provider,
                                              java.lang.CharSequence jpqlQuery,
                                              java.lang.String queryBNFId,
                                              boolean tolerant)
        Creates a state model representation of a JPQL query that can be edited.
        Parameters:
        provider - The provider of managed types
        jpqlQuery - The JPQL query to parse into a StateObject model
        queryBNFId - The unique identifier of the query BNF that will be used to parse the fragment
        tolerant - Determines if the parsing system should be tolerant, meaning if it should try to parse invalid or incomplete queries
        Returns:
        The root of the StateObject model that represents the edited form of the JPQL query
      • buildStateObject

        StateObject buildStateObject​(StateObject parent,
                                     java.lang.CharSequence jpqlFragment,
                                     java.lang.String queryBNFId)
        Creates a StateObject representation of the given JPQL fragment. In order to properly parse the fragment, the given unique identifier of the JPQLQueryBNF will determine how to parse it.

        It is possible the given JPQL fragment has more than one expression, in this case, parsing should stop at the first comma (x, y) or space (x y) where x and y are two separate expressions.

        Parameters:
        parent - The StateObject that will be the parent of the newly created model
        jpqlFragment - A portion of a JPQL query that will be parsed and the StateObject representation will be created
        queryBNFId - The unique identifier of the query BNF that will be used to parse the fragment
        Returns:
        The StateObject representation of the given JPQL fragment
      • buildStateObjectBuilder

        INewValueStateObjectBuilder buildStateObjectBuilder​(UpdateItemStateObject stateObject)
        Creates a builder that can create a new value expression programmatically. Once the expression is complete, INewValueStateObjectBuilder.commit() will push the result onto the given state object.
        Parameters:
        stateObject - The parent for which a new value expression can be created
        Returns:
        The builder of a new value expression
      • getGrammar

        JPQLGrammar getGrammar()
        Returns the JPQLGrammar that is associated with this builder.
        Returns:
        The JPQLGrammar that was used to parse the JPQL query or JPQL fragments