|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.opensymphony.module.propertyset.AbstractPropertySet | +--com.opensymphony.module.propertyset.EJBPropertySet
The EJBPropertySet is an implementation of
PropertySet
that
uses Enterprise JavaBeans to store and retrieve Properties.
This class is a proxy to the
PropertyStore
Session Bean that handles the PropertySet and behind the scenes
delegates to various Entity Beans to persist the data in an
efficient way.
Each method in the proxy will catch any thrown
RemoteException
and rethrow it wrapped in a
PropertyImplementationException
.
In order to use an EJBPropertySet, a PropertyStore Session Bean must first be retrieved that represents the PropertySet data. This is typically either returned by another EJB, or looked up using an JNDI location for PropertyStoreHome and an int ID for the actual PropertySet used.
Example
PropertySet ps1 = new EJBPropertySet( myBean.getPropertyStore() );
PropertySet ps2 = new EJBPropertySet( "os.PropertyStore", id );
PropertySet
,
PropertyStore
,
PropertyStoreHome
, Serialized FormFields inherited from class com.opensymphony.module.propertyset.AbstractPropertySet |
schema |
Fields inherited from interface com.opensymphony.module.propertyset.PropertySet |
BOOLEAN, DATA, DATE, DOUBLE, INT, LONG, OBJECT, PROPERTIES, STRING, TEXT, XML |
Constructor Summary | |
EJBPropertySet(PropertyStoreHome home,
java.lang.String entityName,
long entityId)
Create EJBPropertySet proxy by creating new PropertyStore EJB instance with given sequenceName/sequenceId from StoreMap. |
|
EJBPropertySet(PropertyStore store,
java.lang.String entityName,
long entityId)
Create EJBPropertySet proxy around supplied PropertyStore. |
|
EJBPropertySet(java.lang.String propertyStoreHome,
java.lang.String entityName,
long entityId)
Create EJBPropertySet proxy by creating new PropertyStore EJB instance with given sequenceName/sequenceId from StoreMap. |
Method Summary | |
boolean |
exists(java.lang.String key)
Proxy to PropertyStore.exists(java.lang.String,long,java.lang.String) |
protected java.lang.Object |
get(int type,
java.lang.String key)
Proxy to PropertyStore.get(java.lang.String,long,int,java.lang.String) |
java.util.Collection |
getKeys(java.lang.String prefix,
int type)
Proxy to PropertyStore.getKeys(java.lang.String,long,java.lang.String,int) |
int |
getType(java.lang.String key)
Proxy to PropertyStore.getType(java.lang.String,long,java.lang.String) |
void |
remove(java.lang.String key)
Proxy to PropertyStore.remove(java.lang.String,long,java.lang.String) |
protected void |
setImpl(int type,
java.lang.String key,
java.lang.Object value)
Proxy to com.opensymphony.module.propertyset.ejb.PropertyStore#set(java.lang.String,long,int,java.lang.String,java.lang.Object) |
Methods inherited from class com.opensymphony.module.propertyset.AbstractPropertySet |
getBoolean, getData, getDate, getDouble, getInt, getKeys, getKeys, getKeys, getLong, getObject, getProperties, getSchema, getString, getText, getXML, isSettable, setAsActualType, setBoolean, setData, setDate, setDouble, setInt, setLong, setObject, setProperties, setSchema, setString, setText, setXML, supportsType, supportsTypes, toString, type, type |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public EJBPropertySet(PropertyStore store, java.lang.String entityName, long entityId)
public EJBPropertySet(PropertyStoreHome home, java.lang.String entityName, long entityId) throws java.rmi.RemoteException, javax.ejb.CreateException
public EJBPropertySet(java.lang.String propertyStoreHome, java.lang.String entityName, long entityId) throws javax.naming.NamingException, java.rmi.RemoteException, javax.ejb.CreateException
Method Detail |
protected java.lang.Object get(int type, java.lang.String key) throws PropertyException
PropertyStore.get(java.lang.String,long,int,java.lang.String)
get
in class AbstractPropertySet
protected void setImpl(int type, java.lang.String key, java.lang.Object value) throws PropertyException
com.opensymphony.module.propertyset.ejb.PropertyStore#set(java.lang.String,long,int,java.lang.String,java.lang.Object)
setImpl
in class AbstractPropertySet
public boolean exists(java.lang.String key) throws PropertyException
PropertyStore.exists(java.lang.String,long,java.lang.String)
exists
in class AbstractPropertySet
public void remove(java.lang.String key) throws PropertyException
PropertyStore.remove(java.lang.String,long,java.lang.String)
remove
in class AbstractPropertySet
public int getType(java.lang.String key) throws PropertyException
PropertyStore.getType(java.lang.String,long,java.lang.String)
getType
in class AbstractPropertySet
com.opensymphony.module.propertyset.PropertySet
public java.util.Collection getKeys(java.lang.String prefix, int type) throws PropertyException
PropertyStore.getKeys(java.lang.String,long,java.lang.String,int)
getKeys
in class AbstractPropertySet
com.opensymphony.module.propertyset.PropertySet
prefix
- String that keys must start with. If null, than all
keys shall be returned.type
- Type to list. See static class variables. If null, then
all types shall be returned.Collection
of
String
s.
|
See www.opensymphony.com for more information. | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |