title: How do I use the constructor to set an object to an existing object?
body: <p>Here is the problem I want to use a constructor that will simplify image loading process. All you neeed to do is specifty a file path.  </p>
  
  <p>Would it be possible to do this via inheritance or do i need to create a new buffered image object? 
  here is the idea for the code to make it easier to understand. </p>
  
  <pre><code>public class specialImage extends BufferedImage { 
  
      specialImage(String path) {
      super();
      this =  ImageIO.read(new File(Path)); // &lt;--- how can i Do this in java. 
      }
   }
  </code></pre>
  
  <p><em>OR SHOULD I DO THE FOLLOWING</em></p>
  
  <pre><code> class specialImage{
  
      BufferedImage manipulator;
  
      specialImage (String path) {
         manpiulator = ImageIO.read(new File(path));
      }
    }
  </code></pre>
  
  <p><strong>------------------------EDIT 1:-------------------------</strong>
   I am trying to avoid returning. I want to create a series of functions that will manipulate the specialImage class. like </p>
  
  <pre><code>specialImage objectName = new specialImage(FILE_PATH);
  objectName.toGrayscale();
  objectName.specialTransformation();
  //While still using the BufferedImage class, i.e.,
  objectName.getRaster(); 
  </code></pre>