}else if (i1<0xdc00){ if((i1+1)==s.length()|| (s.charAt(i+1) < (0xdc00) && s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c< (int)l1) i+=2; }else throw new NavException(" invalid unicode in string"); offset += (int) (l1 >> 32);
public Map<String, Object> next() { if (!hasNext()) return null; Map<String, Object> row = new HashMap<String, Object>(); try { for (String fieldName : navigators.keySet()) { FieldValueSource navi = navigators.get(fieldName); Object fieldValue = navi.getFieldValue(); row.put(fieldName, fieldValue); } row.put(JulieXMLConstants.VTD_INDEX, index); index = ap.evalXPath(); return row; } catch (XPathEvalException e) { e.printStackTrace(); } catch (NavException e) { e.printStackTrace(); } catch (Exception e) { e.printStackTrace(); } return null; }
}else if (i1<0xdc00){ if((i+1)==s.length() || (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c< (int)l1) i+=2; }else throw new NavException(" invalid unicode in string");
e.printStackTrace(); } catch (NavException e) { e.printStackTrace(); } catch (VTDExceptionHuge e) { e.printStackTrace();
} else if (i1<0xdc00){ if((i+1)==s.length() || (s.charAt(i+1) >= (0xdbff) && s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c< (int)l1) i+=2; }else throw new NavException(" invalid unicode in string"); offset += (int) (l1 >> 32);
e.printStackTrace(); } catch (NavException e) { e.printStackTrace(); } catch (XPathParseException e) { e.printStackTrace();
break; default: throw new NavException("UTF 8 encoding error: should never happen"); temp = XMLDoc.byteAt(offset + a - i); if ((temp & 0xc0) != 0x80) throw new NavException( "UTF 8 encoding error: should never happen"); val = val | ((temp & 0x3f) << ((i << 2) + (i << 1)));
}else if (i1<0xdc00){ if((i+1)==s.length()|| (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c< (int)l1) i+=2; }else throw new NavException(" invalid unicode in string"); offset += (int) (l1 >> 32);
break; default: throw new NavException("UTF 8 encoding error: should never happen"); temp = XMLDoc.byteAt(offset + a - i); if ((temp & 0xc0) != 0x80) throw new NavException( "UTF 8 encoding error: should never happen"); val = val | ((temp & 0x3f) << ((i << 2) + (i << 1)));
}else if (i1<0xdc00){ if((i+1)==s.length() || (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c< temp) i+=2; }else throw new NavException(" invalid unicode in string"); offset += (int) (l1 >> 32);
private long getChar4OtherEncoding(int offset) throws NavException{ if (encoding <= FORMAT_WIN_1258){ int temp = decode(offset); if (temp == '\r') { if (XMLDoc.byteAt(offset + 1) == '\n') { return '\n'|(2L<<32); } else { return '\n'|(1L<<32); } } return temp|(1L<<32); } throw new NavException("Unknown Encoding"); } /**
break; default: throw new NavException("UTF 8 encoding error: should never happen"); temp = XMLDoc.byteAt(offset + a - i); if ((temp & 0xc0) != 0x80) throw new NavException( "UTF 8 encoding error: should never happen"); val = val | ((temp & 0x3f) << ((i << 2) + (i << 1)));
private long getChar4OtherEncoding(int offset) throws NavException{ if (encoding <= FORMAT_WIN_1258){ int temp = decode(offset); if (temp == '\r') { if (XMLDoc.byteAt(offset + 1) == '\n') { return '\n'|(2L<<32); } else { return '\n'|(1L<<32); } } return temp|(1L<<32); } throw new NavException("Unknown Encoding"); } /**
private long getChar4OtherEncoding(int offset) throws NavException{ if (encoding <= FORMAT_WIN_1258){ int temp = decode(offset); if (temp == '\r') { if (XMLDoc.byteAt(offset + 1) == '\n') { return '\n'|(2L<<32); } else { return '\n'|(1L<<32); } } return temp|(1L<<32); } throw new NavException("Unknown Encoding"); } /**
}else if (i1<0xdc00){ if((i+1)==s.length()|| (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c != (int) l1) i+=2; }else throw new NavException(" invalid unicode in string"); offset += (int) (l1 >> 32);
}else if (i1<0xdc00){ if((i+1)==s.length()|| (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c != (int) l1) i+=2; }else throw new NavException(" invalid unicode in string");
/** * Test whether the URL is defined in the scope. Null is allowed to indicate * the name space is undefined. Creation date: (11/16/03 7:54:01 PM) * * @param URL * java.lang.String * @exception com.ximpleware.NavException * When there is any encoding conversion error or unknown * entity. */ final protected int lookupNS() throws NavException { if (context[0]==-1) throw new NavException("Can't lookup NS for document node"); int i = getTokenLength((context[0] != 0) ? context[context[0]] : rootIndex); int offset = getTokenOffset((context[0] != 0) ? context[context[0]] : rootIndex); int preLen = (i >> 16) & 0xffff; return lookupNS(offset, preLen); //return resolveNS(URL, offset, preLen); }
}else if (i1<0xdc00){ if((i+1)==s.length()|| (s.charAt(i+1) < (0xdc00) || s.charAt(i+1)> 0xdfff)) throw new NavException(" invalid unicode in string"); int c= 0x10000+ ((i1-0xd800)<<10)+((s.charAt(i+1)-0xdc00)); if (c != (int) l1) i+=2; }else throw new NavException(" invalid unicode in string");
/** * Test whether the URL is defined in the scope. Null is allowed to indicate * the name space is undefined. Creation date: (11/16/03 7:54:01 PM) * * @param URL * java.lang.String * @exception com.ximpleware.NavException * When there is any encoding conversion error or unknown * entity. */ final protected int lookupNS() throws NavException { if (context[0]==-1) throw new NavException("Can't lookup NS for document node"); int i = getTokenLength((context[0] != 0) ? context[context[0]] : rootIndex); int offset = getTokenOffset((context[0] != 0) ? context[context[0]] : rootIndex); int preLen = (i >> 16) & 0xffff; return lookupNS(offset, preLen); //return resolveNS(URL, offset, preLen); }
/** * Test whether the URL is defined in the scope. Null is allowed to indicate * the name space is undefined. Creation date: (11/16/03 7:54:01 PM) * * @param URL * java.lang.String * @exception com.ximpleware.NavException * When there is any encoding conversion error or unknown * entity. */ final protected int lookupNS() throws NavException { if (context[0]==-1) throw new NavException("Can't lookup NS for document node"); int i = getTokenLength((context[0] != 0) ? context[context[0]] : rootIndex); int offset = getTokenOffset((context[0] != 0) ? context[context[0]] : rootIndex); int preLen = (i >> 16) & 0xffff; return lookupNS(offset, preLen); //return resolveNS(URL, offset, preLen); }