extending it with interfaces to process an xml better

also with some examples how to use it!