title: How can I call a subclass method using a superclass object?
body: <p>I'm having an issue with my code where I need to call a subclass method using a superclass object. Is there any possible way to do this or a work around? I'm completely stumped and there is no helpful answer for my issue.</p>
  
  <pre><code>    String basicCommand = commands[0];
      String advCommand = commands[1];
      String perCommand = commands[2];
      if (objectName.get(advCommand)instanceof Circle){
          objectName.get(advCommand);
          //.changeSize(reader.convertToInt(perCommand));
  </code></pre>
  
  <p><code>advcommand</code> is of type <code>Shape</code> which is a superclass of the class <code>Circle</code>, and the method <code>changesize()</code> is within <code>Circle</code>.</p>
  
  <p>*Data is within a hashmap.</p>