: There is a problem with this. Java does not allow multiple inheritance : and there are other subclasses of QueryParser. Perhaps I can fix it with : a decorator instead.
you might be able to go with a Delegator/Wrapper .. subclass QueryParser to inherit the grammer, override all of the normal methods you override in a subclass to include your field aliasing, but instead of defering to super defer to another instance of QueryParser specified at runtime. I haven't thought through all the implications of wether it will work that easily though .. there's a lot more intra-class "this.foo()" calls in Queryparser then in something like Similarity that may make the Delegator approach problamatic. Honestly: QueryParser is such a mess, you may just want to roll your own from scratch. -Hoss --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]