Cytoscape 2.8.0 API

cytoscape.render.export
Class ImageImposter

java.lang.Object
  extended by java.awt.Image
      extended by cytoscape.render.export.ImageImposter

public final class ImageImposter
extends Image

The primary purpose of this class is to enable an arbitrary Graphics object to receive rendering calls from a cytoscape.render.immed.GraphGraphics instance. This, in turn, can be used to render a graph directly to a scalar vector graphic.


Field Summary
 
Fields inherited from class java.awt.Image
accelerationPriority, SCALE_AREA_AVERAGING, SCALE_DEFAULT, SCALE_FAST, SCALE_REPLICATE, SCALE_SMOOTH, UndefinedProperty
 
Constructor Summary
ImageImposter(Graphics graphics, int width, int height)
          The Graphics object that is passed into this constructor is not modified in any way, ever.
 
Method Summary
 void flush()
          This is a no-op.
 Graphics getGraphics()
          Returns a copy of the Graphics object that was passed into the constructor.
 int getHeight(ImageObserver observer)
          Simply returns the height that was passed into the constructor.
 Object getProperty(String name, ImageObserver observer)
          No properties are defined on this image, ever; this returns UndefinedProperty, always.
 ImageProducer getSource()
          This method simply throws an UnsupportedOperationException.
 int getWidth(ImageObserver observer)
          Simply returns the width that was passed into the constructor.
 
Methods inherited from class java.awt.Image
getAccelerationPriority, getCapabilities, getScaledInstance, setAccelerationPriority
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ImageImposter

public ImageImposter(Graphics graphics,
                     int width,
                     int height)
The Graphics object that is passed into this constructor is not modified in any way, ever. The only direct calls made on this object are graphics.create(), which is used in the getGraphics() method of this class.

Method Detail

getWidth

public final int getWidth(ImageObserver observer)
Simply returns the width that was passed into the constructor.

Specified by:
getWidth in class Image

getHeight

public final int getHeight(ImageObserver observer)
Simply returns the height that was passed into the constructor.

Specified by:
getHeight in class Image

getSource

public final ImageProducer getSource()
This method simply throws an UnsupportedOperationException.

Specified by:
getSource in class Image

getGraphics

public final Graphics getGraphics()
Returns a copy of the Graphics object that was passed into the constructor. The exact value returned is graphics.create() where graphics is the Graphics object passed to the constructor.

Specified by:
getGraphics in class Image

getProperty

public final Object getProperty(String name,
                                ImageObserver observer)
No properties are defined on this image, ever; this returns UndefinedProperty, always.

Specified by:
getProperty in class Image

flush

public final void flush()
This is a no-op.

Overrides:
flush in class Image

Cytoscape 2.8.0 API

Copyright 2010 Cytoscape Consortium. All rights reserved.