public abstract class BlockWriter
extends java.lang.Object
Aparapi
IR to text.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
arrayDimMangleSuffix |
static java.lang.String |
arrayLengthMangleSuffix |
int |
indent |
Constructor and Description |
---|
BlockWriter() |
public static final java.lang.String arrayLengthMangleSuffix
public static final java.lang.String arrayDimMangleSuffix
public int indent
public abstract void write(java.lang.String _string)
public void writeln(java.lang.String _string)
public void in()
public void out()
public void newLine()
public void writeConditionalBranch16(InstructionSet.ConditionalBranch16 _branch16, boolean _invert) throws CodeGenException
CodeGenException
public void writeComposite(InstructionSet.CompositeInstruction instruction) throws CodeGenException
CodeGenException
public void writeSequence(Instruction _first, Instruction _last) throws CodeGenException
CodeGenException
protected void writeGetterBlock(ClassModel.ConstantPool.FieldEntry accessorVariableFieldEntry)
public void writeBlock(Instruction _first, Instruction _last) throws CodeGenException
CodeGenException
public Instruction writeConditional(BranchSet _branchSet) throws CodeGenException
CodeGenException
public Instruction writeConditional(BranchSet _branchSet, boolean _invert) throws CodeGenException
CodeGenException
public void write(BranchSet.LogicalExpressionNode _node) throws CodeGenException
CodeGenException
public java.lang.String convertType(java.lang.String _typeDesc, boolean useClassModel, boolean isLocal)
public java.lang.String convertCast(java.lang.String _cast)
public void writeInstruction(Instruction _instruction) throws CodeGenException
CodeGenException
private boolean isNeedParenthesis(Instruction instruction)
private boolean isMultiDimensionalArray(ClassModel.ConstantPool.NameAndTypeEntry nameAndTypeEntry)
private boolean isObjectArray(ClassModel.ConstantPool.NameAndTypeEntry nameAndTypeEntry)
private boolean isMultiDimensionalArray(InstructionSet.AccessArrayElement arrayLoadInstruction)
private boolean isObjectArray(InstructionSet.AccessArrayElement arrayLoadInstruction)
private InstructionSet.AccessField getUltimateInstanceFieldAccess(InstructionSet.AccessArrayElement arrayLoadInstruction)
private InstructionSet.AccessLocalVariable getUltimateInstanceLocalVarAccess(InstructionSet.AccessArrayElement arrayLoadInstruction)
public void writeMethod(InstructionSet.MethodCall _methodCall, ClassModel.ConstantPool.MethodEntry _methodEntry) throws CodeGenException
CodeGenException
public void writeThisRef()
public void writeMethodBody(MethodModel _methodModel) throws CodeGenException
CodeGenException
public abstract void write(Entrypoint entryPoint) throws CodeGenException
CodeGenException