public final class IntegerImmediate implements MicroInstructionParameter
{
private BitVector value;
-
+
public IntegerImmediate(BigInteger value, int bits)
{
this.value = BitVector.from(value, bits);
}
-
+
public IntegerImmediate(BitVector value)
{
this.value = value;
}
-
+
@Override
public BitVector getValue()
{
return false;
return true;
}
+
+ /**
+ * @return The value of this IntegerImmediate as an unsigned BigInteger
+ */
+ public BigInteger getValueAsBigInteger()
+ {
+ return value.getUnsignedValue();
+ }
+
+ @Override
+ public String toString()
+ {
+ return getValueAsBigInteger().toString();
+ }
}