| org.mmbase.storage.Storable
All known Subclasses: org.mmbase.core.CoreField,
Storable | public interface Storable (Code) | | This interface contains functionality for retrieving a storage identifier - a name or id
suitable for storing the object. It also holds status information (i.e. whether a field is in Storage
or not) and storage-specific data.
author: Pierre van Rooden since: MMBase-1.7 version: $Id: Storable.java,v 1.6 2005/06/28 14:01:41 pierre Exp $ |
Method Summary | |
public Object | getStorageIdentifier() Returns a storage identifier for this object.
This should return:
- For MMBase: the object storage element identifier as a String (i.e.
| public int | getStorageType() Retrieves the storage type. | public boolean | inStorage() Returns whether an object is (or, for a new object, should be) defined in the storage. | public void | setStorageType(int value) Sets the storage type. |
getStorageIdentifier | public Object getStorageIdentifier() throws StorageException(Code) | | Returns a storage identifier for this object.
This should return:
- For MMBase: the object storage element identifier as a String (i.e. fully expanded table name)
- For MMObjectBuilder: the builder storage element identifier as a String (i.e. fully expanded table name)
- For MMObjectNode: the object number as a Integer
- For CoreField: a storage-compatible field name as a String (if no such name exists a StorageException is thrown)
A Storable object (except for MMObjectNode) should retrieve its storage identifier using
StorageManagerFactory.getStorageIdentifier when it is first instantiated.
the identifier |
getStorageType | public int getStorageType()(Code) | | Retrieves the storage type. The meaning of this type is dependent
on the storage implementation.
|
inStorage | public boolean inStorage()(Code) | | Returns whether an object is (or, for a new object, should be) defined in the storage.
Virtual fields or builders should return false .
true if the object is kept in the storage |
setStorageType | public void setStorageType(int value)(Code) | | Sets the storage type. This method is called by the storage layer when first loading a builder.
The meaning of this type is dependent on the storage implementation.
Parameters: value - the value to set |
|
|