Adding support for methods to code dom