com.sun.jersey.json.impl.reader.StaxLocation Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jersey-bundle Show documentation
Show all versions of jersey-bundle Show documentation
A bundle containing code of all jar-based modules that provide
JAX-RS and Jersey-related features. Such a bundle is *only intended* for
developers that do not use Maven's dependency system.
The bundle does not include code for contributes, tests and samples.
package com.sun.jersey.json.impl.reader;
import javax.xml.stream.Location;
import org.codehaus.jackson.JsonLocation;
class StaxLocation implements Location {
int charOffset = -1;
int column = -1;
int line = -1;
StaxLocation(final int charOffset, final int column, final int line) {
super();
this.charOffset = charOffset;
this.column = column;
this.line = line;
}
StaxLocation(final JsonLocation location) {
this((int)location.getCharOffset(), location.getColumnNr(), location.getLineNr());
}
StaxLocation(final JsonLexer lexer) {
this(lexer.getCharOffset(), lexer.getColumn(), lexer.getLineNumber());
}
public int getCharacterOffset() {
return charOffset;
}
public int getColumnNumber() {
return column;
}
public int getLineNumber() {
return line;
}
public String getPublicId() {
return null;
}
public String getSystemId() {
return null;
}
}