org.sandev.basics.Authorizer
Class AuthorizerNodeBase

java.lang.Object
  extended byorg.sandev.basics.Authorizer.AuthorizerNodeDecl
      extended byorg.sandev.basics.Authorizer.AuthorizerNodeBase
All Implemented Interfaces:
Controllable, Loggable, Messageable
Direct Known Subclasses:
AuthorizerNode

public class AuthorizerNodeBase
extends AuthorizerNodeDecl
implements Controllable, Messageable, Loggable

AUTOGENERATED FILE, DO NOT EDIT DIRECTLY.
source: org.sandev.basics.Authorizer.AuthorizerNodeDecl
generator: org.sandev.generator.NodeClassGenerator
time: Dec 2, 2005 6:38:50 PM

This file contains:


Field Summary
protected  ControlWrapper[] ctrlwrappers
          The control wrappers we need to notify of state or parameter changes.
protected  Controllable[] helperNodes
          Our helper nodes
protected static int LOGDEBUG
          Convenience redeclaration of corresponding Logger.LOGLEVEL constant
protected static int LOGERROR
          Convenience redeclaration of corresponding Logger.LOGLEVEL constant
protected static int LOGFATAL
          Convenience redeclaration of corresponding Logger.LOGLEVEL constant
protected  Logger logger
          Logfile output at specified severity levels.
protected static int LOGINFO
          Convenience redeclaration of corresponding Logger.LOGLEVEL constant
protected  int logLevel
          Calls to log with severity levels less than this value will be ignored.
static int LOGLEVEL_DEBUG
          Possible value for logLevel
static int LOGLEVEL_ERROR
          Possible value for logLevel
static int LOGLEVEL_FATAL
          Possible value for logLevel
static int LOGLEVEL_INFO
          Possible value for logLevel
static int LOGLEVEL_WARN
          Possible value for logLevel
protected static int LOGWARN
          Convenience redeclaration of corresponding Logger.LOGLEVEL constant
protected  Messager messager
          Communications to and from this node.
protected  NodeInstance nodeInstance
          The declaration used to initialize this node instance when it was first created.
protected  Controllable parent
          Our parent node
protected  java.lang.String sandNodeErrorMessage
          Text details of the node execution error.
protected  int sandNodeState
          Runtime state of the node.
static int SANDNODESTATE_FAILED
          Possible value for sandNodeState
static int SANDNODESTATE_FAILING
          Possible value for sandNodeState
static int SANDNODESTATE_RESUMING
          Possible value for sandNodeState
static int SANDNODESTATE_RUNNING
          Possible value for sandNodeState
static int SANDNODESTATE_STARTING
          Possible value for sandNodeState
static int SANDNODESTATE_STOPPED
          Possible value for sandNodeState
static int SANDNODESTATE_STOPPING
          Possible value for sandNodeState
static int SANDNODESTATE_SUSPENDED
          Possible value for sandNodeState
static int SANDNODESTATE_SUSPENDING
          Possible value for sandNodeState
static int SANDNODESTATE_UNDEFINED
          Possible value for sandNodeState
protected  SandRoot sandRoot
          Back reference to the SandRoot that launched us.
 
Fields inherited from class org.sandev.basics.Authorizer.AuthorizerNodeDecl
authFilterClassName, authUserLookupInstanceName, encryptorName, lookupInstanceName, serializerClassName
 
Fields inherited from interface org.sandev.basics.nodecommon.Controllable
OPERATION_FAIL, OPERATION_RESUME, OPERATION_SHUTDOWN, OPERATION_STARTUP, OPERATION_STR_FAIL, OPERATION_STR_RESUME, OPERATION_STR_SHUTDOWN, OPERATION_STR_STARTUP, OPERATION_STR_SUSPEND, OPERATION_STR_UNDEFINED, OPERATION_STRINGS, OPERATION_SUSPEND, OPERATION_UNDEFINED, SHUTDOWN_ERROR_RESTART_GLOBAL, SHUTDOWN_ERROR_RESTART_LOCAL, SHUTDOWN_ERROR_TERMINATE, SHUTDOWN_NORMAL, STATE_FAILED, STATE_FAILING, STATE_RESUMING, STATE_RUNNING, STATE_STARTING, STATE_STOPPED, STATE_STOPPING, STATE_STR_FAILED, STATE_STR_FAILING, STATE_STR_RESUMING, STATE_STR_RUNNING, STATE_STR_STARTING, STATE_STR_STOPPED, STATE_STR_STOPPING, STATE_STR_SUSPENDED, STATE_STR_SUSPENDING, STATE_STR_UNDEFINED, STATE_STRINGS, STATE_SUSPENDED, STATE_SUSPENDING, STATE_UNDEFINED
 
Constructor Summary
AuthorizerNodeBase()
          Default constructor calls init.
 
Method Summary
 void addWrapper(ControlWrapper wrapper)
          Add the specified wrapper to our notification collection
 void deliver(SandMessage msg)
          Only those deliver methods explicitely declared by the node should actually be called.
 boolean fieldHasFlag(java.lang.String fieldname, int fieldflag)
          Return true if the named field declares the indicated flag, false otherwise.
 java.lang.String getAuthFilterClassName()
          Accessor for authFilterClassName
static java.lang.String getAuthFilterClassNameDefaultValue()
          Default value for authFilterClassName.
 java.lang.String getAuthFilterClassNameFieldPrintValue()
          Return the print name of the authFilterClassName field.
static boolean getAuthFilterClassNameFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getAuthFilterClassNameInvalidValue()
          Invalid value for authFilterClassName.
static int getAuthFilterClassNameLengthMax()
          Maximum authFilterClassName length is 120 characters
static int getAuthFilterClassNameLengthNorm()
          Normal authFilterClassName length is 60 characters
 java.lang.String getAuthFilterClassNameMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getAuthFilterClassNamePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getAuthFilterClassNameRange()
          Return the range specification for this field
 java.lang.String getAuthFilterClassNameValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 java.lang.String getAuthUserLookupInstanceName()
          Accessor for authUserLookupInstanceName
static java.lang.String getAuthUserLookupInstanceNameDefaultValue()
          Default value for authUserLookupInstanceName.
 java.lang.String getAuthUserLookupInstanceNameFieldPrintValue()
          Return the print name of the authUserLookupInstanceName field.
static boolean getAuthUserLookupInstanceNameFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getAuthUserLookupInstanceNameInvalidValue()
          Invalid value for authUserLookupInstanceName.
static int getAuthUserLookupInstanceNameLengthMax()
          Maximum authUserLookupInstanceName length is 70 characters
static int getAuthUserLookupInstanceNameLengthNorm()
          Normal authUserLookupInstanceName length is 30 characters
 java.lang.String getAuthUserLookupInstanceNameMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getAuthUserLookupInstanceNamePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getAuthUserLookupInstanceNameRange()
          Return the range specification for this field
 java.lang.String getAuthUserLookupInstanceNameValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 java.lang.String getEncryptorName()
          Accessor for encryptorName
static java.lang.String getEncryptorNameDefaultValue()
          Default value for encryptorName.
 java.lang.String getEncryptorNameFieldPrintValue()
          Return the print name of the encryptorName field.
static boolean getEncryptorNameFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getEncryptorNameInvalidValue()
          Invalid value for encryptorName.
static int getEncryptorNameLengthMax()
          Maximum encryptorName length is 120 characters
static int getEncryptorNameLengthNorm()
          Normal encryptorName length is 60 characters
 java.lang.String getEncryptorNameMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getEncryptorNamePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getEncryptorNameRange()
          Return the range specification for this field
 java.lang.String getEncryptorNameValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 Controllable[] getHelperNodes()
          accessor for helperNodes
 IDCache getIDCache()
          Stub for retrieving the IDCache used by this node.
 Logger getLogger()
          Accessor for logger
static Logger getLoggerDefaultValue()
          Default value for logger.
 java.lang.String getLoggerFieldPrintValue()
          Return the print name of the logger field.
static boolean getLoggerFlag(int fieldflag)
          Field flag accessor.
static Logger getLoggerInvalidValue()
          Invalid value for logger.
 java.lang.String getLoggerMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getLoggerPrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getLoggerRange()
          Return the range specification for this field
 java.lang.String getLoggerValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 int getLogLevel()
          Accessor for logLevel
static java.lang.String[] getLogLevelActualVals()
          Return an array of the possible values for this field as Strings.
static int getLogLevelDefaultValue()
          Default value for logLevel.
static java.lang.String getLogLevelEnumSummary()
          Return a single String summary of the possible enum values for debug and similar purposes.
 java.lang.String getLogLevelFieldPrintValue()
          Return the print name of the logLevel field.
static boolean getLogLevelFlag(int fieldflag)
          Field flag accessor.
static int getLogLevelInvalidValue()
          Invalid value for logLevel.
static java.lang.String[] getLogLevelKeyVals()
          Return an array of unique keys for the values of this field.
 java.lang.String getLogLevelMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
static java.lang.String[] getLogLevelPrintVals()
          Return an array of the possible values for this field in display format.
 java.lang.String getLogLevelPrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getLogLevelRange()
          Return the range specification for this field
 java.lang.String getLogLevelValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 java.lang.String getLookupInstanceName()
          Accessor for lookupInstanceName
static java.lang.String getLookupInstanceNameDefaultValue()
          Default value for lookupInstanceName.
 java.lang.String getLookupInstanceNameFieldPrintValue()
          Return the print name of the lookupInstanceName field.
static boolean getLookupInstanceNameFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getLookupInstanceNameInvalidValue()
          Invalid value for lookupInstanceName.
static int getLookupInstanceNameLengthMax()
          Maximum lookupInstanceName length is 70 characters
static int getLookupInstanceNameLengthNorm()
          Normal lookupInstanceName length is 30 characters
 java.lang.String getLookupInstanceNameMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getLookupInstanceNamePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getLookupInstanceNameRange()
          Return the range specification for this field
 java.lang.String getLookupInstanceNameValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 Messager getMessager()
          Accessor for messager
static Messager getMessagerDefaultValue()
          Default value for messager.
 java.lang.String getMessagerFieldPrintValue()
          Return the print name of the messager field.
static boolean getMessagerFlag(int fieldflag)
          Field flag accessor.
static Messager getMessagerInvalidValue()
          Invalid value for messager.
 java.lang.String getMessagerMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getMessagerPrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getMessagerRange()
          Return the range specification for this field
 java.lang.String getMessagerValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 NodeInstance getNodeInstance()
          Accessor for nodeInstance
static NodeInstance getNodeInstanceDefaultValue()
          Default value for nodeInstance.
 java.lang.String getNodeInstanceFieldPrintValue()
          Return the print name of the nodeInstance field.
static boolean getNodeInstanceFlag(int fieldflag)
          Field flag accessor.
static NodeInstance getNodeInstanceInvalidValue()
          Invalid value for nodeInstance.
 java.lang.String getNodeInstanceMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getNodeInstanceName()
          convenience wrapper method to retrieve our instance name
 java.lang.String getNodeInstancePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getNodeInstanceRange()
          Return the range specification for this field
 java.lang.String getNodeInstanceValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 Controllable getParent()
          accessor for parent
 java.lang.String getSandNodeErrorMessage()
          Accessor for sandNodeErrorMessage
static java.lang.String getSandNodeErrorMessageDefaultValue()
          Default value for sandNodeErrorMessage.
 java.lang.String getSandNodeErrorMessageFieldPrintValue()
          Return the print name of the sandNodeErrorMessage field.
static boolean getSandNodeErrorMessageFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getSandNodeErrorMessageInvalidValue()
          Invalid value for sandNodeErrorMessage.
static int getSandNodeErrorMessageLengthMax()
          Maximum sandNodeErrorMessage length is 70 characters
static int getSandNodeErrorMessageLengthNorm()
          Normal sandNodeErrorMessage length is 30 characters
 java.lang.String getSandNodeErrorMessageMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getSandNodeErrorMessagePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getSandNodeErrorMessageRange()
          Return the range specification for this field
 java.lang.String getSandNodeErrorMessageValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 int getSandNodeState()
          Accessor for sandNodeState
