public BXXMLResource getResource(final String id) throws XMLDBException {
check();
if(id == null) return null;
final Data data = ctx.data;
final byte[] idd = Token.token(id);
<BUG>for(final int pre : data.doc()) {
if(Token.eq(data.text(pre, true), idd))</BUG>
return new BXXMLResource(data, pre, id, this);
}
return null;

public BXXMLResource getResource(final String id) throws XMLDBException {
check();
if(id == null) return null;
final Data data = ctx.data;
final byte[] idd = Token.token(id);
final IntList il = data.doc();
for(int i = 0, is = il.size(); i < is; i++) {
final int pre = il.get(i);
if(Token.eq(data.text(pre, true), idd))
return new BXXMLResource(data, pre, id, this);
}
return null;
