things.common
Class ThingsException

java.lang.Object
  extended by java.lang.Throwable
      extended by things.common.ThingsException
All Implemented Interfaces:
java.io.Serializable, ThingsCodes
Direct Known Subclasses:
ActionException, CommandException, SystemException, TestAbortException, TestFailException, ThingsUsageException, UniverseException, UserException

public class ThingsException
extends java.lang.Throwable
implements ThingsCodes

A base exception for all things. It adds functionality for problem management rather than just a way to code exceptions.

Version:
1.0

Version History

 EPG - Initial - 2 DEC 01
 TNH - Change how attributes works - 1 AUG 02
 EPG - Add various rendering options - 16 MAY 04
 EPG - Add attribute functions and fix bugs - 11 JAN 05
 EPG - Clean up reports so they work better with the kernel debugging - 19 MAR 06
 EPG - Add 'worst-exception' for RendSite.  - 23 AUG 09
 
Author:
Erich P. Gatejen
See Also:

, Serialized Form


Field Summary
protected  java.util.HashMap<java.lang.String,java.lang.String> attributes
          Attributes.
static int CHAIN_DEPTH_LIMIT
          The total exception depth we'll examine for attributes.
 int numeric
          Exception numeric.
static int THINGS_EXCEPTION_GENERIC
          Numeric values for the exception.
 
