You can use the jadclient non-GUI client application to automate the generation and extraction of an existing C# exposure, passing command line arguments after the
The jadclient non-GUI client application, see "
"
Generating an exposure using the C# Exposure wizard in the JADE development environment, see "Generating the C# Classes", earlier in this chapter.
Extracting a C# exposure from the JADE development environment, see "Extracting a C# Exposure", earlier in this chapter.
To generate and extract an existing C# exposure as a non-GUI application, specify the following parameters in the jadclient program command line. The parameters following startAppParameters must be specified in the following order. (Parameters within brackets ([]) are optional.)
jadclient schema=JadeSchema app=CSharpGenerator path=database-path ini=JADE-initialization-file-path-and name startAppParameters schemaName=top‑most‑schema‑in‑which‑classes‑defined exposureName=existing‑exposure‑name outputFolderName=absolute‑path‑and‑name‑of‑output‑directory [shouldGenerateProjFile=true] [shouldGenerateAppConfigFile=true dataSourceConfigParam=absolute‑path‑of‑the‑database‑control‑file configFileConfigParam=name‑and‑path‑of‑JADE‑initialization‑file singleUserConfigParam=true|false schemaConfigParam=name‑of‑user‑defined‑schema‑in‑the‑database [applicationConfigParam=an‑application‑defined‑in‑schemaName‑parameter]]
The parameters that you can specify after the
Parameter | Description |
---|---|
schemaName | Name of the highest schema in the hierarchy whose classes are to be included in the C# exposure generation |
exposureName | Name your existing C# exposure |
outputFolderName |
Name and absolute path of the directory to which the C# classes will be written |
[shouldGenerateProjFile] |
False, if you do not want a sample .csproj file generated |
[shouldGenerateAppConfigFile |
False, if you do not want a sample .config file generated |
dataSourceConfigParam | Absolute path of the folder containing the database control file (_control.datpath, when the shouldGenerateAppConfigFile parameter is specified with a value of true |
configFileConfigParam |
Name and absolute path of the JADE initialization file, when the shouldGenerateAppConfigFile parameter is specified with a value of true |
singleUserConfigParam |
True or false (the default value), to indicate if you want to sign on to the JADE database in single user mode or multiuser mode, respectively, when the shouldGenerateAppConfigFile parameter is specified with a value of true |
schemaConfigParam | Name of the user‑defined schema in the database |
[applicationConfigParam]] |
Optionally specifies the name of the default application in the database specified in the schemaName parameter (defaults to RootSchemaApp), when the shouldGenerateAppConfigFile parameter is specified with a value of true |
The following is an example of the jadclient command line that generates and extracts a C# exposure.
jadclient schema=JadeSchema app=CSharpGenerator path=c:\jade\system ini=c:\jade\system\jade.ini startAppParameters schemaName=ErewhonInvestmentsModelSchema exposureName=DocCsharpExample outputFolderName=c:\jade\csharp shouldGenerateProjFile=true shouldGenerateAppConfigFile=true dataSourceConfigParam=c:\jade\system configFileConfigParam=c:\jade\system\jade.ini singleUserConfigParam=false schemaConfigParam=DocCsharpDemoSchema applicationConfigParam=CsharpConnectionApp
When specifying C# generate and extract parameters:
Enclose command line arguments that contain spaces in double ("") or single ('') quotation marks.
The jadclient program treats processing arguments enclosed in double ("") or single ('') quotation marks after the startAppParameters parameter as single-string entries in the huge string array. The handling of strings in this huge string array is application-specific. For example, path= "program files" is treated as a two-string entry and "path= program files" is treated as a one-string entry. How these entries are handled is determined by your application.
The parameters are case-sensitive (that is, multiple is a valid argument but Multiple is not).
You cannot use the jadclient program to automate the generation and extraction of C# files from a deployed environment, as the internal system-only JadeSchema schema from which batch generate and extract actions are run is not present in deployed databases.