1 16 19 20 package org.apache.xml.dtm.ref; 21 22 import javax.xml.transform.SourceLocator ; 23 24 31 public class NodeLocator implements SourceLocator 32 { 33 protected String m_publicId; 34 protected String m_systemId; 35 protected int m_lineNumber; 36 protected int m_columnNumber; 37 38 46 public NodeLocator(String publicId, String systemId, 47 int lineNumber, int columnNumber) 48 { 49 this.m_publicId = publicId; 50 this.m_systemId = systemId; 51 this.m_lineNumber = lineNumber; 52 this.m_columnNumber = columnNumber; 53 } 54 55 60 public String getPublicId() 61 { 62 return m_publicId; 63 } 64 65 70 public String getSystemId() 71 { 72 return m_systemId; 73 } 74 75 80 public int getLineNumber() 81 { 82 return m_lineNumber; 83 } 84 85 91 public int getColumnNumber() 92 { 93 return m_columnNumber; 94 } 95 96 102 public String toString() 103 { 104 return "file '" + m_systemId 105 + "', line #" + m_lineNumber 106 + ", column #" + m_columnNumber; 107 } 108 } 109 | Popular Tags |