mirror of https://github.com/apache/poi.git
latest changes
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353521 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
356fd986dd
commit
76e7400e21
|
@ -0,0 +1,36 @@
|
|||
package org.apache.poi.hwpf.model;
|
||||
|
||||
import org.apache.poi.hwpf.sprm.SprmBuffer;
|
||||
|
||||
import java.lang.ref.SoftReference;
|
||||
|
||||
public class CachedPropertyNode
|
||||
extends PropertyNode
|
||||
{
|
||||
protected SoftReference _propCache;
|
||||
|
||||
public CachedPropertyNode(int start, int end, SprmBuffer buf)
|
||||
{
|
||||
super(start, end, buf);
|
||||
}
|
||||
|
||||
protected void fillCache(Object ref)
|
||||
{
|
||||
_propCache = new SoftReference(ref);
|
||||
}
|
||||
|
||||
protected Object getCacheContents()
|
||||
{
|
||||
return _propCache == null ? null : _propCache.get();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return This property's property in compressed form.
|
||||
*/
|
||||
public SprmBuffer getSprmBuf()
|
||||
{
|
||||
return (SprmBuffer)_buf;
|
||||
}
|
||||
|
||||
|
||||
}
|
Loading…
Reference in New Issue