i got this exception when i am using java reflection api
<p>i got this exception when i am using java reflection api</p>

<pre><code>java.lang.IllegalArgumentException
 at sun.reflect.UnsafeFieldAccessorImpl.ensureObj(UnsafeFieldAccessorImpl.java:37)
 at sun.reflect.UnsafeObjectFieldAccessorImpl.get(UnsafeObjectFieldAccessorImpl.java:18)
 at java.lang.reflect.Field.get(Field.java:357)
</code></pre>

<p>Code:</p>

<pre><code>    Field fieldlist[] = TestValue.class.getDeclaredFields();
    String result="";
    try {
        for (int i = 0; i &lt; fieldlist.length; i++) {
            Field fld = fieldlist[i];
            result += "name = " + fld.getName() + "\n";
            fld.setAccessible(true);
            result += "value = " + fld.get(this)+ "\n";
            System.out.println("Result-----&gt;"+result);
        }
    } catch (SecurityException e1) {
        // TODO Auto-generated catch block
        e1.printStackTrace();
    } catch (Exception e1) {
        // TODO Auto-generated catch block
        e1.printStackTrace();
    }
</code></pre>