static java.lang.String[] getSandNodeStateActualVals()
          Return an array of the possible values for this field as Strings.
static int getSandNodeStateDefaultValue()
          Default value for sandNodeState.
static java.lang.String getSandNodeStateEnumSummary()
          Return a single String summary of the possible enum values for debug and similar purposes.
 java.lang.String getSandNodeStateFieldPrintValue()
          Return the print name of the sandNodeState field.
static boolean getSandNodeStateFlag(int fieldflag)
          Field flag accessor.
static int getSandNodeStateInvalidValue()
          Invalid value for sandNodeState.
static java.lang.String[] getSandNodeStateKeyVals()
          Return an array of unique keys for the values of this field.
 java.lang.String getSandNodeStateMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
static java.lang.String[] getSandNodeStatePrintVals()
          Return an array of the possible values for this field in display format.
 java.lang.String getSandNodeStatePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getSandNodeStateRange()
          Return the range specification for this field
 java.lang.String getSandNodeStateValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 SandRoot getSandRoot()
          accessor for sandRoot
 java.lang.String getSerializerClassName()
          Accessor for serializerClassName
static java.lang.String getSerializerClassNameDefaultValue()
          Default value for serializerClassName.
 java.lang.String getSerializerClassNameFieldPrintValue()
          Return the print name of the serializerClassName field.
static boolean getSerializerClassNameFlag(int fieldflag)
          Field flag accessor.
static java.lang.String getSerializerClassNameInvalidValue()
          Invalid value for serializerClassName.
static int getSerializerClassNameLengthMax()
          Maximum serializerClassName length is 120 characters
static int getSerializerClassNameLengthNorm()
          Normal serializerClassName length is 60 characters
 java.lang.String getSerializerClassNameMetatype()
          Return the metatype text for this field, or "" if no metatype was declared.
 java.lang.String getSerializerClassNamePrintValue()
          Retrieve the current value of this field as a print String.
 java.lang.String getSerializerClassNameRange()
          Return the range specification for this field
 java.lang.String getSerializerClassNameValidityCheck()
          Return the empty string if the value of this field is valid according to the base SAND declarations.
 java.lang.String getServername()
          convenience wrapper method to retrieve our home server name
 void init()
          Initialize all fields to their default values
 void log(int severity, java.lang.String msg)
          Log the message with the specified severity.
 void log(java.lang.String msg)
          Shorthand for log(Logger.LOGLEVEL_INFO,msg)
static java.lang.String logLevelActual2Print(java.lang.String actualVal)
          Utility method to transform an actual value for this field into a print value.
 int logLevelLabelToValue(java.lang.String label)
          Given a label, return the value for it.
static java.lang.String logLevelPrint2Actual(java.lang.String printVal)
          Utility method to transform a print value for this field into an actual value.
static java.lang.String logLevelPrint2Key(java.lang.String printVal)
          Utility method to transform a print value for this field into a key value.
 java.lang.String logLevelValueToLabel(int val)
          Given a value, return the declared label for it.
protected  void notifyStateChange(int prevState, int currState)
          Notify our registered control wrappers of our state change
protected  void onFailure()
          Override this method to do work when the node enters the failed state.
protected  void onRestart()
          Override this method to do work during startup().
protected  void onResume()
          Override this method to do work during resume().
protected  void onShutdown()
          Override this method to do work during shutdown().
protected  void onStartup()
          Override this method to do work during startup().
protected  void onSuspend()
          Override this method to do work during suspend().
 SandMessage receive(SandMessage msg)
          Only those receive methods explicitely declared by the node should actually be called.
 void restart()
          Restarts a running node by calling shutdown and then startup
 void resume()
          Resumes a suspended node.
static java.lang.String sandNodeStateActual2Print(java.lang.String actualVal)
          Utility method to transform an actual value for this field into a print value.
 int sandNodeStateLabelToValue(java.lang.String label)
          Given a label, return the value for it.
static java.lang.String sandNodeStatePrint2Actual(java.lang.String printVal)
          Utility method to transform a print value for this field into an actual value.
static java.lang.String sandNodeStatePrint2Key(java.lang.String printVal)
          Utility method to transform a print value for this field into a key value.
 java.lang.String sandNodeStateValueToLabel(int val)
          Given a value, return the declared label for it.
 void setAuthFilterClassName(java.lang.Object authFilterClassName)
          Generic mutator for authFilterClassName
 void setAuthFilterClassName(java.lang.String authFilterClassName)
          Mutator for authFilterClassName
 void setAuthUserLookupInstanceName(java.lang.Object authUserLookupInstanceName)
          Generic mutator for authUserLookupInstanceName
 void setAuthUserLookupInstanceName(java.lang.String authUserLookupInstanceName)
          Mutator for authUserLookupInstanceName
 void setEncryptorName(java.lang.Object encryptorName)
          Generic mutator for encryptorName
 void setEncryptorName(java.lang.String encryptorName)
          Mutator for encryptorName
 void setHelperNodes(Controllable[] nodes)
          mutator for helperNodes
 void setLogger(Logger logger)
          Mutator for logger
 void setLogger(java.lang.Object logger)
          Generic mutator for logger
 void setLogLevel(int logLevel)
          Mutator for logLevel
 void setLookupInstanceName(java.lang.Object lookupInstanceName)
          Generic mutator for lookupInstanceName
 void setLookupInstanceName(java.lang.String lookupInstanceName)
          Mutator for lookupInstanceName
 void setMessager(Messager messager)
          Mutator for messager
 void setMessager(java.lang.Object messager)
          Generic mutator for messager
 void setNodeInstance(NodeInstance nodeInstance)
          Mutator for nodeInstance
 void setNodeInstance(java.lang.Object nodeInstance)
          Generic mutator for nodeInstance
 void setParent(Controllable node)
          mutator for parent
 void setSandNodeErrorMessage(java.lang.Object sandNodeErrorMessage)
          Generic mutator for sandNodeErrorMessage
 void setSandNodeErrorMessage(java.lang.String sandNodeErrorMessage)
          Mutator for sandNodeErrorMessage
 void setSandNodeState(int sandNodeState)
          Mutator for sandNodeState
 void setSandRoot(SandRoot val)
          mutator for sandRoot
 void setSerializerClassName(java.lang.Object serializerClassName)
          Generic mutator for serializerClassName
 void setSerializerClassName(java.lang.String serializerClassName)
          Mutator for serializerClassName
