de.upb.hni.vmagic.statement
Class AssertionStatement

java.lang.Object
  extended by de.upb.hni.vmagic.VhdlElement
      extended by de.upb.hni.vmagic.LabeledElement
          extended by de.upb.hni.vmagic.statement.SequentialStatement
              extended by de.upb.hni.vmagic.statement.AssertionStatement

public class AssertionStatement
extends SequentialStatement

Assertion statement.

Example:
vMAGIC code:
AssertionStatement statement = new AssertionStatement(
    Standard.BOOLEAN_TRUE, "true is not true", Standard.SEVERITY_LEVEL_NOTE);
VHDL output:
assert TRUE report "true is true" severity NOTE;

Constructor Summary
AssertionStatement(Expression condition)
          Creates an assertion statement.
AssertionStatement(Expression condition, Expression reportedExpression)
          Creates an assertion statement with a reported message.
AssertionStatement(Expression condition, Expression reportedExpression, Expression severity)
          Creates an assertion statement with reported message and severity.
AssertionStatement(Expression condition, java.lang.String reportedExpression)
          Creates an assertion statement with a reported expression.
AssertionStatement(Expression condition, java.lang.String reportedExpression, Expression severity)
          Creates an assertion statement with reported message and severity.
 
Method Summary
 Expression getCondition()
          Returns the assertion condition.
 Expression getReportedExpression()
          Returns the reported message.
 Expression getSeverity()
          Returns the severity.
 void setCondition(Expression condition)
          Sets the assertion condition.
 void setReportedExpression(Expression reportedExpression)
          Sets the reported message.
 void setReportedExpression(java.lang.String reportedExpression)
          Sets the reported message.
 void setSeverity(Expression severity)
          Sets the severity.
 
Methods inherited from class de.upb.hni.vmagic.statement.SequentialStatement
getLabel, setLabel
 
Methods inherited from class de.upb.hni.vmagic.VhdlElement
getParent, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AssertionStatement

public AssertionStatement(Expression condition)
Creates an assertion statement.

Parameters:
condition - the assertion condition

AssertionStatement

public AssertionStatement(Expression condition,
                          Expression reportedExpression)
Creates an assertion statement with a reported message.

Parameters:
condition - the assertion condtion
reportedExpression - the reported message

AssertionStatement

public AssertionStatement(Expression condition,
                          java.lang.String reportedExpression)
Creates an assertion statement with a reported expression.

Parameters:
condition - the assertion condition
reportedExpression - the reported message

AssertionStatement

public AssertionStatement(Expression condition,
                          Expression reportedExpression,
                          Expression severity)
Creates an assertion statement with reported message and severity.

Parameters:
condition - the assertion condition
reportedExpression - the reported message
severity - the severity

AssertionStatement

public AssertionStatement(Expression condition,
                          java.lang.String reportedExpression,
                          Expression severity)
Creates an assertion statement with reported message and severity.

Parameters:
condition - the assertion condition
reportedExpression - the reported message
severity - the severity
Method Detail

getCondition

public Expression getCondition()
Returns the assertion condition.

Returns:
the condition

setCondition

public void setCondition(Expression condition)
Sets the assertion condition.

Parameters:
condition - the condition

getReportedExpression

public Expression getReportedExpression()
Returns the reported message.

Returns:
the reported message

setReportedExpression

public void setReportedExpression(Expression reportedExpression)
Sets the reported message.

Parameters:
reportedExpression - the reported message

setReportedExpression

public void setReportedExpression(java.lang.String reportedExpression)
Sets the reported message.

Parameters:
reportedExpression - the reported message

getSeverity

public Expression getSeverity()
Returns the severity.

Returns:
the severity

setSeverity

public void setSeverity(Expression severity)
Sets the severity.

Parameters:
severity - the severity