Package org.jivesoftware.openfire.vcard
Class PhotoResizer
- java.lang.Object
-
- org.jivesoftware.openfire.vcard.PhotoResizer
-
public class PhotoResizer extends Object
Image resizing utility methods.
-
-
Field Summary
Fields Modifier and Type Field Description static String
PROPERTY_RESIZE_ON_CREATE
static boolean
PROPERTY_RESIZE_ON_CREATE_DEFAULT
static String
PROPERTY_RESIZE_ON_LOAD
static boolean
PROPERTY_RESIZE_ON_LOAD_DEFAULT
static String
PROPERTY_TARGETDIMENSION
static int
PROPERTY_TARGETDIMENSION_DEFAULT
-
Constructor Summary
Constructors Constructor Description PhotoResizer()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static byte[]
cropAndShrink(byte[] bytes, int targetDimension, ImageWriter iw)
static void
resizeAvatar(org.dom4j.Element vCardElement)
-
-
-
Field Detail
-
PROPERTY_RESIZE_ON_LOAD
public static final String PROPERTY_RESIZE_ON_LOAD
- See Also:
- Constant Field Values
-
PROPERTY_RESIZE_ON_LOAD_DEFAULT
public static final boolean PROPERTY_RESIZE_ON_LOAD_DEFAULT
- See Also:
- Constant Field Values
-
PROPERTY_RESIZE_ON_CREATE
public static final String PROPERTY_RESIZE_ON_CREATE
- See Also:
- Constant Field Values
-
PROPERTY_RESIZE_ON_CREATE_DEFAULT
public static final boolean PROPERTY_RESIZE_ON_CREATE_DEFAULT
- See Also:
- Constant Field Values
-
PROPERTY_TARGETDIMENSION
public static final String PROPERTY_TARGETDIMENSION
- See Also:
- Constant Field Values
-
PROPERTY_TARGETDIMENSION_DEFAULT
public static final int PROPERTY_TARGETDIMENSION_DEFAULT
- See Also:
- Constant Field Values
-
-
Method Detail
-
resizeAvatar
public static void resizeAvatar(org.dom4j.Element vCardElement)
-
cropAndShrink
public static byte[] cropAndShrink(byte[] bytes, int targetDimension, ImageWriter iw)
-
-