Class AbstractSpaceProxy
java.lang.Object
com.gigaspaces.internal.client.spaceproxy.AbstractSpaceProxy
- All Implemented Interfaces:
IPojoSpace,ISpaceProxy,SecuredService,IDotnetProxyAssociated,ActionMaker,IJSpace,JavaSpace
- Direct Known Subclasses:
AbstractDirectSpaceProxy,AbstractSpaceCacheContainer
A common base class for most space proxies. Implements all the space operations and calling
the appropriate Listener using the
AbstractSpaceProxyActionManager. Extended classes
should initialize the listeners in the action manager.- Author:
- GigaSpaces
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaggregate(Object template, AggregationSet aggregationSet, Transaction txn, int readModifiers) voidapplyNotifyInfoDefaults(NotifyInfo notifyInfo) asyncAddIndexes(String typeName, SpaceIndex[] indexes, AsyncFutureListener<AddTypeIndexesResult> listener) <T> Future<ChangeResult<T>>asyncChange(Object template, ChangeSet changeSet, Transaction txn, long timeout, ChangeModifiers modifiers, AsyncFutureListener<ChangeResult<T>> listener) AsyncFuture<?>asyncRead(Object template, Transaction txn, long timeout, int modifiers, AsyncFutureListener listener) Internal methods only.AsyncFuture<?>asyncTake(Object template, Transaction txn, long timeout, int modifiers, AsyncFutureListener listener) Internal methods only.<T> ChangeResult<T>change(Object template, ChangeSet changeSet, Transaction txn, long timeout, ChangeModifiers modifiers) Change entry in spacebooleanvoidclear(Object template, Transaction txn) intclear(Object template, Transaction txn, int modifiers) intcount(Object template, Transaction txn) intcount(Object template, Transaction txn, int modifiers) protected abstract AbstractSpaceProxyActionManager<?>voidDrops all Class's entries and all its templates from this Space instance.execute(SpaceTask task, Object routing, Transaction tx, AsyncFutureListener listener) Executes a task on a single space.execute(SpaceTask task, Object routing, Transaction tx, AsyncFutureListener listener, Map<String, byte[]> classes) Executes a task on a single space.intlongGets an object representing the space health statusgetTypeDescriptor(String typeName) booleanbooleanbooleanbooleanbooleannotify(Entry template, Transaction txn, RemoteEventListener listener, long lease, MarshalledObject handback) When entries are written that match this template notify the givenlistenerwith aRemoteEventthat includes thehandbackobject.voidping()Checks whether the space is alive and accessible.read(Object template, Transaction txn, long timeout) read(Object template, Transaction txn, long timeout, int modifiers) read(Object template, Transaction txn, long timeout, int modifiers, boolean ifExists) read(Entry template, Transaction txn, long timeout) Read any matching entry from the space, blocking until one exists.readById(ReadTakeProxyActionInfo actionInfo) readById(String className, Object id, Object routing, Transaction txn, long timeout, int modifiers, boolean ifExists, QueryResultTypeInternal resultType, String[] projections) Object[]readByIds(ReadTakeByIdsProxyActionInfo actionInfo, boolean returnPackets) Object[]readByIds(String className, Object[] ids, Object[] routings, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) Object[]readByIds(String className, Object[] ids, Object routing, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) readByUid(String uid, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPacket) readEntriesUids(ITemplatePacket template, Transaction transaction, int entriesLimit, int modifiers) Read entries UIDs from space.readIfExists(Object template, Transaction txn, long timeout) readIfExists(Object template, Transaction txn, long timeout, int modifiers) readIfExists(Entry template, Transaction txn, long timeout) Read any matching entry from the space, returningnullif there is currently is none.Object[]readMultiple(Object template, Transaction txn, int maxEntries) Object[]readMultiple(Object template, Transaction txn, int maxEntries, int modifiers) Object[]readMultiple(Object template, Transaction txn, int maxEntries, int modifiers, boolean returnOnlyUids) Object[]readMultiple(Object template, Transaction txn, long timeout, int maxEntries, int minEntriesToWaitFor, int modifiers, boolean returnOnlyUids, boolean ifExist) voidregisterTypeDescriptor(ITypeDesc typeDesc) registerTypeDescriptor(Class<?> type) voidsetAppDomainId(int appDomainId) associate this object to the specified AppDomain idvoidsetDotnetProxyHandleId(long handleId) Sets a dotnet proxy handle id<T> ISpaceQuery<T>The process of serializing an entry for transmission to a JavaSpaces service will be identical if the same entry is used twice.take(Object template, Transaction txn, long timeout) take(Object template, Transaction txn, long timeout, int modifiers) take(Object template, Transaction txn, long timeout, int modifiers, boolean ifExists) take(Entry template, Transaction txn, long timeout) Take a matching entry from the space, waiting until one exists.takeById(ReadTakeProxyActionInfo actionInfo) takeById(String className, Object id, Object routing, int version, Transaction txn, long timeout, int modifiers, boolean ifExists, QueryResultTypeInternal resultType, String[] projections) Object[]takeByIds(ReadTakeByIdsProxyActionInfo actionInfo, boolean returnPackets) Object[]takeByIds(String className, Object[] ids, Object[] routings, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) Object[]takeByIds(String className, Object[] ids, Object routing, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) takeByUid(String uid, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPacket) takeIfExists(Object template, Transaction txn, long timeout) takeIfExists(Object template, Transaction txn, long timeout, int modifiers) takeIfExists(Entry template, Transaction txn, long timeout) Take a matching entry from the space, returningnullif there is currently is none.Object[]takeMultiple(Object template, Transaction txn, int maxEntries) Object[]takeMultiple(Object template, Transaction txn, int maxEntries, int modifiers) Object[]takeMultiple(Object template, Transaction txn, int maxEntries, int modifiers, boolean returnOnlyUids) Object[]takeMultiple(Object template, Transaction txn, long timeout, int maxEntries, int minEntriesToWaitFor, int modifiers, boolean returnOnlyUids, boolean ifExist) voidunregisterTypeDescriptor(String typeName) update(Object updatedEntry, Transaction transaction, long lease, long timeout) update(Object entry, Transaction txn, long lease, long timeout, int modifiers) Object[]updateMultiple(Object[] entries, Transaction txn, long[] leases) Object[]updateMultiple(Object[] entries, Transaction txn, long[] leases, int modifiers) LeaseContext<?>write(Object entry, Transaction txn, long lease) LeaseContext<?>write(Object entry, Transaction txn, long lease, long timeout, int modifiers) write(Entry entry, Transaction txn, long lease) Write a new entry into the space.LeaseContext<?>[]writeMultiple(Object[] objects, Transaction txn, long lease) LeaseContext<?>[]writeMultiple(Object[] objects, Transaction txn, long[] leases, int modifiers) LeaseContext<?>[]writeMultiple(Object[] objects, Transaction txn, long lease, int modifiers) LeaseContext<?>[]writeMultiple(Object[] objects, Transaction txn, long lease, long[] leases, int modifiers) LeaseContext<?>[]writeMultiple(Object[] objects, Transaction txn, long lease, long[] leases, long timeout, int modifiers) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.j_spaces.core.client.ActionMaker
setActionListenerMethods inherited from interface com.j_spaces.core.IJSpace
getAdmin, getCacheTypeName, getDirectProxy, getFinderURL, getName, getReadModifiers, getReferentUuid, getUpdateModifiers, getURL, isEmbedded, isFifo, isOptimisticLockingEnabled, isSecured, isStartedWithinGSC, setFifo, setOptimisticLocking, setReadModifiers, setUpdateModifiersMethods inherited from interface com.gigaspaces.internal.client.spaceproxy.ISpaceProxy
close, createNewOperationID, getContextTransaction, getNotificationsDirectProxy, getPrivilegedAdmin, initWriteModifiers, isClustered, loadRemoteClass, replaceContextTransaction, replaceContextTransactionMethods inherited from interface com.gigaspaces.security.service.SecuredService
isServiceSecured, login
-
Constructor Details
-
AbstractSpaceProxy
protected AbstractSpaceProxy()
-
-
Method Details
-
createActionManager
-
getContainerName
- Specified by:
getContainerNamein interfaceIJSpace
-
write
public Lease write(Entry entry, Transaction txn, long lease) throws TransactionException, RemoteException Description copied from interface:JavaSpaceWrite a new entry into the space. Equivalent to callingIPojoSpace.write(Object, Transaction, long, long, int)withUpdateModifiers.WRITE_ONLY.- Specified by:
writein interfaceJavaSpace- Parameters:
entry- the entry to writetxn- the transaction object, if any, under which to perform the writelease- the requested lease time, in milliseconds- Returns:
- a lease for the entry that was written to the space
- Throws:
TransactionException- if a transaction error occursRemoteException- if a communication error occurs
-
read
public Entry read(Entry template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException Description copied from interface:JavaSpaceRead any matching entry from the space, blocking until one exists. Returnnullif the timeout expires.- Specified by:
readin interfaceJavaSpace- Parameters:
template- The template used for matching. Matching is done againsttmplwithnullfields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The transaction (if any) under which to work.timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout ofNO_WAITmeans to wait no time at all; this is equivalent to a wait of zero.- Returns:
- a copy of the entry read from the space
- Throws:
UnusableEntryException- if any serialized field of the entry being read cannot be deserialized for any reasonTransactionException- if a transaction error occursInterruptedException- if the thread in which the read occurs is interruptedRemoteException- if a communication error occurs
-
readIfExists
public Entry readIfExists(Entry template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException Description copied from interface:JavaSpaceRead any matching entry from the space, returningnullif there is currently is none. Matching and timeouts are done as inread, except that blocking in this call is done only if necessary to wait for transactional state to settle.- Specified by:
readIfExistsin interfaceJavaSpace- Parameters:
template- The template used for matching. Matching is done againsttmplwithnullfields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The transaction (if any) under which to work.timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout ofNO_WAITmeans to wait no time at all; this is equivalent to a wait of zero.- Returns:
- a copy of the entry read from the space
- Throws:
UnusableEntryException- if any serialized field of the entry being read cannot be deserialized for any reasonTransactionException- if a transaction error occursInterruptedException- if the thread in which the read occurs is interruptedRemoteException- if a communication error occurs- See Also:
-
take
public Entry take(Entry template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException Description copied from interface:JavaSpaceTake a matching entry from the space, waiting until one exists. Matching is and timeout done as forread.- Specified by:
takein interfaceJavaSpace- Parameters:
template- The template used for matching. Matching is done againsttmplwithnullfields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The transaction (if any) under which to work.timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout ofNO_WAITmeans to wait no time at all; this is equivalent to a wait of zero.- Returns:
- the entry taken from the space
- Throws:
UnusableEntryException- if any serialized field of the entry being read cannot be deserialized for any reasonTransactionException- if a transaction error occursInterruptedException- if the thread in which the take occurs is interruptedRemoteException- if a communication error occurs- See Also:
-
takeIfExists
public Entry takeIfExists(Entry template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException Description copied from interface:JavaSpaceTake a matching entry from the space, returningnullif there is currently is none. Matching is and timeout done as forread, except that blocking in this call is done only if necessary to wait for transactional state to settle.- Specified by:
takeIfExistsin interfaceJavaSpace- Parameters:
template- The template used for matching. Matching is done againsttmplwithnullfields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The transaction (if any) under which to work.timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout ofNO_WAITmeans to wait no time at all; this is equivalent to a wait of zero.- Returns:
- the entry taken from the space
- Throws:
UnusableEntryException- if any serialized field of the entry being read cannot be deserialized for any reasonTransactionException- if a transaction error occursInterruptedException- if the thread in which the take occurs is interruptedRemoteException- if a communication error occurs- See Also:
-
notify
public EventRegistration notify(Entry template, Transaction txn, RemoteEventListener listener, long lease, MarshalledObject handback) throws TransactionException, RemoteException Description copied from interface:JavaSpaceWhen entries are written that match this template notify the givenlistenerwith aRemoteEventthat includes thehandbackobject. Matching is done as forread.- Specified by:
notifyin interfaceJavaSpace- Parameters:
template- The template used for matching. Matching is done againsttmplwithnullfields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The transaction (if any) under which to work.listener- The remote event listener to notify.lease- the requested lease time, in millisecondshandback- An object to send to the listener as part of the event notification.- Returns:
- the event registration to the the registrant
- Throws:
TransactionException- if a transaction error occursRemoteException- if a communication error occurs- See Also:
-
snapshot
Description copied from interface:JavaSpaceThe process of serializing an entry for transmission to a JavaSpaces service will be identical if the same entry is used twice. This is most likely to be an issue with templates that are used repeatedly to search for entries withreadortake. The client-side implementations ofreadandtakecannot reasonably avoid this duplicated effort, since they have no efficient way of checking whether the same template is being used without intervening modification. Thesnapshotmethod gives the JavaSpaces service implementor a way to reduce the impact of repeated use of the same entry. Invokingsnapshotwith anEntrywill return anotherEntryobject that contains a snapshot of the original entry. Using the returned snapshot entry is equivalent to using the unmodified original entry in all operations on the same JavaSpaces service. Modifications to the original entry will not affect the snapshot. You cansnapshotanulltemplate;snapshotmay or may not return null given anulltemplate. The entry returned fromsnapshotwill be guaranteed equivalent to the original unmodified object only when used with the space. Using the snapshot with any other JavaSpaces service will generate anIllegalArgumentExceptionunless the other space can use it because of knowledge about the JavaSpaces service that generated the snapshot. The snapshot will be a different object from the original, may or may not have the same hash code, andequalsmay or may not returntruewhen invoked with the original object, even if the original object is unmodified. A snapshot is guaranteed to work only within the virtual machine in which it was generated. If a snapshot is passed to another virtual machine (for example, in a parameter of an RMI call), using it--even with the same JavaSpaces service--may generate anIllegalArgumentException.- Specified by:
snapshotin interfaceJavaSpace- Parameters:
e- the entry to take a snapshot of.- Returns:
- a snapshot of the entry.
- Throws:
RemoteException- if a communication error occurs
-
getTypeDescriptor
- Specified by:
getTypeDescriptorin interfaceISpaceProxy- Throws:
RemoteException
-
registerTypeDescriptor
- Specified by:
registerTypeDescriptorin interfaceISpaceProxy- Throws:
RemoteException
-
registerTypeDescriptor
- Specified by:
registerTypeDescriptorin interfaceISpaceProxy- Throws:
RemoteException
-
asyncAddIndexes
public AsyncFuture<AddTypeIndexesResult> asyncAddIndexes(String typeName, SpaceIndex[] indexes, AsyncFutureListener<AddTypeIndexesResult> listener) throws RemoteException - Specified by:
asyncAddIndexesin interfaceISpaceProxy- Throws:
RemoteException
-
dropClass
Description copied from interface:IJSpaceDrops all Class's entries and all its templates from this Space instance. Calling this method will remove all internal metadata related to this class stored in the Space. When using persistent spaced the relevant RDBMS table will be dropped. It is the caller responsibility to ensure that no entries from this class are written to the space while this method is called. This is not a clustered operation. If you want only to delete the entries, use clear operation.- Specified by:
dropClassin interfaceIJSpace- Parameters:
className- name of class to delete.- Throws:
RemoteException- if a communication error occursDropClassException- Failed to drop desired class.- See Also:
-
unregisterTypeDescriptor
- Specified by:
unregisterTypeDescriptorin interfaceISpaceProxy- Throws:
RemoteException
-
clear
public void clear(Object template, Transaction txn) throws RemoteException, TransactionException, UnusableEntryException - Specified by:
clearin interfaceIPojoSpace- Throws:
RemoteExceptionTransactionExceptionUnusableEntryException
-
clear
public int clear(Object template, Transaction txn, int modifiers) throws RemoteException, TransactionException, UnusableEntryException - Specified by:
clearin interfaceIPojoSpace- Throws:
RemoteExceptionTransactionExceptionUnusableEntryException
-
count
public int count(Object template, Transaction txn) throws RemoteException, TransactionException, UnusableEntryException - Specified by:
countin interfaceIPojoSpace- Throws:
RemoteExceptionTransactionExceptionUnusableEntryException
-
count
public int count(Object template, Transaction txn, int modifiers) throws RemoteException, TransactionException, UnusableEntryException - Specified by:
countin interfaceIPojoSpace- Throws:
RemoteExceptionTransactionExceptionUnusableEntryException
-
execute
public AsyncFuture execute(SpaceTask task, Object routing, Transaction tx, AsyncFutureListener listener) throws TransactionException, RemoteException Description copied from interface:ISpaceProxyExecutes a task on a single space.- Specified by:
executein interfaceISpaceProxy- Parameters:
task- task (non-null) to execute on single space, according to the routing field.tx- transaction (if any) under which to work.listener- event listener to execute result.- Returns:
- future to retrieve the result in an asynchronous way
- Throws:
TransactionException- if a transaction error occursRemoteException- if a communication error occurs
-
execute
public AsyncFuture execute(SpaceTask task, Object routing, Transaction tx, AsyncFutureListener listener, Map<String, byte[]> classes) throws TransactionException, RemoteExceptionDescription copied from interface:ISpaceProxyExecutes a task on a single space.- Specified by:
executein interfaceISpaceProxy- Parameters:
task- task (non-null) to execute on single space, according to the routing field.tx- transaction (if any) under which to work.listener- event listener to execute result.- Returns:
- future to retrieve the result in an asynchronous way
- Throws:
TransactionException- if a transaction error occursRemoteException- if a communication error occurs
-
ping
Description copied from interface:IJSpaceChecks whether the space is alive and accessible.- Specified by:
pingin interfaceIJSpace- Throws:
RemoteException- when space was unreachable
-
getSpaceHealthStatus
Description copied from interface:ISpaceProxyGets an object representing the space health status- Specified by:
getSpaceHealthStatusin interfaceISpaceProxy- Returns:
- object representing the space health status
- Throws:
RemoteException
-
read
public Object read(Object template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
readin interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
read
public Object read(Object template, Transaction txn, long timeout, int modifiers) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
readin interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
read
public Object read(Object template, Transaction txn, long timeout, int modifiers, boolean ifExists) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
readin interfaceISpaceProxy- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
asyncRead
public AsyncFuture<?> asyncRead(Object template, Transaction txn, long timeout, int modifiers, AsyncFutureListener listener) throws RemoteException Description copied from interface:ISpaceProxyInternal methods only. Read any matching entry from the space, unblocking. Returns an AsyncFuture which returns null if the timeout expires.- Specified by:
asyncReadin interfaceISpaceProxy- Parameters:
template- The template used for matching. Matching is done against template with null fields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The template used for matching. Matching is done against template with null fields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout of NO_WAIT means to wait no time at all; this is equivalent to a wait of zero.modifiers- one or a union ofReadModifiers.listener- event listener to execute result.- Returns:
- object from the space
- Throws:
RemoteException
-
readById
public Object readById(String className, Object id, Object routing, Transaction txn, long timeout, int modifiers, boolean ifExists, QueryResultTypeInternal resultType, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
readByIdin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
readById
public Object readById(ReadTakeProxyActionInfo actionInfo) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
readByIdin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
takeById
public Object takeById(ReadTakeProxyActionInfo actionInfo) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
takeByIdin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
readByUid
public Object readByUid(String uid, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPacket) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
readByUidin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
readIfExists
public Object readIfExists(Object template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
readIfExistsin interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
readIfExists
public Object readIfExists(Object template, Transaction txn, long timeout, int modifiers) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
readIfExistsin interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
readMultiple
public Object[] readMultiple(Object template, Transaction txn, int maxEntries) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
readMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
readMultiple
public Object[] readMultiple(Object template, Transaction txn, int maxEntries, int modifiers) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
readMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
readMultiple
public Object[] readMultiple(Object template, Transaction txn, int maxEntries, int modifiers, boolean returnOnlyUids) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
readMultiplein interfaceISpaceProxy- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
readMultiple
public Object[] readMultiple(Object template, Transaction txn, long timeout, int maxEntries, int minEntriesToWaitFor, int modifiers, boolean returnOnlyUids, boolean ifExist) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
readMultiplein interfaceISpaceProxy- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
snapshot
- Specified by:
snapshotin interfaceIPojoSpace- Throws:
RemoteException
-
take
public Object take(Object template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
takein interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
take
public Object take(Object template, Transaction txn, long timeout, int modifiers) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
takein interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
take
public Object take(Object template, Transaction txn, long timeout, int modifiers, boolean ifExists) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
takein interfaceISpaceProxy- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
asyncTake
public AsyncFuture<?> asyncTake(Object template, Transaction txn, long timeout, int modifiers, AsyncFutureListener listener) throws RemoteException Description copied from interface:ISpaceProxyInternal methods only. Take any matching entry from the space, unblocking. Returns an AsyncFuture which returns null if the timeout expires.- Specified by:
asyncTakein interfaceISpaceProxy- Parameters:
template- The template used for matching. Matching is done against template with null fields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").txn- The template used for matching. Matching is done against template with null fields being wildcards ("match anything") other fields being values ("match exactly on the serialized form").timeout- How long the client is willing to wait for a transactionally proper matching entry. A timeout of NO_WAIT means to wait no time at all; this is equivalent to a wait of zero.modifiers- one or a union ofReadModifiers.listener- event listener to execute result.- Returns:
- object from the space
- Throws:
RemoteException
-
takeById
public Object takeById(String className, Object id, Object routing, int version, Transaction txn, long timeout, int modifiers, boolean ifExists, QueryResultTypeInternal resultType, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
takeByIdin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
takeByUid
public Object takeByUid(String uid, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPacket) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
takeByUidin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
takeIfExists
public Object takeIfExists(Object template, Transaction txn, long timeout) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException - Specified by:
takeIfExistsin interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionInterruptedExceptionRemoteException
-
takeIfExists
public Object takeIfExists(Object template, Transaction txn, long timeout, int modifiers) throws UnusableEntryException, TransactionException, InterruptedException, RemoteException -
takeMultiple
public Object[] takeMultiple(Object template, Transaction txn, int maxEntries) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
takeMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
takeMultiple
public Object[] takeMultiple(Object template, Transaction txn, int maxEntries, int modifiers) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
takeMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
takeMultiple
public Object[] takeMultiple(Object template, Transaction txn, int maxEntries, int modifiers, boolean returnOnlyUids) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
takeMultiplein interfaceISpaceProxy- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
takeMultiple
public Object[] takeMultiple(Object template, Transaction txn, long timeout, int maxEntries, int minEntriesToWaitFor, int modifiers, boolean returnOnlyUids, boolean ifExist) throws TransactionException, UnusableEntryException, RemoteException - Specified by:
takeMultiplein interfaceISpaceProxy- Throws:
TransactionExceptionUnusableEntryExceptionRemoteException
-
update
public Object update(Object updatedEntry, Transaction transaction, long lease, long timeout) throws TransactionException, UnusableEntryException, RemoteException, InterruptedException - Specified by:
updatein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteExceptionInterruptedException
-
update
public Object update(Object entry, Transaction txn, long lease, long timeout, int modifiers) throws TransactionException, UnusableEntryException, RemoteException, InterruptedException - Specified by:
updatein interfaceIPojoSpace- Throws:
TransactionExceptionUnusableEntryExceptionRemoteExceptionInterruptedException
-
updateMultiple
public Object[] updateMultiple(Object[] entries, Transaction txn, long[] leases) throws UnusableEntryException, TransactionException, RemoteException - Specified by:
updateMultiplein interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionRemoteException
-
updateMultiple
public Object[] updateMultiple(Object[] entries, Transaction txn, long[] leases, int modifiers) throws UnusableEntryException, TransactionException, RemoteException - Specified by:
updateMultiplein interfaceIPojoSpace- Throws:
UnusableEntryExceptionTransactionExceptionRemoteException
-
write
public LeaseContext<?> write(Object entry, Transaction txn, long lease) throws TransactionException, RemoteException - Specified by:
writein interfaceIPojoSpace- Throws:
TransactionExceptionRemoteException
-
write
public LeaseContext<?> write(Object entry, Transaction txn, long lease, long timeout, int modifiers) throws TransactionException, RemoteException - Specified by:
writein interfaceIPojoSpace- Throws:
TransactionExceptionRemoteException
-
writeMultiple
public LeaseContext<?>[] writeMultiple(Object[] objects, Transaction txn, long lease) throws TransactionException, RemoteException - Specified by:
writeMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionRemoteException
-
writeMultiple
public LeaseContext<?>[] writeMultiple(Object[] objects, Transaction txn, long lease, int modifiers) throws TransactionException, RemoteException - Specified by:
writeMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionRemoteException
-
writeMultiple
public LeaseContext<?>[] writeMultiple(Object[] objects, Transaction txn, long[] leases, int modifiers) throws TransactionException, RemoteException - Specified by:
writeMultiplein interfaceIPojoSpace- Throws:
TransactionExceptionRemoteException
-
writeMultiple
public LeaseContext<?>[] writeMultiple(Object[] objects, Transaction txn, long lease, long[] leases, int modifiers) throws TransactionException, RemoteException - Throws:
TransactionExceptionRemoteException
-
writeMultiple
public LeaseContext<?>[] writeMultiple(Object[] objects, Transaction txn, long lease, long[] leases, long timeout, int modifiers) throws TransactionException, RemoteException - Specified by:
writeMultiplein interfaceISpaceProxy- Throws:
TransactionExceptionRemoteException
-
readByIds
public Object[] readByIds(String className, Object[] ids, Object routing, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
readByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
readByIds
public Object[] readByIds(String className, Object[] ids, Object[] routings, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
readByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
readByIds
public Object[] readByIds(ReadTakeByIdsProxyActionInfo actionInfo, boolean returnPackets) throws RemoteException, TransactionException, InterruptedException, UnusableEntryException - Specified by:
readByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionTransactionExceptionInterruptedExceptionUnusableEntryException
-
takeByIds
public Object[] takeByIds(String className, Object[] ids, Object routing, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
takeByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
takeByIds
public Object[] takeByIds(String className, Object[] ids, Object[] routings, Transaction txn, int modifiers, QueryResultTypeInternal resultType, boolean returnPackets, String[] projections) throws RemoteException, UnusableEntryException, TransactionException, InterruptedException - Specified by:
takeByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionUnusableEntryExceptionTransactionExceptionInterruptedException
-
takeByIds
public Object[] takeByIds(ReadTakeByIdsProxyActionInfo actionInfo, boolean returnPackets) throws RemoteException, TransactionException, InterruptedException, UnusableEntryException - Specified by:
takeByIdsin interfaceISpaceProxy- Throws:
RemoteExceptionTransactionExceptionInterruptedExceptionUnusableEntryException
-
readEntriesUids
public ReadTakeEntriesUidsResult readEntriesUids(ITemplatePacket template, Transaction transaction, int entriesLimit, int modifiers) throws RemoteException, TransactionException, UnusableEntryException Description copied from interface:ISpaceProxyRead entries UIDs from space.- Specified by:
readEntriesUidsin interfaceISpaceProxy- Throws:
RemoteExceptionTransactionExceptionUnusableEntryException
-
change
public <T> ChangeResult<T> change(Object template, ChangeSet changeSet, Transaction txn, long timeout, ChangeModifiers modifiers) throws RemoteException, TransactionException Description copied from interface:ISpaceProxyChange entry in space- Specified by:
changein interfaceISpaceProxy- Throws:
RemoteExceptionTransactionException
-
asyncChange
public <T> Future<ChangeResult<T>> asyncChange(Object template, ChangeSet changeSet, Transaction txn, long timeout, ChangeModifiers modifiers, AsyncFutureListener<ChangeResult<T>> listener) throws RemoteException - Specified by:
asyncChangein interfaceISpaceProxy- Throws:
RemoteException
-
aggregate
public AggregationResult aggregate(Object template, AggregationSet aggregationSet, Transaction txn, int readModifiers) throws RemoteException, TransactionException, InterruptedException - Specified by:
aggregatein interfaceISpaceProxy- Throws:
RemoteExceptionTransactionExceptionInterruptedException
-
setAppDomainId
public void setAppDomainId(int appDomainId) Description copied from interface:IDotnetProxyAssociatedassociate this object to the specified AppDomain id- Specified by:
setAppDomainIdin interfaceIDotnetProxyAssociated
-
hasAssociatedAppDomain
public boolean hasAssociatedAppDomain()- Specified by:
hasAssociatedAppDomainin interfaceIDotnetProxyAssociated- Returns:
- true if this object is associated to an AppDomain.
-
getAppDomainId
public int getAppDomainId()- Specified by:
getAppDomainIdin interfaceIDotnetProxyAssociated- Returns:
- the id of the associated AppDomain, throws an exception if this object is not
associated to any AppDomain.
IDotnetProxyAssociated.hasAssociatedAppDomain()
-
setDotnetProxyHandleId
public void setDotnetProxyHandleId(long handleId) Description copied from interface:IDotnetProxyAssociatedSets a dotnet proxy handle id- Specified by:
setDotnetProxyHandleIdin interfaceIDotnetProxyAssociated- Parameters:
handleId- handle id of the proxy
-
isTargetOfADotnetProxy
public boolean isTargetOfADotnetProxy()- Specified by:
isTargetOfADotnetProxyin interfaceIDotnetProxyAssociated- Returns:
- true if this object is a target .NET proxy
-
getDotnetProxyHandleId
public long getDotnetProxyHandleId()- Specified by:
getDotnetProxyHandleIdin interfaceIDotnetProxyAssociated- Returns:
- the handle id of this object that the proxy is using.
-
applyNotifyInfoDefaults
- Specified by:
applyNotifyInfoDefaultsin interfaceISpaceProxy
-
checkIfConnected
public boolean checkIfConnected()- Specified by:
checkIfConnectedin interfaceISpaceProxy
-
isCacheContainer
public boolean isCacheContainer() -
getLocalSpace
-
getRemoteSpace
-
isLocalCacheCacheContainer
public boolean isLocalCacheCacheContainer() -
isLocalViewContainer
public boolean isLocalViewContainer()
-