protected  void setupSecureReceive()
          Register us for receive with our local Authorizer
protected  void setupSubscriptions()
          Subscribe us to the nodes we need to listen to
 void shutdown()
          Stops a running node.
 void startup()
          Starts a stopped node.
 void suspend()
          Suspends a running node.
 void systemwideShutdown(int code)
          Call our shutdown, which shuts down our local nodes, then cascade this call upward to our parent so it spreads throughout the system as needed.
 boolean validTransition(int transition)
          Validates a state transition by comparing the desired transition with the current state.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sandNodeState

protected int sandNodeState
Runtime state of the node. Must be one of the STATE constants defined in Controllable


SANDNODESTATE_UNDEFINED

public static final int SANDNODESTATE_UNDEFINED
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_RUNNING

public static final int SANDNODESTATE_RUNNING
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_SUSPENDED

public static final int SANDNODESTATE_SUSPENDED
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_STOPPED

public static final int SANDNODESTATE_STOPPED
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_FAILED

public static final int SANDNODESTATE_FAILED
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_STARTING

public static final int SANDNODESTATE_STARTING
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_STOPPING

public static final int SANDNODESTATE_STOPPING
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_SUSPENDING

public static final int SANDNODESTATE_SUSPENDING
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_RESUMING

public static final int SANDNODESTATE_RESUMING
Possible value for sandNodeState

See Also:
Constant Field Values

SANDNODESTATE_FAILING

public static final int SANDNODESTATE_FAILING
Possible value for sandNodeState

See Also:
Constant Field Values

sandNodeErrorMessage

protected java.lang.String sandNodeErrorMessage
Text details of the node execution error.


messager

protected Messager messager
Communications to and from this node.


logger

protected Logger logger
Logfile output at specified severity levels.


logLevel

protected int logLevel
Calls to log with severity levels less than this value will be ignored. For example, if you set this field to LOGLEVEL_WARN, then a call to log with LOGLEVEL_INFO will be ignored, while any call with LOGLEVEL_WARN/ERROR/FATAL will be processed. The log levels are defined in org.sandev.basics.nodecommon.Logger


LOGLEVEL_DEBUG

public static final int LOGLEVEL_DEBUG
Possible value for logLevel

See Also:
Constant Field Values

LOGLEVEL_INFO

public static final int LOGLEVEL_INFO
Possible value for logLevel

See Also:
Constant Field Values

LOGLEVEL_WARN

public static final int LOGLEVEL_WARN
Possible value for logLevel

See Also:
Constant Field Values

LOGLEVEL_ERROR

public static final int LOGLEVEL_ERROR
Possible value for logLevel

See Also:
Constant Field Values

LOGLEVEL_FATAL

public static final int LOGLEVEL_FATAL
Possible value for logLevel

See Also:
Constant Field Values

nodeInstance

protected NodeInstance nodeInstance
The declaration used to initialize this node instance when it was first created. This information is for reference only, it can only be modified within the configuration.


sandRoot

protected SandRoot sandRoot
Back reference to the SandRoot that launched us.


LOGDEBUG

protected static final int LOGDEBUG
Convenience redeclaration of corresponding Logger.LOGLEVEL constant

See Also:
Constant Field Values

LOGINFO

protected static final int LOGINFO
Convenience redeclaration of corresponding Logger.LOGLEVEL constant

See Also:
Constant Field Values

LOGWARN

protected static final int LOGWARN
Convenience redeclaration of corresponding Logger.LOGLEVEL constant

See Also:
Constant Field Values

LOGERROR

protected static final int LOGERROR
Convenience redeclaration of corresponding Logger.LOGLEVEL constant

See Also:
Constant Field Values

LOGFATAL

protected static final int LOGFATAL
Convenience redeclaration of corresponding Logger.LOGLEVEL constant

See Also:
Constant Field Values

parent

protected Controllable parent
Our parent node


helperNodes

protected Controllable[] helperNodes
Our helper nodes


ctrlwrappers

protected ControlWrapper[] ctrlwrappers
The control wrappers we need to notify of state or parameter changes.

Constructor Detail

AuthorizerNodeBase

public AuthorizerNodeBase()
Default constructor calls init.

Method Detail

fieldHasFlag

public boolean fieldHasFlag(java.lang.String fieldname,
                            int fieldflag)
Return true if the named field declares the indicated flag, false otherwise. See the FIELDFLAG* constants in SandInstanceMessage for supported fieldflag values.


getSerializerClassName

public java.lang.String getSerializerClassName()
Accessor for serializerClassName


setSerializerClassName

public void setSerializerClassName(java.lang.String serializerClassName)
Mutator for serializerClassName


setSerializerClassName

public void setSerializerClassName(java.lang.Object serializerClassName)
Generic mutator for serializerClassName


getSerializerClassNameFlag

public static boolean getSerializerClassNameFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getSerializerClassNameLengthNorm

public static int getSerializerClassNameLengthNorm()
Normal serializerClassName length is 60 characters


getSerializerClassNameLengthMax

public static int getSerializerClassNameLengthMax()
Maximum serializerClassName length is 120 characters


getSerializerClassNameDefaultValue

public static java.lang.String getSerializerClassNameDefaultValue()
Default value for serializerClassName. Returns "org.sandev.tools.util.XMLSerializer"


getSerializerClassNameInvalidValue

public static java.lang.String getSerializerClassNameInvalidValue()
Invalid value for serializerClassName. Returns "AUTHORIZER_INVALID_SERIALIZER"


getSerializerClassNamePrintValue

public java.lang.String getSerializerClassNamePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getSerializerClassNameFieldPrintValue

