title: Can't Access Protected Method of Instantiated Class
body: <p>I am trying to access this protected class: <code>protected boolean canDraw()</code>, and get its value placed into a variable.  Two ways I'm trying to access it are not working:</p>
  
  <pre><code>    &lt;%@ page import="com.day.cq.wcm.foundation.Image" %&gt;
      &lt;%@include file="/apps/tju/global.jsp"%&gt;
      &lt;% //..... 
         Image thisImage = new Image(resource); %&gt;
  </code></pre>
  
  <p><code>boolean foo = thisImage.canDraw();</code> throws <strong>The method canDraw() from the type Image is not visible</strong></p>
  
  <p>and</p>
  
  <p><code>boolean foo = super.canDraw();</code> throws <strong>The method canDraw() is undefined for the type HttpJspBase</strong></p>
  
  <p>Full javadoc of the class being used can be found here: <a href="http://dev.day.com/docs/en/cq/5-3/javadoc/com/day/cq/wcm/foundation/Image.html" rel="nofollow">http://dev.day.com/docs/en/cq/5-3/javadoc/com/day/cq/wcm/foundation/Image.html</a></p>