Class ImmutableSparseSwitchPayload
- java.lang.Object
-
- org.jf.dexlib2.immutable.instruction.ImmutableInstruction
-
- org.jf.dexlib2.immutable.instruction.ImmutableSparseSwitchPayload
-
- All Implemented Interfaces:
SparseSwitchPayload
,Instruction
,PayloadInstruction
,SwitchPayload
public class ImmutableSparseSwitchPayload extends ImmutableInstruction implements SparseSwitchPayload
-
-
Field Summary
Fields Modifier and Type Field Description static Opcode
OPCODE
protected com.google.common.collect.ImmutableList<? extends ImmutableSwitchElement>
switchElements
-
Fields inherited from class org.jf.dexlib2.immutable.instruction.ImmutableInstruction
opcode
-
-
Constructor Summary
Constructors Constructor Description ImmutableSparseSwitchPayload(com.google.common.collect.ImmutableList<? extends ImmutableSwitchElement> switchElements)
ImmutableSparseSwitchPayload(java.util.List<? extends SwitchElement> switchElements)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getCodeUnits()
Gets the size of this instruction.Format
getFormat()
java.util.List<? extends SwitchElement>
getSwitchElements()
static ImmutableSparseSwitchPayload
of(SparseSwitchPayload instruction)
-
Methods inherited from class org.jf.dexlib2.immutable.instruction.ImmutableInstruction
getOpcode, immutableListOf, of
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jf.dexlib2.iface.instruction.Instruction
getOpcode
-
-
-
-
Field Detail
-
OPCODE
public static final Opcode OPCODE
-
switchElements
@Nonnull protected final com.google.common.collect.ImmutableList<? extends ImmutableSwitchElement> switchElements
-
-
Constructor Detail
-
ImmutableSparseSwitchPayload
public ImmutableSparseSwitchPayload(@Nullable java.util.List<? extends SwitchElement> switchElements)
-
ImmutableSparseSwitchPayload
public ImmutableSparseSwitchPayload(@Nullable com.google.common.collect.ImmutableList<? extends ImmutableSwitchElement> switchElements)
-
-
Method Detail
-
of
@Nonnull public static ImmutableSparseSwitchPayload of(SparseSwitchPayload instruction)
-
getSwitchElements
@Nonnull public java.util.List<? extends SwitchElement> getSwitchElements()
- Specified by:
getSwitchElements
in interfaceSwitchPayload
-
getCodeUnits
public int getCodeUnits()
Description copied from interface:Instruction
Gets the size of this instruction.- Specified by:
getCodeUnits
in interfaceInstruction
- Overrides:
getCodeUnits
in classImmutableInstruction
- Returns:
- The size of this instruction, as a count of the number of 16-bit code units that make up this instruction.
-
getFormat
public Format getFormat()
- Specified by:
getFormat
in classImmutableInstruction
-
-