ggregory 2004/09/08 10:44:41
Modified: codec/src/java/org/apache/commons/codec/language
Soundex.java
Log:
// comments.
Revision Changes Path
1.27 +3 -1
jakarta-commons/codec/src/java/org/apache/commons/codec/language/Soundex.java
Index: Soundex.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/language/Soundex.java,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -r1.26 -r1.27
--- Soundex.java 7 Jul 2004 23:15:24 -0000 1.26
+++ Soundex.java 8 Sep 2004 17:44:41 -0000 1.27
@@ -162,6 +162,7 @@
* if the character is not mapped
*/
private char getMappingCode(String str, int index) {
+ // map() throws IllegalArgumentException
char mappedChar = this.map(str.charAt(index));
// HW rule check
if (index > 1 && mappedChar != '0') {
@@ -255,6 +256,7 @@
char last, mapped;
int incount = 1, count = 1;
out[0] = str.charAt(0);
+ // getMappingCode() throws IllegalArgumentException
last = getMappingCode(str, 0);
while ((incount < str.length()) && (count < out.length)) {
mapped = getMappingCode(str, incount++);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]