Package rubydragon.groovy
Class GroovyScriptProvider
java.lang.Object
ghidra.app.script.GhidraScriptProvider
rubydragon.groovy.GroovyScriptProvider
- All Implemented Interfaces:
ghidra.util.classfinder.ExtensionPoint
,Comparable<ghidra.app.script.GhidraScriptProvider>
public class GroovyScriptProvider
extends ghidra.app.script.GhidraScriptProvider
Supports Groovy scripts within ghidra.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
createNewScript
(generic.jar.ResourceFile newScript, String category) Creates a new script file for the given script and category.Returns a Pattern that matches block comment closings.Returns a Pattern that matches block comment openings.The comment character for Groovy scripts.A short description of the type of scripts this provider supports.The extension of Groovy scripts, including the period.ghidra.app.script.GhidraScript
getScriptInstance
(generic.jar.ResourceFile sourceFile, PrintWriter writer) Creates a new GroovyScript instance for the given file and returns it.Methods inherited from class ghidra.app.script.GhidraScriptProvider
compareTo, deleteScript, equals, hashCode, toString
-
Constructor Details
-
GroovyScriptProvider
public GroovyScriptProvider()
-
-
Method Details
-
createNewScript
Creates a new script file for the given script and category.- Specified by:
createNewScript
in classghidra.app.script.GhidraScriptProvider
- Throws:
IOException
-
getBlockCommentStart
Returns a Pattern that matches block comment openings. For Kotlin this is "/*".- Overrides:
getBlockCommentStart
in classghidra.app.script.GhidraScriptProvider
- Returns:
- the Pattern for Kotlin block comment openings
-
getBlockCommentEnd
Returns a Pattern that matches block comment closings. In Kotlin this is an asterisk followed by a forward slash.- Overrides:
getBlockCommentEnd
in classghidra.app.script.GhidraScriptProvider
- Returns:
- the Pattern for Kotlin block comment closings
-
getCommentCharacter
The comment character for Groovy scripts.- Specified by:
getCommentCharacter
in classghidra.app.script.GhidraScriptProvider
-
getDescription
A short description of the type of scripts this provider supports.- Specified by:
getDescription
in classghidra.app.script.GhidraScriptProvider
-
getExtension
The extension of Groovy scripts, including the period.- Specified by:
getExtension
in classghidra.app.script.GhidraScriptProvider
-
getScriptInstance
public ghidra.app.script.GhidraScript getScriptInstance(generic.jar.ResourceFile sourceFile, PrintWriter writer) throws ghidra.app.script.GhidraScriptLoadException Creates a new GroovyScript instance for the given file and returns it.- Specified by:
getScriptInstance
in classghidra.app.script.GhidraScriptProvider
- Throws:
ghidra.app.script.GhidraScriptLoadException
-