Package ghidra.pcode.exec
Class AnnotatedPcodeUseropLibrary<T>
java.lang.Object
ghidra.pcode.exec.AnnotatedPcodeUseropLibrary<T>
- Type Parameters:
T
- the type of data processed by the library
- All Implemented Interfaces:
PcodeUseropLibrary<T>
- Direct Known Subclasses:
AdaptedEmulator.AdaptedPcodeUseropLibrary
,AnnotatedEmuSyscallUseropLibrary
,DefaultPcodeThread.PcodeEmulationLibrary
,PcodeExpression.ValueCapturingPcodeUseropLibrary
public abstract class AnnotatedPcodeUseropLibrary<T>
extends Object
implements PcodeUseropLibrary<T>
A userop library wherein Java methods are exported via a special annotation
See StandAloneEmuExampleScript
for an example of implementing a userop library.
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static class
A wrapped, annotated Java method, exported as a userop definitionprotected static class
An annotated userop with a fixed number of argumentsstatic @interface
An annotation to receive the executor itself into a parameterstatic @interface
An annotation to receive the complete library into a parameterstatic @interface
An annotation to receive the output varnode into a parameterstatic @interface
An annotation to receive the executor's state into a parameterstatic @interface
An annotation to export a Java method as a userop in the library.protected static class
An annotated userop with a variable number of argumentsNested classes/interfaces inherited from interface ghidra.pcode.exec.PcodeUseropLibrary
PcodeUseropLibrary.EmptyPcodeUseropLibrary, PcodeUseropLibrary.PcodeUseropDefinition<T>
-
Field Summary
Modifier and TypeFieldDescriptionprotected Map
<String, PcodeUseropLibrary.PcodeUseropDefinition<T>> Fields inherited from interface ghidra.pcode.exec.PcodeUseropLibrary
NIL
-
Constructor Summary
ConstructorDescriptionDefault constructor, usually invoked implicitly -
Method Summary
Modifier and TypeMethodDescriptionprotected MethodHandles.Lookup
An override to provide method access, if any non-public method is exported as a userop.protected Type
Determine the operand type by examining the type substituted forT
Get all the userops defined in this library, keyed by (symbol) name.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface ghidra.pcode.exec.PcodeUseropLibrary
compose, getSymbols
-
Field Details
-
ops
-
-
Constructor Details
-
AnnotatedPcodeUseropLibrary
public AnnotatedPcodeUseropLibrary()Default constructor, usually invoked implicitly
-
-
Method Details
-
getOperandType
Determine the operand type by examining the type substituted forT
- Returns:
- the type of data processed by the userop
-
getMethodLookup
An override to provide method access, if any non-public method is exported as a userop.- Returns:
- a lookup that can access all
AnnotatedPcodeUseropLibrary.PcodeUserop
-annotated methods.
-
getUserops
Description copied from interface:PcodeUseropLibrary
Get all the userops defined in this library, keyed by (symbol) name.- Specified by:
getUserops
in interfacePcodeUseropLibrary<T>
- Returns:
- the map of names to defined userops
-