01: /*
02: * $Id: UnknownLocation.java,v 1.1 2004/07/08 14:30:23 cniles Exp $
03: */
04: package javanet.staxutils.helpers;
05:
06: import javanet.staxutils.StaticLocation;
07:
08: import javax.xml.stream.Location;
09:
10: /**
11: * {@link Location} used to represent unknown locations.
12: *
13: * @author Christian Niles
14: * @version $Revision: 1.1 $
15: */
16: public final class UnknownLocation implements Location, StaticLocation {
17:
18: public static final UnknownLocation INSTANCE = new UnknownLocation();
19:
20: public int getLineNumber() {
21:
22: return -1;
23:
24: }
25:
26: public int getColumnNumber() {
27:
28: return -1;
29:
30: }
31:
32: public int getCharacterOffset() {
33:
34: return -1;
35:
36: }
37:
38: public String getPublicId() {
39:
40: return null;
41:
42: }
43:
44: public String getSystemId() {
45:
46: return null;
47:
48: }
49:
50: }
|