public void fire() throws IllegalActionException {
super.fire();
if (A.isKnown() && B.isKnown()) {
BigInteger intResult = null;
Precision precision = new Precision(
((Parameter) getAttribute("outputPrecision"))
.getExpression());
if (A.hasToken(0) && B.hasToken(0)) {
FixPoint valueA = ((FixToken) A.get(0)).fixValue();
FixPoint valueB = ((FixToken) B.get(0)).fixValue();
if (valueA.getPrecision().getNumberOfBits() != precision
.getNumberOfBits()) {
throw new IllegalActionException(this,
"Input A has different width than the output port");
}
if (valueB.getPrecision().getNumberOfBits() != precision
.getNumberOfBits()) {
throw new IllegalActionException(this,
"Input B has different width than the output port");
}
BigInteger bigIntA = valueA.getUnscaledValue();