TheClassic Intelligent Evidence Gathering Guide provides an introduction to scripts and question groups within Classic IEG. The database can be populated by using the Classic IEG editor to define these scripts. However, support is also provided for representing the groups and scripts as xml data. Although the files are consistent with well and fully formed xml, the file extensions are modified to denote the contents as script (.sx) and question group(.gx). These xml data files can be created and manipulated directly to allow for the synchronization between these files, and the database. A number of extra targets have been introduced to enable this:
v importieg- This target imports all IEG files in a specified directory to the database. This command takes two parameters - directory and overwrite.
directory- This parameter denotes the directory from which IEG scripts and question groups are imported.
overwrite (Optional)- This is an optional flag with the default value asfalse, indicating whether the database should be overwritten if an imported script or group already exists.
For example:
Where<SERVER_DIR>/components/core/ieg denotes the path to the import directory and true denotes the flag to overwrite the database if a file already exists.
v importiegscript- This target imports an IEG script from a file system to the database. This command takes two parameters - IEG file and overwrite.
ieg.file- This parameter denotes the full path of the IEG script to be imported.
overwrite (Optional)- This is an optional flag with the default value asfalse, indicating whether the database should be overwritten if the script already exists.
For example:
ant validateruleset
-Drulesets.file=
<SERVER_DIR>/components/core/rulesets/PRODUCT_1.xml ant validateruleset
-Drulesets.file=
<SERVER_DIR>/components/core/rulesets/PRODUCT_1.xml -Dschema.file=C:/Rules/ruleset.xsd
build importieg -Ddirectory=
<
SERVER_DIR>/components/core/ieg -Doverwrite=true
build importiegscript -Dieg.file=
<
SERVER_DIR>/components/core/ieg/PRODUCT_1.sx -Doverwrite=true
Where<SERVER_DIR>/components/core/ieg/PRODUCT_1.sxdenotes the path of the script definition file and 'true' denotes the flag to overwrite the database if the question script already exists.
v importiegcomponent- This target imports all IEG data (IEG scripts and question groups) from theiegsubdirectory of a specified component to the database. This command takes two parameters - component and overwrite.
component- This parameter denotes the component from which to import all IEG data to the database.
overwrite (Optional)- This is an optional flag with the default value asfalse, indicating whether the database should be overwritten if the IEG data already exists.
For example:
Wherecoredenotes the path of the component and 'true' denotes the flag to overwrite the database if the question script already exists.
v importiegsubdirs- This target imports all IEG data (IEG scripts and question groups) from theiegsubdirectory of subdirectories of a specified directory to the database. This command takes two parameters - directory and overwrite.
This target is used when it is required to import IEG data from multiple components.
directory- This parameter denotes the directory whose subdirectories will be searched for IEG data to import to the database.
overwrite (Optional)- This is an optional flag with the default value asfalse, indicating whether the database should be overwritten if the IEG data already exists.
For example:
Where<SERVER_DIR>/componentsdenotes the path of the directory and 'true' denotes the flag to overwrite the database if the IEG data already exists.
v importquestiongroup- This target imports an IEG question group from a file system to the database. This command takes two parameters - IEG file and overwrite.
ieg.file- This parameter denotes the full path of the IEG question group to be imported.
overwrite (Optional)- This is an optional flag with the default value asfalse, indicating whether the database should be overwritten if IEG import data already exists.
For example:
build importquestiongroup -Dieg.file=
<SERVER_DIR>/components/core/ieg/
PRODUCT_1.gx -Doverwrite=true
Where<SERVER_DIR>/components/core/ieg/PRODUCT_1.gxdenotes the path of the question group definition file and true denotes the flag to overwrite the
database, if the question group already exists.
build importiegcomponent -Dcomponent=core -Doverwrite=true
build importiegsubdirs
-Ddirectory=<SERVER_DIR>/components -Doverwrite=true
v exportiegscript- This target exports a script definition (.sx file) from a database to the file system. This command takes two parameters - scriptid and
component. Exported scripts will be saved and named as [specified rulesetid].sx in the <SERVER_DIR>/components/[specified component]/iegfolder.
scriptid- Identifier of the script that is to be exported from the database.
component- Name of the component to which the script has to be exported (copied).
For example:
Where 'PRODUCT_1' denotes the identifier of the script that is to be exported from the database and 'core' denotes the name of the component to which the script has to be exported (copied).
v exportiegscripttodir- This target exports a script definition (.sx file) from a database to the file system. This command takes two parameters - scriptid and exportdirectory. Exported scripts will be saved and named as [specified rulesetid].sx in the specified export directory.
scriptid- Identifier of the script that is to be exported from the database.
exportdirectory- Full path of the directory to which the script has to be exported (copied).
For example:
Where 'PRODUCT_1' denotes the identifier of the script that is to be exported from the database and 'C:/exportedscripts' denotes path to the directory to which the script has to be exported (copied).
v exportfulliegscript- This target exports a specific script definition (.sx file) and its associated group definitions(.gx files) from the database to the file system. If any of the files exported are read only, a warning will be reported and the file will not be overwritten. The exportfulliegscript command takes two parameters - scriptid and component. The exported script is named as [specified scriptid].sx and the associated question groups are saved and named as
[associated questiongroupid].gx in the<SERVER_DIR>/components/[specified component]/iegfolder.
scriptid- Identifier of the script that is to be exported from the database.
component- Name of the component to which the script has to be exported (copied).
For example:
Where 'PRODUCT_1' denotes the identifier of the script that is to be exported from the database and 'core' denotes the name of the component to which the script and its associated question groups has to be exported (copied).
v exportfulliegscripttodir- This target exports a specific script definition (.sx file) and its associated group definitions(.gx files) from the database to the file system. If any of the files exported are read only, a warning will be reported and build exportiegscript
-Dscriptid=PRODUCT_1 -Dcomponent=core
build exportiegscripttodir -Dscriptid=PRODUCT_1
-Dexportdirectory=C:/exportedscripts
build exportiegscript -Dscriptid=PRODUCT_1 -Dcomponent=core
the file will not be overwritten. The exportfulliegscripttodir command takes two parameters - scriptid and exportdirectory. The exported script is named as [specified scriptid].sx and the associated question groups are saved and named as [associated questiongroupid].gx in the specified export directory.
scriptid- Identifier of the script that is to be exported from the database.
exportdirectory- Full path of the directory to which the script has to be exported (copied).
For example:
Where 'PRODUCT_1' denotes the identifier of the script that is to be exported from the database and 'C:/exportedscripts' denotes the path to the directory to which the script and its associated question groups has to be exported (copied).
v exportquestiongroup- This target exports a question group definition (.gx file) from database to the file system. This command takes two parameters - groupid and component. Exported question groups will be saved as [specified
rulesetid].gx in<SERVER_DIR>/components/[specified component]/iegfolder.
groupid- Identifier of the question group that is to be exported from the database.
component- Name of the component to which the rule set has to be exported (copied).
For example:
build exportquestiongroup -Dgroupid=PRODUCT_1 -Dcomponent=core
Where 'PRODUCT_1' denotes the identifier of the question group that is to be exported from the database and 'core' denotes the name of the component to which the question group has to be exported (copied).
v listiegscripts- Produces a list of all the IEG scripts available in the database.
v listquestiongroups- Produces a list of all the question groups available in the database.
v migrateiegscript- Migrate a Classic IEG script definition to an IEG2 script definition (use -Dscriptfilename= -Dinputdir= -Doutputdir=).
scriptfilename- denotes the name of the file to import.
inputdir- denotes the directory to import from.
outputdir- denotes the directory to write the migrated script to.
v validatealliegscripts- Validates the IEG scripts.