Fields inherited from interface things.common.ThingsCodes
ACCESS_ERROR_CANNOT_OPEN, ACCESS_ERROR_CONCURRENT_NOT_ALLOWED, ACCESS_ERROR_NULL_ITEM, ACCESS_ERROR_STREAM_NOT_RECOGNIZED, ACTORSERVICE_ERROR, ACTORSERVICE_FAULT, ACTORSERVICE_FAULT_BAD_MESSAGE, ACTORSERVICE_FAULT_BAD_MESSAGE_FIELD, ACTORSERVICE_FAULT_BAD_USAGE, ACTORSERVICE_FAULT_MESSAGE, ACTORSERVICE_FAULT_STARTUP, ACTORSERVICE_LINK_ERROR, ACTORSERVICE_PROTOCOL_ERROR, ACTORSERVICE_SEND_ERROR, ALL, BAD_DSN, CODE_NONE, COMMANDLINE_ERROR_MISSING_REQUIRED, COMMANDLINE_ERROR_MISSING_REQUIRED_ASSUMED, COMMANDLINE_ERROR_NAME_NULL, CONFIGURATION_ERROR_BAD_CONFIGURATION, CONFIGURATION_FAILED_CHECKPOINT, CONFIGURATION_FAILED_DEFAULT, CONFIGURATION_FAULT_DEFAULT, CRAWLER_ERROR, CRAWLER_ERROR_DURING_SETUP, DATA_ATTRIBUTE_OBJECT_NULL, DATA_ERROR_BAD_DATE_FORMAT, DATA_ERROR_BRANCH_PROCESSING_ERROR, DATA_ERROR_CANNOT_BE_NULL_OR_EMPTY, DATA_ERROR_EXPECTED_NUMBER, DATA_ERROR_GENERAL, DATA_ERROR_INDEX_OUTOFBOUNDS, DATA_ERROR_MATCHER_CANNOT_ADD, DATA_ERROR_MATCHER_FAILED, DATA_ERROR_MATCHER_GENERAL, DATA_ERROR_MATCHER_PATTERN_NOT_ADDED, DATA_ERROR_PARSING_ERROR, DATA_ERROR_PATH_NULL, DATA_ERROR_PROPERTY_BAD_PLY, DATA_ERROR_PROPERTY_DECODING_PROBLEM, DATA_ERROR_PROPERTY_EMPTY_PLY, DATA_ERROR_PROPERTY_ENCODING_PROBLEM, DATA_ERROR_PROPERTY_FAILED_VALIDATION, DATA_ERROR_PROPERTY_PATH_NULL, DATA_ERROR_PROPERTY_VALUE_NULL, DEBUG, DEBUG_MODULE_LOADED, DEBUG_MODULE_SETUP, DEBUG_PROPERTY_VALUE, DEBUG_SMTP_RETRIABLE_ERROR, DEBUG_THING_CALL_DONE, DEBUG_THING_CALL_DONE_EXCEPTION, DEBUG_THING_CALL_DONE_INTERRUPTION, DEBUG_THING_CALL_ENTER, DEBUG_THING_CALL_GENERAL, DEBUG_THING_CALL_SETUP, DEBUG_THING_ECLIPSE_PARENT_EXPRESSOR, DEBUG_THING_LOADED, DEBUG_THING_MODULE_INSTANCE, DEBUG_THING_RUN_DONE_EXCEPTION, DEBUG_THING_RUN_GENERAL, DEBUG_TOP, DECOMPOSER_FAULT, DECOMPOSER_LOOKUP_ERROR, DEFAULT_NUMERIC, ERROR, ERROR_MODULE_IMPLEMENTATION_NOT_FOUND, ERROR_MODULE_INSTANTIATION_FAILED, ERROR_THING_BAD_VALUE, ERROR_THING_CALL_FAILED, ERROR_THING_CALL_IMPLEMENTATION_NOT_FOUND, ERROR_THING_CLUSTER, ERROR_THING_CLUSTER_CHECK_FAILED, ERROR_THING_CLUSTER_NODE_ALREADY_DEFINED, ERROR_THING_CLUSTER_NODE_START_ERROR, ERROR_THING_ERROR, ERROR_THING_EXPRESSION_COULD_NOT_SET, ERROR_THING_EXPRESSION_DEFAULT_ERROR, ERROR_THING_REQUIRED_PROPERTY_MISSING, ERROR_THING_RESULT_CALCULATION_FAILED, ERROR_THING_RESULT_NOT_DEFINED, ERROR_THING_RESULT_SPURIOUS_ERROR, ERROR_THING_RUN_FAILED, ERROR_TOP, FAULT, FAULT_TOP, FILESYSTEM_ERROR_ACCESS_DENIED, FILESYSTEM_ERROR_BAD_PATH, FILESYSTEM_ERROR_CONFUSED, FILESYSTEM_ERROR_COULD_NOT_DELETE, FILESYSTEM_ERROR_COULD_NOT_REPLACE, FILESYSTEM_ERROR_DEFAULT, FILESYSTEM_ERROR_DELETE_FAILED, FILESYSTEM_ERROR_FAILED_DIRECTORY_OPERATION, FILESYSTEM_ERROR_FILE_NOT_FOUND, FILESYSTEM_ERROR_FILE_WONT_DELETE, FILESYSTEM_ERROR_NOT_A_KNOWN_TYPE, FLOOR_NUMERIC, GENERAL_PARSER_ERROR, GENERAL_PARSER_FAULT, INFO, INFO_TOP, INVALID_NUMERIC, IO_CONDUIT_ERROR_POSTED_TO_NO_DRAINS, IO_CONDUIT_FAULT_GENERAL, IO_CONDUIT_FAULT_NOT_INITIALIZED, IO_CONDUIT_FAULT_POST_FAILED, IO_CONDUIT_FAULT_POST_FAILED_ON_ENDPOINT_NOT_READY, IO_CONDUIT_FAULT_POST_FAILED_ON_ENDPOINT_NOT_READY_RESOURCE, IO_FAULT, IO_FAULT_ABSTRACT_STREAM, IO_FAULT_POSTING_FAULT, IO_FILESYSTEM_FAULT_DEFAULT, IO_FILESYSTEM_FAULT_GENERAL, KERNEL_ERROR_DEATH_NOTICE_FAILED, KERNEL_FAULT, KERNEL_FAULT_CLASS_ISSUE, KERNEL_FAULT_COULD_NOT_FORGE_LOGGER, KERNEL_FAULT_INTERNAL_LOCK_FAILURE, KERNEL_FAULT_PROCESS_ALREADY_INITIALIZED, KERNEL_FAULT_PROCESS_ALREADY_NAMED, KERNEL_FAULT_PROCESS_CREDENTIAL_FAULT, KERNEL_FAULT_PROCESS_FAULT, KERNEL_FAULT_PROCESS_ILL_CONSTRUCTED, KERNEL_FAULT_PROCESS_INTERRUPTED, KERNEL_FAULT_PROCESS_MANAGEMENT, KERNEL_FAULT_PROCESS_NOT_RECOGNIZED, KERNEL_FAULT_PROCESS_REGISTRATION_BAD, KERNEL_PROCESS_DONE, KERNEL_PROCESS_FINALIZATION, KERNEL_PROCESS_INTERRUPTED, KERNEL_PROCESS_STARTED, KERNEL_PROCESS_THING_STARTED, KERNEL_PROCESS_THING_WAITING_START, MODULE_BUILTIN_UPA_LOAD_FAILED, MODULE_BUILTIN_UPA_SAVE_FAILED, MODULE_ERROR, MODULE_FAULT_BAD_USAGE, MODULE_FAULT_FAILED_INIT, MODULE_FAULT_NULL_PARAMETER, NO_NUMERIC, PANIC, PANIC_KERNEL_GENERAL, PANIC_KERNEL_ID_ALREADY_USED, PANIC_PROCESS_RESPONDING_TO_HALT_OK, PANIC_REQUIRED_PROPERTY_NOT_SET, PANIC_SYSTEM_COMMAND_CASCADING_PROBLEMS, PANIC_SYSTEM_COMMAND_GENERAL, PANIC_SYSTEM_COMMAND_GENERAL_RESPONSE_TRANSMISSION, PANIC_SYSTEM_COMMAND_INTERRUPTED_AND_UNRELIABLE, PANIC_SYSTEM_CONDUIT_UNRELIABLE, PANIC_SYSTEM_FAILURE, PANIC_SYSTEM_KERNEL_FAILURE, PANIC_SYSTEM_KERNEL_NO_LOGGER_FOR_PROCESS, PANIC_SYSTEM_LOADER_BAD_STATE, PANIC_SYSTEM_LOADER_COULD_NOT_CLEAN_FAILED_COMPILE, PANIC_SYSTEM_LOADER_STARTUP_FAILED, PANIC_SYSTEM_REINIT_CONDUIT_NOT_ALLOWED, PANIC_SYSTEM_REINIT_NOT_ALLOWED, PANIC_SYSTEM_SERVICE_FAILURE, PANIC_SYSTEM_SERVICE_FAILURE_DURING_CONSTRUCTION, PANIC_SYSTEM_SERVICE_UNRECOVERABLE, PANIC_SYSTEM_STARTUP_KERNEL_CONSTRUCTION_FAILURE, PANIC_SYSTEM_STARTUP_KERNEL_FAILURE, PANIC_SYSTEM_STARTUP_SERVICE_FAILURE, PANIC_THINGER_BUG, PANIC_THINGER_INITIALIZATION_FAULT, PANIC_THINGER_INITIALIZATION_VIOLATION, PANIC_THINGS_BUG, PANIC_THINGS_COMMON_BUG, PANIC_TOP, PROCESS_ERROR_BAD_CALL, PROCESS_ERROR_CREDENTIAL_FAILED, PROCESS_ERROR_DEFAULT, PROCESS_ERROR_FINALIZATION_FAILED, PROCESS_ERROR_ID_NULL, PROCESS_ERROR_NOT_FOUND, PROCESS_ERROR_PROCESS, PROCESSING_ERROR_DEFINITION, PROCESSING_ERROR_GENERAL, PROCESSING_ERROR_MERGE, PROCESSING_ERROR_MERGE_INCOMPLETE, PROCESSING_ERROR_SETUP, PROCESSING_ERROR_TEXT_GENERAL, PROCESSING_FAULT, PROCESSING_FAULT_HTTP, PROCESSING_FAULT_MATCHER, PROCESSOR_HTTP_GHOSTED_PROCESS, PROCESSOR_HTTPHEADER_FAILED, PROCESSOR_HTTPHEADER_UNHANDLED, PROCESSOR_HTTPREQUEST_FAILED, PROXY_CONNECTION_ERROR, PROXY_ERROR, PROXY_FAULT, PROXY_FAULT_SESSION, PROXY_FAULT_SOCKET_PREPARE, PROXY_SESSION_ERROR, RESOURCE_ERROR_ALREADY_DISPOSED, RESOURCE_ERROR_ALREADY_REGISTERED, RESOURCE_ERROR_BAD_REGISTRATION, RESOURCE_ERROR_DURING_LOOKUP, RESOURCE_ERROR_DURING_REGISTRATION, RESOURCE_ERROR_GENERAL, RESOURCE_ERROR_IDNAMED_USED, RESOURCE_ERROR_RESOURCE_NOT_REGISTERED, SERVICE_ACTOR_CONNECTION_ACCEPTED, SERVICE_ACTOR_OK, SERVICE_CLI_BAD_COMMAND_LINE, SERVICE_FAULT_HTTPTOOL, SERVICE_FAULT_HTTPTOOL_SPURIOUS, SERVICE_FAULT_HTTPTOOL_STOCK_SETUP, SERVICE_HTTPTOOL_ACTION_LOAD_FAILED, SERVICE_HTTPTOOL_ACTIONIZER_BAD_DECLARE, SERVICE_HTTPTOOL_ACTIONIZER_DECLARATION_FAILED, SERVICE_HTTPTOOL_BAD_REQUEST, SERVICE_HTTPTOOL_CONVERSION_ERROR, SERVICE_HTTPTOOL_ERROR, SERVICE_HTTPTOOL_ERROR_UNKNOWN_METHOD, SERVICE_HTTPTOOL_MANAGE_HEAD_FAILED, SERVICE_HTTPTOOL_OK, SERVICE_HTTPTOOL_PAGE_LOAD_FAILED, SERVICE_HTTPTOOL_PAGE_MERGE_FAILED, SERVICE_HTTPTOOL_PAGE_MERGE_FAILED_USAGE, SERVICE_HTTPTOOL_PAGE_RENDER_FAILED, SERVICE_HTTPTOOL_RESPONSE_FAILED, SERVICE_HTTPTOOL_SERVE_FAILED, SERVICE_PROXY_ACCEPT, SERVICE_PROXY_CONTEXT_START_PROCESS, SERVICE_PROXY_SR_COMPLETE, SERVICE_THINGER_BAD_CONSTRUCTION, SERVICE_THINGER_ERROR, SMTPCLIENT_BENIGN_DISCONNECT_ERROR, SMTPCLIENT_ERROR_ALREADY_CONNECTED, SMTPCLIENT_ERROR_LOGIN_FAILED, SMTPCLIENT_ERROR_MAILFROM_FAILED, SMTPCLIENT_ERROR_RCPTTO_FAILED, SMTPCLIENT_ERROR_SEND_FAILED, SMTPCLIENT_ERROR_SEND_TIMEOUT, SMTPCLIENT_FAULT_BAD_STATE, SMTPCLIENT_FAULT_CANNOT_COMPLETE, SMTPCLIENT_FAULT_CANNOT_COMPLETE_NOT_RETRYABLE, SMTPCLIENT_FAULT_CANNOT_CONNECT, SMTPCLIENT_FAULT_GENERAL, SMTPCLIENT_FAULT_NOT_STARTED, SMTPCLIENT_FAULT_SPURIOUS, SMTPCLIENT_FAULT_STARTUP, SMTPCLIENT_INTERRUPTED_AND_QUITTING, SMTPCLIENT_SEND_OK, SYSTEM_CALL_ERROR_BAD_CALL, SYSTEM_CALL_ERROR_GENERAL, SYSTEM_CALL_ERROR_GET_CONFIG_PROPERTIES, SYSTEM_CALL_ERROR_GET_EXPRESSOR, SYSTEM_CALL_ERROR_GET_LOCAL_LOG, SYSTEM_CALL_ERROR_GET_LOCAL_PROPERTIES, SYSTEM_CALL_ERROR_GET_SYSTEM_LOGGER, SYSTEM_CALL_ERROR_LOAD_MODULE, SYSTEM_CALL_ERROR_LOAD_THING, SYSTEM_CALL_ERROR_RUN_THING, SYSTEM_COMMAND_ERROR_ALREADY_RESPONDED, SYSTEM_COMMAND_ERROR_BAD_DECLARATION, SYSTEM_COMMAND_ERROR_BAD_PARAMETER, SYSTEM_COMMAND_ERROR_BAD_PROCESSING, SYSTEM_COMMAND_ERROR_COMMAND_ALREADY_DONE, SYSTEM_COMMAND_ERROR_COMMAND_NOT_FOUND, SYSTEM_COMMAND_ERROR_COMMAND_RESPONSE_PROCESSING, SYSTEM_COMMAND_ERROR_DATATYPE_VIOLATION_VALUE, SYSTEM_COMMAND_ERROR_GENERAL, SYSTEM_COMMAND_ERROR_INSTANCE_MISSING_REQUIRED_PARAMETER, SYSTEM_COMMAND_ERROR_ISSUANCE_FAILED, SYSTEM_COMMAND_ERROR_ISSUANCE_NO_RECEIPTS, SYSTEM_COMMAND_ERROR_MALFORMED, SYSTEM_COMMAND_ERROR_NOT_DECLARED, SYSTEM_COMMAND_ERROR_NULL_COMMAND, SYSTEM_COMMAND_ERROR_NULL_PARAMETER_NAME, SYSTEM_COMMAND_ERROR_NULL_RESPONSE_RECEIPT, SYSTEM_COMMAND_ERROR_OCCURANCE_VIOLATION, SYSTEM_COMMAND_ERROR_OCCURANCE_VIOLATION_NEVER, SYSTEM_COMMAND_ERROR_OCCURANCE_VIOLATION_ONLYONE, SYSTEM_COMMAND_ERROR_OPERATION_FAILED, SYSTEM_COMMAND_ERROR_PARAMETER_NOT_DEFINED, SYSTEM_COMMAND_ERROR_PROPERTY_PROBLEM, SYSTEM_COMMAND_ERROR_RESPONSE_NOT_DEFINED, SYSTEM_COMMAND_ERROR_SET_FAILED, SYSTEM_COMMAND_ERROR_TYPE_VIOLATION, SYSTEM_COMMAND_FAULT, SYSTEM_COMMAND_FAULT_CANNOT_DEFINE, SYSTEM_COMMAND_FAULT_CLASS_NOT_FOUND, SYSTEM_COMMAND_FAULT_COULD_NOT_BUILD_CLI_COMMAND, SYSTEM_COMMAND_FAULT_COULD_NOT_BUILD_COMMANDER, SYSTEM_COMMAND_FAULT_COULD_NOT_BUILD_RESPONSE, SYSTEM_COMMAND_FAULT_COULD_NOT_ISSUE_CLI_COMMAND, SYSTEM_COMMAND_FAULT_DURING_ISSUANCE, SYSTEM_COMMAND_FAULT_INSTANCE_DATA_BAD, SYSTEM_COMMAND_FAULT_INSTANCE_TYPE_MIXING, SYSTEM_COMMAND_FAULT_INSTANCE_USED_BEFORE_READY, SYSTEM_COMMAND_FAULT_NOT_DEFINED, SYSTEM_COMMAND_FAULT_PARAMETER_MISSING_AFTER_TRANSMISSION, SYSTEM_COMMAND_FAULT_RESPONSE_FAILED, SYSTEM_COMMAND_FAULT_RESPONSE_FAILED_BAD_RECIEPT, SYSTEM_COMMAND_FAULT_RESPONSE_OBJECT_BAD, SYSTEM_COMMAND_FAULT_RESPONSE_PROCESSING, SYSTEM_COMMAND_FAULT_SERVICE_ABORTED, SYSTEM_COMMAND_FAULT_SET_PROBLEM, SYSTEM_COMMAND_FAULT_SPURIOUS, SYSTEM_COMMAND_FAULT_UNDEFINED_STATE, SYSTEM_COMMAND_WARNING_GENERAL, SYSTEM_COMMAND_WARNING_NO_ONE_LISTENING, SYSTEM_DEBUG, SYSTEM_DEBUG_COMMAND, SYSTEM_ERROR, SYSTEM_ERROR_ATTRIBUTE_CODEC_FAILED, SYSTEM_ERROR_BAD_PROPERTY, SYSTEM_ERROR_BAD_PROPERTY_NAME_NULL, SYSTEM_ERROR_BAD_PROPERTY_NOT_DEFINED, SYSTEM_ERROR_BAD_PROPERTY_TEXT, SYSTEM_ERROR_BAD_PROPERTY_WRITE, SYSTEM_ERROR_COMPONENT_INTERRUPTED, SYSTEM_ERROR_LOGGING_FAILED, SYSTEM_ERROR_LOGGING_FAILED_ON_CONDUIT, SYSTEM_ERROR_LOGGING_FAILED_ON_RESOURCE_NOT_READY, SYSTEM_ERROR_LOGGING_LOG_LEVEL_INVALID, SYSTEM_ERROR_LOGGING_LOGGER_ALREADY_ISSUED, SYSTEM_ERROR_MESSAGE_ENCODING_FAILED, SYSTEM_ERROR_OPTIONAL_PROPERTY_NOT_SINGLE, SYSTEM_ERROR_REQUIRED_PROPERTY_NOT_AN_INTEGER, SYSTEM_ERROR_REQUIRED_PROPERTY_NOT_SET, SYSTEM_ERROR_REQUIRED_PROPERTY_NOT_SINGLE, SYSTEM_ERROR_TOP, SYSTEM_FAULT, SYSTEM_FAULT_DATA_DEFAULT, SYSTEM_FAULT_DATA_VIOLATE_NATIVE, SYSTEM_FAULT_EXTERNAL_INTERRUPTION, SYSTEM_FAULT_FAILED_INIT, SYSTEM_FAULT_PROCESS, SYSTEM_FAULT_PROCESS_INIT_FAILED, SYSTEM_FAULT_PROCESS_INTERRUPTED, SYSTEM_FAULT_PROCESS_REGISTER_FAILED, SYSTEM_FAULT_PROCESS_UNHANDLED, SYSTEM_FAULT_PROCESS_WAIT_INTERRUPTED, SYSTEM_FAULT_PROPERTIES_BAD_ACCESS, SYSTEM_FAULT_PROPERTIES_LOAD_FAILED, SYSTEM_FAULT_PROPERTIES_MODE_VIOLATION, SYSTEM_FAULT_PROPERTIES_SAVE_FAILED, SYSTEM_FAULT_PROPERTIES_SOURCE_NOT_FOUND, SYSTEM_FAULT_PROPERTYVIEW_NOT_INITIALIZED, SYSTEM_FAULT_SERVICE_FAILED_TO_CONSTRUCT, SYSTEM_FAULT_SERVICE_GERERAL, SYSTEM_FAULT_SERVICE_PROBLEM, SYSTEM_FAULT_SOFTWARE_DETECTED, SYSTEM_FAULT_SOFTWARE_PROBLEM, SYSTEM_FAULT_SOFTWARE_PROCESS_DISALLOWED, SYSTEM_FAULT_STAMP_CREATION_FAILED, SYSTEM_FAULT_TEST_SUITE, SYSTEM_FAULT_THING_CONSTRUCTION_BAD_CLASS, SYSTEM_FAULT_THING_CONSTRUCTION_NULLED, SYSTEM_FAULT_THING_CONSTRUCTION_SPURIOUS_EXCEPTION, SYSTEM_FAULT_THING_DIED, SYSTEM_FAULT_THING_FAILED_DEFINITION, SYSTEM_FAULT_THING_FAILED_INIT, SYSTEM_FAULT_THING_FAULT, SYSTEM_FAULT_THING_PROBLEM, SYSTEM_FAULT_THING_RESULT_BAD, SYSTEM_FAULT_THING_RESULT_MISUSED, SYSTEM_FAULT_THING_SPURIOUS_EXCEPTION, SYSTEM_FAULT_TOOLKIT_FAILED, SYSTEM_FAULT_WITH_PROPERTIES, SYSTEM_INFRA_ATTR_CODEC, SYSTEM_INFRA_BAD_DATA, SYSTEM_INFRA_BAD_DATA_ODD, SYSTEM_INFRA_ERROR, SYSTEM_INFRA_NULLED_DATA, SYSTEM_LOADER_ERROR_BAD_THING_NAME, SYSTEM_LOADER_ERROR_CANT_FIND_THING, SYSTEM_LOADER_ERROR_COMPILE_ERRORS, SYSTEM_LOADER_ERROR_COULD_NOT_LOAD, SYSTEM_LOADER_ERROR_UNIVERSE_PROBLEM, SYSTEM_LOADER_FAULT, SYSTEM_LOADER_FAULT_BAD_CONFIG, SYSTEM_LOADER_FAULT_COMPILER_FAILED, SYSTEM_LOADER_FAULT_DUPLICATE_CONFIG, SYSTEM_SERVICE_DONE, SYSTEM_SERVICE_ERROR_COMMAND_GENERAL, SYSTEM_SERVICE_ERROR_COMMAND_MALFORMED, SYSTEM_SERVICE_NOTIFICATION, SYSTEM_SERVICE_RESPONSE_TIMEOUT, TEST_ERROR_ABORT, TEST_ERROR_COULD_NOT_PREP_TEST, TEST_ERROR_DEFAULT, TEST_ERROR_FAIL, TEST_ERROR_GROUP_ERROR, TEST_ERROR_TEST_IMPL_PROBLEM, TEST_FAULT_DEFAULT, TEST_FAULT_NOT_INITIALIZED, THING_CLUSTER_NODE_STARTED, THING_FAULT_COMMANDLINE_BAD_DECLARATION, THING_FAULT_COMMANDLINE_NOT_DECLARED, THING_FAULT_COMMANDLINE_PROCESSOR_STARTUP, THING_FAULT_DEFAULT, THING_FAULT_DEFINITION, THING_FAULT_DEFINITION_ALREADY_NAMED, THING_FAULT_DEFINITION_BAD, THING_FAULT_MODULE_DEFAULT, THING_FAULT_RESULT_COLLECTION, THING_FAULT_RESULT_FUNDIMENTAL, THING_FAULT_RESULT_MANAGEMENT, THING_FAULT_SERVICE_COULD_NOT_GET_UNIVERSE, THING_FAULT_SERVICE_COULD_NOT_GET_UNIVERSE_ACCESSOR, UNIVERSE_ERROR_BAD_KEY, UNIVERSE_ERROR_CONFIG_BAD_REQUIRED, UNIVERSE_ERROR_CONFIG_BAD_VALUE, UNIVERSE_ERROR_CONFIG_MISSING_REQUIRED, UNIVERSE_ERROR_DEFAULT, UNIVERSE_ERROR_DELETE_FAILED, UNIVERSE_ERROR_DISALLOWED_NAME, UNIVERSE_ERROR_EMPTY_NAME, UNIVERSE_ERROR_GET_MATCHES, UNIVERSE_ERROR_GET_MODIFIED_DATE_FAILED, UNIVERSE_ERROR_IO_PROBLEM, UNIVERSE_ERROR_OBJECT_DOESNT_EXIST, UNIVERSE_ERROR_OBJECT_LOCKED, UNIVERSE_ERROR_REGISTRATION_BAD, UNIVERSE_ERROR_REGISTRATION_DUPLICATE, UNIVERSE_ERROR_REGISTRATION_NOT_ALLOWED, UNIVERSE_FAULT_ACCESSOR_PROBLEM, UNIVERSE_FAULT_BAD_CALL, UNIVERSE_FAULT_COULD_NOT_ACCESS, UNIVERSE_FAULT_DEFAULT, UNIVERSE_FAULT_LOCAL_MANAGEMENT, UNIVERSE_FAULT_LOCAL_PATH_MANAGEMENT, UNIVERSE_FAULT_NAMING_FAILED, UNIVERSE_FAULT_NOT_REGISTERED, UNIVERSE_FAULT_UNEXPECTED, USAGE_ERROR, USER_BAD_CONFIGURATION_ERROR, USER_COMMAND_ERROR, USER_DEBUG_RESERVED_END, USER_DEFAULT_INFO, USER_ERROR_RESERVED_END, USER_EXPRESSION_FAILED, USER_FAULT_RESERVED_END, USER_INFO_RESERVED_END, USER_PANIC_RESERVED_END, USER_RESULT_COMPLETE, USER_RESULT_DEFAULT, USER_RESULT_ERRORED, USER_THING_MANAGEMENT, USER_UNSUPPORTED_FUNCTION_ERROR, USER_WARNING_RESERVED_END, VERBOSE_FAILED_TO_START, WARNING, WARNING_TOP
 
Constructor Summary
ThingsException()
          Default Constructor.
ThingsException(int n)
          Numeric constructor
ThingsException(int n, java.lang.Throwable theCause)
          Numeric constructor with cause
ThingsException(java.lang.String message)
          Message constructor.
ThingsException(java.lang.String message, int n)
          Message and numeric constructor
ThingsException(java.lang.String message, int n, java.lang.String... attr)
          Message and numeric constructor
ThingsException(java.lang.String message, int n, java.lang.Throwable theCause)
          Message and numeric constructor with cause
ThingsException(java.lang.String message, int n, java.lang.Throwable theCause, java.lang.String... attr)
          Message and numeric constructor with cause.
ThingsException(java.lang.String message, java.lang.Throwable theCause)
          Message constructor with Cause.
ThingsException(java.lang.Throwable theCause)
          Default Constructor with Cause
 
Method Summary
 void addAttribute(java.util.HashMap<java.lang.String,java.lang.String> attributes)
          Add attributes from a hashtable.
 void addAttribute(NV attribute)
          Add an attribute as a NV.
 void addAttribute(java.lang.String name, java.lang.String value)
          Add an attribute.
 void addAttributes(java.lang.String... pairs)
          Adds attribute as name value pairs.
protected  NV[] chainAttributes(int number, int limit, NV[] starting)
          Chain attributes through all causes.
 java.util.HashMap<java.lang.String,java.lang.String> getAttributes()
          Get attributes.
 java.lang.String[] getAttributesDecorated(java.lang.String name, java.lang.String value)
          Get attributes as name value pairs in alternating sequence in an array.
 NVImmutable[] getAttributesNV(NV ina)
          Get attributes as NVImmutable.
 NVImmutable[] getAttributesNV(java.lang.String name, java.lang.String value)
          Get attributes as NVImmutable.
 NVImmutable[] getAttributesNVDecorated()
          Get attributes as NVImmutable.
 NVImmutable[] getAttributesNVDecorated(java.lang.String name, java.lang.String value)
          Get attributes as NVImmutable.
 NVImmutable[] getAttributesNVMulti(NV... ina)
          Get attributes as NVs.
 AttributeReader getAttributesReader()
          Get attributes wrapped in a reader.
 java.lang.String getAttributestoString()
          Get attributes as a String.
 ThingsException getRootCause()
          Get the root cause.
 ThingsException getWorst()
          Get the worst ThingsException from all the causes.
 boolean isDebug()
          Helper for determining level - DEBUG
static boolean isDebug(int code)
          Helper for determining level - DEBUG
 boolean isError()
          Helper for determining level - ERROR
static boolean isError(int code)
          Helper for determining level - ERROR
 boolean isFault()
          Helper for determining level - FAULT
static boolean isFault(int code)
          Helper for determining level - FAULT
static boolean isInformational(int code)
          Helper for determining level - Informational
 boolean isInformational(ThingsException e)
          Helper for determining level - Informational
 boolean isPanic()
          Helper for determining level - FAULT
static boolean isPanic(int code)
          Helper for determining level - FAULT
 boolean isWarning()
          Helper for determining level - WARNING
static boolean isWarning(int code)
          Helper for determining level - WARNING
 boolean isWorseThanError()
          Helper for determining level - Is it worse than an ERROR?
 boolean isWorseThanFault()
          Helper for determining level - Is it worse than a FAULT?
 boolean isWorseThanWarning()
          Helper for determining level - Is it worse than a WARNING?
 void panicReport()
          Panic report.
static void panicReport(java.lang.String message)
          Panic report.
 boolean pass(int threshold)
          Check to see if this Exception passes a threshold.
static boolean pass(int threshold, int numeric)
          Check to see if any numeric passes a threshold.
 java.lang.String reportCause()
          Get causes.
