KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > xerces > xni > grammars > XMLGrammarDescription


1 /*
2  * Copyright 2000-2002,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.xerces.xni.grammars;
18
19 import org.apache.xerces.xni.XMLResourceIdentifier;
20
21 /**
22  * <p> This interface describes basic attributes of XML grammars--their
23  * physical location and their type. </p>
24  *
25  * @author Neil Graham, IBM
26  * @version $Id: XMLGrammarDescription.java,v 1.7 2004/02/24 23:15:58 mrglavas Exp $
27  */

28 public interface XMLGrammarDescription extends XMLResourceIdentifier {
29
30     // initial set of grammar constants that some configurations will recognize;user
31
// components which create and/or recognize other types of grammars may
32
// certainly use their own constants in place of these (so long as
33
// their Grammar objects implement this interface).
34

35     /**
36      * The grammar type constant for XML Schema grammars. When getGrammarType()
37      * method returns this constant, the object should be an instance of
38      * the XMLSchemaDescription interface.
39      */

40     public static final String JavaDoc XML_SCHEMA = "http://www.w3.org/2001/XMLSchema";
41     
42     /**
43      * The grammar type constant for DTD grammars. When getGrammarType()
44      * method returns this constant, the object should be an instance of
45      * the XMLDTDDescription interface.
46      */

47     public static final String JavaDoc XML_DTD = "http://www.w3.org/TR/REC-xml";
48
49     /**
50      * Return the type of this grammar.
51      *
52      * @return the type of this grammar
53      */

54     public String JavaDoc getGrammarType();
55
56 } // interface XMLGrammarDescription
57
Popular Tags