Package ghidra.program.util
Class GhidraProgramUtilities
java.lang.Object
ghidra.program.util.GhidraProgramUtilities
-
Method Summary
Modifier and TypeMethodDescriptionstatic Program
getCurrentProgram
(PluginTool tool) returns the current program, given a tool, if a program is opened; otherwise returns null.static void
removeAnalyzedFlag
(Program program) Removes the analyzed flag from the program properties.static void
setAnalyzedFlag
(Program program, boolean analyzed) Sets the analyzed flag to the specified value.static boolean
shouldAskToAnalyze
(Program program) Returns true if the program does not contain the analyzed flag.
-
Method Details
-
getCurrentProgram
returns the current program, given a tool, if a program is opened; otherwise returns null. -
shouldAskToAnalyze
Returns true if the program does not contain the analyzed flag. The assumption is that a non-null value means that the user has already made a decision about analyzing.- Parameters:
program
- the program to check for the property- Returns:
- true if the program does not contain the analyzed flag
-
removeAnalyzedFlag
Removes the analyzed flag from the program properties. With this property removed, the user will be prompted to analyze the program the next time it is opened.- Parameters:
program
- the program containing the property to be removed
-
setAnalyzedFlag
Sets the analyzed flag to the specified value.- Parameters:
program
- the program to set propertyanalyzed
- the analyzed flag
-