public class ConditionalBlock extends java.lang.Object
EConditionalType. An condition may be given if
the block represents an if, else if or case block. The content of the block
is a list of shallow entities that represent the code that gets executed when
the block gets executed.| Modifier and Type | Field and Description |
|---|---|
protected EConditionalType |
blockType
The
EConditionalType of the block. |
protected java.util.List<IToken> |
condition
The list of ITokens representing the condition.
|
protected java.util.List<ShallowEntity> |
content
The content of the block that gets executed.
|
| Constructor and Description |
|---|
ConditionalBlock(EConditionalType blockType,
java.util.List<IToken> condition,
java.util.List<ShallowEntity> content) |
ConditionalBlock(EConditionalType blockType,
java.util.List<ShallowEntity> content)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
EConditionalType |
getBlockType() |
java.util.List<IToken> |
getCondition() |
java.util.List<ShallowEntity> |
getContent() |
boolean |
hasCondition()
Weather or not the block has a condition.
|
boolean |
hasContent() |
int |
hashCode() |
void |
setBlockType(EConditionalType blockType) |
void |
setCondition(java.util.List<IToken> condition) |
void |
setContent(java.util.List<ShallowEntity> content) |
java.lang.String |
toString() |
protected EConditionalType blockType
EConditionalType of the block.protected java.util.List<IToken> condition
protected java.util.List<ShallowEntity> content
public ConditionalBlock(EConditionalType blockType, java.util.List<ShallowEntity> content)
public ConditionalBlock(EConditionalType blockType, java.util.List<IToken> condition, java.util.List<ShallowEntity> content)
public EConditionalType getBlockType()
blockTypepublic void setBlockType(EConditionalType blockType)
blockTypepublic java.util.List<IToken> getCondition()
conditionpublic void setCondition(java.util.List<IToken> condition)
conditionpublic java.util.List<ShallowEntity> getContent()
contentpublic void setContent(java.util.List<ShallowEntity> content)
contentpublic boolean hasCondition()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean hasContent()