AW: [Metafacture] Character classes in data source

Christoph, Pascal christoph at hbz-nrw.de
Thu Oct 17 11:38:45 CEST 2013


Hi Christoph,

Am 16.10.2013 19:34 schrieb Böhme, Christoph :

> it is currently not possible to use character classes. You would have to extend the WildcardTrie class [1] to support more elaborate matching patterns. I reckon it should not be incredibly difficult to add support for character classes. We do not have any plans for implementing this at the moment, though. Perhaps you could give it a try yourself?

Yes, I have done this already, see the pull request[1].
I am not sure how to embed that new functionality, though. As you can see in
[1] I made a wrapper, for the WildardTrie is final and thus cannot be extended.
#135 provides a metamorph test, too. To make it simple for now, the new class
is instantiated at the WildcardDataRegistry , which is obviously not a good
place resp. needs renaming.
I would be glad if you have a more solid notion of integrating this new class.
Renaming is also fine with me.

-o

[1] https://github.com/culturegraph/metafacture-core/pull/135

> Best,
> Christoph
> 
> 
> 
> [1] https://github.com/culturegraph/metafacture-core/blob/master/src/main/java/org/culturegraph/mf/util/tries/WildcardTrie.java
> 
> 
> 
>> -----Ursprüngliche Nachricht-----
>> Von: metafacture-bounces at lists.dnb.de [mailto:metafacture-
>> bounces at lists.dnb.de] Im Auftrag von Christoph, Pascal
>> Gesendet: Mittwoch, 16. Oktober 2013 10:42
>> An: metafacture at lists.dnb.de
>> Betreff: [Metafacture] Character classes in data source
>> 
>> Hello *,
>> 
>> in metamorph, is there a possibility to use more then wildcards ('*','?')
>> defining the data source? I would like to use simple character classes. For
>> instance, something like this:
>> 
>> <rules>
>> 	<data source="902-1.9|907-1.9|.../>
>> </rules>
>> 
>> should be expressable by this:
>> 
>> <rules>
>> 	<data source="9[0123445678][27]-[-1].9/>
>> </rules>
>> 
>> -o
>> 
>> _______________________________________________
>> Metafacture mailing list
>> Metafacture at lists.dnb.de
>> http://lists.dnb.de/mailman/listinfo/metafacture
> 




More information about the Metafacture mailing list