|
Protomatter Classes v1.1.6 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.protomatter.j2ee.ejb.ProtoEJB
Base class for all EJBs.
Field Summary | |
static java.lang.String |
COMP_ENV_CHANNEL_LIST
The JNDI name of the syslog channel list. |
Constructor Summary | |
ProtoEJB()
Default constructor. |
Method Summary | |
protected boolean |
close(java.sql.Connection c)
Close the given SQL Connection. |
protected boolean |
close(java.sql.ResultSet r)
Close the given SQL ResultSet. |
protected boolean |
close(java.sql.Statement s)
Close the given SQL Statement. |
protected javax.naming.Context |
getComponentContext()
Get the environment context for this component. |
java.lang.Object |
getSyslogChannel()
Get the list of channels to log to. |
protected void |
initSyslogChannelList()
Initialize the syslog channel list from the component context. |
protected void |
setChannelList(java.util.List channelList)
Set the list of channels to log messages to. |
protected void |
setChannelList(java.lang.String[] channelList)
Set the list of channels to log messages to. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String COMP_ENV_CHANNEL_LIST
initSyslogChannelList()
Constructor Detail |
public ProtoEJB()
Method Detail |
public java.lang.Object getSyslogChannel()
getSyslogChannel
in interface SyslogChannelAware
SyslogChannelAware
protected void setChannelList(java.lang.String[] channelList)
protected void setChannelList(java.util.List channelList)
protected javax.naming.Context getComponentContext() throws javax.naming.NamingException
protected void initSyslogChannelList()
For example, the following snippet from an ejb-jar.xml file:
... <env-entry> <env-entry-name>Syslog.channelList</env-entry-name> <env-entry-type>java.lang.String</env-entry-type> <env-entry-value>THIS_CHANNEL, THAT_CHANNEL</env-entry-value> </env-entry> ... |
Will set the list of channels to contain "THIS_CHANNEL" and "THAT_CHANNEL". Also, whitespace around the edges of the value is stripped, so you can do pretty formatting in the XML file, like this:
... <env-entry> <env-entry-name>Syslog.channelList</env-entry-name> <env-entry-type>java.lang.String</env-entry-type> <env-entry-value> THIS_CHANNEL, THAT_CHANNEL </env-entry-value> </env-entry> ... |
And get the same result as above. Refer to the EJB spec, version 1.1, for more information about the component environment.
protected boolean close(java.sql.Connection c)
DatabaseUtil.close(Connection, Object)
protected boolean close(java.sql.Statement s)
DatabaseUtil.close(Statement, Object)
protected boolean close(java.sql.ResultSet r)
DatabaseUtil.close(ResultSet, Object)
|
Protomatter Classes v1.1.6 Copyright 1998-2001 Nate Sammons |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Protomatter Classes v1.1.6 | http://protomatter.sourceforge.net/1.1.6 |