32 #include "dcmtk/config/osconfig.h"
34 #include "dcmtk/ofstd/ofcond.h"
35 #include "dcmtk/dcmdata/dcxfer.h"
81 const char *appl_name);
131 const char *filename = NULL);
195 OFCmdUnsignedInt itempad_option;
OFCommandLine * cmd
helper class for commandline parsing
int startProvidingService()
This function looks at commandline options and decides what to do.
OFCondition backupFile(const char *file_name)
Backup given file from file to file.bak.
E_TransferSyntax input_xfer_option
denotes the expected transfersyntax
static void splitPathAndValue(const OFString &whole, OFString &path, OFString &value)
This function splits a modify option (inclusive value) as found on commandline into to parts (path an...
OFBool update_metaheader_uids_option
if false, metaheader UIDs are not updated when related dataset UIDs change
This class encapsulates data structures and operations for modifying Dicom files from the commandline...
support class for console applications.
void parseNonJobOptions()
Checks for non-job commandline options like –debug etc.
OFBool no_reservation_checks
If true, it is not checked whether there is a corresponding private reservation during insertion of p...
class reflecting a modify operation (called Job in this context)
MdfDatasetManager * ds_man
dataset manager that is used for modify operations
E_EncodingType enctype_option
write explicit or implicit length encoding
int executeJob(const MdfJob &job, const char *filename=NULL)
Executes given modify job.
OFCmdUnsignedInt filepad_option
internal padding variables
E_GrpLenEncoding glenc_option
option for group length recalcing
OFBool no_backup_option
if true, no backup is made before modifying a file
OFBool output_dataset_option
decides whether to with/without metaheader
MdfJob & operator=(const MdfJob &j)
private undefined copy constructor
~MdfConsoleEngine()
Destructor.
static OFBool jobOptionExpectsParameters(const OFString &job)
Checks whether given job expects more values on commandline, e.
OFBool ignore_errors_option
ignore errors option
OFBool ignore_missing_tags_option
if true, 'tag not found' errors are treated as being successful for modify and erase operations ...
This class encapsulates data structures and operations for modifying Dicom files. ...
OFBool operator==(const MdfJob &j) const
Comparison operator between Jobs.
MdfConsoleEngine(int argc, char *argv[], const char *appl_name)
Constructor.
OFList< MdfJob > * jobs
list of jobs to be executed
OFBool ignore_un_modifies
If enabled, any value modifications of UN leaf elements are not executed.
OFCondition loadFile(const char *filename)
Backup and load file into internal MdfDatasetManager.
E_TransferSyntax output_xfer_option
denotes the transfer syntax that should be written
E_FileReadMode read_mode_option
read file with or without metaheader
a simple string class that implements a subset of std::string.
OFList< OFString > * files
list of files to be modified
OFCondition restoreFile(const char *filename)
Restore given file from file.bak to original (without .bak)
OFConsoleApplication * app
helper class for console applications
handles command line arguments.
E_PaddingEncoding padenc_option
padding output
MdfConsoleEngine & operator=(const MdfConsoleEngine &)
private undefined assignment operator
General purpose class for condition codes.
void parseCommandLine()
Parses commandline options into corresponding file- and job lists and enables debug/verbose mode...