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()
blockType
public void setBlockType(EConditionalType blockType)
blockType
public java.util.List<IToken> getCondition()
condition
public void setCondition(java.util.List<IToken> condition)
condition
public java.util.List<ShallowEntity> getContent()
content
public void setContent(java.util.List<ShallowEntity> content)
content
public boolean hasCondition()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean hasContent()