added methods find, addBefore and addAfter