|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.media.jai.RenderableImageAdapter
An adapter class for externally-generated RenderableImages. All methods are simply forwarded to the image being adapted. The purpose of this class is simply to ensure that the PropertySource interface is available for all JAI RenderableImages.
The set of properties available on the image will be a combination of
those defined locally via setProperty()
and those defined
on the source image with the local properties taking precedence. No
PropertySourceChangeEvent
will be generated as a result of
changes to the property set of the source image.
Fields inherited from interface java.awt.image.renderable.RenderableImage |
HINTS_OBSERVED |
Constructor Summary | |
RenderableImageAdapter(RenderableImage im)
Constructs a RenderableImageAdapter from a RenderableImage. |
Method Summary | |
void |
addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list. |
void |
addPropertyChangeListener(String propertyName,
PropertyChangeListener listener)
Add a PropertyChangeListener for a specific property. |
RenderedImage |
createDefaultRendering()
Gets a RenderedImage instance of this image with a default width and height in pixels. |
RenderedImage |
createRendering(RenderContext renderContext)
Gets a RenderedImage instance of this image from a RenderContext. |
RenderedImage |
createScaledRendering(int w,
int h,
RenderingHints hints)
Gets a RenderedImage instance of this image with width w, and height h in pixels. |
float |
getHeight()
Gets the height in user coordinate space. |
float |
getMinX()
Gets the minimum X coordinate of the rendering-independent image. |
float |
getMinY()
Gets the minimum Y coordinate of the rendering-independent image. |
Object |
getProperty(String name)
Gets a property from the property set of this image. |
Class |
getPropertyClass(String name)
Returns the class expected to be returned by a request for the property with the specified name. |
String[] |
getPropertyNames()
Returns a list of the properties recognized by this image. |
String[] |
getPropertyNames(String prefix)
Returns an array of String s recognized as names by
this property source that begin with the supplied prefix. |
Vector |
getSources()
|
float |
getWidth()
Gets the width in user coordinate space. |
boolean |
isDynamic()
Returns true if successive renderings (that is, calls to createRendering() or createScaledRendering()) with the same arguments may produce different results. |
void |
removeProperty(String name)
Removes the named property from the RenderableImageAdapter . |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list. |
void |
removePropertyChangeListener(String propertyName,
PropertyChangeListener listener)
Remove a PropertyChangeListener for a specific property. |
void |
setProperty(String name,
Object value)
Sets a property on a RenderableImageAdapter . |
static RenderableImageAdapter |
wrapRenderableImage(RenderableImage im)
Adapts a RenderableImage into a RenderableImageAdapter. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public RenderableImageAdapter(RenderableImage im)
im
is null
.Method Detail |
public static RenderableImageAdapter wrapRenderableImage(RenderableImage im)
im
- a RenderableImage.im
is null
.public final Vector getSources()
public final Object getProperty(String name)
name
- the name of the property to get, as a String.name
is
null
.public Class getPropertyClass(String name)
null
will be returned.Class
expected to be return by a
request for the value of this property or null
.name
is
null
.public final String[] getPropertyNames()
null
will be
returned.String
s representing valid
property names.public String[] getPropertyNames(String prefix)
String
s recognized as names by
this property source that begin with the supplied prefix. If
no property names match, null
will be returned.
The comparison is done in a case-independent manner.String
s giving the valid
property names.prefix
is
null
.public void setProperty(String name, Object value)
RenderableImageAdapter
.name
- a String
containing the property's name.value
- the property, as a general Object
.name
or
value
is null
.public void removeProperty(String name)
RenderableImageAdapter
.name
is
null
.public void addPropertyChangeListener(PropertyChangeListener listener)
public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
public void removePropertyChangeListener(PropertyChangeListener listener)
public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)
public final float getWidth()
public final float getHeight()
public final float getMinX()
public final float getMinY()
public final boolean isDynamic()
public final RenderedImage createScaledRendering(int w, int h, RenderingHints hints)
w
- the width of rendered image in pixels.h
- the height of rendered image in pixels.hints
- a RenderingHints object containing rendering hints.public final RenderedImage createDefaultRendering()
public final RenderedImage createRendering(RenderContext renderContext)
renderContext
- the RenderContext to use to produce the rendering.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |