public Object invoke(Object proxy,Method method,Object[] args) throws Throwable {
  String name=method.getName();
  if (method.getDeclaringClass() == GroovyObject.class) {
    if (name.equals("getMetaClass")) {
      return getMetaClass();
    }
 else     if (name.equals("setMetaClass")) {
      return setMetaClass((MetaClass)args[0]);
    }
  }
  return InvokerHelper.invokeMethod(extension,method.getName(),args);
}

public Object invoke ( Object proxy , Method method , Object [ ] args ) throws Throwable { String name = method . getName ( ) ; if ( method . getDeclaringClass ( ) == GroovyObject . class ) { if ( name . equals ( "getMetaClass" ) ) { return getMetaClass ( ) ; } else if ( name . equals ( "setMetaClass" ) ) { return setMetaClass ( ( MetaClass ) args [ 0 ] ) ; } } return InvokerHelper . invokeMethod ( extension , method . getName ( ) , args ) ; }
invokes a method for the groovyresultset . this will try to invoke the given method first on the extension and then on the result set given as proxy parameter .
