|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrabbit.cache.NCacheEntry
public class NCacheEntry
A cached object.
Constructor Summary | |
---|---|
NCacheEntry()
Not to be used, for externalizable only. |
|
NCacheEntry(java.lang.Object key,
long id)
Create a new CacheEntry for given key and filename |
Method Summary | |
---|---|
long |
getCacheTime()
Get the date this object was cached. |
java.lang.Object |
getDataHook(NCache cache)
Get the hooked data. |
long |
getExpires()
Get the expiry-date of our file |
long |
getId()
Get the id of our entry. |
java.lang.Object |
getKey()
Get the key were holding data for |
protected java.lang.Object |
getRealDataHook()
Get the real data hook |
long |
getSize()
Get the size of our file |
void |
readExternal(java.io.ObjectInput in)
Read the cache entry from the object input. |
void |
setCacheTime(java.util.Date date)
Set the date this object was cached. |
void |
setDataHook(java.lang.Object o)
Sets the data hook for this cache object. |
void |
setExpires(long d)
Sets the expirydate of our data |
protected void |
setKey(java.lang.Object key)
Set the key were holding data for |
void |
setSize(long size)
Sets the size of our data |
void |
writeExternal(java.io.ObjectOutput out)
Write the object to the object output. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public NCacheEntry()
public NCacheEntry(java.lang.Object key, long id)
key
- the key for the object.id
- the identity of this entryMethod Detail |
---|
protected void setKey(java.lang.Object key)
key
- the key we have data forpublic java.lang.Object getKey()
public long getCacheTime()
public void setCacheTime(java.util.Date date)
date
- the date.public long getSize()
public void setSize(long size)
size
- the new Sizepublic long getExpires()
public void setExpires(long d)
d
- the new expiry-date.public long getId()
protected java.lang.Object getRealDataHook()
public java.lang.Object getDataHook(NCache cache)
cache
- the NCache this entry lives in.
public void setDataHook(java.lang.Object o)
o
- the new data.public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |