KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > deployment > client > ServerConnectionEnvironment


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23
24 package com.sun.enterprise.deployment.client;
25
26 import com.sun.enterprise.admin.jmx.remote.DefaultConfiguration;
27 import java.util.HashMap JavaDoc;
28 import java.util.Map JavaDoc;
29 import java.util.Map.Entry;
30 import java.util.Set JavaDoc;
31 import java.util.Iterator JavaDoc;
32
33 /**
34  * This class defines the additional environment needed to
35  * connect to a particular application server deployment
36  * backend. For now, the properties supported are specific
37  * to jmx https connector. We will extend it to support
38  * jmx rmi connector when the jmx implementation is ready.
39  * <br>
40  * Environment supported in this class are defined by the
41  * JMX connectors.
42  * @see also com.sun.enterprise.admin.jmx.remote.DefaultConfiguration
43  * <br>
44  * For example, to set a client trust manager, the key of env shall
45  * be DefaultConfiguration.TRUST_MANAGER_PROPERTY_NAME.
46  *
47  * @author Qingqing Ouyang
48  */

49 public final class ServerConnectionEnvironment extends HashMap JavaDoc {
50     
51     /**
52      * Creates a new instance of ServerConnectionEnvironment
53      */

54     public ServerConnectionEnvironment() {
55         super();
56     }
57     
58     /**
59      * Creates a new instance of ServerConnectionEnvironment
60      */

61     public ServerConnectionEnvironment(Map JavaDoc env) {
62         super(env);
63     }
64
65     public String JavaDoc toString() {
66         StringBuffer JavaDoc buf = new StringBuffer JavaDoc();
67         buf.append("ServerConnectionEnvironments: \n");
68         Iterator JavaDoc entries = entrySet().iterator();
69         while (entries.hasNext()) {
70             Map.Entry JavaDoc entry = (Map.Entry JavaDoc) entries.next();
71             buf.append("Key = " + entry.getKey());
72             buf.append(" ");
73             buf.append("Value = " + entry.getValue());
74             buf.append(";\n");
75         }
76
77         return buf.toString();
78     }
79 }
80
Popular Tags