org.apache.naming.factory
クラス MailSessionFactory

java.lang.Object
  |
  +--org.apache.naming.factory.MailSessionFactory
すべての実装インタフェース:
javax.naming.spi.ObjectFactory

public class MailSessionFactory
extends java.lang.Object
implements javax.naming.spi.ObjectFactory

Factory class that creates a JNDI named JavaMail Session factory, which can be used for managing inbound and outbound electronic mail messages via JavaMail APIs. All messaging environment properties described in the JavaMail Specification may be passed to the Session factory; however the following properties are the most commonly used:

This factory can be configured in a <DefaultContext> or <Context> element in your conf/server.xml configuration file. An example of factory configuration is:

 <Resource name="mail/smtp" auth="CONTAINER"
           type="javax.mail.Session"/>
 <ResourceParams name="mail/smtp">
   <parameter>
     <name>factory</name>
     <value>org.apache.naming.factory.MailSessionFactory</value>
   </parameter>
   <parameter>
     <name>mail.smtp.host</name>
     <value>mail.mycompany.com</value>
   </parameter>
 </ResourceParams>
 

バージョン:
$Revision: 1.2 $ $Date: 2001/03/26 03:26:05 $
作成者:
Craig R. McClanahan

フィールドの概要
protected static java.lang.String factoryType
          The Java type for which this factory knows how to create objects.
 
コンストラクタの概要
MailSessionFactory()
           
 
メソッドの概要
 java.lang.Object getObjectInstance(java.lang.Object refObj, javax.naming.Name name, javax.naming.Context context, java.util.Hashtable env)
          Create and return an object instance based on the specified characteristics.
 
クラス java.lang.Object から継承したメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

factoryType

protected static final java.lang.String factoryType
The Java type for which this factory knows how to create objects.
コンストラクタの詳細

MailSessionFactory

public MailSessionFactory()
メソッドの詳細

getObjectInstance

public java.lang.Object getObjectInstance(java.lang.Object refObj,
                                          javax.naming.Name name,
                                          javax.naming.Context context,
                                          java.util.Hashtable env)
                                   throws java.lang.Exception
Create and return an object instance based on the specified characteristics.
定義:
インタフェース javax.naming.spi.ObjectFactory 内の getObjectInstance
パラメータ:
refObj - Reference information containing our parameters, or null if there are no parameters
name - The name of this object, relative to context, or null if there is no name
context - The context to which name is relative, or null if name is relative to the default initial context
env - Environment variables, or null if there are none
例外:
java.lang.Exception - if an error occurs during object creation


Copyright ? 2000-2001 Apache Software Foundation. All Rights Reserved.