< prev index next >

src/jdk.jdi/share/classes/com/sun/jdi/ObjectReference.java

Print this page
rev 60127 : 8249205: Remove unnecessary trademark symbols


 105      * requested values.
 106      * @return a Map of the requested {@link Field} objects with
 107      * their {@link Value}.
 108      * @throws java.lang.IllegalArgumentException if any field is not valid for
 109      * this object's class.
 110      */
 111     Map<Field,Value> getValues(List<? extends Field> fields);
 112 
 113     /**
 114      * Sets the value of a given instance or static field in this object.
 115      * The {@link Field} must be valid for this ObjectReference; that is,
 116      * it must be from the mirrored object's class or a superclass of that class.
 117      * If static, the field must not be final.
 118      * <p>
 119      * Object values must be assignment compatible with the field type
 120      * (This implies that the field type must be loaded through the
 121      * enclosing class's class loader). Primitive values must be
 122      * either assignment compatible with the field type or must be
 123      * convertible to the field type without loss of information.
 124      * See section 5.2 of
 125      * <cite>The Java&trade; Language Specification</cite>
 126      * for more information on assignment
 127      * compatibility.
 128      *
 129      * @param field the field containing the requested value
 130      * @param value the new value to assign
 131      * @throws java.lang.IllegalArgumentException if the field is not valid for
 132      * this object's class.
 133      * @throws InvalidTypeException if the value's type does not match
 134      * the field's type.
 135      * @throws ClassNotLoadedException if 'value' is not null, and the field
 136      * type has not yet been loaded through the appropriate class loader.
 137      * @throws VMCannotBeModifiedException if the VirtualMachine is read-only - see {@link VirtualMachine#canBeModified()}.
 138      */
 139     void setValue(Field field, Value value)
 140         throws InvalidTypeException, ClassNotLoadedException;
 141 
 142     /** Perform method invocation with only the invoking thread resumed */
 143     static final int INVOKE_SINGLE_THREADED = 0x1;
 144     /** Perform non-virtual method invocation */
 145     static final int INVOKE_NONVIRTUAL      = 0x2;


 167      * does not return until the invoked method returns in the target VM.
 168      * If the invoked method throws an exception, this method
 169      * will throw an {@link InvocationException} which contains
 170      * a mirror to the exception object thrown.
 171      * <p>
 172      * Object arguments must be assignment compatible with the argument type
 173      * (This implies that the argument type must be loaded through the
 174      * enclosing class's class loader). Primitive arguments must be
 175      * either assignment compatible with the argument type or must be
 176      * convertible to the argument type without loss of information.
 177      * If the method being called accepts a variable number of arguments,
 178      * then the last argument type is an array of some component type.
 179      * The argument in the matching position can be omitted, or can be null,
 180      * an array of the same component type, or an argument of the
 181      * component type followed by any number of other arguments of the same
 182      * type. If the argument is omitted, then a 0 length array of the
 183      * component type is passed.  The component type can be a primitive type.
 184      * Autoboxing is not supported.
 185      *
 186      * See section 5.2 of
 187      * <cite>The Java&trade; Language Specification</cite>
 188      * for more information on assignment compatibility.
 189      * <p>
 190      * By default, the method is invoked using dynamic lookup as
 191      * documented in section 15.12.4.4 of
 192      * <cite>The Java&trade; Language Specification</cite>
 193      * in particular, overriding based on the runtime type of the object
 194      * mirrored by this {@link ObjectReference} will occur. This
 195      * behavior can be changed by specifying the
 196      * {@link #INVOKE_NONVIRTUAL} bit flag in the <code>options</code>
 197      * argument. If this flag is set, the specified method is invoked
 198      * whether or not it is overridden for this object's runtime type.
 199      * The method, in this case, must have an implementation, either in a class
 200      * or an interface. This option is useful for performing method invocations
 201      * like those done with the <code>super</code> keyword in the Java programming
 202      * language.
 203      * <p>
 204      * By default, all threads in the target VM are resumed while
 205      * the method is being invoked if they were previously
 206      * suspended by an event or by {@link VirtualMachine#suspend} or
 207      * {@link ThreadReference#suspend}. This is done to prevent the deadlocks
 208      * that will occur if any of the threads own monitors
 209      * that will be needed by the invoked method.
 210      * Note, however, that this implicit resume acts exactly like
 211      * {@link ThreadReference#resume}, so if the thread's suspend
 212      * count is greater than 1, it will remain in a suspended state




 105      * requested values.
 106      * @return a Map of the requested {@link Field} objects with
 107      * their {@link Value}.
 108      * @throws java.lang.IllegalArgumentException if any field is not valid for
 109      * this object's class.
 110      */
 111     Map<Field,Value> getValues(List<? extends Field> fields);
 112 
 113     /**
 114      * Sets the value of a given instance or static field in this object.
 115      * The {@link Field} must be valid for this ObjectReference; that is,
 116      * it must be from the mirrored object's class or a superclass of that class.
 117      * If static, the field must not be final.
 118      * <p>
 119      * Object values must be assignment compatible with the field type
 120      * (This implies that the field type must be loaded through the
 121      * enclosing class's class loader). Primitive values must be
 122      * either assignment compatible with the field type or must be
 123      * convertible to the field type without loss of information.
 124      * See section 5.2 of
 125      * <cite>The Java Language Specification</cite>
 126      * for more information on assignment
 127      * compatibility.
 128      *
 129      * @param field the field containing the requested value
 130      * @param value the new value to assign
 131      * @throws java.lang.IllegalArgumentException if the field is not valid for
 132      * this object's class.
 133      * @throws InvalidTypeException if the value's type does not match
 134      * the field's type.
 135      * @throws ClassNotLoadedException if 'value' is not null, and the field
 136      * type has not yet been loaded through the appropriate class loader.
 137      * @throws VMCannotBeModifiedException if the VirtualMachine is read-only - see {@link VirtualMachine#canBeModified()}.
 138      */
 139     void setValue(Field field, Value value)
 140         throws InvalidTypeException, ClassNotLoadedException;
 141 
 142     /** Perform method invocation with only the invoking thread resumed */
 143     static final int INVOKE_SINGLE_THREADED = 0x1;
 144     /** Perform non-virtual method invocation */
 145     static final int INVOKE_NONVIRTUAL      = 0x2;


 167      * does not return until the invoked method returns in the target VM.
 168      * If the invoked method throws an exception, this method
 169      * will throw an {@link InvocationException} which contains
 170      * a mirror to the exception object thrown.
 171      * <p>
 172      * Object arguments must be assignment compatible with the argument type
 173      * (This implies that the argument type must be loaded through the
 174      * enclosing class's class loader). Primitive arguments must be
 175      * either assignment compatible with the argument type or must be
 176      * convertible to the argument type without loss of information.
 177      * If the method being called accepts a variable number of arguments,
 178      * then the last argument type is an array of some component type.
 179      * The argument in the matching position can be omitted, or can be null,
 180      * an array of the same component type, or an argument of the
 181      * component type followed by any number of other arguments of the same
 182      * type. If the argument is omitted, then a 0 length array of the
 183      * component type is passed.  The component type can be a primitive type.
 184      * Autoboxing is not supported.
 185      *
 186      * See section 5.2 of
 187      * <cite>The Java Language Specification</cite>
 188      * for more information on assignment compatibility.
 189      * <p>
 190      * By default, the method is invoked using dynamic lookup as
 191      * documented in section 15.12.4.4 of
 192      * <cite>The Java Language Specification</cite>
 193      * in particular, overriding based on the runtime type of the object
 194      * mirrored by this {@link ObjectReference} will occur. This
 195      * behavior can be changed by specifying the
 196      * {@link #INVOKE_NONVIRTUAL} bit flag in the <code>options</code>
 197      * argument. If this flag is set, the specified method is invoked
 198      * whether or not it is overridden for this object's runtime type.
 199      * The method, in this case, must have an implementation, either in a class
 200      * or an interface. This option is useful for performing method invocations
 201      * like those done with the <code>super</code> keyword in the Java programming
 202      * language.
 203      * <p>
 204      * By default, all threads in the target VM are resumed while
 205      * the method is being invoked if they were previously
 206      * suspended by an event or by {@link VirtualMachine#suspend} or
 207      * {@link ThreadReference#suspend}. This is done to prevent the deadlocks
 208      * that will occur if any of the threads own monitors
 209      * that will be needed by the invoked method.
 210      * Note, however, that this implicit resume acts exactly like
 211      * {@link ThreadReference#resume}, so if the thread's suspend
 212      * count is greater than 1, it will remain in a suspended state


< prev index next >