|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.vinculumtech.carrierwave.image.ImageHelper
The ImageHelper class provides a set of utilities to manipulate Image
instances. Specifically
it should be used to access protected members of the Image class for testing, or for accessing
meta-data on a particular Image subclass.
Constructor Summary | |
ImageHelper()
|
Method Summary | |
static java.lang.Object |
buildArray(java.lang.Class imageClass,
java.lang.String fieldName,
java.lang.Class componentType)
Used by all Image subtypes to initialize meta-info arrays. |
static Image |
clone(Image image)
Convenience method for cloning images without catching the exceptions. |
static java.util.List |
cloneContainer(Image parent,
java.util.List objects)
Used by Image subclasses to clone container instances. |
static java.util.Map |
cloneContainer(Image parent,
java.util.Map objects)
Used by Image subclasses to clone container instances. |
static java.util.List |
cloneContainer(java.util.List objects)
Used by Image subclasses to clone container instances. |
static java.util.Map |
cloneContainer(java.util.Map objects)
Used by Image subclasses to clone container instances. |
static Image |
copyImage(Image originalImage,
boolean keepImageableIdentity)
Returns a clone of the given Image instance. The given Image instance is given a new identity unless keepIdenity
is true. |
static Image |
copyImage(Image originalImage,
boolean keepImageableIdentity,
boolean keepImageIdentity)
Returns a clone of the given Image instance. Image instances have Imageable identity if they are reflected (via a 'select') from a remote Imageable instance. |
static Image |
copyLiterals(Image originalImage)
Copies the given image. |
static int |
countParents(Icon icon)
|
static int |
countParents(Image image)
|
static int |
findIndexOf(Image image,
java.lang.String edgeName)
|
static boolean[] |
getDependentEdgesFrom(java.lang.Class imageType)
|
static boolean[] |
getDependentEdgesFrom(java.lang.String imageType)
|
static java.lang.String[] |
getEdgeImageTypesFrom(java.lang.Class imageType)
|
static java.lang.String[] |
getEdgeImageTypesFrom(java.lang.String imageType)
|
static java.lang.String[] |
getEdgesFrom(java.lang.Class imageType)
|
static java.lang.String[] |
getEdgesFrom(java.lang.String imageType)
|
static java.lang.String[] |
getEdgeTypesFrom(java.lang.Class imageType)
|
static java.lang.String[] |
getEdgeTypesFrom(java.lang.String imageType)
|
static java.lang.String |
getImageableTypeFrom(java.lang.Class imageType)
|
static java.lang.String |
getImageableTypeFrom(java.lang.String imageType)
|
static java.lang.String |
getImageInterfaceTypeFrom(java.lang.Class imageType)
|
static java.lang.String |
getImageInterfaceTypeFrom(java.lang.String imageType)
|
static java.lang.String[] |
getLiteralsFrom(java.lang.Class imageType)
|
static java.lang.String[] |
getLiteralsFrom(java.lang.String imageType)
|
static java.lang.String[] |
getLiteralTypesFrom(java.lang.Class imageType)
|
static java.lang.String[] |
getLiteralTypesFrom(java.lang.String imageType)
|
static boolean[] |
getReadOnlyEdgesFrom(java.lang.Class imageType)
|
static boolean[] |
getReadOnlyEdgesFrom(java.lang.String imageType)
|
static boolean[] |
getReadOnlyLiteralsFrom(java.lang.Class imageType)
|
static boolean[] |
getReadOnlyLiteralsFrom(java.lang.String imageType)
|
static boolean[] |
getReferenceOnlyEdgesFrom(java.lang.Class imageType)
|
static boolean[] |
getReferenceOnlyEdgesFrom(java.lang.String imageType)
|
static Icon |
iconOf(java.lang.Object object)
Returns the given object as an Icon. |
static boolean |
isDependentImage(java.lang.Class imageType)
|
static boolean |
isDependentImage(java.lang.String imageType)
|
static void |
setIconOn(Image image,
Icon icon)
setIcon is not public on image to prevent certain classes of errors, but there are cases where it is necessary or helpful. |
static void |
setIsDirtyOn(Image image,
boolean isDirty)
setIsDirtyOn is not public on image to prevent certain classes of errors, but there are cases where it is necessary or helpful. |
static void |
setIsReflectionOn(Image image,
boolean isReflection)
setIsReflection is not public on image to prevent certain classes of errors, but there are cases where it is necessary or helpful. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ImageHelper()
Method Detail |
public static final void setIconOn(Image image, Icon icon)
public static final void setIsReflectionOn(Image image, boolean isReflection)
public static final void setIsDirtyOn(Image image, boolean isDirty)
public static final Icon iconOf(java.lang.Object object)
public static final Image copyLiterals(Image originalImage)
public static final Image clone(Image image)
image
-
public static final int countParents(Image image)
image
-
public static final int countParents(Icon icon)
icon
-
public static final java.lang.Object buildArray(java.lang.Class imageClass, java.lang.String fieldName, java.lang.Class componentType)
imageClass
- fieldName
- componentType
-
public static final java.util.Map cloneContainer(java.util.Map objects)
objects
-
public static final java.util.List cloneContainer(java.util.List objects)
objects
-
public static final java.util.Map cloneContainer(Image parent, java.util.Map objects)
parent
- objects
-
public static final java.util.List cloneContainer(Image parent, java.util.List objects)
parent
- objects
-
public static final boolean isDependentImage(java.lang.String imageType)
public static final boolean isDependentImage(java.lang.Class imageType)
public static final java.lang.String getImageableTypeFrom(java.lang.String imageType)
public static final java.lang.String getImageableTypeFrom(java.lang.Class imageType)
public static final java.lang.String getImageInterfaceTypeFrom(java.lang.String imageType)
public static final java.lang.String getImageInterfaceTypeFrom(java.lang.Class imageType)
public static final java.lang.String[] getEdgesFrom(java.lang.String imageType)
public static final java.lang.String[] getEdgesFrom(java.lang.Class imageType)
public static final java.lang.String[] getLiteralsFrom(java.lang.String imageType)
public static final java.lang.String[] getLiteralsFrom(java.lang.Class imageType)
public static final java.lang.String[] getLiteralTypesFrom(java.lang.String imageType)
public static final java.lang.String[] getLiteralTypesFrom(java.lang.Class imageType)
public static final boolean[] getReadOnlyLiteralsFrom(java.lang.String imageType)
public static final boolean[] getReadOnlyLiteralsFrom(java.lang.Class imageType)
public static final java.lang.String[] getEdgeTypesFrom(java.lang.String imageType)
public static final java.lang.String[] getEdgeTypesFrom(java.lang.Class imageType)
public static final java.lang.String[] getEdgeImageTypesFrom(java.lang.String imageType)
public static final java.lang.String[] getEdgeImageTypesFrom(java.lang.Class imageType)
public static final boolean[] getReadOnlyEdgesFrom(java.lang.String imageType)
public static final boolean[] getReadOnlyEdgesFrom(java.lang.Class imageType)
public static final boolean[] getDependentEdgesFrom(java.lang.String imageType)
public static final boolean[] getDependentEdgesFrom(java.lang.Class imageType)
public static final boolean[] getReferenceOnlyEdgesFrom(java.lang.String imageType)
public static final boolean[] getReferenceOnlyEdgesFrom(java.lang.Class imageType)
public static final int findIndexOf(Image image, java.lang.String edgeName)
public static final Image copyImage(Image originalImage, boolean keepImageableIdentity)
keepIdenity
is true.
originalImage
- keepImageableIdentity
- false if resulting Image instance should have a new identity
public static final Image copyImage(Image originalImage, boolean keepImageableIdentity, boolean keepImageIdentity)
originalImage
- keepImageableIdentity
- false if resulting Image instance should lose its Imageable identitykeepImageIdentity
- false if resulting Image instance should have lose its local identity
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |