Package com.grapecity.documents.excel
Interface IScenario
public interface IScenario
A scenario is a group of input values (called changing cells) that's named and saved.
-
Method Summary
Modifier and TypeMethodDescriptionvoidchangeScenario(IRange changingCells) Changes the scenario to have a new set of changing cells.voidchangeScenario(IRange changingCells, List<Object> values) Changes the scenario to have a new set of changing cells and scenario values.voiddelete()Deletes the object.Gets aIRangeobject that represents the changing cells for the scenario.Gets a String value that represents the comment associated with the scenario.booleanGets a Boolean value that indicates if the scenario is hidden.intgetIndex()Returns the index number of the object within the collection of similar objects.booleanGets a Boolean value that indicates if the scenario is locked.getName()Gets a String value representing the name of the object.Returns a list that contains the current values of the changing cells for the scenario.voidsetComment(String comment) Sets a String value that represents the comment associated with the scenario.voidsetHidden(boolean hidden) Sets a Boolean value that indicates if the scenario is hidden.voidsetLocked(boolean locked) Sets a Boolean value that indicates if the scenario is locked.voidSets a String value representing the name of the object.voidshow()Shows the scenario by inserting its values on the worksheet.
-
Method Details
-
getIndex
int getIndex()Returns the index number of the object within the collection of similar objects.- Returns:
- The index number of the object within the collection of similar objects.
-
getName
String getName()Gets a String value representing the name of the object.- Returns:
- The name of the object.
-
setName
Sets a String value representing the name of the object.- Parameters:
name- The name of the object.
-
getComment
String getComment()Gets a String value that represents the comment associated with the scenario.- Returns:
- The comment associated with the scenario.
-
setComment
Sets a String value that represents the comment associated with the scenario.- Parameters:
comment- The comment associated with the scenario.
-
getHidden
boolean getHidden()Gets a Boolean value that indicates if the scenario is hidden.- Returns:
- True if the scenario is hidden; otherwise, false.
-
setHidden
void setHidden(boolean hidden) Sets a Boolean value that indicates if the scenario is hidden.- Parameters:
hidden- True if the scenario is hidden; otherwise, false.
-
getLocked
boolean getLocked()Gets a Boolean value that indicates if the scenario is locked.- Returns:
- True if the scenario is locked; otherwise, false.
-
setLocked
void setLocked(boolean locked) Sets a Boolean value that indicates if the scenario is locked.- Parameters:
locked- True if the scenario is locked; otherwise, false.
-
getChangingCells
IRange getChangingCells()Gets aIRangeobject that represents the changing cells for the scenario.- Returns:
- The changing cells for a scenario.
-
getValues
Returns a list that contains the current values of the changing cells for the scenario.- Returns:
- A list of objects representing the current values of the changing cells.
-
delete
void delete()Deletes the object. -
show
void show()Shows the scenario by inserting its values on the worksheet. The affected cells are the changing cells of the scenario. -
changeScenario
Changes the scenario to have a new set of changing cells.- Parameters:
changingCells- A Range object that refers to the changing cells for the scenario. The scenario values are assumed to be the current values in the cells in ChangingCells.
-
changeScenario
Changes the scenario to have a new set of changing cells and scenario values.- Parameters:
changingCells- A Range object that refers to the changing cells for the scenario.values- A list that contains the scenario values for the cells in ChangingCells.
-