public java.lang.String getSerializerClassNameFieldPrintValue()
Return the print name of the serializerClassName field. If no printname is declared then this returns the field name.


getSerializerClassNameRange

public java.lang.String getSerializerClassNameRange()
Return the range specification for this field


getSerializerClassNameValidityCheck

public java.lang.String getSerializerClassNameValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getSerializerClassNameMetatype

public java.lang.String getSerializerClassNameMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getEncryptorName

public java.lang.String getEncryptorName()
Accessor for encryptorName


setEncryptorName

public void setEncryptorName(java.lang.String encryptorName)
Mutator for encryptorName


setEncryptorName

public void setEncryptorName(java.lang.Object encryptorName)
Generic mutator for encryptorName


getEncryptorNameFlag

public static boolean getEncryptorNameFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getEncryptorNameLengthNorm

public static int getEncryptorNameLengthNorm()
Normal encryptorName length is 60 characters


getEncryptorNameLengthMax

public static int getEncryptorNameLengthMax()
Maximum encryptorName length is 120 characters


getEncryptorNameDefaultValue

public static java.lang.String getEncryptorNameDefaultValue()
Default value for encryptorName. Returns "org.sandev.basics.util.NullEncryptor"


getEncryptorNameInvalidValue

public static java.lang.String getEncryptorNameInvalidValue()
Invalid value for encryptorName. Returns "AUTHORIZER_INVALID_ENCRYPTOR"


getEncryptorNamePrintValue

public java.lang.String getEncryptorNamePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getEncryptorNameFieldPrintValue

public java.lang.String getEncryptorNameFieldPrintValue()
Return the print name of the encryptorName field. If no printname is declared then this returns the field name.


getEncryptorNameRange

public java.lang.String getEncryptorNameRange()
Return the range specification for this field


getEncryptorNameValidityCheck

public java.lang.String getEncryptorNameValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getEncryptorNameMetatype

public java.lang.String getEncryptorNameMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getAuthFilterClassName

public java.lang.String getAuthFilterClassName()
Accessor for authFilterClassName


setAuthFilterClassName

public void setAuthFilterClassName(java.lang.String authFilterClassName)
Mutator for authFilterClassName


setAuthFilterClassName

public void setAuthFilterClassName(java.lang.Object authFilterClassName)
Generic mutator for authFilterClassName


getAuthFilterClassNameFlag

public static boolean getAuthFilterClassNameFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getAuthFilterClassNameLengthNorm

public static int getAuthFilterClassNameLengthNorm()
Normal authFilterClassName length is 60 characters


getAuthFilterClassNameLengthMax

public static int getAuthFilterClassNameLengthMax()
Maximum authFilterClassName length is 120 characters


getAuthFilterClassNameDefaultValue

public static java.lang.String getAuthFilterClassNameDefaultValue()
Default value for authFilterClassName. Returns "org.sandev.basics.Authorizer.DummyAuthFilter"


getAuthFilterClassNameInvalidValue

public static java.lang.String getAuthFilterClassNameInvalidValue()
Invalid value for authFilterClassName. Returns "AUTHORIZER_INVALID_AUTHFILTER"


getAuthFilterClassNamePrintValue

public java.lang.String getAuthFilterClassNamePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getAuthFilterClassNameFieldPrintValue

public java.lang.String getAuthFilterClassNameFieldPrintValue()
Return the print name of the authFilterClassName field. If no printname is declared then this returns the field name.


getAuthFilterClassNameRange

public java.lang.String getAuthFilterClassNameRange()
Return the range specification for this field


getAuthFilterClassNameValidityCheck

public java.lang.String getAuthFilterClassNameValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getAuthFilterClassNameMetatype

public java.lang.String getAuthFilterClassNameMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getLookupInstanceName

public java.lang.String getLookupInstanceName()
Accessor for lookupInstanceName


setLookupInstanceName

public void setLookupInstanceName(java.lang.String lookupInstanceName)
Mutator for lookupInstanceName


setLookupInstanceName

public void setLookupInstanceName(java.lang.Object lookupInstanceName)
Generic mutator for lookupInstanceName


getLookupInstanceNameFlag

public static boolean getLookupInstanceNameFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getLookupInstanceNameLengthNorm

public static int getLookupInstanceNameLengthNorm()
Normal lookupInstanceName length is 30 characters


getLookupInstanceNameLengthMax

public static int getLookupInstanceNameLengthMax()
Maximum lookupInstanceName length is 70 characters


getLookupInstanceNameDefaultValue

public static java.lang.String getLookupInstanceNameDefaultValue()
Default value for lookupInstanceName. Returns ""


getLookupInstanceNameInvalidValue

public static java.lang.String getLookupInstanceNameInvalidValue()
Invalid value for lookupInstanceName. Returns null


getLookupInstanceNamePrintValue

public java.lang.String getLookupInstanceNamePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getLookupInstanceNameFieldPrintValue

public java.lang.String getLookupInstanceNameFieldPrintValue()
Return the print name of the lookupInstanceName field. If no printname is declared then this returns the field name.


getLookupInstanceNameRange

public java.lang.String getLookupInstanceNameRange()
Return the range specification for this field


getLookupInstanceNameValidityCheck

public java.lang.String getLookupInstanceNameValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getLookupInstanceNameMetatype

public java.lang.String getLookupInstanceNameMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getAuthUserLookupInstanceName

public java.lang.String getAuthUserLookupInstanceName()
Accessor for authUserLookupInstanceName


setAuthUserLookupInstanceName

public void setAuthUserLookupInstanceName(java.lang.String authUserLookupInstanceName)
Mutator for authUserLookupInstanceName


setAuthUserLookupInstanceName

public void setAuthUserLookupInstanceName(java.lang.Object authUserLookupInstanceName)
Generic mutator for authUserLookupInstanceName


getAuthUserLookupInstanceNameFlag

public static boolean getAuthUserLookupInstanceNameFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getAuthUserLookupInstanceNameLengthNorm

public static int getAuthUserLookupInstanceNameLengthNorm()
Normal authUserLookupInstanceName length is 30 characters


