Lines Matching defs:alternate
78 * Encode a value with Double Metaphone, optionally using the alternate
82 * @param alternate use alternate encode
85 public String doubleMetaphone(String value, boolean alternate) {
189 return alternate ? result.getAlternate() : result.getPrimary();
233 * are equal, optionally using the alternate value.
237 * @param alternate use the alternate value if <code>true</code>.
243 boolean alternate) {
244 return doubleMetaphone(value1, alternate).equals(doubleMetaphone
245 (value2, alternate));
1027 * Inner class for storing results, since there is the optional alternate
1033 private StringBuffer alternate = new StringBuffer(getMaxCodeLen());
1045 public void append(char primary, char alternate) {
1047 appendAlternate(alternate);
1057 if (this.alternate.length() < this.maxLength) {
1058 this.alternate.append(value);
1067 public void append(String primary, String alternate) {
1069 appendAlternate(alternate);
1082 int addChars = this.maxLength - this.alternate.length();
1084 this.alternate.append(value);
1086 this.alternate.append(value.substring(0, addChars));
1095 return this.alternate.toString();
1100 this.alternate.length() >= this.maxLength;