Hi José,
sorry for getting back to you this late.
I can only repeat Christian's advice, for a start a XQuery library might be sufficient to get in touch with BaseX. Once you feel confident enough you might want to start poking around the code base.
As our implementation is schema oblivious (i.e. our implemantation has no semantic notion of e.g. xml:id), the task at hand calls for a pure XQuery approach anyway. Maybe you could have a look at our Function implementations (classes implementing the abstract class org.basex.query.func.Fun) and the QueryParser. Spend some time debugging those, so you get a feeling for the building blocks of the engine.
Hope this helped to clarify things a little :-)
Michael Am 14.05.2011 um 09:51 schrieb Christian Grün:
I agree with Michael: a user-defined function might suffice to solve your task; or it might be a better point to get started. Changing the core of BaseX is an interesting challenge, but you will have to invest lots of efforts to accomplish your goal.