KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > commons > digester > RuleSetBase


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

17
18
19 package org.apache.commons.digester;
20
21
22 /**
23  * <p>Convenience base class that implements the {@link RuleSet} interface.
24  * Concrete implementations should list all of their actual rule creation
25  * logic in the <code>addRuleSet()</code> implementation.</p>
26  */

27
28 public abstract class RuleSetBase implements RuleSet {
29
30
31     // ----------------------------------------------------- Instance Variables
32

33
34     /**
35      * The namespace URI that all Rule instances created by this RuleSet
36      * will be associated with.
37      */

38     protected String JavaDoc namespaceURI = null;
39
40
41     // ------------------------------------------------------------- Properties
42

43
44     /**
45      * Return the namespace URI that will be applied to all Rule instances
46      * created from this RuleSet.
47      */

48     public String JavaDoc getNamespaceURI() {
49
50         return (this.namespaceURI);
51
52     }
53
54
55     // --------------------------------------------------------- Public Methods
56

57
58     /**
59      * Add the set of Rule instances defined in this RuleSet to the
60      * specified <code>Digester</code> instance, associating them with
61      * our namespace URI (if any). This method should only be called
62      * by a Digester instance.
63      *
64      * @param digester Digester instance to which the new Rule instances
65      * should be added.
66      */

67     public abstract void addRuleInstances(Digester digester);
68
69
70 }
71
Popular Tags