jeffhao | 5d1ac92 | 2011-09-29 17:41:15 -0700 | [diff] [blame] | 1 | Method name is myMethod |
| 2 | Declaring class is Target |
| 3 | Arg 0: int |
| 4 | Exc 0: java.lang.NullPointerException |
| 5 | Exc 1: java.io.IOException |
| 6 | Return type is int |
| 7 | Access flags are 0x1 |
| 8 | Method name is myMethod |
| 9 | Declaring class is SuperTarget |
| 10 | Arg 0: float |
| 11 | Return type is int |
| 12 | Access flags are 0x1 |
| 13 | Method name is myNoargMethod |
| 14 | Declaring class is Target |
| 15 | Return type is void |
| 16 | Access flags are 0x9 |
| 17 | Method name is myMethod |
| 18 | Declaring class is Target |
| 19 | Arg 0: [Ljava.lang.String; |
| 20 | Arg 1: float |
| 21 | Arg 2: char |
| 22 | Return type is int |
| 23 | Access flags are 0x1 |
| 24 | SuperTarget constructor ()V |
| 25 | Target constructor ()V |
| 26 | Before, float is 3.1415925 |
| 27 | myMethod: hi there 3.1415925 Q ! |
| 28 | Result of invoke: 7 |
| 29 | Calling no-arg void-return method |
| 30 | myNoargMethod ()V |
| 31 | throwingMethod |
| 32 | Invoke got expected exception: |
| 33 | java.lang.reflect.InvocationTargetException |
| 34 | java.lang.NullPointerException: gratuitous throw! |
| 35 | |
| 36 | Field name is string1 |
| 37 | Declaring class is Target |
| 38 | Field type is java.lang.String |
| 39 | Access flags are 0x1 |
| 40 | string1 value is 'hey' |
| 41 | ::: hey:yo:there |
| 42 | string1 value is now 'a new string' |
| 43 | ::: a new string:yo:there |
| 44 | got expected illegal obj store exc |
| 45 | got the other expected access exc |
| 46 | got expected arg exc |
| 47 | pubLong initial value is 1122334455667788 |
| 48 | pubLong new value is 9988776655443322 |
| 49 | Field name is superInt |
| 50 | Declaring class is SuperTarget |
| 51 | Field type is int |
| 52 | Access flags are 0x1 |
| 53 | superInt value is 1010101 |
| 54 | superInt boxed is 1010101 |
| 55 | superInt value is now 20202 |
| 56 | superInt value (from short) is now 30303 |
| 57 | superInt value is now 40404 |
| 58 | got expected long->int failure |
| 59 | got expected long->int failure |
| 60 | got expected string->int failure |
| 61 | got expected int->short failure |
| 62 | Field name is superClassInt |
| 63 | Declaring class is SuperTarget |
| 64 | Field type is int |
| 65 | Access flags are 0x9 |
| 66 | superClassInt value is 1010102 |
| 67 | Field name is staticDouble |
| 68 | Declaring class is Target |
| 69 | Field type is double |
| 70 | Access flags are 0x9 |
| 71 | staticDoubleVal value is 3.3 |
| 72 | got expected double->long failure |
| 73 | as expected: aPrivateInt not found |
| 74 | Field name is constantString |
| 75 | Declaring class is Target |
| 76 | Field type is java.lang.String |
| 77 | Access flags are 0x19 |
| 78 | Constant test value is a constant string |
| 79 | Field name is cantTouchThis |
| 80 | Declaring class is Target |
| 81 | Field type is int |
| 82 | Access flags are 0x11 |
| 83 | cantTouchThis is 77 |
Jeff Hao | 11d5d8f | 2014-03-26 15:08:20 -0700 | [diff] [blame] | 84 | as expected: set-final throws exception |
| 85 | cantTouchThis is still 77 |
Brian Carlstrom | ea46f95 | 2013-07-30 01:26:50 -0700 | [diff] [blame] | 86 | public final int Target.cantTouchThis accessible=false |
| 87 | public final int Target.cantTouchThis accessible=true |
Elliott Hughes | 582a7d1 | 2011-10-10 18:38:42 -0700 | [diff] [blame] | 88 | cantTouchThis is now 87 |
jeffhao | 5d1ac92 | 2011-09-29 17:41:15 -0700 | [diff] [blame] | 89 | cantTouchThis is now 88 |
| 90 | cons modifiers=1 |
| 91 | SuperTarget constructor ()V |
| 92 | Target constructor (IF)V : ii=7 ff=3.3333 |
| 93 | myMethod (I)I |
| 94 | arg=17 anInt=7 |
Jeff Hao | 63f5b9e | 2014-04-23 14:51:46 -0700 | [diff] [blame] | 95 | got expected exception for Class.newInstance |
| 96 | got expected exception for Constructor.newInstance |
jeffhao | 5d1ac92 | 2011-09-29 17:41:15 -0700 | [diff] [blame] | 97 | ReflectTest done! |
Elliott Hughes | 741b5b7 | 2012-01-31 19:18:51 -0800 | [diff] [blame] | 98 | public method |
Brian Carlstrom | ea46f95 | 2013-07-30 01:26:50 -0700 | [diff] [blame] | 99 | static java.lang.Object java.util.Collections.checkType(java.lang.Object,java.lang.Class) accessible=false |
| 100 | static java.lang.Object java.util.Collections.checkType(java.lang.Object,java.lang.Class) accessible=true |
jeffhao | 5d1ac92 | 2011-09-29 17:41:15 -0700 | [diff] [blame] | 101 | checkType invoking null |
| 102 | checkType got expected exception |
Elliott Hughes | 923e8b8 | 2012-03-23 11:44:07 -0700 | [diff] [blame] | 103 | calling const-class FieldNoisyInitUser.class |
| 104 | called const-class FieldNoisyInitUser.class |
| 105 | got fields |
| 106 | got field |
| 107 | FieldNoisyInitUser is initializing |
| 108 | read field value |
| 109 | FieldNoisyInit is initializing |
| 110 | |
| 111 | calling const-class MethodNoisyInitUser.class |
| 112 | called const-class MethodNoisyInitUser.class |
jeffhao | 5d1ac92 | 2011-09-29 17:41:15 -0700 | [diff] [blame] | 113 | got methods |
Elliott Hughes | 923e8b8 | 2012-03-23 11:44:07 -0700 | [diff] [blame] | 114 | got method |
| 115 | MethodNoisyInitUser is initializing |
| 116 | invoked method |
| 117 | MethodNoisyInit is initializing |
Elliott Hughes | 741b5b7 | 2012-01-31 19:18:51 -0800 | [diff] [blame] | 118 | |
| 119 | generic field: java.util.List<java.lang.String> |
| 120 | generic method fancyMethod params='[1] java.util.ArrayList<java.lang.String>' ret='java.util.Map<java.lang.Integer, java.lang.String>' |
| 121 | generic ctor Main params='[1] java.util.ArrayList<java.lang.Integer>' |
Brian Carlstrom | ea46f95 | 2013-07-30 01:26:50 -0700 | [diff] [blame] | 122 | fields are unique |
| 123 | fields are .equals |
| 124 | methods are unique |
| 125 | methods are .equals |