static void softwareProblem(java.lang.String message)
          This will throw a common-formatted ThingsException reporting a software problem.
static void softwareProblem(java.lang.String message, java.lang.String... attr)
          This will throw a common-formatted ThingsException reporting a software problem.
static void softwareProblem(java.lang.String message, java.lang.Throwable t)
          This will throw a common-formatted ThingsException reporting a software problem.
static void softwareProblem(java.lang.String message, java.lang.Throwable t, java.lang.String... attr)
          This will throw a common-formatted ThingsException reporting a software problem.
 java.lang.String toStringAttributes()
          Render the exception as attributes only.
static java.lang.String toStringAttributes(java.lang.Throwable tr)
          Render the exception as attributes only.
 java.lang.String toStringCauses()
          Render the exception as a string without the trace, but with all causes.
static java.lang.String toStringCauses(java.lang.Throwable tr)
          Render the exception as a string without the trace, but with all causes.
 java.lang.String toStringComplex()
          Render the exception as a string.
static java.lang.String toStringComplex(java.lang.Throwable tr)
          Render a throwable as a string.
 java.lang.String toStringSimple()
          Render the exception as a string without the trace.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

numeric

public int numeric
Exception numeric.


attributes

protected java.util.HashMap<java.lang.String,java.lang.String> attributes
Attributes.


