Uses of Interface
org.apache.cayenne.ObjectContext
Packages that use ObjectContext
Package
Description
-
Uses of ObjectContext in org.apache.cayenne
Fields in org.apache.cayenne declared as ObjectContextMethods in org.apache.cayenne that return ObjectContextModifier and TypeMethodDescriptionPersistent.getObjectContext()PersistentObject.getObjectContext()CayenneRuntime.newContext()Returns a new ObjectContext instance based on the runtime's main DataChannel.CayenneRuntime.newContext(DataChannel parentChannel) Deprecated, for removal: This API element is subject to removal in a future version.CayenneRuntime.newContext(ObjectContext parentContext) Returns a new ObjectContext nested in the specified parent context.Methods in org.apache.cayenne with parameters of type ObjectContextModifier and TypeMethodDescriptionCayenneRuntime.newContext(ObjectContext parentContext) Returns a new ObjectContext nested in the specified parent context.static <T extends Persistent>
TCayenne.objectForPK(ObjectContext context, Class<T> persistentObjectClass, int pk) Deprecated, for removal: This API element is subject to removal in a future version.static <T extends Persistent>
TCayenne.objectForPK(ObjectContext context, Class<T> persistentObjectClass, Object pk) Deprecated, for removal: This API element is subject to removal in a future version.static <T extends Persistent>
TCayenne.objectForPK(ObjectContext context, Class<T> persistentObjectClass, Map<String, ?> pk) Deprecated, for removal: This API element is subject to removal in a future version.static ObjectCayenne.objectForPK(ObjectContext context, String objEntityName, int pk) Deprecated, for removal: This API element is subject to removal in a future version.static ObjectCayenne.objectForPK(ObjectContext context, String objEntityName, Object pk) Deprecated, for removal: This API element is subject to removal in a future version.static ObjectCayenne.objectForPK(ObjectContext context, String objEntityName, Map<String, ?> pk) Deprecated, for removal: This API element is subject to removal in a future version.static ObjectCayenne.objectForPK(ObjectContext context, ObjectId id) Deprecated, for removal: This API element is subject to removal in a future version.static ObjectCayenne.objectForQuery(ObjectContext context, Query query) Deprecated, for removal: This API element is subject to removal in a future version.DataChannel.onIdQuery(ObjectContext context, ObjectId id) Resolves an object by id, returning it registered with the originating context.voidDataChannel.onInvalidate(ObjectContext context, Collection<ObjectId> objectIds) Invalidates objects with the given ids in this channel and all its parents, so that they are refetched on the next access.DataChannel.onQuery(ObjectContext context, Query query, boolean iteratedResult) Executes a query, using provided context to register persistent objects if query returns any objects.DataChannelQueryFilter.onQuery(ObjectContext originatingContext, Query query, boolean iteratedResult, DataChannelQueryFilterChain filterChain) DataChannelQueryFilterChain.onQuery(ObjectContext originatingContext, Query query, boolean iteratedResult) List<? extends Persistent> DataChannel.onRelationshipQuery(ObjectContext context, ObjectId sourceId, String relationshipName) Resolves objects related to a given object via a mapped relationship, returning them registered with the originating context.DataChannel.onSync(ObjectContext context, GraphDiff changes, int syncType) Processes synchronization request from a child ObjectContext, returning a GraphDiff that describes changes to objects made on the receiving end as a result of synchronization.DataChannelSyncFilter.onSync(ObjectContext originatingContext, GraphDiff changes, int syncType, DataChannelSyncFilterChain filterChain) DataChannelSyncFilterChain.onSync(ObjectContext originatingContext, GraphDiff changes, int syncType) voidPersistent.setObjectContext(ObjectContext objectContext) voidPersistentObject.setObjectContext(ObjectContext objectContext) -
Uses of ObjectContext in org.apache.cayenne.access
Classes in org.apache.cayenne.access that implement ObjectContextFields in org.apache.cayenne.access with type parameters of type ObjectContextModifier and TypeFieldDescriptionprotected static final ThreadLocal<ObjectContext> DataContext.threadObjectContextDeprecated, for removal: This API element is subject to removal in a future version.Methods in org.apache.cayenne.access that return ObjectContextModifier and TypeMethodDescriptionDataContextFactory.createContext(DataChannel parent) DataContextFactory.createContext(ObjectContext parent) ObjectContextFactory.createContext(DataChannel parent) Creates an ObjectContext attached to a provided channelObjectContextFactory.createContext(ObjectContext parent) Creates an ObjectContext nested in the provided parent context.static ObjectContextDataContext.getThreadObjectContext()Deprecated, for removal: This API element is subject to removal in a future version.if you are using thread context, you can create your own ThreadLocalMethods in org.apache.cayenne.access with parameters of type ObjectContextModifier and TypeMethodDescriptionstatic voidDataContext.bindThreadObjectContext(ObjectContext context) Deprecated, for removal: This API element is subject to removal in a future version.if you are using thread context, you can create your own ThreadLocalDataContextFactory.createContext(ObjectContext parent) ObjectContextFactory.createContext(ObjectContext parent) Creates an ObjectContext nested in the provided parent context.Map<?, ?> OptimisticLockException.getFreshSnapshot(ObjectContext context) Retrieves fresh snapshot for the failed row.DataContextChannel.onIdQuery(ObjectContext childContext, ObjectId id) DataDomain.onIdQuery(ObjectContext context, ObjectId id) Resolves an object from the snapshot cache, or from the database if the cache lookup fails.voidDataContextChannel.onInvalidate(ObjectContext childContext, Collection<ObjectId> objectIds) voidDataDomain.onInvalidate(ObjectContext originatingContext, Collection<ObjectId> objectIds) Evicts snapshots of the given objects from the snapshot cache, notifying all contexts that share it.DataContextChannel.onQuery(ObjectContext childContext, Query query, boolean iteratedResult) DataDomain.onQuery(ObjectContext context, Query query, boolean iteratedResult) Runs a query, returning all of its results as a list ofQueryResults.DataContextChannel.onRelationshipQuery(ObjectContext childContext, ObjectId sourceId, String relationshipName) DataDomain.onRelationshipQuery(ObjectContext context, ObjectId sourceId, String relationshipName) Resolves a relationship from the snapshot cache, or from the database if the cache lookup fails.DataContextChannel.onSync(ObjectContext childContext, GraphDiff changes, int syncType) DataDomain.onSync(ObjectContext context, GraphDiff changes, int syncType) Only handles commit-type synchronization, ignoring any other type. -
Uses of ObjectContext in org.apache.cayenne.commitlog
Methods in org.apache.cayenne.commitlog with parameters of type ObjectContextModifier and TypeMethodDescriptionvoidCommitLogListener.onPostCommit(ObjectContext originatingContext, ChangeMap changes) CommitLogFilter.onSync(ObjectContext originatingContext, GraphDiff beforeDiff, int syncType, DataChannelSyncFilterChain filterChain) -
Uses of ObjectContext in org.apache.cayenne.graph
Fields in org.apache.cayenne.graph declared as ObjectContextConstructors in org.apache.cayenne.graph with parameters of type ObjectContext -
Uses of ObjectContext in org.apache.cayenne.query
Methods in org.apache.cayenne.query with parameters of type ObjectContextModifier and TypeMethodDescriptiondefault ResultBatchIterator<T> Select.batchIterator(ObjectContext context, int size) Creates a ResultBatchIterator based on the provided context and batch size.int[]ProcedureCall.batchUpdate(ObjectContext context) Executes the procedure, returning the counts of its first update.ProcedureCall.call(ObjectContext context) Executes the procedure, returning all of its result sets, update counts and OUT parameters in the order they were produced.MappedExec.execute(ObjectContext context) Executes the query, returning all of its result sets, update counts and OUT parameters in the order they were produced.SQLExec.execute(ObjectContext context) Executes the query, returning all of its result sets and update counts in the order they were produced.default voidSelect.iterate(ObjectContext context, ResultIteratorCallback<T> callback) Creates a ResultIterator based on the provided context and passes it to a callback for processing.default ResultIterator<T> Select.iterator(ObjectContext context) Creates a ResultIterator based on the provided context.ProcedureCall.select(ObjectContext context) Executes the procedure, returning its first result set.Select.select(ObjectContext context) Selects objects using provided context.longObjectSelect.selectCount(ObjectContext context) Quick way to select count of recordsColumnSelect.selectFirst(ObjectContext context) MappedSelect.selectFirst(ObjectContext context) ObjectSelect.selectFirst(ObjectContext context) ProcedureQuery.selectFirst(ObjectContext context) Select.selectFirst(ObjectContext context) Selects a single object using provided context.SelectById.selectFirst(ObjectContext context) Deprecated, for removal: This API element is subject to removal in a future version.SQLSelect.selectFirst(ObjectContext context) SQLTemplate.selectFirst(ObjectContext context) default TSelect.selectOne(ObjectContext context) Selects a single object using provided context.int[]MappedExec.update(ObjectContext context) Executes the query, returning the counts of its first update result.intProcedureCall.update(ObjectContext context) Executes the procedure, returning the count of its first update.intSQLExec.update(ObjectContext context) int[]SQLExec.updateBatch(ObjectContext context) -
Uses of ObjectContext in org.apache.cayenne.tx
Methods in org.apache.cayenne.tx with parameters of type ObjectContextModifier and TypeMethodDescriptionTransactionFilter.onSync(ObjectContext originatingContext, GraphDiff changes, int syncType, DataChannelSyncFilterChain filterChain)
CayenneRuntime.newContext()orCayenneRuntime.newContext(ObjectContext)