public class SessionProperties extends Object
Constructor and Description |
---|
SessionProperties(javax.mail.Session session)
Constructs a new instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
getBooleanProperty(String name,
boolean defaultValue)
Gets a boolean property value.
|
String |
getProperty(String name)
Gets a property value.
|
String |
getRequiredProperty(String name)
Gets a required property value.
|
public SessionProperties(javax.mail.Session session)
session
- public String getProperty(String name)
name
- name of the propertynull
if no value is set for the given
namepublic String getRequiredProperty(String name) throws javax.mail.MessagingException
name
- name of the propertyjavax.mail.MessagingException
- if the property is not setpublic boolean getBooleanProperty(String name, boolean defaultValue) throws javax.mail.MessagingException
name
- name of the propertydefaultValue
- value to return if none is setjavax.mail.MessagingException
- if the property is not set to a legitimate
boolean valueCopyright © 2014–2018. All rights reserved.