#include "StdString.h"
#include <iostream>
#include <fstream>
#include "dbscStrings.h"
#include "messagePrinting.h"
#include "DBSchemaGenerator.h"
#include "MetadataLoader.h"
Include dependency graph for dbscMain.cpp:
Defines | |
#define | DEFAULT_CREATE_SCRIPT_NAME "create.sql" |
#define | DEFAULT_DROP_SCRIPT_NAME "drop.sql" |
#define | DEFAULT_EXPLAIN_SCRIPT_NAME "explain.sql" |
Functions | |
void | showProgramInfo () |
void | showHelpHint () |
void | showHelp () |
int | setSourceFile (char *arg, CStdString &inputFile, bool useMissingParameterMsg=0, bool printMessage=1) |
int | parseCommandLine (int argc, char **argv, CStdString &inputFile, CStdString &createScriptFile, CStdString &dropScriptFile, CStdString &explainScriptFile, bool &generateCreationComments) |
int | processMetadata (const char *inputFile, const char *createScriptFile, const char *dropScriptFile, const char *explainScriptFile, bool generateCreationComments) |
int | main (int argc, char **argv) |
|
Default name of DB schema creation script (used if user specifies "-c" switch without filename). |
|
Default name of DB schema drop script (used if user specifies "-d" switch without filename). |
|
Default name of explain plan script (used if user specifies "-e" switch without filename). |
|
Shows program info (DBSC_PROGRAM_INFO).
|
|
Shows hint how to get help (DBSC_HELP_HINT).
|
|
Shows help - IOPC DBSC usage (DBSC_HELP).
|
|
Helper function - tests whether
|
|
Parses IOPC DBSC's command line (
|
|
Processes the metadata, creates desired scripts Loads the metadata using XMLMetadataLoader, using DBSchemaGenerator checks whether the metadata are valid (DBSchemaGenerator::createInheritanceHierarchy(), DBSchemaGenerator::checkInheritanceHierarchy()) and generates missing values such as DB table names (DBSchemaGenerator::generateMissingValues(), DBSchemaGenerator::generateColumnTypes()). Then generates all the scripts for which non empty filename was given (DBSchemaGenerator::generateCreationScript(), DBSchemaGenerator::generateDropScript(), DBSchemaGenerator::generateExplainScript()).
|
|
Main function of IOPC DBSC.
Parses its command line (
|