sk.uniba.euromath.gene.image
Class BufferedImageRef

java.lang.Object
  extended by sk.uniba.euromath.gene.image.BufferedImageRef
All Implemented Interfaces:
ImageRef

public final class BufferedImageRef
extends Object
implements ImageRef

Represents a buffered image.

Author:
Martin Vysny

Field Summary
 String id
          A temporary solution to transfer ID of source.
 
Constructor Summary
BufferedImageRef(BufferedImage image)
          Creates instance of object.
 
Method Summary
 Graphics2D asGraphics()
          Returns the graphics aspect of the image.
 Image asImage()
          Returns the Image aspect of the image.
 RenderedImage asRenderedImage()
          Returns the RenderedImage aspect of the image.
 void dispose()
          Disposes of the image.
 String getId()
          A temporary solution to transfer ID of source.
 void setId(String id)
          A temporary solution to transfer ID of source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

id

public String id
A temporary solution to transfer ID of source. Returns ID of root node R: all nodes that are rendered in this image are descendants or same nodes as R.

Constructor Detail

BufferedImageRef

public BufferedImageRef(BufferedImage image)
Creates instance of object.

Parameters:
image - the buffered image that shall be represented.
Method Detail

asGraphics

public Graphics2D asGraphics()
Description copied from interface: ImageRef
Returns the graphics aspect of the image. It must never be null.

Specified by:
asGraphics in interface ImageRef
Returns:
Graphics instance.

asImage

public Image asImage()
Description copied from interface: ImageRef
Returns the Image aspect of the image. May be null.

Specified by:
asImage in interface ImageRef
Returns:
Image instance.

asRenderedImage

public RenderedImage asRenderedImage()
Description copied from interface: ImageRef
Returns the RenderedImage aspect of the image. May be null.

Specified by:
asRenderedImage in interface ImageRef
Returns:
RenderedImage instance.

dispose

public void dispose()
Description copied from interface: ImageRef
Disposes of the image. The image must not be used after deleting.

Specified by:
dispose in interface ImageRef

getId

public String getId()
Description copied from interface: ImageRef
A temporary solution to transfer ID of source. Returns ID of root node R: all nodes that are rendered in this image are descendants or same nodes as R.

Specified by:
getId in interface ImageRef
Returns:
ID of root node.

setId

public void setId(String id)
Description copied from interface: ImageRef
A temporary solution to transfer ID of source. Sets ID of root node R: all nodes that are rendered in this image are descendants or same nodes as R.

Specified by:
setId in interface ImageRef
Parameters:
id - the id of root node.


Copyright 2003-2003-2006 null. All Rights Reserved.