|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.avalon.excalibur.testcase.ComponentStateValidator
public final class ComponentStateValidator
This class provides basic facilities for enforcing Avalon's contracts within your own code. Based on Avalon version from Sandbox.
| Constructor Summary | |
|---|---|
ComponentStateValidator(Object object)
Deprecated. Create state validator from object (this can be used for more than just components). |
|
| Method Summary | |
|---|---|
void |
checkActive()
Deprecated. Checks to see if the state is active. |
void |
checkActive(String message)
Deprecated. Checks to see if the state is active. |
void |
checkComposed()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkComposed(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkConfigured()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkConfigured(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkContextualized()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkContextualized(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkDisposed()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkDisposed(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkInitialized()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkInitialized(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkLogEnabled()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkLogEnabled(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkLoggable()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkLoggable(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkNotAssigned(Object object)
Deprecated. Make sure object has not been assigned yet. |
void |
checkNotAssigned(Object object,
String message)
Deprecated. Make sure object has not been assigned yet. |
void |
checkParameterized()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkParameterized(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkResumed()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkResumed(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkServiced()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkServiced(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkStarted()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkStarted(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkStopped()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkStopped(String message)
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkSuspended()
Deprecated. Throw an exception if the initialization is out of order. |
void |
checkSuspended(String message)
Deprecated. Throw an exception if the initialization is out of order. |
boolean |
isActive()
Deprecated. Checks to see if the state is active, and returns true or false. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ComponentStateValidator(Object object)
| Method Detail |
|---|
public void checkLogEnabled()
IllegalStateException - if the state is manage out of orderpublic void checkLogEnabled(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkLoggable()
IllegalStateException - if the state is manage out of orderpublic void checkLoggable(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkContextualized()
IllegalStateException - if the state is manage out of orderpublic void checkContextualized(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkServiced()
IllegalStateException - if the state is manage out of orderpublic void checkServiced(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkComposed()
IllegalStateException - if the state is manage out of orderpublic void checkComposed(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkConfigured()
IllegalStateException - if the state is manage out of orderpublic void checkConfigured(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkParameterized()
IllegalStateException - if the state is manage out of orderpublic void checkParameterized(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkInitialized()
initialize stage.
IllegalStateException - if the state is manage out of orderpublic void checkInitialized(String message)
initialize stage.
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkStarted()
start stage.
IllegalStateException - if the state is manage out of orderpublic void checkStarted(String message)
start stage.
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkSuspended()
IllegalStateException - if the state is manage out of orderpublic void checkSuspended(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkResumed()
IllegalStateException - if the state is manage out of orderpublic void checkResumed(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkStopped()
IllegalStateException - if the state is manage out of orderpublic void checkStopped(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkDisposed()
IllegalStateException - if the state is manage out of orderpublic void checkDisposed(String message)
message - the message to include in the thrown exception
IllegalStateException - if the state is manage out of orderpublic void checkActive()
IllegalStateException - if the component is not activepublic void checkActive(String message)
message - the message to include in the thrown exception
IllegalStateException - if the component is not activepublic boolean isActive()
true if active, false if notpublic void checkNotAssigned(Object object)
object - to test
IllegalStateException - if the state is manage out of order
public void checkNotAssigned(Object object,
String message)
object - to testmessage - the message to include in the thrown exception
IllegalStateException - if the state is manage out of order
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||