Package org.jboss.logmanager.config
Class HandlerConfigurationImpl
java.lang.Object
org.jboss.logmanager.config.AbstractBasicConfiguration<Handler,HandlerConfigurationImpl>
org.jboss.logmanager.config.AbstractPropertyConfiguration<Handler,HandlerConfigurationImpl>
org.jboss.logmanager.config.HandlerConfigurationImpl
- All Implemented Interfaces:
HandlerConfiguration
,HandlerContainingConfigurable
,NamedConfigurable
,ObjectConfigurable
,PropertyConfigurable
final class HandlerConfigurationImpl
extends AbstractPropertyConfiguration<Handler,HandlerConfigurationImpl>
implements HandlerConfiguration
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jboss.logmanager.config.AbstractPropertyConfiguration
AbstractPropertyConfiguration.ConstructAction, AbstractPropertyConfiguration.ModuleFinder
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ValueExpression
<String> private ValueExpression
<String> private ValueExpression
<String> private ValueExpression
<String> private ValueExpression
<String> Fields inherited from class org.jboss.logmanager.config.AbstractBasicConfiguration
configs, refs
-
Constructor Summary
ConstructorsConstructorDescriptionHandlerConfigurationImpl
(LogContextConfigurationImpl configuration, String name, String moduleName, String className, String[] constructorProperties) -
Method Summary
Modifier and TypeMethodDescriptionboolean
addHandlerName
(String name) Add a handler name to this logger.(package private) ConfigAction
<Handler> (package private) String
Returns the encoding which may be an expression.Returns the error manager name which may be an expression.Returns a filter that may be an expression.Get the name of the configured formatter for this handler.Gets the formatter name which may be an expression.Get the names of the configured handlers.getLevel()
Gets the level set on the handler.Returns the level that may be an expression.(package private) ConfigAction
<Void> boolean
removeHandlerName
(String name) Remove a handler name from this logger.void
setEncoding
(String encoding) void
setEncoding
(String expression, String value) Sets the expression value for the encoding.private void
setEncoding
(ValueExpression<String> expression) void
setErrorManagerName
(String errorManagerName) void
setErrorManagerName
(String expression, String value) Sets the expression value for the error manager name.private void
setErrorManagerName
(ValueExpression<String> expression) void
void
Sets the expression value and for the filter.private void
setFilter
(ValueExpression<String> expression) void
setFormatterName
(String formatterName) Set the name of the configured formatter for this handler.void
setFormatterName
(String expression, String value) Sets the expression value for the formatter name.private void
setFormatterName
(ValueExpression<String> expression) void
setHandlerNames
(String... names) Set the names of the configured handlers.void
setHandlerNames
(Collection<String> names) Set the names of the configured handlers.void
Sets the level on the handler.void
Sets the expression value for the level.private void
setLevelValueExpression
(ValueExpression<String> expression) Methods inherited from class org.jboss.logmanager.config.AbstractPropertyConfiguration
addPostConfigurationActions, addPostConfigurationMethod, contains, getActualClass, getClassName, getConstructorProperties, getConstructorPropertyType, getModuleName, getPostConfigurationMethods, getPropertyGetter, getPropertyNames, getPropertySetter, getPropertyType, getPropertyValueExpression, getPropertyValueString, hasConstructorProperty, hasProperty, removePostConfigurationActions, removePostConfigurationMethod, removeProperty, setPostConfigurationMethods, setPostConfigurationMethods, setPropertyValueExpression, setPropertyValueExpression, setPropertyValueString
Methods inherited from class org.jboss.logmanager.config.AbstractBasicConfiguration
clearRemoved, getConfigs, getConfiguration, getName, getRefs, isRemoved, setRemoved
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jboss.logmanager.config.NamedConfigurable
getName
Methods inherited from interface org.jboss.logmanager.config.ObjectConfigurable
getClassName, getModuleName
Methods inherited from interface org.jboss.logmanager.config.PropertyConfigurable
addPostConfigurationMethod, getConstructorProperties, getPostConfigurationMethods, getPropertyNames, getPropertyValueExpression, getPropertyValueString, hasConstructorProperty, hasProperty, removePostConfigurationMethod, removeProperty, setPostConfigurationMethods, setPostConfigurationMethods, setPropertyValueExpression, setPropertyValueExpression, setPropertyValueString
-
Field Details
-
handlerNames
-
formatterName
-
level
-
filter
-
encoding
-
errorManagerName
-
-
Constructor Details
-
HandlerConfigurationImpl
HandlerConfigurationImpl(LogContextConfigurationImpl configuration, String name, String moduleName, String className, String[] constructorProperties)
-
-
Method Details
-
getFormatterName
Description copied from interface:HandlerConfiguration
Get the name of the configured formatter for this handler.- Specified by:
getFormatterName
in interfaceHandlerConfiguration
- Returns:
- the formatter name
-
getFormatterNameValueExpression
Description copied from interface:HandlerConfiguration
Gets the formatter name which may be an expression.- Specified by:
getFormatterNameValueExpression
in interfaceHandlerConfiguration
- Returns:
- the formatter name
-
setFormatterName
Description copied from interface:HandlerConfiguration
Set the name of the configured formatter for this handler.- Specified by:
setFormatterName
in interfaceHandlerConfiguration
- Parameters:
formatterName
- the formatter name
-
setFormatterName
Description copied from interface:HandlerConfiguration
Sets the expression value for the formatter name. This method will not parse the expression for the value and instead use thelevel
parameter for the formatter name on the handler.- Specified by:
setFormatterName
in interfaceHandlerConfiguration
- Parameters:
expression
- the expression used to resolve the levelvalue
- the value to set the formatter name to- See Also:
-
setFormatterName
-
getLevel
Description copied from interface:HandlerConfiguration
Gets the level set on the handler.- Specified by:
getLevel
in interfaceHandlerConfiguration
- Returns:
- the level
-
getLevelValueExpression
Description copied from interface:HandlerConfiguration
Returns the level that may be an expression.- Specified by:
getLevelValueExpression
in interfaceHandlerConfiguration
- Returns:
- the level
-
setLevel
Description copied from interface:HandlerConfiguration
Sets the level on the handler.- Specified by:
setLevel
in interfaceHandlerConfiguration
- Parameters:
level
- the level to set, may be an expression- See Also:
-
setLevel
Description copied from interface:HandlerConfiguration
Sets the expression value for the level. This method will not parse the expression for the value and instead use thelevel
parameter for the level on the handler.- Specified by:
setLevel
in interfaceHandlerConfiguration
- Parameters:
expression
- the expression used to resolve the levellevel
- the level to use- See Also:
-
setLevelValueExpression
-
getFilter
- Specified by:
getFilter
in interfaceHandlerConfiguration
-
getFilterValueExpression
Description copied from interface:HandlerConfiguration
Returns a filter that may be an expression.- Specified by:
getFilterValueExpression
in interfaceHandlerConfiguration
- Returns:
- the filter
-
setFilter
- Specified by:
setFilter
in interfaceHandlerConfiguration
-
setFilter
Description copied from interface:HandlerConfiguration
Sets the expression value and for the filter. This method will not parse the expression for the value and instead use thevalue
parameter for the filter on the handler.- Specified by:
setFilter
in interfaceHandlerConfiguration
- Parameters:
expression
- the expressionvalue
- the value to set the filter to
-
setFilter
-
getEncoding
- Specified by:
getEncoding
in interfaceHandlerConfiguration
-
getEncodingValueExpression
Description copied from interface:HandlerConfiguration
Returns the encoding which may be an expression.- Specified by:
getEncodingValueExpression
in interfaceHandlerConfiguration
- Returns:
- the encoding
-
setEncoding
- Specified by:
setEncoding
in interfaceHandlerConfiguration
-
setEncoding
Description copied from interface:HandlerConfiguration
Sets the expression value for the encoding. This method will not parse the expression for the value and instead use thevalue
parameter for the encoding on the handler.- Specified by:
setEncoding
in interfaceHandlerConfiguration
- Parameters:
expression
- the expressionvalue
- the value to set the encoding to- See Also:
-
setEncoding
-
getErrorManagerName
- Specified by:
getErrorManagerName
in interfaceHandlerConfiguration
-
getErrorManagerNameValueExpression
Description copied from interface:HandlerConfiguration
Returns the error manager name which may be an expression.- Specified by:
getErrorManagerNameValueExpression
in interfaceHandlerConfiguration
- Returns:
- the error manager name
-
setErrorManagerName
- Specified by:
setErrorManagerName
in interfaceHandlerConfiguration
-
setErrorManagerName
Description copied from interface:HandlerConfiguration
Sets the expression value for the error manager name. This method will not parse the expression for the value and instead use thevalue
parameter for the error manager name on the handler.- Specified by:
setErrorManagerName
in interfaceHandlerConfiguration
- Parameters:
expression
- the expressionvalue
- the value to set the error manager name to- See Also:
-
setErrorManagerName
-
getHandlerNames
Description copied from interface:HandlerContainingConfigurable
Get the names of the configured handlers.- Specified by:
getHandlerNames
in interfaceHandlerContainingConfigurable
- Returns:
- the names of the configured handlers
-
setHandlerNames
Description copied from interface:HandlerContainingConfigurable
Set the names of the configured handlers.- Specified by:
setHandlerNames
in interfaceHandlerContainingConfigurable
- Parameters:
names
- the names of the configured handlers
-
setHandlerNames
Description copied from interface:HandlerContainingConfigurable
Set the names of the configured handlers.- Specified by:
setHandlerNames
in interfaceHandlerContainingConfigurable
- Parameters:
names
- the names of the configured handlers
-
addHandlerName
Description copied from interface:HandlerContainingConfigurable
Add a handler name to this logger.- Specified by:
addHandlerName
in interfaceHandlerContainingConfigurable
- Parameters:
name
- the handler name- Returns:
true
if the name was not already set,false
if it was
-
removeHandlerName
Description copied from interface:HandlerContainingConfigurable
Remove a handler name from this logger.- Specified by:
removeHandlerName
in interfaceHandlerContainingConfigurable
- Parameters:
name
- the handler name- Returns:
true
if the name was removed,false
if it was not present
-
getDescription
String getDescription()- Specified by:
getDescription
in classAbstractPropertyConfiguration<Handler,
HandlerConfigurationImpl>
-
getConstructAction
ConfigAction<Handler> getConstructAction()- Overrides:
getConstructAction
in classAbstractPropertyConfiguration<Handler,
HandlerConfigurationImpl>
-
getRemoveAction
ConfigAction<Void> getRemoveAction()- Overrides:
getRemoveAction
in classAbstractBasicConfiguration<Handler,
HandlerConfigurationImpl>
-