getAuthUserLookupInstanceNameLengthMax

public static int getAuthUserLookupInstanceNameLengthMax()
Maximum authUserLookupInstanceName length is 70 characters


getAuthUserLookupInstanceNameDefaultValue

public static java.lang.String getAuthUserLookupInstanceNameDefaultValue()
Default value for authUserLookupInstanceName. Returns ""


getAuthUserLookupInstanceNameInvalidValue

public static java.lang.String getAuthUserLookupInstanceNameInvalidValue()
Invalid value for authUserLookupInstanceName. Returns null


getAuthUserLookupInstanceNamePrintValue

public java.lang.String getAuthUserLookupInstanceNamePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getAuthUserLookupInstanceNameFieldPrintValue

public java.lang.String getAuthUserLookupInstanceNameFieldPrintValue()
Return the print name of the authUserLookupInstanceName field. If no printname is declared then this returns the field name.


getAuthUserLookupInstanceNameRange

public java.lang.String getAuthUserLookupInstanceNameRange()
Return the range specification for this field


getAuthUserLookupInstanceNameValidityCheck

public java.lang.String getAuthUserLookupInstanceNameValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getAuthUserLookupInstanceNameMetatype

public java.lang.String getAuthUserLookupInstanceNameMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getSandNodeState

public int getSandNodeState()
Accessor for sandNodeState

Specified by:
getSandNodeState in interface Controllable

setSandNodeState

public void setSandNodeState(int sandNodeState)
Mutator for sandNodeState


sandNodeStateValueToLabel

public java.lang.String sandNodeStateValueToLabel(int val)
Given a value, return the declared label for it. This is a conversion method suitable for things like XML serialization where the value must be unique, descriptive, and readable, but is not subject to the same degree of transformation as a UI.


sandNodeStateLabelToValue

public int sandNodeStateLabelToValue(java.lang.String label)
Given a label, return the value for it. This is a conversion method performing the inverse of ValueToLabel. See the comments there for more details.


getSandNodeStatePrintVals

public static java.lang.String[] getSandNodeStatePrintVals()
Return an array of the possible values for this field in display format. These values can be used by a UI directly, or as keys for looking up localized text. These values are not guaranteed to be globally unique, another field with the same possible value may share the same string instance.


getSandNodeStateKeyVals

public static java.lang.String[] getSandNodeStateKeyVals()
Return an array of unique keys for the values of this field. These keys are globally unique and can be used for looking up localized text without any chance of the same key being used by any other field value in the application.


getSandNodeStateActualVals

public static java.lang.String[] getSandNodeStateActualVals()
Return an array of the possible values for this field as Strings. These values can be directly converted to their integer equivalents.


sandNodeStatePrint2Key

public static java.lang.String sandNodeStatePrint2Key(java.lang.String printVal)
Utility method to transform a print value for this field into a key value. See the getSandNodeStatePrintVals and getSandNodeStateKeyVals methods for details.


sandNodeStatePrint2Actual

public static java.lang.String sandNodeStatePrint2Actual(java.lang.String printVal)
Utility method to transform a print value for this field into an actual value. See the getSandNodeStatePrintVals and getSandNodeStateActualVals methods for details.


sandNodeStateActual2Print

public static java.lang.String sandNodeStateActual2Print(java.lang.String actualVal)
Utility method to transform an actual value for this field into a print value. See the getSandNodeStateActualVals and getSandNodeStatePrintVals methods for details.


getSandNodeStateEnumSummary

public static java.lang.String getSandNodeStateEnumSummary()
Return a single String summary of the possible enum values for debug and similar purposes.


getSandNodeStateFlag

public static boolean getSandNodeStateFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getSandNodeStateDefaultValue

public static int getSandNodeStateDefaultValue()
Default value for sandNodeState. Returns 0


getSandNodeStateInvalidValue

public static int getSandNodeStateInvalidValue()
Invalid value for sandNodeState. Returns Integer.MIN_VALUE


getSandNodeStatePrintValue

public java.lang.String getSandNodeStatePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getSandNodeStateFieldPrintValue

public java.lang.String getSandNodeStateFieldPrintValue()
Return the print name of the sandNodeState field. If no printname is declared then this returns the field name.


getSandNodeStateRange

public java.lang.String getSandNodeStateRange()
Return the range specification for this field


getSandNodeStateValidityCheck

public java.lang.String getSandNodeStateValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getSandNodeStateMetatype

public java.lang.String getSandNodeStateMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getSandNodeErrorMessage

public java.lang.String getSandNodeErrorMessage()
Accessor for sandNodeErrorMessage


setSandNodeErrorMessage

public void setSandNodeErrorMessage(java.lang.String sandNodeErrorMessage)
Mutator for sandNodeErrorMessage


setSandNodeErrorMessage

public void setSandNodeErrorMessage(java.lang.Object sandNodeErrorMessage)
Generic mutator for sandNodeErrorMessage


getSandNodeErrorMessageFlag

public static boolean getSandNodeErrorMessageFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getSandNodeErrorMessageLengthNorm

public static int getSandNodeErrorMessageLengthNorm()
Normal sandNodeErrorMessage length is 30 characters


getSandNodeErrorMessageLengthMax

public static int getSandNodeErrorMessageLengthMax()
Maximum sandNodeErrorMessage length is 70 characters


getSandNodeErrorMessageDefaultValue

public static java.lang.String getSandNodeErrorMessageDefaultValue()
Default value for sandNodeErrorMessage. Returns ""


getSandNodeErrorMessageInvalidValue

public static java.lang.String getSandNodeErrorMessageInvalidValue()
Invalid value for sandNodeErrorMessage. Returns null


getSandNodeErrorMessagePrintValue

public java.lang.String getSandNodeErrorMessagePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getSandNodeErrorMessageFieldPrintValue

public java.lang.String getSandNodeErrorMessageFieldPrintValue()
Return the print name of the sandNodeErrorMessage field. If no printname is declared then this returns the field name.


getSandNodeErrorMessageRange

public java.lang.String getSandNodeErrorMessageRange()
Return the range specification for this field


