public boolean isValidTermOrPhrase( final List<TermInfo> phraseCandidate ){if( !terminal ) return false;if( phraseCandidate.size() == 1 ) return true;int pos = phraseCandidate.get( 0 ).getPosition();for( int i = 1; i < phraseCandidate.size(); i++ ){int nextPos = phraseCandidate.get( i ).getPosition();if( Math.abs( nextPos - pos - 1 ) > slop ) return false;pos = nextPos;}return true;}

public virtual bool IsValidTermOrPhrase(IList<TermInfo> phraseCandidate){if (!terminal) return false;if (phraseCandidate.Count == 1) return true;int pos = phraseCandidate[0].Position;for (int i = 1; i < phraseCandidate.Count; i++){int nextPos = phraseCandidate[i].Position;if (Math.Abs(nextPos - pos - 1) > slop) return false;pos = nextPos;}return true;}
