wt.fc
Class LobLocator
java.lang.Object
wt.fc.LobLocator
- All Implemented Interfaces:
- Serializable
- public final class LobLocator
- extends Object
- implements Serializable
LobLocator provides interfaces to store and retrieve large objects (LOBs)
from a datastore.
Notes:
When an object which contains a LobLocator attribute is retrieved from
the datastore,the LobLocator is initialized with "locator" information
to enable the actual retrieval of the LOB. This retrieval requires a
"2nd trip" and is accomplished via the PersistenceHelper.manager.getLob method.
A lob is inserted into the datastore via the PersistenceHelper.manager.setLob method.
Example application code
Class LobHolder extends ItemAnchor {
LobLocator aLobLocator;
}
LobHolder anObj = LobHolder.find(someCriteria).nextElement();
InputStream in = PersistenceHelper.manager.getLob(anObj,anObj.getALobLocator());
do stuff
InputStream i;
long len = i.available(); // or some mechanism to determine stream length
PersistenceHelper.manager.updateLob(anObj.anObj.getALobLocator(),i,len);
- See Also:
InputStream
,
Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
versionID
private static final String versionID
- See Also:
- Constant Field Values
oid
private ObjectIdentifier oid
primaryKeyName
private String primaryKeyName
attributeName
private String attributeName
tableName
private String tableName
columnName
private String columnName
LobLocator
public LobLocator()
getObjectIdentifier
public ObjectIdentifier getObjectIdentifier()
setObjectIdentifier
public void setObjectIdentifier(ObjectIdentifier anOid)
getPrimaryKeyName
public String getPrimaryKeyName()
setPrimaryKeyName
public void setPrimaryKeyName(String keyName)
getAttributeName
public String getAttributeName()
setAttributeName
public void setAttributeName(String aName)
getTableName
public String getTableName()
setTableName
public void setTableName(String tName)
getColumnName
public String getColumnName()
setColumnName
public void setColumnName(String cName)
setLocatorNames
public void setLocatorNames(String anAttributeName,
String aTableName,
String aColumnName)
dumpLocator
public void dumpLocator()