|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.rim.device.api.ui.image.ImageFactory
public class ImageFactory
A factory class for creating different types of images. See Image
for more details:
Method Summary | ||
---|---|---|
static Image |
createImage(String name)
Creates an image from provided bitmap name resource. |
|
static Image |
createImage(String module,
String name)
Creates an image from provided bitmap named resource found in module. |
|
static Image |
createImage(Bitmap bitmap)
Create an Image object for the provided Bitmap . |
|
static Image |
createImage(EncodedImage encodedImage)
Construct an Image object for the provided EncodedImage . |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static Image createImage(Bitmap bitmap)
Bitmap
.
bitmap
- Bitmap object to abstract.
IllegalArgumentException
- if bitmap
is null
.public static Image createImage(EncodedImage encodedImage)
EncodedImage
.
encodedImage
- EncodedImage object to abstract.
IllegalArgumentException
- if encodedImage
is null
.public static Image createImage(String module, String name)
This method looks for the resource in both the .cod file that called this method and any .cod files that it relies on. The resource files are automatically generated by the compiler when a new graphic (PNG, GIF, or, JPG) is added to a project.
module
- Name of the module containing the bitmap resource. If
not specified, the name of the calling module is used.name
- Name of the bitmap resource.
NullPointerException
- If the name parameter is null.
IllegalArgumentException
- if resource with name parameter can not be found.public static Image createImage(String name)
This method looks for the resource in both the .cod file that called this method and any .cod files that it relies on. The resource files are automatically generated by the compiler when a new graphic (PNG, GIF, or, JPG) is added to a project.
name
- Name of the bitmap resource.
NullPointerException
- If the name parameter is null.
IllegalArgumentException
- if resource with name parameter can not be found.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal