Class AbstractInstructionOperandList
java.lang.Object
com.pnfsoftware.jeb.core.units.code.asm.processor.AbstractInstructionOperandGeneric
com.pnfsoftware.jeb.core.units.code.asm.processor.AbstractInstructionOperandList
- All Implemented Interfaces:
IInstructionOperandGeneric,IInstructionOperandList,IInstructionOperandRegisterBased,IInstructionOperandSized,IInstructionOperand
@Ser
public abstract class AbstractInstructionOperandList
extends AbstractInstructionOperandGeneric
implements IInstructionOperandList
Reference implementation for
IInstructionOperandList.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intReserved inner space for mask.static final intrepresent no flagstatic final int: separatorstatic final int, separatorstatic final int- separatorstatic final int; separatorstatic final int" " separatorstatic final int" " before and after a separatorstatic final int{} containerstatic final int[] containerstatic final int<> containerstatic final int"" containerstatic final int() containerstatic final int'' containerstatic final int"" containerstatic final intReserved value for Child classesstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.pnfsoftware.jeb.core.units.code.asm.processor.AbstractInstructionOperandGeneric
bitsize, type, valueFields inherited from interface com.pnfsoftware.jeb.core.units.code.asm.processor.IInstructionOperandGeneric
TYPE_ADDR, TYPE_ALIAS, TYPE_CMA, TYPE_IMM, TYPE_LIST, TYPE_MEMIMM, TYPE_MEMREG, TYPE_REG, TYPE_RELADDR, TYPE_SIMM, TYPE_USER_1 -
Constructor Summary
ConstructorsConstructorDescriptionAbstractInstructionOperandList(int type, int size, long value, int flags, IInstructionOperandGeneric... operands) AbstractInstructionOperandList(int size, long value, int flags, IInstructionOperandGeneric... operands) -
Method Summary
Modifier and TypeMethodDescriptionbooleanprotected CharSequenceformatOperand(IInstruction insn, long address) intgetFlags()Get the list of operands represented by this operand.getPrefix(IInstruction insn) Get the optional prefix to be prepended to the formatted operand.Retrieve the separator of the elements of the listgetSuffix(IInstruction insn) Get the optional suffix to be appended to the formatted operand.inthashCode()merge(long address) Attempt to merge parameter list to 1 parameter.Methods inherited from class com.pnfsoftware.jeb.core.units.code.asm.processor.AbstractInstructionOperandGeneric
format, getAlias, getOperandBitsize, getOperandType, getOperandValue, getOperandValue, innerFormat, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.pnfsoftware.jeb.core.units.code.IInstructionOperand
formatMethods inherited from interface com.pnfsoftware.jeb.core.units.code.asm.processor.IInstructionOperandGeneric
getAlias, getOperandType, getOperandValue, getOperandValue, isImmediate, isRegisterMethods inherited from interface com.pnfsoftware.jeb.core.units.code.asm.processor.IInstructionOperandRegisterBased
getRegisterNameMethods inherited from interface com.pnfsoftware.jeb.core.units.code.asm.processor.IInstructionOperandSized
getOperandBitsize
-
Field Details
-
NO_FLAG
public static final int NO_FLAGrepresent no flag- See Also:
-
SURROUND_BRACKETS
public static final int SURROUND_BRACKETS[] container- See Also:
-
SURROUND_BRACES
public static final int SURROUND_BRACES{} container- See Also:
-
SURROUND_PARENTHESES
public static final int SURROUND_PARENTHESES() container- See Also:
-
SURROUND_CHEVRONS
public static final int SURROUND_CHEVRONS<> container- See Also:
-
SURROUND_QUOTES
public static final int SURROUND_QUOTES'' container- See Also:
-
SURROUND_DOUBLE_QUOTES
public static final int SURROUND_DOUBLE_QUOTES"" container- See Also:
-
SURROUND_SPACES
public static final int SURROUND_SPACES"" container- See Also:
-
SEPARATOR_SPACE
public static final int SEPARATOR_SPACE" " separator- See Also:
-
SEPARATOR_COMMA
public static final int SEPARATOR_COMMA, separator- See Also:
-
SEPARATOR_COLON
public static final int SEPARATOR_COLON: separator- See Also:
-
SEPARATOR_SEMI_COLON
public static final int SEPARATOR_SEMI_COLON; separator- See Also:
-
SEPARATOR_HYPHEN
public static final int SEPARATOR_HYPHEN- separator- See Also:
-
SEPARATOR_SURROUND_SPACE
public static final int SEPARATOR_SURROUND_SPACE" " before and after a separator- See Also:
-
USER_DEFINED_1
public static final int USER_DEFINED_1Reserved value for Child classes- See Also:
-
USER_DEFINED_2
public static final int USER_DEFINED_2- See Also:
-
USER_DEFINED_3
public static final int USER_DEFINED_3- See Also:
-
USER_DEFINED_4
public static final int USER_DEFINED_4- See Also:
-
USER_DEFINED_5
public static final int USER_DEFINED_5- See Also:
-
USER_DEFINED_6
public static final int USER_DEFINED_6- See Also:
-
USER_DEFINED_7
public static final int USER_DEFINED_7- See Also:
-
USER_DEFINED_8
public static final int USER_DEFINED_8- See Also:
-
FLAG_MASK
public static final int FLAG_MASKReserved inner space for mask. Concrete children can have bigger space- See Also:
-
-
Constructor Details
-
AbstractInstructionOperandList
public AbstractInstructionOperandList(int size, long value, int flags, IInstructionOperandGeneric... operands) - Parameters:
size- size of the operandvalue- internal value, can be 0 if unnecessaryoperands- list of operandsflags- used to format the operand list : this concerns separator as well as container.
For example:BRACKETS | COMMA | SPACEwill generate a list [el1, el2, el3]
-
AbstractInstructionOperandList
public AbstractInstructionOperandList(int type, int size, long value, int flags, IInstructionOperandGeneric... operands)
-
-
Method Details
-
formatOperand
- Overrides:
formatOperandin classAbstractInstructionOperandGeneric
-
getPrefix
Description copied from interface:IInstructionOperandGenericGet the optional prefix to be prepended to the formatted operand.- Specified by:
getPrefixin interfaceIInstructionOperandGeneric- Overrides:
getPrefixin classAbstractInstructionOperandGeneric- Returns:
- optional prefix
-
getSuffix
Description copied from interface:IInstructionOperandGenericGet the optional suffix to be appended to the formatted operand.- Specified by:
getSuffixin interfaceIInstructionOperandGeneric- Overrides:
getSuffixin classAbstractInstructionOperandGeneric- Returns:
- optional suffix
-
getOperands
Description copied from interface:IInstructionOperandListGet the list of operands represented by this operand.- Specified by:
getOperandsin interfaceIInstructionOperandList
-
getFlags
public int getFlags() -
getSeparator
Description copied from interface:IInstructionOperandListRetrieve the separator of the elements of the list- Specified by:
getSeparatorin interfaceIInstructionOperandList
-
merge
Description copied from interface:IInstructionOperandListAttempt to merge parameter list to 1 parameter. When not possible, this method will return null. Otherwise, the returned value can be considered as equivalent to the list. For example 0x45, 0 defined for a right shift is equivalent to 0x22, PC+4 is equivalent to its absolute address.- Specified by:
mergein interfaceIInstructionOperandList- Returns:
-
hashCode
public int hashCode()- Overrides:
hashCodein classAbstractInstructionOperandGeneric
-
equals
- Overrides:
equalsin classAbstractInstructionOperandGeneric
-