Fetches a portion of the state for this cache from secondary storage (disk, database) and writes it to a provided ObjectOutputStream. State written to the provided ObjectOutputStream parameter is used for activation of a portion of a new CacheImpl instance. When the state gets transferred to the new cache instance its cacheloader calls {@link #storeState(Fqn,ObjectInputStream)}.
Implementations of this method should not catch any exception or close the given ObjectOutputStream parameter. In order to ensure cacheloader interoperability contents of the cache are written to the ObjectOutputStream as a sequence of NodeData objects.
Default implementation is provided by {@link AbstractCacheLoader} and ensures cacheloaderinteroperability. Implementors are encouraged to consider extending AbstractCacheLoader prior to implementing completely custom cacheloader.
@param subtree Fqn naming the root (i.e. highest level parent) node ofthe subtree for which state is requested.
@param os ObjectOutputStream to write state
@see AbstractCacheLoader#loadState(Fqn,ObjectOutputStream)
@see org.jboss.cache.Region#activate()
@see org.jboss.cache.marshall.NodeData