KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > simulator > container > ContainerConfigException


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tc.simulator.container;
5
6 public final class ContainerConfigException extends Exception JavaDoc {
7   static final Reason INVALID_CONTAINER_START_TIMEOUT = new Reason("Invalid container start timeout.");
8   static final Reason INVALID_APPLICATION_START_TIMEOUT = new Reason("Invalid application start timeout.");
9   static final Reason INVALID_APPLICATION_EXECUTION_TIMEOUT = new Reason("Invalid application execution timeout.");
10   static final Reason INVALID_APPLICATION_INSTANCE_COUNT = new Reason("Invalid application instance count");
11
12   private final Reason reason;
13
14   ContainerConfigException(String JavaDoc message, Reason reason) {
15     super(message);
16     this.reason = reason;
17   }
18
19   Reason getReason() {
20     return this.reason;
21   }
22
23   static class Reason {
24     private final String JavaDoc name;
25
26     private Reason(String JavaDoc name) {
27       this.name = name;
28     }
29
30     public String JavaDoc toString() {
31       return this.name;
32     }
33   }
34 }
Popular Tags