FEDEM Solver  R8.0
Source code of the dynamics solver
Macros | Functions | Variables
cmdLineArgInitStd.C File Reference

This file contains C++ code for setting up the command-line handler. More...

#include "FFaLib/FFaCmdLineArg/FFaCmdLineArg.H"
#include "FFaLib/FFaDefinitions/FFaAppInfo.H"
#include "FFaLib/FFaOS/FFaFilePath.H"
#include "Admin/FedemAdmin.H"
#include <iostream>
#include <unistd.h>
#include <stdio.h>
Include dependency graph for cmdLineArgInitStd.C:

Macros

#define ADDOPTION   FFaCmdLineArg::instance()->addOption
 Convenience macro. More...
 

Functions

void resetCWD ()
 Resets the current working directory after the solver has finished. More...
 
void cmdLineArgInitStd (int argc, char **argv)
 Initializes the command-line parser. More...
 
void readOptionFilesStd (const char *program)
 Reads the command-line options files. More...
 

Variables

static char * oldwd = NULL
 Previous working directory, to return to after finished. More...
 

Detailed Description

This file contains C++ code for setting up the command-line handler.

The file contains some global functions that are invoked by the C++ main programs for initializing the command-line argument handler, printing of help texts to console, etc.

Macro Definition Documentation

◆ ADDOPTION

#define ADDOPTION   FFaCmdLineArg::instance()->addOption

Convenience macro.

Function Documentation

◆ cmdLineArgInitStd()

void cmdLineArgInitStd ( int  argc,
char **  argv 
)

Initializes the command-line parser.

Parameters
[in]argcNumber of command-line arguments (including program name)
[in]argvList of command-line arguments

This function also defines some general command-line options that are common for all solver modules.

◆ readOptionFilesStd()

void readOptionFilesStd ( const char *  program)

Reads the command-line options files.

Parameters
[in]programName of the program module

The help text containing all available command-line options may also be printed to console if the -help (or -helpAll) is specified.

◆ resetCWD()

void resetCWD ( )

Resets the current working directory after the solver has finished.

Variable Documentation

◆ oldwd

char* oldwd = NULL
static

Previous working directory, to return to after finished.