Java in a Nutshell

Previous Chapter 18
The java.awt Package
Next
 

18.32 java.awt.Image (JDK 1.0)

This abstract class represents a displayable image in a platform-independent way. An Image object may not be instantiated directly through a constructor; it must be obtained through a call like Applet.getImage() or Component.createImage(). getSource() method returns the ImageProducer object that produces the image data. getGraphics() returns a Graphics object that can be used for drawing into offscreen images (but not images that are downloaded or generated by an ImageProducer).

public abstract class Image extends Object {
    // Default Constructor: public Image()
    // Constants
        1.1  public static final int SCALE_AREA_AVERAGING;
        1.1  public static final int SCALE_DEFAULT;
        1.1  public static final int SCALE_FAST;
        1.1  public static final int SCALE_REPLICATE;
        1.1  public static final int SCALE_SMOOTH;
            public static final Object UndefinedProperty;
    // Public Instance Methods
            public abstract void flush();
            public abstract Graphics getGraphics();
            public abstract int getHeight(ImageObserver observer);
            public abstract Object getProperty(String name, ImageObserver observer);
        1.1  public Image getScaledInstance(int width, int height, int hints);
            public abstract ImageProducer getSource();
            public abstract int getWidth(ImageObserver observer);
}

Passed To:

Component.checkImage(), Component.imageUpdate(), Component.prepareImage(), ComponentPeer.checkImage(), ComponentPeer.prepareImage(), Frame.setIconImage(), FramePeer.setIconImage(), Graphics.drawImage(), ImageObserver.imageUpdate(), MediaTracker.addImage(), MediaTracker.removeImage(), PixelGrabber(), Toolkit.checkImage(), Toolkit.prepareImage()

Returned By:

Applet.getImage(), AppletContext.getImage(), BeanInfo.getIcon(), Component.createImage(), ComponentPeer.createImage(), Frame.getIconImage(), Image.getScaledInstance(), SimpleBeanInfo.getIcon(), SimpleBeanInfo.loadImage(), Toolkit.createImage(), Toolkit.getImage()


Previous Home Next
java.awt.IllegalComponentStateException (JDK 1.1) Book Index java.awt.Insets (JDK 1.0)

Java in a Nutshell Java Language Reference Java AWT Java Fundamental Classes Exploring Java
This HTML Help has been published using the chm2web software.