KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > beehive > netui > tools > testrecorder > shared > config > ServerConfig


1 /*
2  * Copyright 2004 The Apache Software Foundation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  * $Header:$
17  */

18
19 package org.apache.beehive.netui.tools.testrecorder.shared.config;
20
21 /**
22  * User: ozzy
23  * Date: Apr 15, 2004
24  * Time: 3:08:44 PM
25  */

26 public class ServerConfig {
27
28     private String JavaDoc name;
29     private String JavaDoc hostname;
30     private int port;
31
32     public ServerConfig( String JavaDoc name, String JavaDoc hostname, int port ) {
33         this.name = name;
34         this.hostname = hostname;
35         this.port = port;
36     }
37
38     public String JavaDoc getName() {
39         return name;
40     }
41
42     public String JavaDoc getHostname() {
43         return hostname;
44     }
45
46     public int getPort() {
47         return port;
48     }
49
50     public String JavaDoc toString() {
51         StringBuffer JavaDoc sb = new StringBuffer JavaDoc( 48 );
52         sb.append( "[ " );
53         sb.append( "name( " + getName() + " )" );
54         sb.append( ", hostname( " + getHostname() + " )" );
55         sb.append( ", port( " + getPort() + " )" );
56         sb.append( " ]" );
57         return sb.toString();
58     }
59
60 }
61
Popular Tags