KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > ws > jaxme > xs > jaxb > impl > JAXBWildcardImpl


1 /*
2  * Copyright 2003, 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  */

17 package org.apache.ws.jaxme.xs.jaxb.impl;
18
19 import org.apache.ws.jaxme.xs.XSObject;
20 import org.apache.ws.jaxme.xs.impl.XSUtil;
21 import org.apache.ws.jaxme.xs.impl.XSWildcardImpl;
22 import org.apache.ws.jaxme.xs.jaxb.JAXBProperty;
23 import org.apache.ws.jaxme.xs.jaxb.JAXBSchemaBindings;
24 import org.apache.ws.jaxme.xs.jaxb.JAXBWildcard;
25 import org.apache.ws.jaxme.xs.jaxb.JAXBXsSchema;
26 import org.apache.ws.jaxme.xs.xml.XsTWildcard;
27 import org.xml.sax.SAXException JavaDoc;
28
29
30 /**
31  * @author <a HREF="mailto:joe@ispsoft.de">Jochen Wiedmann</a>
32  */

33 public class JAXBWildcardImpl extends XSWildcardImpl implements JAXBWildcard {
34     private JAXBProperty jaxbProperty;
35
36     protected JAXBWildcardImpl(XSObject pParent, XsTWildcard pBaseObject) {
37         super(pParent, pBaseObject);
38     }
39
40     public JAXBProperty getJAXBProperty() { return jaxbProperty; }
41
42     public void validate() throws SAXException JavaDoc {
43         if (isValidated()) {
44             return;
45         } else {
46             super.validate();
47             jaxbProperty = (JAXBProperty) XSUtil.getSingleAppinfo(getAnnotations(), JAXBProperty.class);
48         }
49     }
50
51     public JAXBSchemaBindings getJAXBSchemaBindings() {
52         return ((JAXBXsSchema) getXsObject().getXsESchema()).getJAXBSchemaBindings();
53     }
54 }
55
Popular Tags