1   /***
2    * JFoxSOAF, Service-Oriented Application Framework
3    * 
4    * Copyright (C) www.huihoo.org
5    * 
6    * Distributable under GNU LGPL For more information, please visit:
7    * http://www.huihoo.org/jfox/jfoxsoaf
8    */
9   
10  package org.huihoo.jfox.soaf.container;
11  
12  import java.io.IOException;
13  import java.io.Writer;
14  import java.util.Enumeration;
15  
16  import org.exolab.castor.xml.MarshalException;
17  import org.exolab.castor.xml.ValidationException;
18  import org.huihoo.jfox.soaf.schema.service.Parameter;
19  import org.xml.sax.ContentHandler;
20  
21  /***
22   * MockObject for ServiceEntry.
23   * 
24   * @author <a href="mailto:founder_chen@yahoo.com.cn">Peter Cheng </a>
25   * @version $Revision: 1.1 $ $Date: 2004/10/18 13:00:12 $
26   * @version Revision: 1.0
27   */
28  
29  public class MockServiceEntry implements ServiceEntry {
30  
31      private String id;
32  
33      private String _interface;
34  
35      private String description;
36  
37      private String implementation;
38  
39      private String manageable = "false";
40  
41      /***
42       * @see org.huihoo.jfox.soaf.container.ServiceEntry#addParameter(org.huihoo.jfox.soaf.schema.service.Parameter)
43       */
44      public void addParameter(Parameter vParameter)
45              throws IndexOutOfBoundsException {
46      }
47  
48      /***
49       * @see org.huihoo.jfox.soaf.container.ServiceEntry#addParameter(int,
50       *      org.huihoo.jfox.soaf.schema.service.Parameter)
51       */
52      public void addParameter(int index, Parameter vParameter)
53              throws IndexOutOfBoundsException {
54      }
55  
56      /***
57       * @see org.huihoo.jfox.soaf.container.ServiceEntry#enumerateParameter()
58       */
59      public Enumeration enumerateParameter() {
60          return null;
61      }
62  
63      /***
64       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getDescription()
65       */
66      public String getDescription() {
67          return this.description;
68      }
69  
70      /***
71       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getId()
72       */
73      public String getId() {
74          return this.id;
75      }
76  
77      /***
78       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getImplementation()
79       */
80      public String getImplementation() {
81          return this.implementation;
82      }
83  
84      /***
85       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getInterface()
86       */
87      public String getInterface() {
88          return this._interface;
89      }
90  
91      /***
92       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getManageable()
93       */
94      public String getManageable() {
95          return this.manageable;
96      }
97  
98      /***
99       * @see org.huihoo.jfox.soaf.container.ServiceEntry#getParameter(int)
100      */
101     public Parameter getParameter(int index) throws IndexOutOfBoundsException {
102         return null;
103     }
104 
105     /***
106      * @see org.huihoo.jfox.soaf.container.ServiceEntry#getParameter()
107      */
108     public Parameter[] getParameter() {
109         return null;
110     }
111 
112     /***
113      * @see org.huihoo.jfox.soaf.container.ServiceEntry#getParameterCount()
114      */
115     public int getParameterCount() {
116         return 0;
117     }
118 
119     /***
120      * @see org.huihoo.jfox.soaf.container.ServiceEntry#isValid()
121      */
122     public boolean isValid() {
123         return false;
124     }
125 
126     /***
127      * @see org.huihoo.jfox.soaf.container.ServiceEntry#marshal(java.io.Writer)
128      */
129     public void marshal(Writer out) throws MarshalException,
130             ValidationException {
131     }
132 
133     /***
134      * @see org.huihoo.jfox.soaf.container.ServiceEntry#marshal(org.xml.sax.ContentHandler)
135      */
136     public void marshal(ContentHandler handler) throws IOException,
137             MarshalException, ValidationException {
138     }
139 
140     /***
141      * @see org.huihoo.jfox.soaf.container.ServiceEntry#removeAllParameter()
142      */
143     public void removeAllParameter() {
144     }
145 
146     /***
147      * @see org.huihoo.jfox.soaf.container.ServiceEntry#removeParameter(int)
148      */
149     public Parameter removeParameter(int index) {
150         return null;
151     }
152 
153     /***
154      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setDescription(java.lang.String)
155      */
156     public void setDescription(String description) {
157         this.description = description;
158     }
159 
160     /***
161      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setId(java.lang.String)
162      */
163     public void setId(String id) {
164         this.id = id;
165     }
166 
167     /***
168      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setImplementation(java.lang.String)
169      */
170     public void setImplementation(String implementation) {
171         this.implementation = implementation;
172     }
173 
174     /*
175      * (non-Javadoc)
176      * 
177      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setInterface(java.lang.String)
178      */
179     public void setInterface(String _interface) {
180         this._interface = _interface;
181 
182     }
183 
184     /***
185      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setManageable(java.lang.String)
186      */
187     public void setManageable(String manageable) {
188         this.manageable = manageable;
189     }
190 
191     /***
192      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setParameter(int,
193      *      org.huihoo.jfox.soaf.schema.service.Parameter)
194      */
195     public void setParameter(int index, Parameter vParameter)
196             throws IndexOutOfBoundsException {
197     }
198 
199     /***
200      * @see org.huihoo.jfox.soaf.container.ServiceEntry#setParameter(org.huihoo.jfox.soaf.schema.service.Parameter[])
201      */
202     public void setParameter(Parameter[] parameterArray) {
203     }
204 
205     /***
206      * @see org.huihoo.jfox.soaf.container.ServiceEntry#validate()
207      */
208     public void validate() throws ValidationException {
209     }
210 
211 }