com.sun.j2ee.blueprints.smarticket.ejb.localeinfo
Class LocaleInfoEJB

java.lang.Object
  |
  +--com.sun.j2ee.blueprints.smarticket.ejb.localeinfo.LocaleInfoEJB
All Implemented Interfaces:
javax.ejb.EnterpriseBean, java.io.Serializable, javax.ejb.SessionBean

public class LocaleInfoEJB
extends java.lang.Object
implements javax.ejb.SessionBean

Implements the LocaleInfo EJB component. Takes care of business methods and database access. This is a stateless session bean.

See Also:
Serialized Form

Field Summary
protected  javax.sql.DataSource dataSource
           
protected static java.lang.String LOCALEINFO_DB
           
 
Constructor Summary
LocaleInfoEJB()
           
 
Method Summary
 void ejbActivate()
           
 void ejbCreate()
           
 void ejbPassivate()
           
 void ejbRemove()
           
 java.util.List getLocales()
          Get a list of the available locales for this application.
 java.util.List getMessages(int locale)
          Return a list of localized messages for the given locale.
 void setSessionContext(javax.ejb.SessionContext sc)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCALEINFO_DB

protected static final java.lang.String LOCALEINFO_DB

dataSource

protected javax.sql.DataSource dataSource
Constructor Detail

LocaleInfoEJB

public LocaleInfoEJB()
Method Detail

setSessionContext

public void setSessionContext(javax.ejb.SessionContext sc)
Specified by:
setSessionContext in interface javax.ejb.SessionBean

ejbCreate

public void ejbCreate()

ejbRemove

public void ejbRemove()
Specified by:
ejbRemove in interface javax.ejb.SessionBean

ejbActivate

public void ejbActivate()
Specified by:
ejbActivate in interface javax.ejb.SessionBean

ejbPassivate

public void ejbPassivate()
Specified by:
ejbPassivate in interface javax.ejb.SessionBean

getLocales

public java.util.List getLocales()
Get a list of the available locales for this application.

getMessages

public java.util.List getMessages(int locale)
Return a list of localized messages for the given locale.
Parameters:
locale - the ID of the locale.


Copyright © 2002 Sun Microsystems Inc. All rights reserved.