KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > hivemind > xml > definition > impl > XmlServicePointDefinitionImpl


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

15 package org.apache.hivemind.xml.definition.impl;
16
17 import org.apache.hivemind.Location;
18 import org.apache.hivemind.definition.ModuleDefinition;
19 import org.apache.hivemind.definition.Occurances;
20 import org.apache.hivemind.definition.Visibility;
21 import org.apache.hivemind.definition.impl.ServicePointDefinitionImpl;
22 import org.apache.hivemind.schema.Schema;
23
24 /**
25  * Specialization of {@link ServicePointDefinitionImpl} for service points defined in xml.
26  *
27  * @author Achim Huegen
28  */

29 public class XmlServicePointDefinitionImpl extends ServicePointDefinitionImpl
30 {
31     private Schema _parametersSchema;
32     private Occurances _parametersCount = Occurances.REQUIRED;
33     private String JavaDoc _parametersSchemaId;
34
35     public XmlServicePointDefinitionImpl(ModuleDefinition module)
36     {
37         super(module);
38     }
39     
40     public XmlServicePointDefinitionImpl(ModuleDefinition module, String JavaDoc id, Location location, Visibility visibility, String JavaDoc interfaceClassName)
41     {
42         super(module, id, location, visibility, interfaceClassName);
43     }
44
45     /**
46      * Returns the {@link Schema} used to process any parameters passed to the service. Service
47      * implementation factories and service interceptor factories allow parameters.
48      */

49     public Schema getParametersSchema()
50     {
51         return _parametersSchema;
52     }
53
54     public void setParametersSchema(Schema schema)
55     {
56         _parametersSchema = schema;
57     }
58
59     /**
60      * Returns the number of parameter object expected; generally this is the default of exactly one (
61      * {@link Occurances#REQUIRED}).
62      */

63     public Occurances getParametersCount()
64     {
65         return _parametersCount;
66     }
67
68     public void setParametersCount(Occurances parametersCount)
69     {
70         _parametersCount = parametersCount;
71     }
72
73     public void setParametersSchemaId(String JavaDoc parametersSchemaId)
74     {
75         _parametersSchemaId = parametersSchemaId;
76     }
77
78     public String JavaDoc getParametersSchemaId()
79     {
80         return _parametersSchemaId;
81     }
82     
83 }
84
Popular Tags