Package io.keikai.model.impl
Class AbstractCellAdv
- java.lang.Object
-
- io.keikai.model.impl.AbstractCellAdv
-
- All Implemented Interfaces:
CellStyleHolder,FormulaContent,LinkedModelObject,SCell,Serializable
- Direct Known Subclasses:
CellImpl
public abstract class AbstractCellAdv extends Object implements SCell, LinkedModelObject, Serializable
- Since:
- 3.5.0
- Author:
- dennis
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.keikai.model.SCell
SCell.CellType
-
-
Constructor Summary
Constructors Constructor Description AbstractCellAdv()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidcheckFormulaResultType(SCell.CellType... types)protected voidcheckType(SCell.CellType... types)BooleangetBooleanValue()Gets the boolean valueDategetDateValue()Gets the date value that is transfered by the double number value.ErrorValuegetErrorValue()abstract CellValuegetEvalCellValue(boolean evaluatedVal)abstract FormulaExpressiongetFormulaExpression()StringgetFormulaValue()ObjectgetInitValue()DoublegetNumberValue()SRichTextgetRichTextValue()Return the rich text value.StringgetStringValue()abstract intgetTextHeight()abstract intgetTextWidth()ObjectgetValue()abstract booleanisCalcAutoHeight()booleanisRichTextValue()Check if this cell contains a rich-text valuevoidsetBooleanValue(Boolean date)abstract voidsetCalcAutoHeight(boolean b)voidsetDateValue(Date date)Sets the number value a date instance, it will transfer the date to double valuevoidsetErrorValue(ErrorValue errorValue)abstract voidsetFormulaResultValue(ValueEval value)abstract voidsetFormulaValue(String formula, FormulaType formulaType)abstract voidsetFormulaValue(String formula, Locale locale)abstract voidsetFormulaValue(String formula, Locale locale, FormulaType formulaType)voidsetNumberValue(Double number)voidsetStringValue(String value)Set string value, if the value start with '=', then it sets as formulaabstract voidsetTextHeight(int height)abstract voidsetTextWidth(int width)SCommentsetupComment()SHyperlinksetupHyperlink(SHyperlink.HyperlinkType type, String address, String label)setup a hyperlinkSRichTextsetupRichTextValue()Setup a rich text value(Create a new one if the old value is not a rich-text) and return the instance which to be edited.protected abstract voidsetValue(Object value, boolean aString)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.keikai.model.CellStyleHolder
getCellStyle, getCellStyle, setCellStyle
-
Methods inherited from interface io.keikai.model.FormulaContent
clearFormulaResultCache, isFormulaParsingError
-
Methods inherited from interface io.keikai.model.impl.LinkedModelObject
checkOrphan, destroy
-
Methods inherited from interface io.keikai.model.SCell
clearValue, deleteComment, getArrayFormulaRegion, getColumnIndex, getComment, getFormulaResultType, getHyperlink, getReferenceString, getRowIndex, getSheet, getType, isNull, isPartOfArrayFormulaGroup, setComment, setFormulaValue, setHyperlink, setValue
-
-
-
-
Method Detail
-
checkType
protected void checkType(SCell.CellType... types)
-
checkFormulaResultType
protected void checkFormulaResultType(SCell.CellType... types)
-
setStringValue
public void setStringValue(String value)
Description copied from interface:SCellSet string value, if the value start with '=', then it sets as formula- Specified by:
setStringValuein interfaceSCell
-
getStringValue
public String getStringValue()
- Specified by:
getStringValuein interfaceSCell
-
getInitValue
public Object getInitValue()
-
setNumberValue
public void setNumberValue(Double number)
- Specified by:
setNumberValuein interfaceSCell
-
getNumberValue
public Double getNumberValue()
- Specified by:
getNumberValuein interfaceSCell
-
setDateValue
public void setDateValue(Date date)
Description copied from interface:SCellSets the number value a date instance, it will transfer the date to double value- Specified by:
setDateValuein interfaceSCell
-
getDateValue
public Date getDateValue()
Description copied from interface:SCellGets the date value that is transfered by the double number value.- Specified by:
getDateValuein interfaceSCell
-
setBooleanValue
public void setBooleanValue(Boolean date)
- Specified by:
setBooleanValuein interfaceSCell
-
getBooleanValue
public Boolean getBooleanValue()
Description copied from interface:SCellGets the boolean value- Specified by:
getBooleanValuein interfaceSCell
-
getErrorValue
public ErrorValue getErrorValue()
- Specified by:
getErrorValuein interfaceSCell
-
setErrorValue
public void setErrorValue(ErrorValue errorValue)
- Specified by:
setErrorValuein interfaceSCell
-
getFormulaValue
public String getFormulaValue()
- Specified by:
getFormulaValuein interfaceSCell- Returns:
- returns formula string without '=', e.g. SUM(A1:B2)
-
setupRichTextValue
public SRichText setupRichTextValue()
Description copied from interface:SCellSetup a rich text value(Create a new one if the old value is not a rich-text) and return the instance which to be edited.- Specified by:
setupRichTextValuein interfaceSCell
-
getRichTextValue
public SRichText getRichTextValue()
Description copied from interface:SCellReturn the rich text value. if this cell is a simple string value, it will return a read-only rich-text which wraps string-value and current font.- Specified by:
getRichTextValuein interfaceSCell- Returns:
-
isRichTextValue
public boolean isRichTextValue()
Description copied from interface:SCellCheck if this cell contains a rich-text value- Specified by:
isRichTextValuein interfaceSCell
-
setupHyperlink
public SHyperlink setupHyperlink(SHyperlink.HyperlinkType type, String address, String label)
Description copied from interface:SCellsetup a hyperlink- Specified by:
setupHyperlinkin interfaceSCell
-
setupComment
public SComment setupComment()
- Specified by:
setupCommentin interfaceSCell
-
setFormulaValue
public abstract void setFormulaValue(String formula, Locale locale, FormulaType formulaType)
- Parameters:
formula-locale-- Since:
- 6.0.0
-
setFormulaValue
public abstract void setFormulaValue(String formula, FormulaType formulaType)
- Parameters:
formula-- Since:
- 6.0.0
-
setFormulaResultValue
public abstract void setFormulaResultValue(ValueEval value)
-
setValue
protected abstract void setValue(Object value, boolean aString)
-
getFormulaExpression
public abstract FormulaExpression getFormulaExpression()
-
setTextHeight
public abstract void setTextHeight(int height)
-
getTextHeight
public abstract int getTextHeight()
-
setCalcAutoHeight
public abstract void setCalcAutoHeight(boolean b)
-
isCalcAutoHeight
public abstract boolean isCalcAutoHeight()
-
setTextWidth
public abstract void setTextWidth(int width)
-
getTextWidth
public abstract int getTextWidth()
-
getEvalCellValue
public abstract CellValue getEvalCellValue(boolean evaluatedVal)
-
-