public abstract class BinaryExpressionWriter extends Object
Modifier and Type | Field and Description |
---|---|
protected static int[] |
stdCompareCodes |
Constructor and Description |
---|
BinaryExpressionWriter(WriterController controller,
MethodCaller arraySet,
MethodCaller arrayGet) |
Modifier and Type | Method and Description |
---|---|
boolean |
arrayGet(int operation,
boolean simulate) |
boolean |
arraySet(boolean simulate) |
protected abstract void |
doubleTwoOperands(org.objectweb.asm.MethodVisitor mv) |
protected MethodCaller |
getArrayGetCaller() |
protected ClassNode |
getArrayGetResultType() |
protected MethodCaller |
getArraySetCaller() |
protected abstract int |
getBitwiseOperationBytecode(int type) |
protected abstract int |
getCompareCode() |
WriterController |
getController()
return writer controller
|
protected abstract ClassNode |
getDevisionOpResultType() |
protected abstract ClassNode |
getNormalOpResultType() |
protected abstract int |
getShiftOperationBytecode(int type) |
protected abstract int |
getStandardOperationBytecode(int type) |
protected abstract void |
removeTwoOperands(org.objectweb.asm.MethodVisitor mv) |
void |
setArraySetAndGet(MethodCaller arraySet,
MethodCaller arrayGet) |
protected boolean |
supportsDivision() |
boolean |
write(int operation,
boolean simulate) |
protected boolean |
writeBitwiseOp(int type,
boolean simulate)
writes some the bitwise operations.
|
protected boolean |
writeDivision(boolean simulate) |
protected abstract void |
writeMinusMinus(org.objectweb.asm.MethodVisitor mv) |
protected abstract void |
writePlusPlus(org.objectweb.asm.MethodVisitor mv) |
boolean |
writePostOrPrefixMethod(int operation,
boolean simulate) |
protected boolean |
writeShiftOp(int type,
boolean simulate)
Write shifting operations.
|
protected boolean |
writeSpaceship(int type,
boolean simulate) |
protected boolean |
writeStdCompare(int type,
boolean simulate)
writes some int standard operations for compares
|
protected boolean |
writeStdOperators(int type,
boolean simulate) |
public BinaryExpressionWriter(WriterController controller, MethodCaller arraySet, MethodCaller arrayGet)
public WriterController getController()
protected abstract int getCompareCode()
protected boolean writeStdCompare(int type, boolean simulate)
type
- the token typeprotected abstract void doubleTwoOperands(org.objectweb.asm.MethodVisitor mv)
protected abstract void removeTwoOperands(org.objectweb.asm.MethodVisitor mv)
protected boolean writeSpaceship(int type, boolean simulate)
protected abstract ClassNode getNormalOpResultType()
protected abstract int getStandardOperationBytecode(int type)
protected boolean writeStdOperators(int type, boolean simulate)
protected boolean writeDivision(boolean simulate)
protected boolean supportsDivision()
protected abstract ClassNode getDevisionOpResultType()
protected abstract int getBitwiseOperationBytecode(int type)
protected boolean writeBitwiseOp(int type, boolean simulate)
type
- the token typeprotected abstract int getShiftOperationBytecode(int type)
protected boolean writeShiftOp(int type, boolean simulate)
type
- the token typepublic boolean write(int operation, boolean simulate)
protected MethodCaller getArrayGetCaller()
protected ClassNode getArrayGetResultType()
protected MethodCaller getArraySetCaller()
public void setArraySetAndGet(MethodCaller arraySet, MethodCaller arrayGet)
public boolean arrayGet(int operation, boolean simulate)
public boolean arraySet(boolean simulate)
public boolean writePostOrPrefixMethod(int operation, boolean simulate)
protected abstract void writePlusPlus(org.objectweb.asm.MethodVisitor mv)
protected abstract void writeMinusMinus(org.objectweb.asm.MethodVisitor mv)