01: /*
02: * Copyright 2001-2004 The Apache Software Foundation.
03: *
04: * Licensed under the Apache License, Version 2.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.apache.org/licenses/LICENSE-2.0
09: *
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:
17: package org.apache.ws.scout.registry.infomodel;
18:
19: import javax.xml.registry.JAXRException;
20: import javax.xml.registry.LifeCycleManager;
21: import javax.xml.registry.infomodel.ClassificationScheme;
22: import javax.xml.registry.infomodel.InternationalString;
23: import javax.xml.registry.infomodel.RegistryObject;
24:
25: /**
26: * Implements JAXR Interface.
27: * For futher details, look into the JAXR API Javadoc.
28: *
29: * @author Anil Saldhana <anil@apache.org>
30: */
31: public class ExternalIdentifierImpl extends RegistryObjectImpl
32: implements javax.xml.registry.infomodel.ExternalIdentifier {
33:
34: private ClassificationScheme identity = new ClassificationSchemeImpl(
35: null);
36: private String value = new String();
37: private RegistryObject parent;
38:
39: /**
40: * Creates a new instance of ExternalIdentifierImpl
41: */
42: public ExternalIdentifierImpl(LifeCycleManager lifeCycleManager) {
43: super (lifeCycleManager);
44: }
45:
46: public ExternalIdentifierImpl(LifeCycleManager lifeCycleManager,
47: ClassificationScheme identity, InternationalString name,
48: String value) {
49: super (lifeCycleManager, name);
50: this .identity = identity;
51: this .value = value;
52: }
53:
54: public ClassificationScheme getIdentificationScheme()
55: throws JAXRException {
56: return identity;
57: }
58:
59: public RegistryObject getRegistryObject() throws JAXRException {
60: return parent;
61: }
62:
63: public String getValue() throws JAXRException {
64: return value;
65: }
66:
67: public void setIdentificationScheme(ClassificationScheme cs)
68: throws JAXRException {
69: identity = cs;
70: }
71:
72: public void setValue(String str) throws JAXRException {
73: value = str;
74: }
75:
76: //Specific API
77: public void setRegistryObject(RegistryObject obj) {
78: parent = obj;
79: }
80:
81: }
|