|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.geronimo.mail.util.SessionUtil
public class SessionUtil
Simple utility class for managing session properties.
| Constructor Summary | |
|---|---|
SessionUtil()
|
|
| Method Summary | |
|---|---|
static boolean |
getBooleanProperty(Session session,
String name,
boolean defaultValue)
Get a property associated with this mail session as a boolean value. |
static boolean |
getBooleanProperty(String name,
boolean defaultValue)
Get a system property associated with this mail session as a boolean value. |
static int |
getIntProperty(Session session,
String name,
int defaultValue)
Get a property associated with this mail session as an integer value. |
static String |
getProperty(Session session,
String name)
Get a property associated with this mail session. |
static String |
getProperty(Session session,
String name,
String defaultValue)
Get a property associated with this mail session. |
static String |
getProperty(String name)
Get a system property associated with this mail session as a boolean value. |
static String |
getProperty(String name,
String defaultValue)
Get a system property associated with this mail session as a boolean value. |
static boolean |
isPropertyFalse(Session session,
String name)
Process a session property as a boolean value, returning either true or false. |
static boolean |
isPropertyTrue(Session session,
String name)
Process a session property as a boolean value, returning either true or false. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SessionUtil()
| Method Detail |
|---|
public static String getProperty(Session session,
String name)
session - The attached session.name - The name of the property.
public static String getProperty(Session session,
String name,
String defaultValue)
session - The attached session.name - The name of the property.defaultValue - The default value to return if the property doesn't exist.
public static boolean isPropertyTrue(Session session,
String name)
session - The source session.name -
public static boolean isPropertyFalse(Session session,
String name)
session - The source session.name -
public static int getIntProperty(Session session,
String name,
int defaultValue)
session - The source session.name - The name of the property.defaultValue - The default value to return if the property doesn't exist.
public static boolean getBooleanProperty(Session session,
String name,
boolean defaultValue)
session - The source session.name - The name of the property.defaultValue - The default value to return if the property doesn't exist.
public static boolean getBooleanProperty(String name,
boolean defaultValue)
name - The name of the property.defaultValue - The default value to return if the property doesn't exist.
public static String getProperty(String name,
String defaultValue)
name - The name of the property.defaultValue - The default value to return if the property doesn't exist.
public static String getProperty(String name)
name - The name of the property.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||