Tagpublic class ImageTag extends BaseTag
An ImageTag represents an image to be placed on the sheet.
 The rows and cols attributes, if specified,
 control how many Excel rows tall and columns wide the image is.  If not
 specified, the image is sized according to its natural dimensions.  The
 required pathname attribute is the name of the image file, to
 be loaded relative to the current working directory.  The optional
 type attribute gives the image type, which defaults to "png".
BaseTag.intintStringString
     | Modifier and Type | Field | Description | 
|---|---|---|
static java.lang.String | 
ATTR_COLS | 
 Attribute for specifying the number of columns wide the image will be. 
 | 
static java.lang.String | 
ATTR_PATHNAME | 
 Attribute for specifying the pathname of the image file, relative to the
 current working directory. 
 | 
static java.lang.String | 
ATTR_ROWS | 
 Attribute for specifying the number of rows tall the image will be. 
 | 
static java.lang.String | 
ATTR_TYPE | 
 Attribute for specifying the type of the image file. 
 | 
static java.lang.String | 
DEF_TYPE | 
 The default image type, "png". 
 | 
static java.lang.String | 
TYPE_DIB | 
 The type for a device independent image (or .bmp). 
 | 
static java.lang.String | 
TYPE_EMF | 
 The type for a Enhanced Windows Metafile image. 
 | 
static java.lang.String | 
TYPE_JPEG | 
 The type for a JPEG image. 
 | 
static java.lang.String | 
TYPE_PICT | 
 The type for a Mac PICT image. 
 | 
static java.lang.String | 
TYPE_PNG | 
 The type for a PNG image. 
 | 
static java.lang.String | 
TYPE_WMF | 
 The type for a Windows Metafile image. 
 | 
ATTR_ON_PROCESSED, SPEC_SEP| Constructor | Description | 
|---|---|
ImageTag() | 
| Modifier and Type | Method | Description | 
|---|---|---|
java.lang.String | 
getName() | 
 Returns this  
Tag's name. | 
java.util.List<java.lang.String> | 
getOptionalAttributes() | 
 Returns the  
List of optional attribute names. | 
java.util.List<java.lang.String> | 
getRequiredAttributes() | 
 Returns the  
List of required attribute names. | 
boolean | 
process() | 
 Loads the image data and scales it if necessary, with the top-left
 corner of the image at the top-left corner of this cell. 
 | 
void | 
validateAttributes() | 
 Validates the attributes for this  
Tag. | 
checkAttributes, clearBlock, deleteBlock, getAttributes, getContext, getLocation, getParentTag, getWorkbookContext, isBodiless, processTag, removeBlock, setAttributes, setBodiless, setContext, setParentTag, setWorkbookContextpublic static final java.lang.String ATTR_ROWS
rows nor cols is specified, then the
 image's dimensions will be preserved from the original image file.public static final java.lang.String ATTR_COLS
rows nor cols is specified, then the
 image's dimensions will be preserved from the original image file.public static final java.lang.String ATTR_PATHNAME
public static final java.lang.String ATTR_TYPE
public static final java.lang.String TYPE_DIB
public static final java.lang.String TYPE_EMF
public static final java.lang.String TYPE_JPEG
public static final java.lang.String TYPE_PICT
public static final java.lang.String TYPE_PNG
public static final java.lang.String TYPE_WMF
public static final java.lang.String DEF_TYPE
public java.lang.String getName()
Tag's name.Tag's name.public java.util.List<java.lang.String> getRequiredAttributes()
List of required attribute names.getRequiredAttributes in class BaseTagList of required attribute names.public java.util.List<java.lang.String> getOptionalAttributes()
List of optional attribute names.getOptionalAttributes in class BaseTagList of optional attribute names.public void validateAttributes()
                        throws TagParseException
Tag.  The "rows" and
 "cols" attributes, if present, must be positive integers.validateAttributes in class BaseTagTagParseException - If the attribute values are illegal or
    unacceptable.Copyright © 2012–2018 Jett Team. All rights reserved.