<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">I have started working on that in the plane back home.<div><span class="Apple-style-span" style="font-family: Verdana; line-height: 15px; ">It's available upstream and requires the upstream commons-annotations and annotations projects.</span></div><div><br></div><div><span class="Apple-style-span" style="font-family: Courier; font-size: 11px; -webkit-border-horizontal-spacing: 1px; -webkit-border-vertical-spacing: 1px; "> SearchMapping mapping = new SearchMapping(); <br> mapping.analyzerDef( "stem", StandardTokenizerFactory.class ) <br> .tokenizerParam( "name", "value" ) <br> .tokenizerParam( "name2", "value2" ) <br> .filter( LowerCaseFilterFactory.class ) <br> .filter( SnowballPorterFilterFactory.class) <br> .param("language", "English") <br> .analyzerDef( "ngram", StandardTokenizerFactory.class ) <br> .tokenizerParam( "name", "value" ) <br> .tokenizerParam( "name2", "value2" ) <br> .filter( LowerCaseFilterFactory.class ) <br> .filter( NGramFilterFactory.class) <br> .param("minGramSize", "3") <br> .param("maxGramSize", "3") <br> .indexedClass(Address.class, "Address_Index") <br> .property("street1", ElementType.FIELD) <br> .field() <br> .field() <br> .name("street1_iso") <br> .store( Store.YES ) <br> .index( Index.TOKENIZED ) <br> .analyzer( ISOLatin1Analyzer.class) <br> .field() <br> .name("street1_ngram") <br> .analyzer("ngram") <br> .indexedClass(User.class) <br> .property("name", ElementType.METHOD) <br> .field() <br> .analyzerDef( "minimal", StandardTokenizerFactory.class ); <br><br> configuration.getProperties().put( "hibernate.search.mapping_model", mapping ); </span></div><div><span class="Apple-style-span" style="font-family: Verdana; font-size: 16px; "><span class="postbody" style="font-size: 12px; line-height: 125%; "><br>It works nicely (analyzerDef is not wired yet) and the mapping API needs to be completed. A benefit is that it solves the problem encountered by people willing to get XML mapping support in a much nicer way. <br></span></span></div><div><font class="Apple-style-span" face="Verdana"><span class="Apple-style-span" style="line-height: 15px;"><br></span></font></div><div><font class="Apple-style-span" face="Verdana"><span class="Apple-style-span" style="line-height: 15px;">It would benefit from a few additional pairs of eye before completing the work.</span></font></div><div><div><br></div><div><a href="http://forum.hibernate.org/viewtopic.php?p=2409404#2409404">http://forum.hibernate.org/viewtopic.php?p=2409404#2409404</a></div><div><a href="http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-352">http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-352</a></div></div></body></html>