Object type to Reader type?
<p>I have a java.io.Reader as the return type of my method. But i have Object type of an instance which i get from Database. So how can I convert this to Reader type and return?</p>

<p>I have the following code where getByteArrayObject() return a byte array. and the same i need to return, but the return type is Reader which i cant change.</p>

<pre><code> public Reader getMediaReader(String arg0) {
    // TODO Auto-generated method stub
    Object obj  = getByteArrayObject();
    System.out.println("HELLO I AM DETCTED....... in getMediaReader");
    return null;
    }
</code></pre>

<p>need help
thanks.</p>
