KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > sync4j > framework > server > Sync4jModule


1 /**
2  * Copyright (C) 2003-2005 Funambol
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation; either version 2 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  */

18
19 package sync4j.framework.server;
20
21 import java.io.Serializable JavaDoc;
22
23 /**
24  * This class represents a Sync4j module.
25  *
26  * @author Luigia Fassina @ Funambol
27  *
28  * @version $Id: Sync4jModule.java,v 1.6 2005/03/02 20:57:38 harrie Exp $
29  *
30  */

31 public class Sync4jModule implements Serializable JavaDoc {
32
33     private String JavaDoc moduleId ;
34     private String JavaDoc moduleName ;
35     private String JavaDoc description ;
36     private Sync4jConnector[] connectors ;
37
38     /** Creates a new instance of Sync4jModule */
39     public Sync4jModule() {
40         this(null,null,null);
41     }
42
43     public Sync4jModule(String JavaDoc moduleId ,
44                         String JavaDoc moduleName ,
45                         String JavaDoc description) {
46         this.moduleId = moduleId;
47         this.moduleName = moduleName;
48         this.description = description;
49     }
50
51     /** Getter for property moduleId.
52      * @return Value of property moduleId.
53      *
54      */

55     public String JavaDoc getModuleId() {
56         return moduleId;
57     }
58
59     /** Setter for property moduleId.
60      * @param moduleId New value of property moduleId.
61      *
62      */

63     public void setModuleId(String JavaDoc moduleId) {
64         this.moduleId = moduleId;
65     }
66
67     /** Getter for property moduleName.
68      * @return Value of property moduleName.
69      *
70      */

71     public String JavaDoc getModuleName() {
72         return moduleName;
73     }
74
75     /** Setter for property moduleName.
76      * @param moduleName New value of property moduleName.
77      *
78      */

79     public void setModuleName(String JavaDoc moduleName) {
80         this.moduleName = moduleName;
81     }
82
83     /** Getter for property desciption.
84      * @return Value of property description.
85      *
86      */

87     public String JavaDoc getDescription() {
88         return description;
89     }
90
91     /** Setter for property description.
92      * @param description New value of property description.
93      *
94      */

95     public void setDescription(String JavaDoc description) {
96         this.description = description;
97     }
98
99     public void setConnectors(Sync4jConnector[] connectors) {
100         this.connectors = connectors;
101     }
102
103     public Sync4jConnector[] getConnectors() {
104         return connectors;
105     }
106
107     public String JavaDoc toString() {
108     StringBuffer JavaDoc sb = new StringBuffer JavaDoc();
109     sb.append("ModuleId: ").append(moduleId).append(", ")
110           .append("ModuleName: ").append(moduleName).append(", ")
111       .append("Description: ").append(description);
112     return sb.toString();
113     }
114
115 }
116
Popular Tags