#include <catch2/catch_session.hpp>
#include <catch2/catch_test_macros.hpp>
#include "code.h"
#include "neuron.h"
#include "nrnmpi.h"
#include "ocfunc.h"
#include "section.h"
#include "multicore.h"
#include <exception>
Go to the source code of this file.
◆ ivocmain_session()
int ivocmain_session |
( |
int |
argc, |
|
|
const char ** |
argv, |
|
|
const char ** |
env, |
|
|
int |
start_session |
|
) |
| |
This used to be ivocmain, the main entrypoint to the HOC interpreter.
ivocmain_session parses command line argument, calls of initialization functions and drops into an interactive HOC session. This function is called for example by the "real main" in nrnmain.cpp
, but can be also called from other external user applications that use NEURON. Additionally to the original implemenation a new parameter start_session
was introduced to control whether an interactive HOC session shoudl be started or simply NEURON and all data structures be initialized and control returned to the caller.
- Note
env
argument should not be used as it might become invalid
- Parameters
-
argc | argument count as found in C/C++ main functions |
argv | argument vector as found in C/C++ main functions |
env | environment variable array as optionally found in main functions. |
start_session | set to 1 for default behavior (drop into interactive HOC session otherwise set to 0. If set to 1, but compiled with python support this function will still directly return (since in that mode we don't need an interactive HOC session either. |
- Returns
- 0 on success, otherwise error code.
Definition at line 361 of file ivocmain.cpp.
◆ main()
int main |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
◆ modl_reg()
◆ nrn_main_launch
◆ nrn_nobanner_