Package com.jme3.app.state
Class ConstantVerifierState
java.lang.Object
com.jme3.app.state.BaseAppState
com.jme3.app.state.ConstantVerifierState
- All Implemented Interfaces:
AppState
Checks the various JME 'constants' for drift using either asserts
or straight checks. The list of constants can also be configured
but defaults to the standard JME Vector3f, Quaternion, etc. constants.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionCreates a verifier app state that will check all of the default constant checks using asserts.Creates a verifier app state that will check all of the default constant checks using the specified error reporting mechanism. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddChecker(Object constant, Object goodValue) protected voidprotected voidcleanup(Application app) Called after the app state is detached or during application shutdown if the state is still attached.protected voidinitialize(Application app) Called during initialization once the app state is attached and before onEnable() is called.protected voidCalled when the state was previously enabled but is now disabled either because setEnabled(false) was called or the state is being cleaned up.protected voidonEnable()Called when the state is fully enabled, ie: is attached and isEnabled() is true or when the setEnabled() status changes after the state is attached.voidCalled after all rendering commands are flushed.voidsetErrorType(ConstantVerifierState.ErrorType errorType) Methods inherited from class com.jme3.app.state.BaseAppState
cleanup, getApplication, getId, getState, getState, getState, getState, getStateManager, initialize, isEnabled, isInitialized, render, setEnabled, setId, stateAttached, stateDetached, update
-
Constructor Details
-
ConstantVerifierState
public ConstantVerifierState()Creates a verifier app state that will check all of the default constant checks using asserts. -
ConstantVerifierState
Creates a verifier app state that will check all of the default constant checks using the specified error reporting mechanism.- Parameters:
errorType- the mechanism to use
-
-
Method Details
-
addChecker
-
setErrorType
-
getErrorType
-
initialize
Description copied from class:BaseAppStateCalled during initialization once the app state is attached and before onEnable() is called.- Specified by:
initializein classBaseAppState- Parameters:
app- the application
-
cleanup
Description copied from class:BaseAppStateCalled after the app state is detached or during application shutdown if the state is still attached. onDisable() is called before this cleanup() method if the state is enabled at the time of cleanup.- Specified by:
cleanupin classBaseAppState- Parameters:
app- the application
-
onEnable
protected void onEnable()Description copied from class:BaseAppStateCalled when the state is fully enabled, ie: is attached and isEnabled() is true or when the setEnabled() status changes after the state is attached.- Specified by:
onEnablein classBaseAppState
-
onDisable
protected void onDisable()Description copied from class:BaseAppStateCalled when the state was previously enabled but is now disabled either because setEnabled(false) was called or the state is being cleaned up.- Specified by:
onDisablein classBaseAppState
-
postRender
public void postRender()Description copied from interface:AppStateCalled after all rendering commands are flushed. This method will be called every render pass if theAppStateis both attached and enabled.- Specified by:
postRenderin interfaceAppState- Overrides:
postRenderin classBaseAppState
-
checkValues
protected void checkValues()
-