w11 - cpp
0.794
Backend server for Rlink and w11
Loading...
Searching...
No Matches
Rlinktpp_Init.cpp
Go to the documentation of this file.
1
// $Id: Rlinktpp_Init.cpp 1186 2019-07-12 17:49:59Z mueller $
2
// SPDX-License-Identifier: GPL-3.0-or-later
3
// Copyright 2011-2018 by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4
//
5
// Revision History:
6
// Date Rev Version Comment
7
// 2014-08-22 584 1.0.6 use nullptr
8
// 2013-02-10 485 1.0.5 remove Tcl_InitStubs()
9
// 2013-01-27 478 1.0.4 add rlinkport
10
// 2013-01-12 474 1.0.3 add rlinkserver
11
// 2011-03-20 372 1.0.2 renamed ..tcl -> ..tpp
12
// 2011-03-19 371 1.0.1 moved Bvi into librtoolstcl
13
// 2011-03-14 370 1.0 Initial version
14
// 2011-02-11 360 0.1 First draft
15
// ---------------------------------------------------------------------------
16
21
#include "tcl.h"
22
23
#include <stdexcept>
24
25
#include "
librtcltools/RtclClassOwned.hpp
"
26
#include "
RtclRlinkPort.hpp
"
27
#include "
RtclRlinkConnect.hpp
"
28
#include "
RtclRlinkServer.hpp
"
29
30
using namespace
std;
31
using namespace
Retro
;
32
33
extern
"C"
int
Rlinktpp_Init
(Tcl_Interp* interp);
// -Wmissing-prototypes fix
34
35
//------------------------------------------+-----------------------------------
36
extern
"C"
int
Rlinktpp_Init
(Tcl_Interp* interp)
37
{
38
int
irc;
39
40
// declare package name and version
41
irc = Tcl_PkgProvide(interp,
"rlinktpp"
,
"1.0.0"
);
42
if
(irc != TCL_OK)
return
irc;
43
44
try
{
45
// register class commands
46
RtclClassOwned<RtclRlinkPort>::CreateClass
(interp,
"rlinkport"
,
47
"RlinkPort"
);
48
RtclClassOwned<RtclRlinkConnect>::CreateClass
(interp,
"rlinkconnect"
,
49
"RlinkConnect"
);
50
RtclClassOwned<RtclRlinkServer>::CreateClass
(interp,
"rlinkserver"
,
51
"RlinkServer"
);
52
return
TCL_OK;
53
54
}
catch
(exception& e) {
55
Tcl_AppendResult(interp,
"-E: exception caught in Rlinktpp_Init: '"
,
56
e.what(),
"'"
,
nullptr
);
57
}
58
return
TCL_ERROR;
59
}
60
Rlinktpp_Init
int Rlinktpp_Init(Tcl_Interp *interp)
Definition:
Rlinktpp_Init.cpp:36
RtclClassOwned.hpp
RtclRlinkConnect.hpp
RtclRlinkPort.hpp
RtclRlinkServer.hpp
Retro::RtclClassOwned::CreateClass
static void CreateClass(Tcl_Interp *interp, const char *name, const std::string &type)
FIXME_docs.
Definition:
RtclClassOwned.ipp:71
Retro
Declaration of class ReventLoop.
Definition:
ReventLoop.cpp:47
librlinktpp
Rlinktpp_Init.cpp
Generated on Thu Feb 9 2023 12:40:57 for w11 - cpp by
1.9.6