jxl.write
Class WritableCellFeatures

java.lang.Object
  extended byjxl.biff.BaseCellFeatures
      extended byjxl.CellFeatures
          extended byjxl.write.WritableCellFeatures

public class WritableCellFeatures
extends CellFeatures

Container for any additional cell features


Field Summary
static jxl.biff.BaseCellFeatures.ValidationCondition BETWEEN
           
static jxl.biff.BaseCellFeatures.ValidationCondition EQUAL
           
static jxl.biff.BaseCellFeatures.ValidationCondition GREATER_EQUAL
           
static jxl.biff.BaseCellFeatures.ValidationCondition GREATER_THAN
           
static jxl.biff.BaseCellFeatures.ValidationCondition LESS_EQUAL
           
static jxl.biff.BaseCellFeatures.ValidationCondition LESS_THAN
           
static jxl.biff.BaseCellFeatures.ValidationCondition NOT_BETWEEN
           
static jxl.biff.BaseCellFeatures.ValidationCondition NOT_EQUAL
           
 
Fields inherited from class jxl.biff.BaseCellFeatures
logger
 
Constructor Summary
WritableCellFeatures()
          Constructor
WritableCellFeatures(CellFeatures cf)
          Copy constructor
 
Method Summary
 void removeComment()
          Removes the cell comment, if present
 void removeDataValidation()
          Removes any data validation, if present
 void setComment(java.lang.String s)
          Sets the cell comment
 void setComment(java.lang.String s, double width, double height)
          Sets the cell comment and sets the size of the text box (in cells) in which the comment is displayed
 void setDataValidationList(java.util.Collection c)
          The list of items to validate for this cell.
 void setDataValidationRange(int col1, int row1, int col2, int row2)
          The list of items to validate for this cell in the form of a cell range.
 void setDataValidationRange(java.lang.String namedRange)
          Sets the data validation based upon a named range
 void setNumberValidation(double val, jxl.biff.BaseCellFeatures.ValidationCondition c)
          Sets the numeric value against which to validate
 void setNumberValidation(double val1, double val2, jxl.biff.BaseCellFeatures.ValidationCondition c)
          Sets the numeric range against which to validate the data
 
Methods inherited from class jxl.CellFeatures
getComment, getDataValidationList
 
Methods inherited from class jxl.biff.BaseCellFeatures
getCommentDrawing, getCommentHeight, getCommentWidth, getDVParser, hasDataValidation, hasDropDown, setComboBox, setCommentDrawing, setReadComment, setValidationSettings, setWritableCell
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BETWEEN

public static final jxl.biff.BaseCellFeatures.ValidationCondition BETWEEN

NOT_BETWEEN

public static final jxl.biff.BaseCellFeatures.ValidationCondition NOT_BETWEEN

EQUAL

public static final jxl.biff.BaseCellFeatures.ValidationCondition EQUAL

NOT_EQUAL

public static final jxl.biff.BaseCellFeatures.ValidationCondition NOT_EQUAL

GREATER_THAN

public static final jxl.biff.BaseCellFeatures.ValidationCondition GREATER_THAN

LESS_THAN

public static final jxl.biff.BaseCellFeatures.ValidationCondition LESS_THAN

GREATER_EQUAL

public static final jxl.biff.BaseCellFeatures.ValidationCondition GREATER_EQUAL

LESS_EQUAL

public static final jxl.biff.BaseCellFeatures.ValidationCondition LESS_EQUAL
Constructor Detail

WritableCellFeatures

public WritableCellFeatures()
Constructor


WritableCellFeatures

public WritableCellFeatures(CellFeatures cf)
Copy constructor

Parameters:
cf - the cell to copy
Method Detail

setComment

public void setComment(java.lang.String s)
Sets the cell comment

Parameters:
s - the comment

setComment

public void setComment(java.lang.String s,
                       double width,
                       double height)
Sets the cell comment and sets the size of the text box (in cells) in which the comment is displayed

Parameters:
s - the comment
width - the width of the comment box in cells
height - the height of the comment box in cells

removeComment

public void removeComment()
Removes the cell comment, if present


removeDataValidation

public void removeDataValidation()
Removes any data validation, if present


setDataValidationList

public void setDataValidationList(java.util.Collection c)
The list of items to validate for this cell. For each object in the collection, the toString() method will be called and the data entered will be validated against that string

Parameters:
c - the list of valid values

setDataValidationRange

public void setDataValidationRange(int col1,
                                   int row1,
                                   int col2,
                                   int row2)
The list of items to validate for this cell in the form of a cell range.

Parameters:
col1 - the first column containing the data to validate against
row1 - the first row containing the data to validate against
col2 - the second column containing the data to validate against
row2 - the second row containing the data to validate against

setDataValidationRange

public void setDataValidationRange(java.lang.String namedRange)
Sets the data validation based upon a named range

Parameters:
namedRange - the workbook named range defining the validation boundaries

setNumberValidation

public void setNumberValidation(double val,
                                jxl.biff.BaseCellFeatures.ValidationCondition c)
Sets the numeric value against which to validate

Parameters:
val - the number
c - the validation condition

setNumberValidation

public void setNumberValidation(double val1,
                                double val2,
                                jxl.biff.BaseCellFeatures.ValidationCondition c)
Sets the numeric range against which to validate the data

Parameters:
val1 - the first number
val2 - the second number
c - the validation condition