Top Description Constructors Methods
org.droidparts.dexmaker.dx.rop.code

public final Class PlainCstInsn

extends CstInsn
Class Inheritance
Imports
org.droidparts.dexmaker.dx.rop.cst.Constant, org.droidparts.dexmaker.dx.rop.type.StdTypeList, .Type, .TypeList

Instruction which contains an explicit reference to a constant but which cannot throw an exception.

Constructor Summary

AccessConstructor and Description
public
PlainCstInsn(Rop
non-null; the opcode
opcode
,
SourcePosition
non-null; source position
position
,
RegisterSpec
null-ok; spec for the result, if any
result
,
RegisterSpecList
non-null; specs for all the sources
sources
,
Constant
non-null; the constant
cst
)

Constructs an instance.

Method Summary

Modifier and TypeMethod and Description
public void
accept(Insn.Visitor
non-null; the visitor to call on
visitor
)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.accept.

Calls the appropriate method on the given visitor, depending on the class of this instance.
public TypeList
getCatches()

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.getCatches.

Gets the list of possibly-caught exceptions.
public Insn
withAddedCatch(Type
non-null; type to append to the catch list
type
)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withAddedCatch.

Returns an instance that is just like this one, except that it has a catch list with the given item appended to the end.
public Insn
withNewRegisters(RegisterSpec
null-ok; new result register
result
,
RegisterSpecList
non-null; new sources registers
sources
)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withNewRegisters.

Returns an instance that is just like this one, except with new result and source registers.
public Insn
withRegisterOffset(int
the amount to offset register references by
delta
)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withRegisterOffset.

Returns an instance that is just like this one, except that all register references have been offset by the given delta.
Inherited from org.droidparts.dexmaker.dx.rop.code.CstInsn:
contentEqualsgetConstantgetInlineString

Constructor Detail

PlainCstInsnback to summary
public PlainCstInsn(Rop opcode, SourcePosition position, RegisterSpec result, RegisterSpecList sources, Constant cst)

Constructs an instance.

Parameters
opcode:Rop

non-null; the opcode

position:SourcePosition

non-null; source position

result:RegisterSpec

null-ok; spec for the result, if any

sources:RegisterSpecList

non-null; specs for all the sources

cst:Constant

non-null; the constant

Method Detail

acceptback to summary
public void accept(Insn.Visitor visitor)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.accept.

Doc from org.droidparts.dexmaker.dx.rop.code.Insn.accept.

Calls the appropriate method on the given visitor, depending on the class of this instance. Subclasses must override this.

Parameters
visitor:Insn.Visitor

non-null; the visitor to call on

Annotations
@Override
getCatchesback to summary
public TypeList getCatches()

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.getCatches.

Doc from org.droidparts.dexmaker.dx.rop.code.Insn.getCatches.

Gets the list of possibly-caught exceptions. This returns StdTypeList#EMPTY if this instruction has no handlers, which can be either if this instruction can't possibly throw or if it merely doesn't handle any of its possible exceptions. To determine whether this instruction can throw, use canThrow.

Returns:TypeList

non-null; the catches list

Annotations
@Override
withAddedCatchback to summary
public Insn withAddedCatch(Type type)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withAddedCatch.

Doc from org.droidparts.dexmaker.dx.rop.code.Insn.withAddedCatch.

Returns an instance that is just like this one, except that it has a catch list with the given item appended to the end. This method throws an exception if this instance can't possibly throw. To determine whether this instruction can throw, use canThrow.

Parameters
type:Type

non-null; type to append to the catch list

Returns:Insn

non-null; an appropriately-constructed instance

Annotations
@Override
withNewRegistersback to summary
public Insn withNewRegisters(RegisterSpec result, RegisterSpecList sources)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withNewRegisters.

Doc from org.droidparts.dexmaker.dx.rop.code.Insn.withNewRegisters.

Returns an instance that is just like this one, except with new result and source registers.

Parameters
result:RegisterSpec

null-ok; new result register

sources:RegisterSpecList

non-null; new sources registers

Returns:Insn

non-null; an appropriately-constructed instance

Annotations
@Override
withRegisterOffsetback to summary
public Insn withRegisterOffset(int delta)

Implements abstract org.droidparts.dexmaker.dx.rop.code.Insn.withRegisterOffset.

Doc from org.droidparts.dexmaker.dx.rop.code.Insn.withRegisterOffset.

Returns an instance that is just like this one, except that all register references have been offset by the given delta.

Parameters
delta:int

the amount to offset register references by

Returns:Insn

non-null; an appropriately-constructed instance

Annotations
@Override