Add commands to the interpreter that take the AnalysisBuilder as clientData.
| 71 | // Add commands to the interpreter that take the AnalysisBuilder as clientData. |
| 72 | // |
| 73 | int |
| 74 | G3_AddTclAnalysisAPI(Tcl_Interp *interp, BasicModelBuilder& context) |
| 75 | { |
| 76 | BasicAnalysisBuilder *builder = new BasicAnalysisBuilder(context); |
| 77 | Tcl_CreateCommand(interp, "wipeAnalysis", &wipeAnalysis, builder, nullptr); |
| 78 | Tcl_CreateCommand(interp, "_clearAnalysis", &TclCommand_clearAnalysis, builder, nullptr); |
| 79 | |
| 80 | Tcl_CreateCommand(interp, "numberer", TclCommand_setNumberer, builder, nullptr); |
| 81 | |
| 82 | Tcl_CreateCommand(interp, "responseSpectrumAnalysis", &OpenSees::responseSpectrumAnalysis, nullptr, nullptr); |
| 83 | |
| 84 | |
| 85 | static int ncmd = sizeof(tcl_analysis_cmds)/sizeof(char_cmd); |
| 86 | for (int i = 0; i < ncmd; ++i) |
| 87 | Tcl_CreateCommand(interp, |
| 88 | tcl_analysis_cmds[i].name, |
| 89 | tcl_analysis_cmds[i].func, |
| 90 | (ClientData) builder, nullptr); |
| 91 | |
| 92 | return TCL_OK; |
| 93 | } |
| 94 | |
| 95 | // |
| 96 | // command invoked to build an Analysis object |
no outgoing calls
no test coverage detected