getSandNodeErrorMessageValidityCheck

public java.lang.String getSandNodeErrorMessageValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getSandNodeErrorMessageMetatype

public java.lang.String getSandNodeErrorMessageMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getMessager

public Messager getMessager()
Accessor for messager

Specified by:
getMessager in interface Messageable

setMessager

public void setMessager(Messager messager)
Mutator for messager

Specified by:
setMessager in interface Messageable

setMessager

public void setMessager(java.lang.Object messager)
Generic mutator for messager


getMessagerFlag

public static boolean getMessagerFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getMessagerDefaultValue

public static Messager getMessagerDefaultValue()
Default value for messager. Returns null


getMessagerInvalidValue

public static Messager getMessagerInvalidValue()
Invalid value for messager. Returns null


getMessagerPrintValue

public java.lang.String getMessagerPrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getMessagerFieldPrintValue

public java.lang.String getMessagerFieldPrintValue()
Return the print name of the messager field. If no printname is declared then this returns the field name.


getMessagerRange

public java.lang.String getMessagerRange()
Return the range specification for this field


getMessagerValidityCheck

public java.lang.String getMessagerValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getMessagerMetatype

public java.lang.String getMessagerMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getLogger

public Logger getLogger()
Accessor for logger

Specified by:
getLogger in interface Loggable

setLogger

public void setLogger(Logger logger)
Mutator for logger

Specified by:
setLogger in interface Loggable

setLogger

public void setLogger(java.lang.Object logger)
Generic mutator for logger


getLoggerFlag

public static boolean getLoggerFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getLoggerDefaultValue

public static Logger getLoggerDefaultValue()
Default value for logger. Returns null


getLoggerInvalidValue

public static Logger getLoggerInvalidValue()
Invalid value for logger. Returns null


getLoggerPrintValue

public java.lang.String getLoggerPrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getLoggerFieldPrintValue

public java.lang.String getLoggerFieldPrintValue()
Return the print name of the logger field. If no printname is declared then this returns the field name.


getLoggerRange

public java.lang.String getLoggerRange()
Return the range specification for this field


getLoggerValidityCheck

public java.lang.String getLoggerValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getLoggerMetatype

public java.lang.String getLoggerMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getLogLevel

public int getLogLevel()
Accessor for logLevel

Specified by:
getLogLevel in interface Loggable

setLogLevel

public void setLogLevel(int logLevel)
Mutator for logLevel

Specified by:
setLogLevel in interface Loggable

logLevelValueToLabel

public java.lang.String logLevelValueToLabel(int val)
Given a value, return the declared label for it. This is a conversion method suitable for things like XML serialization where the value must be unique, descriptive, and readable, but is not subject to the same degree of transformation as a UI.


logLevelLabelToValue

public int logLevelLabelToValue(java.lang.String label)
Given a label, return the value for it. This is a conversion method performing the inverse of ValueToLabel. See the comments there for more details.


getLogLevelPrintVals

public static java.lang.String[] getLogLevelPrintVals()
Return an array of the possible values for this field in display format. These values can be used by a UI directly, or as keys for looking up localized text. These values are not guaranteed to be globally unique, another field with the same possible value may share the same string instance.


getLogLevelKeyVals

public static java.lang.String[] getLogLevelKeyVals()
Return an array of unique keys for the values of this field. These keys are globally unique and can be used for looking up localized text without any chance of the same key being used by any other field value in the application.


getLogLevelActualVals

public static java.lang.String[] getLogLevelActualVals()
Return an array of the possible values for this field as Strings. These values can be directly converted to their integer equivalents.


logLevelPrint2Key

public static java.lang.String logLevelPrint2Key(java.lang.String printVal)
Utility method to transform a print value for this field into a key value. See the getLogLevelPrintVals and getLogLevelKeyVals methods for details.


logLevelPrint2Actual

public static java.lang.String logLevelPrint2Actual(java.lang.String printVal)
Utility method to transform a print value for this field into an actual value. See the getLogLevelPrintVals and getLogLevelActualVals methods for details.


logLevelActual2Print

public static java.lang.String logLevelActual2Print(java.lang.String actualVal)
Utility method to transform an actual value for this field into a print value. See the getLogLevelActualVals and getLogLevelPrintVals methods for details.


getLogLevelEnumSummary

public static java.lang.String getLogLevelEnumSummary()
Return a single String summary of the possible enum values for debug and similar purposes.


getLogLevelFlag

public static boolean getLogLevelFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getLogLevelDefaultValue

public static int getLogLevelDefaultValue()
Default value for logLevel. Returns 0


getLogLevelInvalidValue

public static int getLogLevelInvalidValue()
Invalid value for logLevel. Returns Integer.MIN_VALUE


getLogLevelPrintValue

public java.lang.String getLogLevelPrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getLogLevelFieldPrintValue

public java.lang.String getLogLevelFieldPrintValue()
Return the print name of the logLevel field. If no printname is declared then this returns the field name.


getLogLevelRange

public java.lang.String getLogLevelRange()
Return the range specification for this field


getLogLevelValidityCheck

public java.lang.String getLogLevelValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getLogLevelMetatype

public java.lang.String getLogLevelMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getNodeInstance

public NodeInstance getNodeInstance()
Accessor for nodeInstance

Specified by:
getNodeInstance in interface Controllable

setNodeInstance

public void setNodeInstance(NodeInstance nodeInstance)
Mutator for nodeInstance

Specified by:
setNodeInstance in interface Controllable

setNodeInstance

public void setNodeInstance(java.lang.Object nodeInstance)
Generic mutator for nodeInstance


getNodeInstanceFlag

public static boolean getNodeInstanceFlag(int fieldflag)
Field flag accessor. Returns whether the given FIELDFLAG_* (defined in SandInstanceMessage) is true or false.


getNodeInstanceDefaultValue

public static NodeInstance getNodeInstanceDefaultValue()
Default value for nodeInstance. Returns null


getNodeInstanceInvalidValue

public static NodeInstance getNodeInstanceInvalidValue()
Invalid value for nodeInstance. Returns null


