Autopsy  4.19.3
Graphical digital forensics platform for The Sleuth Kit and other tools.
Classes | Public Member Functions | Static Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor Class Reference

Inherits OptionProcessor.

Classes

enum  ProcessState
 

Public Member Functions

void addPropertyChangeListener (PropertyChangeListener l)
 
String getDefaultArgument ()
 
synchronized ProcessState getState ()
 
synchronized boolean isRunFromCommandLine ()
 
void removePropertyChangeListener (PropertyChangeListener l)
 
synchronized void runFromCommandLine (boolean runFromCommandLine)
 

Static Public Attributes

static String PROCESSING_COMPLETED = "command line process completed"
 
static String PROCESSING_STARTED = "command line process started"
 

Protected Member Functions

Set< Option > getOptions ()
 
void process (Env env, Map< Option, String[]> values) throws CommandException
 

Private Member Functions

void handleError (String errorMessage) throws CommandException
 
synchronized void setState (ProcessState state)
 

Private Attributes

final Option addDataSourceCommandOption = Option.withoutArgument('a', "addDataSource")
 
final Option caseBaseDirOption = Option.requiredArgument('o', "caseBaseDir")
 
final Option caseNameOption = Option.requiredArgument('n', "caseName")
 
final Option caseTypeOption = Option.requiredArgument('t', "caseType")
 
PropertyChangeSupport changes = new PropertyChangeSupport(this)
 
final List< CommandLineCommand > commands = new ArrayList<>()
 
final Option createCaseCommandOption = Option.withoutArgument('c', "createCase")
 
final Option dataSourceObjectIdOption = Option.requiredArgument('i', "dataSourceObjectId")
 
final Option dataSourcePathOption = Option.requiredArgument('s', "dataSourcePath")
 
final Option defaultArgument = Option.defaultArguments()
 
String defaultArgumentValue = null
 
final Option generateReportsOption = Option.optionalArgument('g', "generateReports")
 
final Option listAllDataSourcesCommandOption = Option.withoutArgument('l', "listAllDataSources")
 
final Option listAllIngestProfileOption = Option.withoutArgument('p', "listAllIngestProfiles")
 
boolean runFromCommandLine = false
 
final Option runIngestCommandOption = Option.optionalArgument('r', "runIngest")
 
ProcessState state = ProcessState.NOT_STARTED
 

Static Private Attributes

static final Logger logger = Logger.getLogger(CommandLineOptionProcessor.class.getName())
 

Detailed Description

This class can be used to add command line options to Autopsy

Definition at line 45 of file CommandLineOptionProcessor.java.

Member Function Documentation

void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.addPropertyChangeListener ( PropertyChangeListener  l)
String org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.getDefaultArgument ( )

Return the value of the default argument.

Returns
The default argument value or null if one was not set.

Definition at line 348 of file CommandLineOptionProcessor.java.

Referenced by org.sleuthkit.autopsy.casemodule.StartupWindowProvider.getDefaultArgument().

Set<Option> org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.getOptions ( )
protected

Definition at line 83 of file CommandLineOptionProcessor.java.

synchronized ProcessState org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.getState ( )
void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.handleError ( String  errorMessage) throws CommandException
private

Send the error message to the log file and create the exception.

Parameters
errorMessage
Exceptions
CommandException

Definition at line 368 of file CommandLineOptionProcessor.java.

synchronized boolean org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.isRunFromCommandLine ( )

Returns whether Autopsy should be running in command line mode or not.

Returns
true if running in command line mode, false otherwise.

Definition at line 335 of file CommandLineOptionProcessor.java.

Referenced by org.sleuthkit.autopsy.casemodule.StartupWindowProvider.isRunningFromCommandLine().

void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.process ( Env  env,
Map< Option, String[]>  values 
) throws CommandException
protected
void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.removePropertyChangeListener ( PropertyChangeListener  l)

Definition at line 377 of file CommandLineOptionProcessor.java.

synchronized void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.runFromCommandLine ( boolean  runFromCommandLine)

Definition at line 339 of file CommandLineOptionProcessor.java.

synchronized void org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.setState ( ProcessState  state)
private

Definition at line 382 of file CommandLineOptionProcessor.java.

Member Data Documentation

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.addDataSourceCommandOption = Option.withoutArgument('a', "addDataSource")
private

Definition at line 54 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.caseBaseDirOption = Option.requiredArgument('o', "caseBaseDir")
private

Definition at line 50 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.caseNameOption = Option.requiredArgument('n', "caseName")
private

Definition at line 48 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.caseTypeOption = Option.requiredArgument('t', "caseType")
private

Definition at line 49 of file CommandLineOptionProcessor.java.

PropertyChangeSupport org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.changes = new PropertyChangeSupport(this)
private

Definition at line 70 of file CommandLineOptionProcessor.java.

final List<CommandLineCommand> org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.commands = new ArrayList<>()
private

Definition at line 63 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.createCaseCommandOption = Option.withoutArgument('c', "createCase")
private

Definition at line 51 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.dataSourceObjectIdOption = Option.requiredArgument('i', "dataSourceObjectId")
private

Definition at line 53 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.dataSourcePathOption = Option.requiredArgument('s', "dataSourcePath")
private

Definition at line 52 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.defaultArgument = Option.defaultArguments()
private

Definition at line 59 of file CommandLineOptionProcessor.java.

String org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.defaultArgumentValue = null
private

Definition at line 68 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.generateReportsOption = Option.optionalArgument('g', "generateReports")
private

Definition at line 57 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.listAllDataSourcesCommandOption = Option.withoutArgument('l', "listAllDataSources")
private

Definition at line 56 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.listAllIngestProfileOption = Option.withoutArgument('p', "listAllIngestProfiles")
private

Definition at line 58 of file CommandLineOptionProcessor.java.

final Logger org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.logger = Logger.getLogger(CommandLineOptionProcessor.class.getName())
staticprivate

Definition at line 47 of file CommandLineOptionProcessor.java.

String org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.PROCESSING_COMPLETED = "command line process completed"
static
String org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.PROCESSING_STARTED = "command line process started"
static

Definition at line 71 of file CommandLineOptionProcessor.java.

boolean org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.runFromCommandLine = false
private

Definition at line 61 of file CommandLineOptionProcessor.java.

final Option org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.runIngestCommandOption = Option.optionalArgument('r', "runIngest")
private

Definition at line 55 of file CommandLineOptionProcessor.java.

ProcessState org.sleuthkit.autopsy.commandlineingest.CommandLineOptionProcessor.state = ProcessState.NOT_STARTED
private

Definition at line 80 of file CommandLineOptionProcessor.java.


The documentation for this class was generated from the following file:

Copyright © 2012-2022 Basis Technology. Generated on: Tue Oct 4 2022
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.