Package org.jboss.as.logging
Class LoggingProfileContextSelector
- java.lang.Object
-
- org.jboss.as.logging.LoggingProfileContextSelector
-
public final class LoggingProfileContextSelector extends Object
- Author:
- James R. Perkins
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanexists(String loggingProfile)Checks to see if the logging profile has a log context associated with it.org.jboss.logmanager.LogContextget(String loggingProfile)Returns the log context associated with the logging profile ornullif the logging profile does not have an associated log context.static LoggingProfileContextSelectorgetInstance()protected org.jboss.logmanager.LogContextgetOrCreate(String loggingProfile)Get or create the log context based on the logging profile.org.jboss.logmanager.LogContextremove(String loggingProfile)Removes the associated log context from the logging profile.
-
-
-
Method Detail
-
getInstance
public static LoggingProfileContextSelector getInstance()
-
getOrCreate
protected org.jboss.logmanager.LogContext getOrCreate(String loggingProfile)
Get or create the log context based on the logging profile.- Parameters:
loggingProfile- the logging profile to get or create the log context for- Returns:
- the log context that was found or a new log context
-
get
public org.jboss.logmanager.LogContext get(String loggingProfile)
Returns the log context associated with the logging profile ornullif the logging profile does not have an associated log context.- Parameters:
loggingProfile- the logging profile associated with the log context- Returns:
- the log context or
nullif the logging profile is not associated with a log context
-
exists
public boolean exists(String loggingProfile)
Checks to see if the logging profile has a log context associated with it.- Parameters:
loggingProfile- the logging profile to check- Returns:
trueif the logging profile has an associated log context, otherwisefalse
-
remove
public org.jboss.logmanager.LogContext remove(String loggingProfile)
Removes the associated log context from the logging profile.- Parameters:
loggingProfile- the logging profile associated with the log context- Returns:
- the log context that was removed or
nullif there was no log context associated
-
-