Class StoredProcedureQuery

  • All Implemented Interfaces:
    Serializable, org.datanucleus.ExecutionContextListener

    public class StoredProcedureQuery
    extends org.datanucleus.store.query.AbstractStoredProcedureQuery
    Query using a stored procedure.
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.datanucleus.store.query.AbstractStoredProcedureQuery

        org.datanucleus.store.query.AbstractStoredProcedureQuery.StoredProcedureParameter
      • Nested classes/interfaces inherited from class org.datanucleus.store.query.Query

        org.datanucleus.store.query.Query.QueryType, org.datanucleus.store.query.Query.SubqueryDefinition
    • Field Summary

      • Fields inherited from class org.datanucleus.store.query.AbstractStoredProcedureQuery

        outputParamValues, procedureName, resultClasses, resultMetaDatas, resultSetNumber, storedProcParams
      • Fields inherited from class org.datanucleus.store.query.Query

        candidateClass, candidateClassName, clr, compilation, ec, explicitParameters, explicitVariables, EXTENSION_CHECK_UNUSED_PARAMETERS, EXTENSION_CLOSE_RESULTS_AT_EC_CLOSE, EXTENSION_COMPILATION_CACHED, EXTENSION_COMPILE_OPTIMISE_VAR_THIS, EXTENSION_EVALUATE_IN_MEMORY, EXTENSION_EXCLUDE_SUBCLASSES, EXTENSION_FLUSH_BEFORE_EXECUTION, EXTENSION_JDOQL_ALLOW_ALL, EXTENSION_JDOQL_STRICT, EXTENSION_JPQL_ALLOW_RANGE, EXTENSION_JPQL_STRICT, EXTENSION_LOAD_RESULTS_AT_COMMIT, EXTENSION_QUERY_TYPE, EXTENSION_RESULT_CACHE_TYPE, EXTENSION_RESULT_CACHE_VALIDATE_OBJECTS, EXTENSION_RESULT_SIZE_METHOD, EXTENSION_RESULTS_CACHED, EXTENSION_SQL_ALLOW_ALL, EXTENSION_SQL_SYNTAX_CHECKS, EXTENSION_UPDATE_ALL_CANDIDATE_FIELDS, EXTENSION_USE_FETCH_PLAN, extensions, filter, from, fromInclNo, fromInclParam, grouping, having, ignoreCache, implicitParameters, imports, inputParameters, insertFields, insertSelectQuery, ordering, parameterNames, parsedImports, queryResults, range, result, resultClass, resultClassName, resultDistinct, storeMgr, subclasses, subqueries, tasks, toExclNo, toExclParam, type, unique, unmodifiable, update
    • Constructor Summary

      Constructors 
      Constructor Description
      StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr, org.datanucleus.ExecutionContext ec)  
      StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr, org.datanucleus.ExecutionContext ec, String procName)
      Constructs a new query instance for the specified stored procedure name.
      StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr, org.datanucleus.ExecutionContext ec, StoredProcedureQuery query)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void compileInternal​(Map parameterValues)  
      protected Object executeQuery​(Map parameters)
      Method to execute the actual query.
      Object getNextResults()  
      protected org.datanucleus.store.query.QueryResult getResultsForResultSet​(RDBMSStoreManager storeMgr, ResultSet rs, org.datanucleus.store.connection.ManagedConnection mconn)  
      int getUpdateCount()  
      boolean hasMoreResults()  
      protected Object performExecute​(Map parameters)  
      boolean processesRangeInDatastoreQuery()  
      • Methods inherited from class org.datanucleus.store.query.AbstractStoredProcedureQuery

        getLanguage, getOutputParameterValue, getOutputParameterValue, registerParameter, registerParameter, setCandidates, setCandidates, setResultClasses, setResultMetaData
      • Methods inherited from class org.datanucleus.store.query.Query

        addExtension, addSubquery, applyImplicitParameterValueToCompilation, applyImplicitParameterValueToSubqueries, assertIsModifiable, assertIsOpen, assertSupportsCancel, cancel, cancel, cancelTaskObject, checkForMissingParameters, checkParameterTypesAgainstCompilation, checkUnusedParameters, close, closeAll, compile, declareExplicitParameters, declareExplicitVariables, declareImports, deepFindSymbolForParameterInCompilation, deletePersistentAll, deletePersistentAll, deletePersistentAll, deregisterTask, discardCompiled, equals, execute, executeWithArray, executeWithMap, executionContextClosing, getBooleanExtensionProperty, getCandidateClass, getCandidateClassMetaData, getCandidateClassName, getCompilation, getDatastoreReadTimeoutMillis, getDatastoreWriteTimeoutMillis, getExecutionContext, getExplicitParametersDeclaration, getExplicitVariablesDeclaration, getExtension, getExtensions, getFetchPlan, getFilter, getFrom, getGrouping, getHaving, getIgnoreCache, getImplicitParameters, getImportsDeclaration, getInputParameters, getInsertFields, getInsertSelectQuery, getNativeQuery, getOrdering, getParameterMapForValues, getParsedImports, getQueryManager, getRange, getRangeFromIncl, getRangeFromInclParam, getRangeToExcl, getRangeToExclParam, getResult, getResultClass, getResultClassName, getResultDistinct, getSerializeRead, getStoreManager, getStringExtensionProperty, getSubqueryForVariable, getSupportedExtensions, getType, getUpdate, hashCode, hasSubqueryForVariable, isCompiled, isSubclasses, isUnique, isUnmodifiable, performDeletePersistentAll, prepareDatastore, registerTask, resolveClassDeclaration, setCacheResults, setCandidateClass, setCandidateClassName, setCompilation, setDatastoreReadTimeoutMillis, setDatastoreWriteTimeoutMillis, setExtensions, setFetchPlan, setFilter, setFrom, setGrouping, setHaving, setIgnoreCache, setImplicitParameter, setImplicitParameter, setInsertFields, setInsertSelectQuery, setOrdering, setRange, setRange, setResult, setResultClass, setResultClassName, setResultDistinct, setResultMetaData, setSerializeRead, setSubclasses, setType, setUnique, setUnmodifiable, setUpdate, shouldReturnSingleRow, supportsTimeout, useCaching, useFetchPlan, useResultsCaching
    • Constructor Detail

      • StoredProcedureQuery

        public StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr,
                                    org.datanucleus.ExecutionContext ec,
                                    StoredProcedureQuery query)
        Parameters:
        storeMgr - StoreManager
        ec - Execution Context
        query - Existing query to base this one
      • StoredProcedureQuery

        public StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr,
                                    org.datanucleus.ExecutionContext ec)
        Parameters:
        storeMgr - StoreManager
        ec - ExecutionContext
      • StoredProcedureQuery

        public StoredProcedureQuery​(org.datanucleus.store.StoreManager storeMgr,
                                    org.datanucleus.ExecutionContext ec,
                                    String procName)
        Constructs a new query instance for the specified stored procedure name.
        Parameters:
        storeMgr - StoreManager for this query
        ec - execution context
        procName - Name of the stored procedure
    • Method Detail

      • compileInternal

        protected void compileInternal​(Map parameterValues)
        Specified by:
        compileInternal in class org.datanucleus.store.query.Query
      • processesRangeInDatastoreQuery

        public boolean processesRangeInDatastoreQuery()
        Overrides:
        processesRangeInDatastoreQuery in class org.datanucleus.store.query.Query
      • executeQuery

        protected Object executeQuery​(Map parameters)
        Method to execute the actual query. Overrides the version in Query since that will handle result set processing and assumes that this is a normal query, which it isn't.
        Overrides:
        executeQuery in class org.datanucleus.store.query.Query
        Parameters:
        parameters - Map of parameter values keyed by parameter name
        Returns:
        Boolean, which is true if there is a result set, and false if an update count.
      • performExecute

        protected Object performExecute​(Map parameters)
        Specified by:
        performExecute in class org.datanucleus.store.query.Query
      • hasMoreResults

        public boolean hasMoreResults()
        Specified by:
        hasMoreResults in class org.datanucleus.store.query.AbstractStoredProcedureQuery
      • getUpdateCount

        public int getUpdateCount()
        Specified by:
        getUpdateCount in class org.datanucleus.store.query.AbstractStoredProcedureQuery
      • getNextResults

        public Object getNextResults()
        Specified by:
        getNextResults in class org.datanucleus.store.query.AbstractStoredProcedureQuery