public interface RegionService
regions
that exist
in a GemFire cache
.
Regions can be obtained using getRegion(java.lang.String)
and queried using getQueryService()
.
The service should be closed
to free up resources
once it is no longer needed.
Once it is closed
any attempt to use it or any regions
obtained from it will cause a CacheClosedException
to be thrown.
Instances of the interface are created using one of the following methods:
CacheFactory.create()
creates a server instance of Cache
.
ClientCacheFactory.create()
creates a client instance of ClientCache
.
ClientCache.createAuthenticatedView(Properties)
creates a client multiuser authenticated cache view.
Modifier and Type | Method and Description |
---|---|
void |
close()
Terminates this region service and releases all its resources.
|
PdxInstance |
createPdxEnum(String className,
String enumName,
int enumOrdinal)
Creates and returns a PdxInstance that represents an enum value.
|
PdxInstanceFactory |
createPdxInstanceFactory(String className)
Returns a factory that can create a
PdxInstance . |
CancelCriterion |
getCancelCriterion()
the cancellation criterion for this service
|
QueryService |
getQueryService()
Return the QueryService for this region service.
|
<K,V> Region<K,V> |
getRegion(String path)
Return the existing region (or subregion) with the specified
path.
|
boolean |
isClosed()
Indicates if this region service has been closed.
|
Set<Region<?,?>> |
rootRegions()
Returns unmodifiable set of the root regions that are in the region service.
|
CancelCriterion getCancelCriterion()
<K,V> Region<K,V> getRegion(String path)
path
- the path to the regionIllegalArgumentException
- if path is null, the empty string, or "/"Set<Region<?,?>> rootRegions()
PdxInstanceFactory createPdxInstanceFactory(String className)
PdxInstance
.className
- the fully qualified class name that the PdxInstance will become
when it is fully deserialized.PdxInstance createPdxEnum(String className, String enumName, int enumOrdinal)
className
- the name of the enum classenumName
- the name of the enum constantenumOrdinal
- the ordinal value of the enum constantIllegalArgumentException
- if className or enumName are null
.QueryService getQueryService()
void close()
Region.close()
on each region in the service.
After this service is closed, any further
method calls on this service or any region object
obtained from the service will throw
CacheClosedException
, unless otherwise noted.CacheClosedException
- if the service is already closed.boolean isClosed()
CacheClosedException
if the service is closed.Copyright © 1997-2017 Pivotal Software, Inc. All rights reserved.