THINGS_EXCEPTION_GENERIC

public static final int THINGS_EXCEPTION_GENERIC
Numeric values for the exception.

See Also:
Constant Field Values

CHAIN_DEPTH_LIMIT

public static final int CHAIN_DEPTH_LIMIT
The total exception depth we'll examine for attributes. This is to prevent runaway recursion.

See Also:
Constant Field Values
Constructor Detail

ThingsException

public ThingsException()
Default Constructor.


ThingsException

public ThingsException(java.lang.Throwable theCause)
Default Constructor with Cause

Parameters:
theCause - for exception chaining

ThingsException

public ThingsException(java.lang.String message)
Message constructor.

Parameters:
message - text message for exception

ThingsException

public ThingsException(java.lang.String message,
                       java.lang.Throwable theCause)
Message constructor with Cause.

Parameters:
message - text message for exception
theCause - for exception chaining

ThingsException

public ThingsException(int n)
Numeric constructor

Parameters:
n - numeric error

ThingsException

public ThingsException(int n,
                       java.lang.Throwable theCause)
Numeric constructor with cause

Parameters:
n - numeric error
theCause - for exception chaining

ThingsException

public ThingsException(java.lang.String message,
                       int n)
Message and numeric constructor

Parameters:
message - text message for exception
n - numeric error

