Cache

Get a segment instance

The first step in referring to a cache segment is to create an empty segment instance using the getSegmentInstance() method which doesn't actually fire a server side call. This empty segment instance does not hold any values.

Ensure the following packages are imported:

Copiedimport com.zc.component.cache.ZCCache;
import com.zc.component.cache.ZCSegment;
Copied//Get a Cache Instance
ZCCache cacheobj=ZCCache.getInstance();
//Get an instance of a specific segment with segment ID
ZCSegment segment = cacheobj.getSegmentInstance(1510000000054091L);