public void sampleState(FastIntBuffer fib){ // for(int i=0;i<context.) // context[i] = -1; for (int i=0;i<=context[0];i++) fib.append(context[i]); if (atTerminal) fib.append(LN); if (context[0]>=1) fib.append(l1index); if (context[0]>=2){ fib.append(l2index); fib.append(l2lower); fib.append(l2upper); } // else return; if (context[0]>=3){ fib.append(l3index); fib.append(l3lower); fib.append(l3upper); } //else return; }
public void sampleState(FastIntBuffer fib){ // for(int i=0;i<context.) // context[i] = -1; for (int i=0;i<=context[0];i++) fib.append(context[i]); if (atTerminal) fib.append(LN); if (context[0]>=1) fib.append(l1index); if (context[0]>=2){ fib.append(l2index); fib.append(l2lower); fib.append(l2upper); } // else return; if (context[0]>=3){ fib.append(l3index); fib.append(l3lower); fib.append(l3upper); } //else return; }
public void sampleState(FastIntBuffer fib){ // for(int i=0;i<context.) // context[i] = -1; for (int i=0;i<=context[0];i++) fib.append(context[i]); if (atTerminal) fib.append(LN); if (context[0]>=1) fib.append(l1index); if (context[0]>=2){ fib.append(l2index); fib.append(l2lower); fib.append(l2upper); } // else return; if (context[0]>=3){ fib.append(l3index); fib.append(l3lower); fib.append(l3upper); } //else return; }
/** * Test whether the input i is unique; * if not, insert into the hash table and return false * otherwise, return true */ public boolean isUnique(int i){ int temp = i & mask1; if (temp>maxDepth){ maxDepth = temp; } if (storage[temp]==null) { storage[temp]= new FastIntBuffer(pageSizeE); storage[temp].append(i); return true; } else{ int size = storage[temp].size; for (int j=0;j<size;j++){ if (i == storage[temp].intAt(j)){ return false; } } storage[temp].append(i); return true; } }
/** * Test whether the input i is unique; * if not, insert into the hash table and return false * otherwise, return true */ public boolean isUnique(int i){ int temp = i & mask1; if (temp>maxDepth){ maxDepth = temp; } if (storage[temp]==null) { storage[temp]= new FastIntBuffer(pageSizeE); storage[temp].append(i); return true; } else{ int size = storage[temp].size; for (int j=0;j<size;j++){ if (i == storage[temp].intAt(j)){ return false; } } storage[temp].append(i); return true; } }
protected boolean checkNsUniqueness(int i) throws NavException { for (int j = 0; j < fib.size(); j++) { if (vn.compareTokens(fib.intAt(j), vn, i) == 0) return false; } fib.append(i); return true; }
protected boolean checkNsUniqueness(int i) throws NavException{ for (int j=0;j<fib.size();j++){ if (vn.compareTokens(fib.intAt(j), vn, i)==0) return false; } fib.append(i); return true; } /**
protected boolean checkNsUniqueness(int i) throws NavException{ for (int j=0;j<fib.size();j++){ if (vn.compareTokens(fib.intAt(j), vn, i)==0) return false; } fib.append(i); return true; } /**
length = getTokenLength(index); t += length; fib.append(index); if (length > VTDGen.MAX_TOKEN_LENGTH){ while(length > VTDGen.MAX_TOKEN_LENGTH){
length = getTokenLength(index); t += length; fib.append(index); if (length > VTDGen.MAX_TOKEN_LENGTH){ while(length > VTDGen.MAX_TOKEN_LENGTH){
length = getTokenLength(index); t += length; fib.append(index); if (length > VTDGen.MAX_TOKEN_LENGTH){ while(length > VTDGen.MAX_TOKEN_LENGTH){
ens.append(i);
fib.append(index); index++; continue;
i1 = getStringVal(vn,i); if (i1 != -1) fib1.append(i1);
i1 = getStringVal(vn,i); if (i1 != -1) fib1.append(i1);