Package org.refcodes.component
Class CloseException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- org.refcodes.component.CloseException
-
- All Implemented Interfaces:
org.refcodes.exception.ErrorCodeAccessor
,org.refcodes.exception.Trap
public class CloseException extends java.io.IOException implements org.refcodes.exception.Trap
Thrown in case closing an open line (connection, junction, link) caused problems. Usually a method similar toClosable.close()
throws such an exception.ATTENTION: This
Exception
does not provide a dedicatedConnectionAccessor
as aLinkComponent
does not necessary provide dedicated connection information, it may be hard wired to another software system's hot spot or similar with the option of opening or closing. In order to provide compatibility with the Java APIs, this exception extends theIOException
. E.g. JAVA APIs throw anIOException
upon close, theClosable
mixin throws an exceptionCloseException
upon failure which can be assigned to anIOException
reference (e.g. caught as anIOException
).- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CloseException.CloseRuntimeException
Unchecked exception with the same semantics as theCloseException
.-
Nested classes/interfaces inherited from interface org.refcodes.exception.ErrorCodeAccessor
org.refcodes.exception.ErrorCodeAccessor.ErrorCodeBuilder<B extends org.refcodes.exception.ErrorCodeAccessor.ErrorCodeBuilder<B>>, org.refcodes.exception.ErrorCodeAccessor.ErrorCodeMutator, org.refcodes.exception.ErrorCodeAccessor.ErrorCodeProperty
-
-
Constructor Summary
Constructors Constructor Description CloseException(java.lang.String message)
Instantiates a new close exception.CloseException(java.lang.String aMessage, java.lang.String aErrorCode)
Instantiates a new close exception.CloseException(java.lang.String message, java.lang.Throwable cause)
Instantiates a new close exception.CloseException(java.lang.String aMessage, java.lang.Throwable aCause, java.lang.String aErrorCode)
Instantiates a new close exception.CloseException(java.lang.Throwable cause)
Instantiates a new close exception.CloseException(java.lang.Throwable aCause, java.lang.String aErrorCode)
Instantiates a new close exception.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getErrorCode()
-
-
-
Constructor Detail
-
CloseException
public CloseException(java.lang.String aMessage, java.lang.String aErrorCode)
Instantiates a new close exception.- Parameters:
aMessage
- the messageaErrorCode
- the error code
-
CloseException
public CloseException(java.lang.String aMessage, java.lang.Throwable aCause, java.lang.String aErrorCode)
Instantiates a new close exception.- Parameters:
aMessage
- the messageaCause
- the causeaErrorCode
- the error code
-
CloseException
public CloseException(java.lang.String message, java.lang.Throwable cause)
Instantiates a new close exception.- Parameters:
message
- the messagecause
- the cause
-
CloseException
public CloseException(java.lang.String message)
Instantiates a new close exception.- Parameters:
message
- the message
-
CloseException
public CloseException(java.lang.Throwable aCause, java.lang.String aErrorCode)
Instantiates a new close exception.- Parameters:
aCause
- the causeaErrorCode
- the error code
-
CloseException
public CloseException(java.lang.Throwable cause)
Instantiates a new close exception.- Parameters:
cause
- the cause
-
-