org.kohsuke.youdebug
Class JDICategory

java.lang.Object
  extended by org.kohsuke.youdebug.JDICategory
All Implemented Interfaces:
groovy.lang.GroovyObject

public class JDICategory
extends Object
implements groovy.lang.GroovyObject

Method augmentation on top of JDI for Groovy

Author:
Kohsuke Kawaguchi

Constructor Summary
JDICategory()
           
 
Method Summary
static Set allInterfaces(com.sun.jdi.InterfaceType it)
           
static void delete(com.sun.jdi.request.EventRequest req)
          Deletes this event request.
static void dumpStackTrace(com.sun.jdi.ObjectReference exp, Object out)
          Dumps the stack trace of an exception.
static void dumpThread(com.sun.jdi.ThreadReference tr, Object out)
          Dumps the current thread stack
static com.sun.jdi.Value getAt(com.sun.jdi.ArrayReference a, int index)
          Index access to array.
 groovy.lang.MetaClass getMetaClass()
           
 Object getProperty(String name)
           
static String getStatusMessage(com.sun.jdi.ThreadReference tr)
           
 Object invokeMethod(String name, Object args)
           
static boolean isAssignableFrom(com.sun.jdi.Type type, com.sun.jdi.Type subtype)
          Is the given value an instance of the given type?
static Object methodMissing(com.sun.jdi.ClassType c, String name, Object args)
          Static method invocation from ClassType.
static Object methodMissing(com.sun.jdi.ObjectReference ref, String name, Object args)
          Allow method invocation directly on the ObjectReference instance.
static Object propertyMissing(com.sun.jdi.ClassType c, String name)
          Static field retrieval.
static void propertyMissing(com.sun.jdi.ClassType c, String name, Object value)
          Static field assignment.
static Object propertyMissing(com.sun.jdi.ObjectReference ref, String name)
          Instance field retrieval.
static void propertyMissing(com.sun.jdi.ObjectReference ref, String name, Object value)
          Instance field assignment.
static Object propertyMissing(com.sun.jdi.StackFrame frame, String name)
          Read variables visible from the stack frame
static void propertyMissing(com.sun.jdi.StackFrame frame, String name, Object value)
          Set variables visible from the stack trace
 void setMetaClass(groovy.lang.MetaClass metaClass)
           
 void setProperty(String name, Object value)
           
static String toString(com.sun.jdi.ObjectReference ref)
          Override the default behavior of Mirror.toString() and instead call the remote Object.toString() method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDICategory

public JDICategory()
Method Detail

delete

public static void delete(com.sun.jdi.request.EventRequest req)
Deletes this event request.


getAt

public static com.sun.jdi.Value getAt(com.sun.jdi.ArrayReference a,
                                      int index)
Index access to array.


dumpStackTrace

public static void dumpStackTrace(com.sun.jdi.ObjectReference exp,
                                  Object out)
Dumps the stack trace of an exception.

Parameters:
out - Either PrintWriter or PrintStream.

methodMissing

public static Object methodMissing(com.sun.jdi.ObjectReference ref,
                                   String name,
                                   Object args)
                            throws com.sun.jdi.InvocationException,
                                   com.sun.jdi.InvalidTypeException,
                                   com.sun.jdi.ClassNotLoadedException,
                                   com.sun.jdi.IncompatibleThreadStateException
Allow method invocation directly on the ObjectReference instance.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

propertyMissing

public static Object propertyMissing(com.sun.jdi.ObjectReference ref,
                                     String name)
                              throws com.sun.jdi.InvocationException,
                                     com.sun.jdi.InvalidTypeException,
                                     com.sun.jdi.ClassNotLoadedException,
                                     com.sun.jdi.IncompatibleThreadStateException
Instance field retrieval.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

propertyMissing

public static void propertyMissing(com.sun.jdi.ObjectReference ref,
                                   String name,
                                   Object value)
                            throws com.sun.jdi.InvocationException,
                                   com.sun.jdi.InvalidTypeException,
                                   com.sun.jdi.ClassNotLoadedException,
                                   com.sun.jdi.IncompatibleThreadStateException
Instance field assignment.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

isAssignableFrom

public static boolean isAssignableFrom(com.sun.jdi.Type type,
                                       com.sun.jdi.Type subtype)
                                throws com.sun.jdi.ClassNotLoadedException
Is the given value an instance of the given type?

Throws:
com.sun.jdi.ClassNotLoadedException

allInterfaces

public static Set allInterfaces(com.sun.jdi.InterfaceType it)

propertyMissing

public static Object propertyMissing(com.sun.jdi.StackFrame frame,
                                     String name)
Read variables visible from the stack frame


propertyMissing

public static void propertyMissing(com.sun.jdi.StackFrame frame,
                                   String name,
                                   Object value)
Set variables visible from the stack trace


methodMissing

public static Object methodMissing(com.sun.jdi.ClassType c,
                                   String name,
                                   Object args)
                            throws com.sun.jdi.InvocationException,
                                   com.sun.jdi.InvalidTypeException,
                                   com.sun.jdi.ClassNotLoadedException,
                                   com.sun.jdi.IncompatibleThreadStateException
Static method invocation from ClassType.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

propertyMissing

public static Object propertyMissing(com.sun.jdi.ClassType c,
                                     String name)
                              throws com.sun.jdi.InvocationException,
                                     com.sun.jdi.InvalidTypeException,
                                     com.sun.jdi.ClassNotLoadedException,
                                     com.sun.jdi.IncompatibleThreadStateException
Static field retrieval.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

propertyMissing

public static void propertyMissing(com.sun.jdi.ClassType c,
                                   String name,
                                   Object value)
                            throws com.sun.jdi.InvocationException,
                                   com.sun.jdi.InvalidTypeException,
                                   com.sun.jdi.ClassNotLoadedException,
                                   com.sun.jdi.IncompatibleThreadStateException
Static field assignment.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

toString

public static String toString(com.sun.jdi.ObjectReference ref)
                       throws com.sun.jdi.InvocationException,
                              com.sun.jdi.InvalidTypeException,
                              com.sun.jdi.ClassNotLoadedException,
                              com.sun.jdi.IncompatibleThreadStateException
Override the default behavior of Mirror.toString() and instead call the remote Object.toString() method.

Throws:
com.sun.jdi.InvocationException
com.sun.jdi.InvalidTypeException
com.sun.jdi.ClassNotLoadedException
com.sun.jdi.IncompatibleThreadStateException

getStatusMessage

public static String getStatusMessage(com.sun.jdi.ThreadReference tr)

dumpThread

public static void dumpThread(com.sun.jdi.ThreadReference tr,
                              Object out)
                       throws com.sun.jdi.IncompatibleThreadStateException
Dumps the current thread stack

Throws:
com.sun.jdi.IncompatibleThreadStateException

getMetaClass

public groovy.lang.MetaClass getMetaClass()
Specified by:
getMetaClass in interface groovy.lang.GroovyObject

setMetaClass

public void setMetaClass(groovy.lang.MetaClass metaClass)
Specified by:
setMetaClass in interface groovy.lang.GroovyObject

invokeMethod

public Object invokeMethod(String name,
                           Object args)
Specified by:
invokeMethod in interface groovy.lang.GroovyObject

getProperty

public Object getProperty(String name)
Specified by:
getProperty in interface groovy.lang.GroovyObject

setProperty

public void setProperty(String name,
                        Object value)
Specified by:
setProperty in interface groovy.lang.GroovyObject


Copyright © 2013. All rights reserved.