コード例 #1
0
 /**
  * Constructor.
  *
  * @param text
  * @param state
  * @param serviceDescriptor
  */
 public BadStateException(String text, ServiceState state, ServiceDescriptor descriptor) {
   super(
       text
           + " (Service= '"
           + (descriptor != null ? descriptor.getKey() : "unknown")
           + ", state= "
           + state
           + ")");
 }
コード例 #2
0
 /** Constructor. */
 public BadStateException(
     ServiceState expectedState, ServiceState state, ServiceDescriptor descriptor) {
   super(
       "Bad state for service '"
           + descriptor.getKey()
           + "'. Expected '"
           + expectedState
           + "' found '"
           + state
           + "'.");
 }
コード例 #3
0
 /**
  * Constructor.
  *
  * @param text
  * @param state
  * @param serviceDescriptor
  */
 public BadStateException(
     String text, ServiceState state, ServiceDescriptor descriptor, Throwable cause) {
   super(text + " (Service= '" + descriptor.getKey() + ", state= " + state + ")", cause);
 }