getNodeInstancePrintValue

public java.lang.String getNodeInstancePrintValue()
Retrieve the current value of this field as a print String. For a String field, this returns the current value. For int, long, double this returns the standard string conversion. For a Date, this returns the default DateFormat format. For an enum, this returns the Actual2Print translation of the current value. For a struct this returns a summary description.

Used for debug output, and as an initial value for transformation and formatting.


getNodeInstanceFieldPrintValue

public java.lang.String getNodeInstanceFieldPrintValue()
Return the print name of the nodeInstance field. If no printname is declared then this returns the field name.


getNodeInstanceRange

public java.lang.String getNodeInstanceRange()
Return the range specification for this field


getNodeInstanceValidityCheck

public java.lang.String getNodeInstanceValidityCheck()
Return the empty string if the value of this field is valid according to the base SAND declarations. This method supports the fieldValidate method, which is in turn specified by the org.sandev.basics.structs.SandInstanceMessage interface. See the comments there for more information, including a list of error Strings returned from here when a field is not valid.


getNodeInstanceMetatype

public java.lang.String getNodeInstanceMetatype()
Return the metatype text for this field, or "" if no metatype was declared.


getNodeInstanceName

public java.lang.String getNodeInstanceName()
convenience wrapper method to retrieve our instance name


getServername

public java.lang.String getServername()
convenience wrapper method to retrieve our home server name


getSandRoot

public SandRoot getSandRoot()
accessor for sandRoot

Specified by:
getSandRoot in interface Controllable

setSandRoot

public void setSandRoot(SandRoot val)
mutator for sandRoot

Specified by:
setSandRoot in interface Controllable

init

public void init()
Initialize all fields to their default values


log

public void log(int severity,
                java.lang.String msg)
Log the message with the specified severity. Valid severity codes are (in increasing severity order): If the severity specified is less than the logLevel set for this node, then no message is generated. For example if the logLevel is set to INFO, no DEBUG messages are output. If the logLevel is set to WARN, then no INFO or DEBUG messages are output. It is not recommended to set the logLevel to anything higher than WARN.


log

public void log(java.lang.String msg)
Shorthand for log(Logger.LOGLEVEL_INFO,msg)


getIDCache

public IDCache getIDCache()
Stub for retrieving the IDCache used by this node. Override this method in your implementation if you are planning on caching instance data locally.

Specified by:
getIDCache in interface Messageable

startup

public void startup()
             throws ControlException
Starts a stopped node. The helper nodes are started first, then this node is started.

Specified by:
startup in interface Controllable
Throws:
ControlException

shutdown

public void shutdown()
              throws ControlException
Stops a running node. This node is stopped first, and then our helper nodes are stopped.

Specified by:
shutdown in interface Controllable
Throws:
ControlException

suspend

public void suspend()
             throws ControlException
Suspends a running node. This node is suspended first, and then our helper nodes are stopped.

Specified by:
suspend in interface Controllable
Throws:
ControlException

resume

public void resume()
            throws ControlException
Resumes a suspended node. The helper nodes are resumed first, and then this node.

Specified by:
resume in interface Controllable
Throws:
ControlException

restart

public void restart()
             throws ControlException
Restarts a running node by calling shutdown and then startup

Specified by:
restart in interface Controllable
Throws:
ControlException

validTransition

public boolean validTransition(int transition)
Validates a state transition by comparing the desired transition with the current state.


onStartup

protected void onStartup()
                  throws SandException
Override this method to do work during startup().

Throws:
SandException

onShutdown

protected void onShutdown()
                   throws SandException
Override this method to do work during shutdown().

Throws:
SandException

onSuspend

protected void onSuspend()
                  throws SandException
Override this method to do work during suspend().

Throws:
SandException

onResume

protected void onResume()
                 throws SandException
Override this method to do work during resume().

Throws:
SandException

onRestart

protected void onRestart()
                  throws SandException
Override this method to do work during startup().

Throws:
SandException

onFailure

protected void onFailure()
                  throws ControlException
Override this method to do work when the node enters the failed state.

Throws:
ControlException

getParent

public Controllable getParent()
accessor for parent

Specified by:
getParent in interface Controllable

setParent

public void setParent(Controllable node)
mutator for parent


getHelperNodes

public Controllable[] getHelperNodes()
accessor for helperNodes

Specified by:
getHelperNodes in interface Controllable

setHelperNodes

public void setHelperNodes(Controllable[] nodes)
mutator for helperNodes

Specified by:
setHelperNodes in interface Controllable

systemwideShutdown

public void systemwideShutdown(int code)
                        throws ControlException
Call our shutdown, which shuts down our local nodes, then cascade this call upward to our parent so it spreads throughout the system as needed. This method is overridden by the root node to handle signalling across multiple server nodes.

Specified by:
systemwideShutdown in interface Controllable
Throws:
ControlException

addWrapper

public void addWrapper(ControlWrapper wrapper)
Add the specified wrapper to our notification collection

Specified by:
addWrapper in interface Controllable

notifyStateChange

protected void notifyStateChange(int prevState,
                                 int currState)
Notify our registered control wrappers of our state change


setupSubscriptions

protected void setupSubscriptions()
Subscribe us to the nodes we need to listen to


setupSecureReceive

protected void setupSecureReceive()
Register us for receive with our local Authorizer


receive

public SandMessage receive(SandMessage msg)
                    throws SandException
Only those receive methods explicitely declared by the node should actually be called. However the Messageable interface forces all calls to be channeled through this general method, which means we have to manually call the correct method from here.

In practice, this doesn't add much overhead if we enumerate the supported methods at code generation time, and then switch on the enumeration.

Specified by:
receive in interface Messageable
Throws:
SandException

deliver

public void deliver(SandMessage msg)
             throws SandException
Only those deliver methods explicitely declared by the node should actually be called. However the Messageable interface forces all calls to be channeled through this general method, which means we have to manually call the correct method from here.

In practice, this doesn't add much overhead if we enumerate the supported methods at code generation time, and then switch on the enumeration.

Specified by:
deliver in interface Messageable
Throws:
SandException