ch.qos.logback.core.net
Class JMSAppenderBase<E>

java.lang.Object
  extended by ch.qos.logback.core.spi.ContextAwareBase
      extended by ch.qos.logback.core.AppenderBase<E>
          extended by ch.qos.logback.core.net.JMSAppenderBase<E>
All Implemented Interfaces:
Appender<E>, ContextAware, FilterAttachable<E>, LifeCycle

public abstract class JMSAppenderBase<E>
extends AppenderBase<E>

This class serves as a base class for JMSTopicAppender and JMSQueueAppender For more information about this appender, please refer to: http://logback.qos.ch/manual/appenders.html#JMSAppenderBase

Author:
Ceki Gülcü, Sébastien Pennec

Field Summary
protected  String initialContextFactoryName
           
protected  String password
           
protected  String providerURL
           
protected  String securityCredentials
           
protected  String securityPrincipalName
           
protected  String urlPkgPrefixes
           
protected  String userName
           
 
Fields inherited from class ch.qos.logback.core.AppenderBase
name, started
 
Fields inherited from class ch.qos.logback.core.spi.ContextAwareBase
context
 
Constructor Summary
JMSAppenderBase()
           
 
Method Summary
 Properties buildEnvProperties()
           
 Context buildJNDIContext()
           
 String getInitialContextFactoryName()
          Returns the value of the InitialContextFactoryName option.
 String getPassword()
           
 String getProviderURL()
           
 String getSecurityCredentials()
           
 String getSecurityPrincipalName()
           
 String getURLPkgPrefixes()
           
 String getUserName()
           
protected  Object lookup(Context ctx, String name)
           
 void setInitialContextFactoryName(String initialContextFactoryName)
          Setting the InitialContextFactoryName method will cause this JMSAppender instance to use the InitialContext.InitialContext(Hashtable) method instead of the no-argument constructor.
 void setPassword(String password)
          The password to use when creating a topic session.
 void setProviderURL(String providerURL)
           
 void setSecurityCredentials(String securityCredentials)
           
 void setSecurityPrincipalName(String securityPrincipalName)
           
 void setURLPkgPrefixes(String urlPkgPrefixes)
           
 void setUserName(String userName)
          The user name to use when javax.jms.TopicConnectionFactory#createTopicConnection(String, String) creating a topic session}.
 
Methods inherited from class ch.qos.logback.core.AppenderBase
addFilter, append, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setName, start, stop, toString
 
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface ch.qos.logback.core.spi.ContextAware
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, setContext
 

Field Detail

securityPrincipalName

protected String securityPrincipalName

securityCredentials

protected String securityCredentials

initialContextFactoryName

protected String initialContextFactoryName

urlPkgPrefixes

protected String urlPkgPrefixes

providerURL

protected String providerURL

userName

protected String userName

password

protected String password
Constructor Detail

JMSAppenderBase

public JMSAppenderBase()
Method Detail

lookup

protected Object lookup(Context ctx,
                        String name)
                 throws NamingException
Throws:
NamingException

buildJNDIContext

public Context buildJNDIContext()
                         throws NamingException
Throws:
NamingException

buildEnvProperties

public Properties buildEnvProperties()

getInitialContextFactoryName

public String getInitialContextFactoryName()
Returns the value of the InitialContextFactoryName option. See setInitialContextFactoryName(java.lang.String) for more details on the meaning of this option.


setInitialContextFactoryName

public void setInitialContextFactoryName(String initialContextFactoryName)
Setting the InitialContextFactoryName method will cause this JMSAppender instance to use the InitialContext.InitialContext(Hashtable) method instead of the no-argument constructor. If you set this option, you should also at least set the ProviderURL option.

See also setProviderURL(String).


getProviderURL

public String getProviderURL()

setProviderURL

public void setProviderURL(String providerURL)

getURLPkgPrefixes

public String getURLPkgPrefixes()

setURLPkgPrefixes

public void setURLPkgPrefixes(String urlPkgPrefixes)

getSecurityCredentials

public String getSecurityCredentials()

setSecurityCredentials

public void setSecurityCredentials(String securityCredentials)

getSecurityPrincipalName

public String getSecurityPrincipalName()

setSecurityPrincipalName

public void setSecurityPrincipalName(String securityPrincipalName)

getUserName

public String getUserName()

setUserName

public void setUserName(String userName)
The user name to use when javax.jms.TopicConnectionFactory#createTopicConnection(String, String) creating a topic session}. If you set this option, you should also set the Password option. See setPassword(String).


getPassword

public String getPassword()

setPassword

public void setPassword(String password)
The password to use when creating a topic session.



Copyright © 2005-2012 QOS.ch. All Rights Reserved.