ThingsException

public ThingsException(java.lang.String message,
                       int n,
                       java.lang.Throwable theCause)
Message and numeric constructor with cause

Parameters:
message - text message for exception
n - numeric error
theCause - for exception chaining

ThingsException

public ThingsException(java.lang.String message,
                       int n,
                       java.lang.String... attr)
Message and numeric constructor

Parameters:
message - text message for exception
attr - A list of attributes. They should come in paris, but if there is an odd dangling attribute name, the value will be the name. The system will attempt to ignore null entries, but it could get confused.
n - numeric error

ThingsException

public ThingsException(java.lang.String message,
                       int n,
                       java.lang.Throwable theCause,
                       java.lang.String... attr)
Message and numeric constructor with cause.

Parameters:
message - text message for exception
n - numeric error
theCause - for exception chaining
attr - A list of attributes. They should come in paris, but if there is an odd dangling attribute name, the value will be the name. The system will attempt to ignore null entries, but it could get confused.
Method Detail

getWorst

public ThingsException getWorst()
Get the worst ThingsException from all the causes. If there are no causes, it'll return this. It is possible that this is the worst exception too. Worst is defined as the least numeric.

Returns:
the worst exception.

isInformational

public static boolean isInformational(int code)
Helper for determining level - Informational

Parameters:
code - numeric code
Returns:
true if it is informational

isDebug

public static boolean isDebug(int code)
Helper for determining level - DEBUG

Parameters:
code - numeric code
Returns:
true if it is informational

isWarning

public static boolean isWarning(int code)
Helper for determining level - WARNING

Parameters:
code - numeric code
Returns:
true if it is informational

isError

public static boolean isError(int code)
Helper for determining level - ERROR

Parameters:
code - numeric code
Returns:
true if it is informational

isFault

public static boolean isFault(int code)
Helper for determining level - FAULT

Parameters:
code - numeric code
Returns:
true if it is informational

isPanic

public static boolean isPanic(int code)
Helper for determining level - FAULT

Parameters:
code - numeric code
Returns:
true if it is informational

isInformational

public boolean isInformational(ThingsException e)
Helper for determining level - Informational

Returns:
true if it is informational

isDebug

public boolean isDebug()
Helper for determining level - DEBUG

Returns:
true if it is informational

isWarning

public boolean isWarning()
Helper for determining level - WARNING

Returns:
true if it is informational

isError

public boolean isError()
Helper for determining level - ERROR

Returns:
true if it is informational

isFault

public boolean isFault()
Helper for determining level - FAULT

Returns:
true if it is informational

isPanic

public boolean isPanic()
Helper for determining level - FAULT

Returns:
true if it is informational

isWorseThanWarning

public boolean isWorseThanWarning()
Helper for determining level - Is it worse than a WARNING?

Returns:
true if it is informational

isWorseThanError

public boolean isWorseThanError()
Helper for determining level - Is it worse than an ERROR?

Returns:
true if it is informational

isWorseThanFault

public boolean isWorseThanFault()
Helper for determining level - Is it worse than a FAULT?

Returns:
true if it is informational

pass

public boolean pass(int threshold)
Check to see if this Exception passes a threshold. This matches the threshold characteristics decumented in ThingsCodes. To pass the threshold, the numeric must be BELOW the threshold level, not equal or within the range.

Parameters:
threshold - The threshold level to check against.
Returns:
true if it passes the threshold, else false.
See Also:
ThingsCodes

pass

public static boolean pass(int threshold,
                           int numeric)
Check to see if any numeric passes a threshold. This matches the threshold characteristics decumented in ThingsCodes. To pass the threshold, the numeric must be BELOW the threshold level, not equal or within the range.

Parameters:
threshold - The threshold level to check against.
numeric - The numeric to check.
Returns:
true if it passes the threshold, else false.
See Also:
ThingsCodes

getAttributes

public java.util.HashMap<java.lang.String,java.lang.String> getAttributes()
Get attributes.

Returns:
a HashMap representing the attributes.

getAttributesNVDecorated

public NVImmutable[] getAttributesNVDecorated()
Get attributes as NVImmutable. Decorate them with message and numeric attributes. This is mostly useful for bridging between exception and logging.

Returns:
an NVImmutable array representing the attributes.

getAttributesReader

public AttributeReader getAttributesReader()
Get attributes wrapped in a reader.

Returns:
an attribute reader for the attributes.

getAttributesNVMulti

public NVImmutable[] getAttributesNVMulti(NV... ina)
Get attributes as NVs.

Parameters:
ina - initial attributes. This array of NVs will be merged with the current attributes in the return array. If you pass null or an empty set, it will be ignored.
Returns:
an NV array representing the attributes.
See Also:
NVImmutable

getAttributesNV

public NVImmutable[] getAttributesNV(NV ina)
Get attributes as NVImmutable.

Parameters:
ina - initial attributes. This single NV will be merged with the current attributes in the return array. If you pass null or an empty set, it will be ignored.
Returns:
an NV array representing the attributes.
See Also:
NVImmutable

getAttributesNV

