How do I write a simple XPath evaluator for an XPath query:
// user [Role = 'moderator'] / address /./zipcode ?
I am trying to write an XPath induced tool to find files in a directory.
EDIT: I should be clear but I am not trying to write a full XPath implementation. If it supports such questions as seen, then it is enough for my purposes. Besides, do not worry about the difficulty level. I am a bit crazy and I will find a way to pull it.)
I want to say that if you need to ask questions, then you probably should not try it. If you want to proceed further, start by reading a few books on compiler writing, especially lexical and syntax analysis. Alternatively, if you are not a person learning from books, get an open source XPath implementation and separate it to see how it works.
Comments
Post a Comment