Class MethodDecl
java.lang.Object
net.covers1624.coffeegrinder.bytecode.Instruction
net.covers1624.coffeegrinder.bytecode.insns.MethodDecl
- All Implemented Interfaces:
net.covers1624.quack.util.Copyable<Instruction>
Created by covers1624 on 19/4/21.
-
Field Summary
FieldsModifier and TypeFieldDescriptionFields inherited from class net.covers1624.coffeegrinder.bytecode.Instruction
opcode -
Constructor Summary
ConstructorsConstructorDescriptionMethodDecl(Method method, Instruction body, List<ParameterVariable> parameters) -
Method Summary
Modifier and TypeMethodDescription<R,C> R accept(InsnVisitor<R, C> visitor, C ctx) Pass thisInstructionthrough the suppliedInsnVisitor.protected EnumBitSet<InstructionFlag> Called to compute the exposed flags exposed viaInstruction.getFlags().getBody()Any direct flags for thisInstruction.Gets the stack type of the value produced by thisInstruction.booleanhasBody()voidsetBody(Instruction body) voidsetResultType(ReferenceType resultType) voidsetReturnType(AType returnType) Methods inherited from class net.covers1624.coffeegrinder.bytecode.Instruction
accept, addRef, ancestorsOfType, copy, descendantsMatching, descendantsOfType, descendantsToList, descendantsToListWhere, descendantsWhere, firstAncestorOfType, getBytecodeOffset, getChildren, getDescendants, getFirstChild, getFirstChildOrNull, getFlags, getLastChild, getLastChildOrNull, getNextSibling, getNextSiblingOrNull, getParent, getParentOrNull, getPrevSibling, getPrevSiblingOrNull, getSourceLine, getTag, hasDirectFlag, hasFlag, insertAfter, insertBefore, invalidateFlags, isConnected, isDescendantOf, onChildModified, onConnected, onDisconnected, releaseRef, remove, replaceWith, setBytecodeOffset, setOffsets, setSourceLine, setTag, toString, toString, withOffsets
-
Field Details
-
parameters
-
variables
-
-
Constructor Details
-
MethodDecl
-
-
Method Details
-
getResultType
Description copied from class:InstructionGets the stack type of the value produced by thisInstruction.- Specified by:
getResultTypein classInstruction- Returns:
- The
AType.
-
computeFlags
Description copied from class:InstructionCalled to compute the exposed flags exposed viaInstruction.getFlags().- Overrides:
computeFlagsin classInstruction- Returns:
- The computed flags.
-
getDirectFlags
Description copied from class:InstructionAny direct flags for thisInstruction.The return value should be cached statically inside the
Instructionimpl.- Specified by:
getDirectFlagsin classInstruction- Returns:
- An
EnumBitSetrepresenting the flags. - See Also:
-
accept
Description copied from class:InstructionPass thisInstructionthrough the suppliedInsnVisitor.- Specified by:
acceptin classInstruction- Parameters:
visitor- TheInsnVisitor.ctx- The context.- Returns:
- The return result from the
InsnVisitor.
-
getMethod
-
getReturnType
-
setBody
-
setReturnType
-
setResultType
-
getReturns
-
hasBody
public boolean hasBody() -
getBody
-