nextapp.echo
Class ResourceImageReference

java.lang.Object
  extended by nextapp.echo.ResourceImageReference
All Implemented Interfaces:
java.io.Serializable, ImageReference

public class ResourceImageReference
extends java.lang.Object
implements ImageReference, java.io.Serializable

A reference to an image that can be retrieved as a resource.

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface nextapp.echo.ImageReference
SIZE_UNKNOWN
 
Constructor Summary
ResourceImageReference(java.lang.String resourceName)
          Creates a resource image reference retrieved from the provided resource name.
ResourceImageReference(java.lang.String resourceName, int width, int height)
          Creates a resource image reference retrieved from the provided resource name with the specified width and height.
ResourceImageReference(java.lang.String resourceName, java.lang.String contentType)
          Creates a resource image reference retrieved from the provided resource name with the specified content type.
ResourceImageReference(java.lang.String resourceName, java.lang.String contentType, int width, int height)
          Creates a resource image reference retrieved from the provided resource name with the specified content type, width and height.
 
Method Summary
 void addImageUpdateListener(ImageUpdateListener l)
          Not supported.
 java.lang.String getContentType()
           
 int getHeight()
          Returns the height of the image.
 int getWidth()
          Returns the width of the image.
 void removeImageUpdateListener(ImageUpdateListener l)
          Not supported.
 void render(java.io.OutputStream out)
           
 void update()
          Not supported.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResourceImageReference

public ResourceImageReference(java.lang.String resourceName)
Creates a resource image reference retrieved from the provided resource name. The content type of the image will be determined based on the extension of the specified resource name.


ResourceImageReference

public ResourceImageReference(java.lang.String resourceName,
                              java.lang.String contentType)
Creates a resource image reference retrieved from the provided resource name with the specified content type.


ResourceImageReference

public ResourceImageReference(java.lang.String resourceName,
                              int width,
                              int height)
Creates a resource image reference retrieved from the provided resource name with the specified width and height. The content type of the image will be determined based on the extension of the specified resource name.


ResourceImageReference

public ResourceImageReference(java.lang.String resourceName,
                              java.lang.String contentType,
                              int width,
                              int height)
Creates a resource image reference retrieved from the provided resource name with the specified content type, width and height.

Method Detail

addImageUpdateListener

public void addImageUpdateListener(ImageUpdateListener l)
Not supported.

Specified by:
addImageUpdateListener in interface ImageReference
Parameters:
l - The ImageUpdateListener to add.
See Also:
ImageReference.addImageUpdateListener(ImageUpdateListener)

getContentType

public java.lang.String getContentType()
See Also:
StreamImageReference.getContentType()

getHeight

public int getHeight()
Description copied from interface: ImageReference
Returns the height of the image. If the height is not known, SIZE_UNKNOWN should be returned.

Specified by:
getHeight in interface ImageReference
Returns:
The height of the image in pixels.
See Also:
ImageReference.getHeight()

getWidth

public int getWidth()
Description copied from interface: ImageReference
Returns the width of the image. If the width is not known, SIZE_UNKNOWN should be returned.

Specified by:
getWidth in interface ImageReference
Returns:
The width of the image in pixels.
See Also:
ImageReference.getWidth()

removeImageUpdateListener

public void removeImageUpdateListener(ImageUpdateListener l)
Not supported.

Specified by:
removeImageUpdateListener in interface ImageReference
Parameters:
l - The ImageUpdateListener to remove.
See Also:
ImageReference.removeImageUpdateListener(ImageUpdateListener)

render

public void render(java.io.OutputStream out)
            throws java.io.IOException
Throws:
java.io.IOException
See Also:
StreamImageReference.render(OutputStream)

update

public void update()
Not supported.

Specified by:
update in interface ImageReference
See Also:
ImageReference.update()