KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > axis > message > NullAttributes


1 package org.apache.axis.message;
2
3 import org.xml.sax.Attributes JavaDoc;
4
5 /**
6  * Null implementation of the Attributes interface.
7  *
8  * @author David Megginson
9  * @author Sam Ruby <rubys@us.ibm.com>
10  */

11 public class NullAttributes implements Attributes JavaDoc {
12
13     public static final NullAttributes singleton = new NullAttributes();
14
15     ////////////////////////////////////////////////////////////////////
16
// Implementation of org.xml.sax.Attributes.
17
////////////////////////////////////////////////////////////////////
18

19
20     /**
21      * Return the number of attributes in the list.
22      *
23      * @return The number of attributes in the list.
24      * @see org.xml.sax.Attributes#getLength
25      */

26     public int getLength () {
27         return 0;
28     }
29
30
31     /**
32      * Return an attribute's Namespace URI.
33      *
34      * @param index The attribute's index (zero-based).
35      * @return The Namespace URI, the empty string if none is
36      * available, or null if the index is out of range.
37      * @see org.xml.sax.Attributes#getURI
38      */

39     public String JavaDoc getURI (int index) {
40         return null;
41     }
42
43
44     /**
45      * Return an attribute's local name.
46      *
47      * @param index The attribute's index (zero-based).
48      * @return The attribute's local name, the empty string if
49      * none is available, or null if the index if out of range.
50      * @see org.xml.sax.Attributes#getLocalName
51      */

52     public String JavaDoc getLocalName (int index) {
53         return null;
54     }
55
56
57     /**
58      * Return an attribute's qualified (prefixed) name.
59      *
60      * @param index The attribute's index (zero-based).
61      * @return The attribute's qualified name, the empty string if
62      * none is available, or null if the index is out of bounds.
63      * @see org.xml.sax.Attributes#getQName
64      */

65     public String JavaDoc getQName (int index) {
66         return null;
67     }
68
69
70     /**
71      * Return an attribute's type by index.
72      *
73      * @param index The attribute's index (zero-based).
74      * @return The attribute's type, "CDATA" if the type is unknown, or null
75      * if the index is out of bounds.
76      * @see org.xml.sax.Attributes#getType(int)
77      */

78     public String JavaDoc getType (int index) {
79         return null;
80     }
81
82
83     /**
84      * Return an attribute's value by index.
85      *
86      * @param index The attribute's index (zero-based).
87      * @return The attribute's value or null if the index is out of bounds.
88      * @see org.xml.sax.Attributes#getValue(int)
89      */

90     public String JavaDoc getValue (int index) {
91         return null;
92     }
93
94
95     /**
96      * Look up an attribute's index by Namespace name.
97      *
98      * <p>In many cases, it will be more efficient to look up the name once and
99      * use the index query methods rather than using the name query methods
100      * repeatedly.</p>
101      *
102      * @param uri The attribute's Namespace URI, or the empty
103      * string if none is available.
104      * @param localName The attribute's local name.
105      * @return The attribute's index, or -1 if none matches.
106      * @see org.xml.sax.Attributes#getIndex(java.lang.String,java.lang.String)
107      */

108     public int getIndex (String JavaDoc uri, String JavaDoc localName) {
109         return -1;
110     }
111
112
113     /**
114      * Look up an attribute's index by qualified (prefixed) name.
115      *
116      * @param qName The qualified name.
117      * @return The attribute's index, or -1 if none matches.
118      * @see org.xml.sax.Attributes#getIndex(java.lang.String)
119      */

120     public int getIndex (String JavaDoc qName) {
121         return -1;
122     }
123
124
125     /**
126      * Look up an attribute's type by Namespace-qualified name.
127      *
128      * @param uri The Namespace URI, or the empty string for a name
129      * with no explicit Namespace URI.
130      * @param localName The local name.
131      * @return The attribute's type, or null if there is no
132      * matching attribute.
133      * @see org.xml.sax.Attributes#getType(java.lang.String,java.lang.String)
134      */

135     public String JavaDoc getType (String JavaDoc uri, String JavaDoc localName) {
136         return null;
137     }
138
139
140     /**
141      * Look up an attribute's type by qualified (prefixed) name.
142      *
143      * @param qName The qualified name.
144      * @return The attribute's type, or null if there is no
145      * matching attribute.
146      * @see org.xml.sax.Attributes#getType(java.lang.String)
147      */

148     public String JavaDoc getType (String JavaDoc qName) {
149         return null;
150     }
151
152
153     /**
154      * Look up an attribute's value by Namespace-qualified name.
155      *
156      * @param uri The Namespace URI, or the empty string for a name
157      * with no explicit Namespace URI.
158      * @param localName The local name.
159      * @return The attribute's value, or null if there is no
160      * matching attribute.
161      * @see org.xml.sax.Attributes#getValue(java.lang.String,java.lang.String)
162      */

163     public String JavaDoc getValue (String JavaDoc uri, String JavaDoc localName) {
164         return null;
165     }
166
167
168     /**
169      * Look up an attribute's value by qualified (prefixed) name.
170      *
171      * @param qName The qualified name.
172      * @return The attribute's value, or null if there is no
173      * matching attribute.
174      * @see org.xml.sax.Attributes#getValue(java.lang.String)
175      */

176     public String JavaDoc getValue (String JavaDoc qName) {
177         return null;
178     }
179 }
180
Popular Tags