Moved some reflection code from AbstractPebbleTemplate into it's own class