Sorry about the last post.  I have attatched the patch this time:

Thanks,
John
-- 
********************************
** John Thorhauer
** [EMAIL PROTECTED]
** take a look at:
**  http://tambora.zenplex.org
**  http://www.zenplex.org
**  http://www.zenplex.com
********************************

Index: jakarta-commons/betwixt/src/java/org/apache/commons/betwixt/strategy/DefaultPluralStemmer.java
===================================================================
RCS file: /home/cvs/jakarta-commons/betwixt/src/java/org/apache/commons/betwixt/strategy/DefaultPluralStemmer.java,v
retrieving revision 1.2
diff -r1.2 DefaultPluralStemmer.java
92a93,97
> 
>         if ( answer == null && !propertyName.endsWith( "y" )) {
>             answer = (ElementDescriptor) map.get( propertyName + "es" );
>         }
> 
129c134
<             log.warn("More then one type matches, using closest match "+keyFound);
---
>             log.warn("More than one type matches, using closest match "+keyFound);
Index: jakarta-commons/betwixt/src/test/org/apache/commons/betwixt/strategy/TestDefaultPluralStemmer.java
===================================================================
RCS file: /home/cvs/jakarta-commons/betwixt/src/test/org/apache/commons/betwixt/strategy/TestDefaultPluralStemmer.java,v
retrieving revision 1.1
diff -r1.1 TestDefaultPluralStemmer.java
154c154
<     
---
>    
181c181,205
<     
---
>    
>     /**
>      *  Test to find matched where plural ending is "es" 
>      */
>     public void testESPluralEndingMatch() {
>         HashMap map = new HashMap();
> 
>         ElementDescriptor index = new ElementDescriptor("index", "index","");
>         map.put("index", index);
>         ElementDescriptor indexes = new ElementDescriptor("indexes", "indexes","");
>         map.put("indexes", indexes);
> 
>         ElementDescriptor patch = new ElementDescriptor("patch", "patch","");
>         map.put("patch", patch);
>         ElementDescriptor patches = new ElementDescriptor("patches", "patches","");
>         map.put("patches", patches);
> 
>         DefaultPluralStemmer stemmer = new DefaultPluralStemmer();
>         ElementDescriptor result = stemmer.findPluralDescriptor("index", map);
>         assertEquals(indexes, result);
> 
>         result = stemmer.findPluralDescriptor("patches", map);
>         assertEquals(patches, result);
>     }
>  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to