net.sf.sasl.aop
Class AbstractRootAspect
java.lang.Object
net.sf.sasl.aop.AbstractRootAspect
- All Implemented Interfaces:
- org.springframework.core.Ordered, org.springframework.core.PriorityOrdered
- Direct Known Subclasses:
- AbstractPlaceholderScriptUsingAspect, DistributedLockAspect, ServiceExceptionFirewallAspect
public abstract class AbstractRootAspect
- extends Object
- implements org.springframework.core.PriorityOrdered
Abstract aspect root class from which aspects could be derived.
Offers standard properties which are needed by a large set of aspects.
- Since:
- 0.0.2 (sasl-common-aspect-library)
- Author:
- Philipp Förmer
Field Summary |
protected org.slf4j.Logger |
logger
Used for log output. |
Fields inherited from interface org.springframework.core.Ordered |
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE |
Method Summary |
org.slf4j.Logger |
getLogger()
|
int |
getOrder()
|
void |
setLogger(org.slf4j.Logger logger)
Sets the logger which will be used by the aspect for log output. |
void |
setLoggerByName(String loggerName)
Sets the logger (by name) which will be used by the aspect for log
output. |
void |
setOrder(int order)
Sets the priority value of this aspect. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected org.slf4j.Logger logger
- Used for log output.
- Since:
- 0.0.2 (sasl-common-aspect-library)
AbstractRootAspect
public AbstractRootAspect()
setOrder
public void setOrder(int order)
- Sets the priority value of this aspect. The priority value will be used
by spring to order the execution of aspects for the same join point.
Lower values mean a higher priority and higher priority aspects run
before lower priority aspects. As of this a lower priority aspect is
nested into a higher priority aspect (only holds for around aspects).
The default setted priority is
LOWEST_PRECEDENCE
.
- Parameters:
order
- any integer value- Since:
- 0.0.2 (sasl-common-aspect-library)
getOrder
public int getOrder()
- Specified by:
getOrder
in interface org.springframework.core.Ordered
- Since:
- 0.0.2 (sasl-common-aspect-library)
- See Also:
setOrder(int)
,
Ordered.getOrder()
setLoggerByName
public void setLoggerByName(String loggerName)
throws IllegalArgumentException
- Sets the logger (by name) which will be used by the aspect for log
output.
- Parameters:
loggerName
- non null.
- Throws:
IllegalArgumentException
- if loggerName is null.- Since:
- 0.0.2 (sasl-common-aspect-library)
getLogger
public org.slf4j.Logger getLogger()
- Returns:
- non null
- Since:
- 0.0.2 (sasl-common-aspect-library)
- See Also:
setLogger(Logger)
setLogger
public void setLogger(org.slf4j.Logger logger)
throws IllegalArgumentException
- Sets the logger which will be used by the aspect for log output.
- Parameters:
logger
- non null.
- Throws:
IllegalArgumentException
- if logger is null.- Since:
- 0.0.2 (sasl-common-aspect-library)
Copyright © 2010. All Rights Reserved.