public NVImmutable[] getAttributesNV(java.lang.String name,
                                     java.lang.String value)
Get attributes as NVImmutable. Merge with an input NV pair (as Strings).

Parameters:
name - The name of the attribute
value - The value of the attribute.
Returns:
an NVImmutable array representing the attributes.

getAttributesDecorated

public java.lang.String[] getAttributesDecorated(java.lang.String name,
                                                 java.lang.String value)
Get attributes as name value pairs in alternating sequence in an array. Merge with an input NV pair (as Strings). Decorate them with message and numeric attributes. This is mostly useful for bridging between exception and logging.

Parameters:
name - The name of the attribute
value - The value of the attribute.
Returns:
Attributes as name value pairs in alternating sequence in an array.

getAttributesNVDecorated

public NVImmutable[] getAttributesNVDecorated(java.lang.String name,
                                              java.lang.String value)
Get attributes as NVImmutable. Merge with an input NV pair (as Strings). Decorate them with message and numeric attributes. This is mostly useful for bridging between exception and logging.

Parameters:
name - The name of the attribute
value - The value of the attribute.
Returns:
an NVImmutable array representing the attributes.

chainAttributes

protected NV[] chainAttributes(int number,
                               int limit,
                               NV[] starting)
Chain attributes through all causes.

Parameters:
number - the number of attributes so far.
limit - the number of plies allowed. This will help detect recursion.
Returns:
attributes. These will NOT be deduped.

addAttribute

public void addAttribute(java.lang.String name,
                         java.lang.String value)
Add an attribute. If the attribute name is null, it will not be added.

Parameters:
name - The attribute name.
value - The attribute value.

addAttributes

public void addAttributes(java.lang.String... pairs)
                   throws ThingsException
Adds attribute as name value pairs.

Parameters:
pairs - pairs of names and values.
Throws:
ThingsException - if it is a null paramter or an uneven number of items.

addAttribute

public void addAttribute(java.util.HashMap<java.lang.String,java.lang.String> attributes)
Add attributes from a hashtable. Duplicates will be overwritten (which may or may not be a problem for you).

Parameters:
attributes - the hashtable. if null, it will quietly return.

addAttribute

public void addAttribute(NV attribute)
Add an attribute as a NV. If the attribute is null or its name is null, it will not be added.

Parameters:
attribute - The NV representing the attribute.
See Also:
NV

getAttributestoString

public java.lang.String getAttributestoString()
                                       throws ThingsException
Get attributes as a String.

Returns:
Returns a string reprsentation. If there was an error or there are no attributes, it will return an empty string.
Throws:
ThingsException
See Also:
ThingsConstants

toStringSimple

public java.lang.String toStringSimple()
Render the exception as a string without the trace.

Returns:
a string representation of this exception.

toStringCauses

public java.lang.String toStringCauses()
Render the exception as a string without the trace, but with all causes.

Returns:
a string representation of this exception.

toStringAttributes

public java.lang.String toStringAttributes()
Render the exception as attributes only.

Returns:
a string representation of this exception.

getRootCause

public ThingsException getRootCause()
Get the root cause. This will be the terminal ThingsException.

Returns:
the terminal ThingsException, which may be this.

toStringAttributes

public static java.lang.String toStringAttributes(java.lang.Throwable tr)
Render the exception as attributes only.

Parameters:
tr - the exception chain.
Returns:
a string representation of this exception.

toStringCauses

public static java.lang.String toStringCauses(java.lang.Throwable tr)
Render the exception as a string without the trace, but with all causes.

Parameters:
tr - the exception chain.
Returns:
a string representation of this exception.

toStringComplex

public java.lang.String toStringComplex()
Render the exception as a string. It will print a stack trace into the string too.

Returns:
a string representation of this exception.

toStringComplex

public static java.lang.String toStringComplex(java.lang.Throwable tr)
Render a throwable as a string. It will print a stack trace into the string too.

Parameters:
tr - The throwable to render.
Returns:
a string representation of this exception.

panicReport

public void panicReport()
Panic report. Something bad happens and we won't be able to report it through the usual subsystems. this report for this instance of ThingsException.


panicReport

public static void panicReport(java.lang.String message)
Panic report. Something bad happens and we won't be able to report it through the usual subsystems. this report for this instance of ThingsException.

Parameters:
message - the message.

softwareProblem

public static void softwareProblem(java.lang.String message)
                            throws ThingsException
This will throw a common-formatted ThingsException reporting a software problem.

Parameters:
message - information message
Throws:
ThingsException

softwareProblem

public static void softwareProblem(java.lang.String message,
                                   java.lang.Throwable t)
                            throws ThingsException
This will throw a common-formatted ThingsException reporting a software problem. This one allows exception chaining.

Parameters:
message - information message
t - The throwable to chain
Throws:
ThingsException

softwareProblem

public static void softwareProblem(java.lang.String message,
                                   java.lang.Throwable t,
                                   java.lang.String... attr)
                            throws ThingsException
This will throw a common-formatted ThingsException reporting a software problem. This one allows exception chaining.

Parameters:
message - information message
t - The throwable to chain
attr - A list of attributes. They should come in paris, but if there is an odd dangling attribute name, the value will be the name. The system will attempt to ignore null entries, but it could get confused.
Throws:
ThingsException

softwareProblem

public static void softwareProblem(java.lang.String message,
                                   java.lang.String... attr)
                            throws ThingsException
This will throw a common-formatted ThingsException reporting a software problem.

Parameters:
message - information message
attr - A list of attributes. They should come in paris, but if there is an odd dangling attribute name, the value will be the name. The system will attempt to ignore null entries, but it could get confused.
Throws:
ThingsException

reportCause

public java.lang.String reportCause()
Get causes. If this exception as a cause, get the root cause. It'll recurse until all causes are encoded.

Returns:
a string listing all the causes.


Things.