Click or drag to resize
RegionCreate Method (CacheableKey, Serializable)
Creates a new entry in this region with the specified key and value.

Namespace: GemStone.GemFire.Cache
Assembly: Gemstone.Gemfire.Cache (in Gemstone.Gemfire.Cache.dll) Version: 9.0.6.18
Syntax
public void Create(
	CacheableKey key,
	Serializable value
)

Parameters

key
Type: GemStone.GemFire.CacheCacheableKey
The key for which to create the entry in this region. The object is created before the call, and the caller should not deallocate the object.
value
Type: GemStone.GemFire.CacheSerializable
The value for the new entry, which may be null to indicate that the new entry starts as if it had been locally invalidated.
Exceptions
ExceptionCondition
IllegalArgumentException if key is null
CacheWriterException if CacheWriter aborts the operation
CacheListenerException if CacheListener throws an exception
CacheServerException If an exception is received from the Java cache server. Only for Native Client regions.
NotConnectedException if not connected to a GemFire system because the client cannot establish usable connections to any of the servers given to it. For pools configured with locators, if no locators are available, innerException of NotConnectedException is set to NoAvailableLocatorsException.
RegionDestroyedException if region has been destroyed
TimeoutException if the operation timed out
OutOfMemoryException if there is not enough memory for the new entry
EntryExistsException if an entry with this key already exists
Remarks

Updates the [!:CacheStatistics.LastAccessedTime] and [!:CacheStatistics.LastModifiedTime] for this region and the entry.

The new entry is propogated to the java server to which it is connected with.

If remote server put fails throwing back a CacheServerException or security exception, then local put is tried to rollback. However, if the entry has overflowed/evicted/expired then the rollback is aborted since it may be due to a more recent notification or update by another thread.

See Also