|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.seam.core.Image
@Name(value="org.jboss.seam.core.image") @Scope(value=CONVERSATION) @Install(precedence=0) @Intercept(value=NEVER) public class Image
Image manipulation and interrogation
Nested Class Summary | |
---|---|
static class |
Image.Type
|
Field Summary | |
---|---|
static int |
DEFAULT_IMAGE_TYPE
|
static int |
PNG_IMAGE_TYPE
|
Constructor Summary | |
---|---|
Image()
|
Method Summary | |
---|---|
Image |
adjustRatio(double desiredRatio,
double precision)
Alter the ratio of the output image without altering the ratio of the input by adding transparent strips. |
Image |
blur(int radius)
Blur the output image using a convolution |
BufferedImage |
getBufferedImage()
|
Image.Type |
getContentType()
The content type of the output image, by default DEFAULT_CONTENT_TYPE |
Integer |
getHeight()
The height of the image |
byte[] |
getImage()
Get the image as a byte[], any conversions having been applied. |
Double |
getRatio()
The aspect ratio of the image |
Integer |
getWidth()
The width of the image |
static Image |
instance()
|
Boolean |
isRatio(double ratio,
double precision)
Check whether the image is of a given ratio to within a given precision |
Image |
resize(int width,
int height)
Resize the image to the given width and height, changing the ratio if necessary |
Image |
scale(double factor)
Scale the image by the given factor |
Image |
scaleToHeight(int height)
Scale the image to the given height |
Image |
scaleToWidth(int width)
Scale the image to the given width |
void |
setBufferedImage(BufferedImage bufferedImage)
|
void |
setContentType(Image.Type contentType)
|
Image |
setInput(Object value)
Set the image. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int PNG_IMAGE_TYPE
public static final int DEFAULT_IMAGE_TYPE
Constructor Detail |
---|
public Image()
Method Detail |
---|
public Image setInput(Object value) throws IOException
value
-
IOException
public byte[] getImage() throws IOException
IOException
public Image.Type getContentType()
public void setContentType(Image.Type contentType)
public BufferedImage getBufferedImage()
public void setBufferedImage(BufferedImage bufferedImage)
public Double getRatio() throws IOException
IOException
public Boolean isRatio(double ratio, double precision) throws IOException
IOException
public Integer getWidth() throws IOException
IOException
public Integer getHeight() throws IOException
IOException
public Image adjustRatio(double desiredRatio, double precision) throws InterruptedException, IOException
InterruptedException
IOException
public Image blur(int radius) throws IOException
IOException
public Image scaleToWidth(int width) throws IOException
IOException
public Image scaleToHeight(int height) throws IOException
IOException
public Image scale(double factor) throws IOException
IOException
public Image resize(int width, int height)
public static Image instance()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |