Package ch.qos.logback.core.net
Class SMTPAppenderBase<E>
- java.lang.Object
 - 
- ch.qos.logback.core.spi.ContextAwareBase
 - 
- ch.qos.logback.core.AppenderBase<E>
 - 
- ch.qos.logback.core.net.SMTPAppenderBase<E>
 
 
 
 
- 
- All Implemented Interfaces:
 Appender<E>,ContextAware,FilterAttachable<E>,LifeCycle
- Direct Known Subclasses:
 SMTPAppender
@Deprecated(since="2022-01-27") public abstract class SMTPAppenderBase<E> extends AppenderBase<E>
Deprecated.This internal logback API is not supported by AEM as a Cloud Service.An abstract class that provides support for sending events to an email address. See http://logback.qos.ch/manual/appenders.html#SMTPAppender for further documentation. 
- 
- 
Constructor Summary
Constructors Constructor Description SMTPAppenderBase()Deprecated. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddTo(java.lang.String to)Deprecated.booleancheckEntryConditions()Deprecated.This method determines if there is a sense in attempting to append.java.lang.StringgetCharsetEncoding()Deprecated.CyclicBufferTracker<E>getCyclicBufferTracker()Deprecated.Discriminator<E>getDiscriminator()Deprecated.java.lang.StringgetFrom()Deprecated.Returns value of the From option.java.lang.StringgetJndiLocation()Deprecated.Layout<E>getLayout()Deprecated.java.lang.StringgetLocalhost()Deprecated.java.lang.StringgetPassword()Deprecated.java.lang.StringgetSmtpHost()Deprecated.Returns value of the SMTPHost option.java.lang.StringgetSMTPHost()Deprecated.Alias for getSmtpHost().intgetSmtpPort()Deprecated.SeesetSmtpPort(int)intgetSMTPPort()Deprecated.Alias forgetSmtpPort()java.lang.StringgetSubject()Deprecated.Returns value of the Subject option.java.util.List<java.lang.String>getToAsListOfString()Deprecated.java.util.List<PatternLayoutBase<E>>getToList()Deprecated.Returns value of the toList option.java.lang.StringgetUsername()Deprecated.booleanisAsynchronousSending()Deprecated.booleanisSessionViaJNDI()Deprecated.booleanisSSL()Deprecated.booleanisSTARTTLS()Deprecated.voidsetAsynchronousSending(boolean asynchronousSending)Deprecated.By default, SMTAppender transmits emails asynchronously.voidsetCharsetEncoding(java.lang.String charsetEncoding)Deprecated.Set the character set encoding of the outgoing email messages.voidsetCyclicBufferTracker(CyclicBufferTracker<E> cbTracker)Deprecated.voidsetDiscriminator(Discriminator<E> discriminator)Deprecated.voidsetEvaluator(EventEvaluator<E> eventEvaluator)Deprecated.The EventEvaluator option takes a string value representing the name of the class implementing theEventEvaluatorinterface.voidsetFrom(java.lang.String from)Deprecated.The From option takes a string value which should be a e-mail address of the sender.voidsetJndiLocation(java.lang.String jndiLocation)Deprecated.Set the location where aSessionresource is located in JNDI.voidsetLayout(Layout<E> layout)Deprecated.voidsetLocalhost(java.lang.String localhost)Deprecated.Set the "mail.smtp.localhost" property to the value passed as parameter to this method.voidsetPassword(java.lang.String password)Deprecated.voidsetSessionViaJNDI(boolean sessionViaJNDI)Deprecated.If set to true, aSessionresource will be retrieved from JNDI.voidsetSmtpHost(java.lang.String smtpHost)Deprecated.The smtpHost option takes a string value which should be a the host name of the SMTP server that will send the e-mail message.voidsetSMTPHost(java.lang.String smtpHost)Deprecated.Alias for smtpHostvoidsetSmtpPort(int port)Deprecated.The port where the SMTP server is running.voidsetSMTPPort(int port)Deprecated.Alias forsetSmtpPort(int).voidsetSSL(boolean ssl)Deprecated.voidsetSTARTTLS(boolean startTLS)Deprecated.voidsetSubject(java.lang.String subject)Deprecated.The Subject option takes a string value which should be a the subject of the e-mail message.voidsetUsername(java.lang.String username)Deprecated.voidstart()Deprecated.Start the appendervoidstop()Deprecated.- 
Methods inherited from class ch.qos.logback.core.AppenderBase
addFilter, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setName, toString 
- 
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getStatusManager, setContext 
- 
Methods inherited from class java.lang.Object
equals, 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 
 - 
 
 - 
 
- 
- 
Method Detail
- 
start
public void start()
Deprecated.Start the appender- Specified by:
 startin interfaceLifeCycle- Overrides:
 startin classAppenderBase<E>
 
- 
checkEntryConditions
public boolean checkEntryConditions()
Deprecated.This method determines if there is a sense in attempting to append. It checks whether there is a set output target and also if there is a set layout. If these checks fail, then the boolean valuefalseis returned. 
- 
stop
public void stop()
Deprecated.- Specified by:
 stopin interfaceLifeCycle- Overrides:
 stopin classAppenderBase<E>
 
- 
getToList
public java.util.List<PatternLayoutBase<E>> getToList()
Deprecated.Returns value of the toList option. 
- 
getFrom
public java.lang.String getFrom()
Deprecated.Returns value of the From option. 
- 
getSubject
public java.lang.String getSubject()
Deprecated.Returns value of the Subject option. 
- 
setFrom
public void setFrom(java.lang.String from)
Deprecated.The From option takes a string value which should be a e-mail address of the sender. 
- 
setSubject
public void setSubject(java.lang.String subject)
Deprecated.The Subject option takes a string value which should be a the subject of the e-mail message. 
- 
setSMTPHost
public void setSMTPHost(java.lang.String smtpHost)
Deprecated.Alias for smtpHost- Parameters:
 smtpHost-
 
- 
setSmtpHost
public void setSmtpHost(java.lang.String smtpHost)
Deprecated.The smtpHost option takes a string value which should be a the host name of the SMTP server that will send the e-mail message. 
- 
getSMTPHost
public java.lang.String getSMTPHost()
Deprecated.Alias for getSmtpHost(). 
- 
getSmtpHost
public java.lang.String getSmtpHost()
Deprecated.Returns value of the SMTPHost option. 
- 
setSMTPPort
public void setSMTPPort(int port)
Deprecated.Alias forsetSmtpPort(int).- Parameters:
 port-
 
- 
setSmtpPort
public void setSmtpPort(int port)
Deprecated.The port where the SMTP server is running. Default value is 25.- Parameters:
 port-
 
- 
getSMTPPort
public int getSMTPPort()
Deprecated.Alias forgetSmtpPort()- Returns:
 
 
- 
getSmtpPort
public int getSmtpPort()
Deprecated.SeesetSmtpPort(int)- Returns:
 
 
- 
getLocalhost
public java.lang.String getLocalhost()
Deprecated. 
- 
setLocalhost
public void setLocalhost(java.lang.String localhost)
Deprecated.Set the "mail.smtp.localhost" property to the value passed as parameter to this method.Useful in case the hostname for the client host is not fully qualified and as a consequence the SMTP server rejects the clients HELO/EHLO command.
- Parameters:
 localhost-
 
- 
getCyclicBufferTracker
public CyclicBufferTracker<E> getCyclicBufferTracker()
Deprecated. 
- 
setCyclicBufferTracker
public void setCyclicBufferTracker(CyclicBufferTracker<E> cbTracker)
Deprecated. 
- 
getDiscriminator
public Discriminator<E> getDiscriminator()
Deprecated. 
- 
setDiscriminator
public void setDiscriminator(Discriminator<E> discriminator)
Deprecated. 
- 
isAsynchronousSending
public boolean isAsynchronousSending()
Deprecated. 
- 
setAsynchronousSending
public void setAsynchronousSending(boolean asynchronousSending)
Deprecated.By default, SMTAppender transmits emails asynchronously. For synchronous email transmission set asynchronousSending to 'false'.- Parameters:
 asynchronousSending- determines whether sending is done asynchronously or not- Since:
 - 1.0.4
 
 
- 
addTo
public void addTo(java.lang.String to)
Deprecated. 
- 
getToAsListOfString
public java.util.List<java.lang.String> getToAsListOfString()
Deprecated. 
- 
isSTARTTLS
public boolean isSTARTTLS()
Deprecated. 
- 
setSTARTTLS
public void setSTARTTLS(boolean startTLS)
Deprecated. 
- 
isSSL
public boolean isSSL()
Deprecated. 
- 
setSSL
public void setSSL(boolean ssl)
Deprecated. 
- 
setEvaluator
public void setEvaluator(EventEvaluator<E> eventEvaluator)
Deprecated.The EventEvaluator option takes a string value representing the name of the class implementing theEventEvaluatorinterface. A corresponding object will be instantiated and assigned as the event evaluator for the SMTPAppender. 
- 
getUsername
public java.lang.String getUsername()
Deprecated. 
- 
setUsername
public void setUsername(java.lang.String username)
Deprecated. 
- 
getPassword
public java.lang.String getPassword()
Deprecated. 
- 
setPassword
public void setPassword(java.lang.String password)
Deprecated. 
- 
getCharsetEncoding
public java.lang.String getCharsetEncoding()
Deprecated.- Returns:
 - the charset encoding value
 - See Also:
 setCharsetEncoding(String)
 
- 
getJndiLocation
public java.lang.String getJndiLocation()
Deprecated. 
- 
setJndiLocation
public void setJndiLocation(java.lang.String jndiLocation)
Deprecated.Set the location where aSessionresource is located in JNDI. Default value is "java:comp/env/mail/Session".- Parameters:
 jndiLocation-- Since:
 - 1.0.6
 
 
- 
isSessionViaJNDI
public boolean isSessionViaJNDI()
Deprecated. 
- 
setSessionViaJNDI
public void setSessionViaJNDI(boolean sessionViaJNDI)
Deprecated.If set to true, aSessionresource will be retrieved from JNDI. Default is false.- Parameters:
 sessionViaJNDI- whether to obtain a javax.mail.Session by JNDI- Since:
 - 1.0.6
 
 
- 
setCharsetEncoding
public void setCharsetEncoding(java.lang.String charsetEncoding)
Deprecated.Set the character set encoding of the outgoing email messages. The default encoding is "UTF-8" which usually works well for most purposes.- Parameters:
 charsetEncoding-
 
 - 
 
 -