Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
uniset2
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
UniSet project repositories
uniset2
Commits
15a2734d
Commit
15a2734d
authored
Mar 05, 2013
by
Pavel Vainerman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Перенегерил обёртки (xxx_wrap.cxx) для python bindings новым swig
parent
0c400359
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
94 additions
and
60 deletions
+94
-60
UExceptions_wrap.cxx
python/lib/pyUniSet/UExceptions_wrap.cxx
+43
-26
UInterface_wrap.cxx
python/lib/pyUniSet/UInterface_wrap.cxx
+0
-0
UModbus_wrap.cxx
python/lib/pyUniSet/UModbus_wrap.cxx
+49
-32
pyUExceptions.py
python/lib/pyUniSet/pyUExceptions.py
+1
-1
pyUModbus.py
python/lib/pyUniSet/pyUModbus.py
+1
-1
No files found.
python/lib/pyUniSet/UExceptions_wrap.cxx
View file @
15a2734d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.
4
* Version 2.0.
8
*
*
* This file is not intended to be easily readable and contains a number of
* This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
* coding conventions designed to improve portability and efficiency. Do not make
...
@@ -757,6 +757,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
...
@@ -757,6 +757,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
...
@@ -1223,7 +1224,7 @@ SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
...
@@ -1223,7 +1224,7 @@ SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetErrorMsg
(
PyObject
*
errtype
,
const
char
*
msg
)
{
SWIG_Python_SetErrorMsg
(
PyObject
*
errtype
,
const
char
*
msg
)
{
SWIG_PYTHON_THREAD_BEGIN_BLOCK
;
SWIG_PYTHON_THREAD_BEGIN_BLOCK
;
PyErr_SetString
(
errtype
,
(
char
*
)
msg
);
PyErr_SetString
(
errtype
,
msg
);
SWIG_PYTHON_THREAD_END_BLOCK
;
SWIG_PYTHON_THREAD_END_BLOCK
;
}
}
...
@@ -1242,7 +1243,11 @@ SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
...
@@ -1242,7 +1243,11 @@ SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetConstant
(
PyObject
*
d
,
PyObject
*
public_interface
,
const
char
*
name
,
PyObject
*
obj
)
{
SWIG_Python_SetConstant
(
PyObject
*
d
,
PyObject
*
public_interface
,
const
char
*
name
,
PyObject
*
obj
)
{
#if PY_VERSION_HEX < 0x02030000
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
#else
PyDict_SetItemString
(
d
,
name
,
obj
);
#endif
Py_DECREF
(
obj
);
Py_DECREF
(
obj
);
if
(
public_interface
)
if
(
public_interface
)
SwigPyBuiltin_AddPublicSymbol
(
public_interface
,
name
);
SwigPyBuiltin_AddPublicSymbol
(
public_interface
,
name
);
...
@@ -1252,7 +1257,11 @@ SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *nam
...
@@ -1252,7 +1257,11 @@ SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *nam
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetConstant
(
PyObject
*
d
,
const
char
*
name
,
PyObject
*
obj
)
{
SWIG_Python_SetConstant
(
PyObject
*
d
,
const
char
*
name
,
PyObject
*
obj
)
{
#if PY_VERSION_HEX < 0x02030000
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
#else
PyDict_SetItemString
(
d
,
name
,
obj
);
#endif
Py_DECREF
(
obj
);
Py_DECREF
(
obj
);
}
}
...
@@ -1573,7 +1582,7 @@ SwigPyObject_repr(SwigPyObject *v, PyObject *args)
...
@@ -1573,7 +1582,7 @@ SwigPyObject_repr(SwigPyObject *v, PyObject *args)
#endif
#endif
{
{
const
char
*
name
=
SWIG_TypePrettyName
(
v
->
ty
);
const
char
*
name
=
SWIG_TypePrettyName
(
v
->
ty
);
PyObject
*
repr
=
SWIG_Python_str_FromFormat
(
"<Swig Object of type '%s' at %p>"
,
name
,
(
void
*
)
v
);
PyObject
*
repr
=
SWIG_Python_str_FromFormat
(
"<Swig Object of type '%s' at %p>"
,
(
name
?
name
:
"unknown"
)
,
(
void
*
)
v
);
if
(
v
->
next
)
{
if
(
v
->
next
)
{
# ifdef METH_NOARGS
# ifdef METH_NOARGS
PyObject
*
nrep
=
SwigPyObject_repr
((
SwigPyObject
*
)
v
->
next
);
PyObject
*
nrep
=
SwigPyObject_repr
((
SwigPyObject
*
)
v
->
next
);
...
@@ -1777,8 +1786,10 @@ SwigPyObject_own(PyObject *v, PyObject *args)
...
@@ -1777,8 +1786,10 @@ SwigPyObject_own(PyObject *v, PyObject *args)
PyObject
*
val
=
0
;
PyObject
*
val
=
0
;
#if (PY_VERSION_HEX < 0x02020000)
#if (PY_VERSION_HEX < 0x02020000)
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"|O:own"
,
&
val
))
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"|O:own"
,
&
val
))
#el
se
#el
if (PY_VERSION_HEX < 0x02050000)
if
(
!
PyArg_UnpackTuple
(
args
,
(
char
*
)
"own"
,
0
,
1
,
&
val
))
if
(
!
PyArg_UnpackTuple
(
args
,
(
char
*
)
"own"
,
0
,
1
,
&
val
))
#else
if
(
!
PyArg_UnpackTuple
(
args
,
"own"
,
0
,
1
,
&
val
))
#endif
#endif
{
{
return
NULL
;
return
NULL
;
...
@@ -2473,23 +2484,29 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
...
@@ -2473,23 +2484,29 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
}
else
{
}
else
{
#if PY_VERSION_HEX >= 0x03000000
#if PY_VERSION_HEX >= 0x03000000
inst
=
PyBaseObject_Type
.
tp_new
((
PyTypeObject
*
)
data
->
newargs
,
Py_None
,
Py_None
);
inst
=
PyBaseObject_Type
.
tp_new
((
PyTypeObject
*
)
data
->
newargs
,
Py_None
,
Py_None
);
PyObject_SetAttr
(
inst
,
SWIG_This
(),
swig_this
);
if
(
inst
)
{
Py_TYPE
(
inst
)
->
tp_flags
&=
~
Py_TPFLAGS_VALID_VERSION_TAG
;
PyObject_SetAttr
(
inst
,
SWIG_This
(),
swig_this
);
Py_TYPE
(
inst
)
->
tp_flags
&=
~
Py_TPFLAGS_VALID_VERSION_TAG
;
}
#else
#else
PyObject
*
dict
=
PyDict_New
();
PyObject
*
dict
=
PyDict_New
();
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
if
(
dict
)
{
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
Py_DECREF
(
dict
);
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
Py_DECREF
(
dict
);
}
#endif
#endif
}
}
return
inst
;
return
inst
;
#else
#else
#if (PY_VERSION_HEX >= 0x02010000)
#if (PY_VERSION_HEX >= 0x02010000)
PyObject
*
inst
;
PyObject
*
inst
=
0
;
PyObject
*
dict
=
PyDict_New
();
PyObject
*
dict
=
PyDict_New
();
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
if
(
dict
)
{
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
Py_DECREF
(
dict
);
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
Py_DECREF
(
dict
);
}
return
(
PyObject
*
)
inst
;
return
(
PyObject
*
)
inst
;
#else
#else
PyInstanceObject
*
inst
=
PyObject_NEW
(
PyInstanceObject
,
&
PyInstance_Type
);
PyInstanceObject
*
inst
=
PyObject_NEW
(
PyInstanceObject
,
&
PyInstance_Type
);
...
@@ -2540,7 +2557,7 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
...
@@ -2540,7 +2557,7 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
SWIGINTERN
PyObject
*
SWIGINTERN
PyObject
*
SWIG_Python_InitShadowInstance
(
PyObject
*
args
)
{
SWIG_Python_InitShadowInstance
(
PyObject
*
args
)
{
PyObject
*
obj
[
2
];
PyObject
*
obj
[
2
];
if
(
!
SWIG_Python_UnpackTuple
(
args
,
(
char
*
)
"swiginit"
,
2
,
2
,
obj
))
{
if
(
!
SWIG_Python_UnpackTuple
(
args
,
"swiginit"
,
2
,
2
,
obj
))
{
return
NULL
;
return
NULL
;
}
else
{
}
else
{
SwigPyObject
*
sthis
=
SWIG_Python_GetSwigThis
(
obj
[
0
]);
SwigPyObject
*
sthis
=
SWIG_Python_GetSwigThis
(
obj
[
0
]);
...
@@ -2596,12 +2613,10 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f
...
@@ -2596,12 +2613,10 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f
assert
(
!
(
flags
&
SWIG_BUILTIN_TP_INIT
));
assert
(
!
(
flags
&
SWIG_BUILTIN_TP_INIT
));
robj
=
SwigPyObject_New
(
ptr
,
type
,
own
);
robj
=
SwigPyObject_New
(
ptr
,
type
,
own
);
if
(
clientdata
&&
!
(
flags
&
SWIG_POINTER_NOSHADOW
))
{
if
(
robj
&&
clientdata
&&
!
(
flags
&
SWIG_POINTER_NOSHADOW
))
{
PyObject
*
inst
=
SWIG_Python_NewShadowInstance
(
clientdata
,
robj
);
PyObject
*
inst
=
SWIG_Python_NewShadowInstance
(
clientdata
,
robj
);
if
(
inst
)
{
Py_DECREF
(
robj
);
Py_DECREF
(
robj
);
robj
=
inst
;
robj
=
inst
;
}
}
}
return
robj
;
return
robj
;
}
}
...
@@ -2816,7 +2831,7 @@ SwigPyObject_GetDesc(PyObject *self)
...
@@ -2816,7 +2831,7 @@ SwigPyObject_GetDesc(PyObject *self)
{
{
SwigPyObject
*
v
=
(
SwigPyObject
*
)
self
;
SwigPyObject
*
v
=
(
SwigPyObject
*
)
self
;
swig_type_info
*
ty
=
v
?
v
->
ty
:
0
;
swig_type_info
*
ty
=
v
?
v
->
ty
:
0
;
return
ty
?
ty
->
str
:
(
char
*
)
""
;
return
ty
?
ty
->
str
:
""
;
}
}
SWIGRUNTIME
void
SWIGRUNTIME
void
...
@@ -2873,6 +2888,7 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg
...
@@ -2873,6 +2888,7 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg
return
result
;
return
result
;
}
}
#ifdef SWIGPYTHON_BUILTIN
SWIGRUNTIME
int
SWIGRUNTIME
int
SWIG_Python_NonDynamicSetAttr
(
PyObject
*
obj
,
PyObject
*
name
,
PyObject
*
value
)
{
SWIG_Python_NonDynamicSetAttr
(
PyObject
*
obj
,
PyObject
*
name
,
PyObject
*
value
)
{
PyTypeObject
*
tp
=
obj
->
ob_type
;
PyTypeObject
*
tp
=
obj
->
ob_type
;
...
@@ -2881,15 +2897,15 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2881,15 +2897,15 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
descrsetfunc
f
;
descrsetfunc
f
;
int
res
;
int
res
;
#ifdef Py_USING_UNICODE
#
ifdef Py_USING_UNICODE
if
(
PyString_Check
(
name
))
{
if
(
PyString_Check
(
name
))
{
name
=
PyUnicode_Decode
(
PyString_AsString
(
name
),
PyString_Size
(
name
),
NULL
,
NULL
);
name
=
PyUnicode_Decode
(
PyString_AsString
(
name
),
PyString_Size
(
name
),
NULL
,
NULL
);
if
(
!
name
)
if
(
!
name
)
return
-
1
;
return
-
1
;
}
else
if
(
!
PyUnicode_Check
(
name
))
}
else
if
(
!
PyUnicode_Check
(
name
))
#else
#
else
if
(
!
PyString_Check
(
name
))
if
(
!
PyString_Check
(
name
))
#endif
#
endif
{
{
PyErr_Format
(
PyExc_TypeError
,
"attribute name must be string, not '%.200s'"
,
name
->
ob_type
->
tp_name
);
PyErr_Format
(
PyExc_TypeError
,
"attribute name must be string, not '%.200s'"
,
name
->
ob_type
->
tp_name
);
return
-
1
;
return
-
1
;
...
@@ -2924,6 +2940,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2924,6 +2940,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
Py_DECREF
(
name
);
Py_DECREF
(
name
);
return
res
;
return
res
;
}
}
#endif
#ifdef __cplusplus
#ifdef __cplusplus
...
@@ -2970,7 +2987,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
...
@@ -2970,7 +2987,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
#endif
#endif
#define SWIG_name "_pyUExceptions"
#define SWIG_name "_pyUExceptions"
#define SWIGVERSION 0x02000
4
#define SWIGVERSION 0x02000
8
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3711,8 +3728,7 @@ SWIG_InitializeModule(void *clientdata) {
...
@@ -3711,8 +3728,7 @@ SWIG_InitializeModule(void *clientdata) {
size_t
i
;
size_t
i
;
swig_module_info
*
module_head
,
*
iter
;
swig_module_info
*
module_head
,
*
iter
;
int
found
,
init
;
int
found
,
init
;
(
void
*
)
clientdata
;
clientdata
=
clientdata
;
/* check to see if the circular list has been setup, if not, set it up */
/* check to see if the circular list has been setup, if not, set it up */
if
(
swig_module
.
next
==
0
)
{
if
(
swig_module
.
next
==
0
)
{
...
@@ -4286,6 +4302,7 @@ SWIG_init(void) {
...
@@ -4286,6 +4302,7 @@ SWIG_init(void) {
m
=
Py_InitModule
((
char
*
)
SWIG_name
,
SwigMethods
);
m
=
Py_InitModule
((
char
*
)
SWIG_name
,
SwigMethods
);
#endif
#endif
md
=
d
=
PyModule_GetDict
(
m
);
md
=
d
=
PyModule_GetDict
(
m
);
(
void
)
md
;
SWIG_InitializeModule
(
0
);
SWIG_InitializeModule
(
0
);
...
...
python/lib/pyUniSet/UInterface_wrap.cxx
deleted
100644 → 0
View file @
0c400359
This source diff could not be displayed because it is too large. You can
view the blob
instead.
python/lib/pyUniSet/UModbus_wrap.cxx
View file @
15a2734d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 2.0.
4
* Version 2.0.
8
*
*
* This file is not intended to be easily readable and contains a number of
* This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
* coding conventions designed to improve portability and efficiency. Do not make
...
@@ -757,6 +757,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
...
@@ -757,6 +757,7 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
...
@@ -1223,7 +1224,7 @@ SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
...
@@ -1223,7 +1224,7 @@ SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetErrorMsg
(
PyObject
*
errtype
,
const
char
*
msg
)
{
SWIG_Python_SetErrorMsg
(
PyObject
*
errtype
,
const
char
*
msg
)
{
SWIG_PYTHON_THREAD_BEGIN_BLOCK
;
SWIG_PYTHON_THREAD_BEGIN_BLOCK
;
PyErr_SetString
(
errtype
,
(
char
*
)
msg
);
PyErr_SetString
(
errtype
,
msg
);
SWIG_PYTHON_THREAD_END_BLOCK
;
SWIG_PYTHON_THREAD_END_BLOCK
;
}
}
...
@@ -1242,7 +1243,11 @@ SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
...
@@ -1242,7 +1243,11 @@ SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetConstant
(
PyObject
*
d
,
PyObject
*
public_interface
,
const
char
*
name
,
PyObject
*
obj
)
{
SWIG_Python_SetConstant
(
PyObject
*
d
,
PyObject
*
public_interface
,
const
char
*
name
,
PyObject
*
obj
)
{
#if PY_VERSION_HEX < 0x02030000
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
#else
PyDict_SetItemString
(
d
,
name
,
obj
);
#endif
Py_DECREF
(
obj
);
Py_DECREF
(
obj
);
if
(
public_interface
)
if
(
public_interface
)
SwigPyBuiltin_AddPublicSymbol
(
public_interface
,
name
);
SwigPyBuiltin_AddPublicSymbol
(
public_interface
,
name
);
...
@@ -1252,7 +1257,11 @@ SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *nam
...
@@ -1252,7 +1257,11 @@ SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *nam
SWIGINTERN
void
SWIGINTERN
void
SWIG_Python_SetConstant
(
PyObject
*
d
,
const
char
*
name
,
PyObject
*
obj
)
{
SWIG_Python_SetConstant
(
PyObject
*
d
,
const
char
*
name
,
PyObject
*
obj
)
{
#if PY_VERSION_HEX < 0x02030000
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
PyDict_SetItemString
(
d
,
(
char
*
)
name
,
obj
);
#else
PyDict_SetItemString
(
d
,
name
,
obj
);
#endif
Py_DECREF
(
obj
);
Py_DECREF
(
obj
);
}
}
...
@@ -1573,7 +1582,7 @@ SwigPyObject_repr(SwigPyObject *v, PyObject *args)
...
@@ -1573,7 +1582,7 @@ SwigPyObject_repr(SwigPyObject *v, PyObject *args)
#endif
#endif
{
{
const
char
*
name
=
SWIG_TypePrettyName
(
v
->
ty
);
const
char
*
name
=
SWIG_TypePrettyName
(
v
->
ty
);
PyObject
*
repr
=
SWIG_Python_str_FromFormat
(
"<Swig Object of type '%s' at %p>"
,
name
,
(
void
*
)
v
);
PyObject
*
repr
=
SWIG_Python_str_FromFormat
(
"<Swig Object of type '%s' at %p>"
,
(
name
?
name
:
"unknown"
)
,
(
void
*
)
v
);
if
(
v
->
next
)
{
if
(
v
->
next
)
{
# ifdef METH_NOARGS
# ifdef METH_NOARGS
PyObject
*
nrep
=
SwigPyObject_repr
((
SwigPyObject
*
)
v
->
next
);
PyObject
*
nrep
=
SwigPyObject_repr
((
SwigPyObject
*
)
v
->
next
);
...
@@ -1777,8 +1786,10 @@ SwigPyObject_own(PyObject *v, PyObject *args)
...
@@ -1777,8 +1786,10 @@ SwigPyObject_own(PyObject *v, PyObject *args)
PyObject
*
val
=
0
;
PyObject
*
val
=
0
;
#if (PY_VERSION_HEX < 0x02020000)
#if (PY_VERSION_HEX < 0x02020000)
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"|O:own"
,
&
val
))
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"|O:own"
,
&
val
))
#el
se
#el
if (PY_VERSION_HEX < 0x02050000)
if
(
!
PyArg_UnpackTuple
(
args
,
(
char
*
)
"own"
,
0
,
1
,
&
val
))
if
(
!
PyArg_UnpackTuple
(
args
,
(
char
*
)
"own"
,
0
,
1
,
&
val
))
#else
if
(
!
PyArg_UnpackTuple
(
args
,
"own"
,
0
,
1
,
&
val
))
#endif
#endif
{
{
return
NULL
;
return
NULL
;
...
@@ -2473,23 +2484,29 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
...
@@ -2473,23 +2484,29 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
}
else
{
}
else
{
#if PY_VERSION_HEX >= 0x03000000
#if PY_VERSION_HEX >= 0x03000000
inst
=
PyBaseObject_Type
.
tp_new
((
PyTypeObject
*
)
data
->
newargs
,
Py_None
,
Py_None
);
inst
=
PyBaseObject_Type
.
tp_new
((
PyTypeObject
*
)
data
->
newargs
,
Py_None
,
Py_None
);
PyObject_SetAttr
(
inst
,
SWIG_This
(),
swig_this
);
if
(
inst
)
{
Py_TYPE
(
inst
)
->
tp_flags
&=
~
Py_TPFLAGS_VALID_VERSION_TAG
;
PyObject_SetAttr
(
inst
,
SWIG_This
(),
swig_this
);
Py_TYPE
(
inst
)
->
tp_flags
&=
~
Py_TPFLAGS_VALID_VERSION_TAG
;
}
#else
#else
PyObject
*
dict
=
PyDict_New
();
PyObject
*
dict
=
PyDict_New
();
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
if
(
dict
)
{
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
Py_DECREF
(
dict
);
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
Py_DECREF
(
dict
);
}
#endif
#endif
}
}
return
inst
;
return
inst
;
#else
#else
#if (PY_VERSION_HEX >= 0x02010000)
#if (PY_VERSION_HEX >= 0x02010000)
PyObject
*
inst
;
PyObject
*
inst
=
0
;
PyObject
*
dict
=
PyDict_New
();
PyObject
*
dict
=
PyDict_New
();
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
if
(
dict
)
{
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
PyDict_SetItem
(
dict
,
SWIG_This
(),
swig_this
);
Py_DECREF
(
dict
);
inst
=
PyInstance_NewRaw
(
data
->
newargs
,
dict
);
Py_DECREF
(
dict
);
}
return
(
PyObject
*
)
inst
;
return
(
PyObject
*
)
inst
;
#else
#else
PyInstanceObject
*
inst
=
PyObject_NEW
(
PyInstanceObject
,
&
PyInstance_Type
);
PyInstanceObject
*
inst
=
PyObject_NEW
(
PyInstanceObject
,
&
PyInstance_Type
);
...
@@ -2540,7 +2557,7 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
...
@@ -2540,7 +2557,7 @@ SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
SWIGINTERN
PyObject
*
SWIGINTERN
PyObject
*
SWIG_Python_InitShadowInstance
(
PyObject
*
args
)
{
SWIG_Python_InitShadowInstance
(
PyObject
*
args
)
{
PyObject
*
obj
[
2
];
PyObject
*
obj
[
2
];
if
(
!
SWIG_Python_UnpackTuple
(
args
,
(
char
*
)
"swiginit"
,
2
,
2
,
obj
))
{
if
(
!
SWIG_Python_UnpackTuple
(
args
,
"swiginit"
,
2
,
2
,
obj
))
{
return
NULL
;
return
NULL
;
}
else
{
}
else
{
SwigPyObject
*
sthis
=
SWIG_Python_GetSwigThis
(
obj
[
0
]);
SwigPyObject
*
sthis
=
SWIG_Python_GetSwigThis
(
obj
[
0
]);
...
@@ -2596,12 +2613,10 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f
...
@@ -2596,12 +2613,10 @@ SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int f
assert
(
!
(
flags
&
SWIG_BUILTIN_TP_INIT
));
assert
(
!
(
flags
&
SWIG_BUILTIN_TP_INIT
));
robj
=
SwigPyObject_New
(
ptr
,
type
,
own
);
robj
=
SwigPyObject_New
(
ptr
,
type
,
own
);
if
(
clientdata
&&
!
(
flags
&
SWIG_POINTER_NOSHADOW
))
{
if
(
robj
&&
clientdata
&&
!
(
flags
&
SWIG_POINTER_NOSHADOW
))
{
PyObject
*
inst
=
SWIG_Python_NewShadowInstance
(
clientdata
,
robj
);
PyObject
*
inst
=
SWIG_Python_NewShadowInstance
(
clientdata
,
robj
);
if
(
inst
)
{
Py_DECREF
(
robj
);
Py_DECREF
(
robj
);
robj
=
inst
;
robj
=
inst
;
}
}
}
return
robj
;
return
robj
;
}
}
...
@@ -2816,7 +2831,7 @@ SwigPyObject_GetDesc(PyObject *self)
...
@@ -2816,7 +2831,7 @@ SwigPyObject_GetDesc(PyObject *self)
{
{
SwigPyObject
*
v
=
(
SwigPyObject
*
)
self
;
SwigPyObject
*
v
=
(
SwigPyObject
*
)
self
;
swig_type_info
*
ty
=
v
?
v
->
ty
:
0
;
swig_type_info
*
ty
=
v
?
v
->
ty
:
0
;
return
ty
?
ty
->
str
:
(
char
*
)
""
;
return
ty
?
ty
->
str
:
""
;
}
}
SWIGRUNTIME
void
SWIGRUNTIME
void
...
@@ -2873,6 +2888,7 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg
...
@@ -2873,6 +2888,7 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(arg
return
result
;
return
result
;
}
}
#ifdef SWIGPYTHON_BUILTIN
SWIGRUNTIME
int
SWIGRUNTIME
int
SWIG_Python_NonDynamicSetAttr
(
PyObject
*
obj
,
PyObject
*
name
,
PyObject
*
value
)
{
SWIG_Python_NonDynamicSetAttr
(
PyObject
*
obj
,
PyObject
*
name
,
PyObject
*
value
)
{
PyTypeObject
*
tp
=
obj
->
ob_type
;
PyTypeObject
*
tp
=
obj
->
ob_type
;
...
@@ -2881,15 +2897,15 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2881,15 +2897,15 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
descrsetfunc
f
;
descrsetfunc
f
;
int
res
;
int
res
;
#ifdef Py_USING_UNICODE
#
ifdef Py_USING_UNICODE
if
(
PyString_Check
(
name
))
{
if
(
PyString_Check
(
name
))
{
name
=
PyUnicode_Decode
(
PyString_AsString
(
name
),
PyString_Size
(
name
),
NULL
,
NULL
);
name
=
PyUnicode_Decode
(
PyString_AsString
(
name
),
PyString_Size
(
name
),
NULL
,
NULL
);
if
(
!
name
)
if
(
!
name
)
return
-
1
;
return
-
1
;
}
else
if
(
!
PyUnicode_Check
(
name
))
}
else
if
(
!
PyUnicode_Check
(
name
))
#else
#
else
if
(
!
PyString_Check
(
name
))
if
(
!
PyString_Check
(
name
))
#endif
#
endif
{
{
PyErr_Format
(
PyExc_TypeError
,
"attribute name must be string, not '%.200s'"
,
name
->
ob_type
->
tp_name
);
PyErr_Format
(
PyExc_TypeError
,
"attribute name must be string, not '%.200s'"
,
name
->
ob_type
->
tp_name
);
return
-
1
;
return
-
1
;
...
@@ -2924,6 +2940,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2924,6 +2940,7 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
Py_DECREF
(
name
);
Py_DECREF
(
name
);
return
res
;
return
res
;
}
}
#endif
#ifdef __cplusplus
#ifdef __cplusplus
...
@@ -2971,7 +2988,7 @@ static swig_module_info swig_module = {swig_types, 6, 0, 0, 0, 0};
...
@@ -2971,7 +2988,7 @@ static swig_module_info swig_module = {swig_types, 6, 0, 0, 0, 0};
#endif
#endif
#define SWIG_name "_pyUModbus"
#define SWIG_name "_pyUModbus"
#define SWIGVERSION 0x02000
4
#define SWIGVERSION 0x02000
8
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3319,14 +3336,14 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
...
@@ -3319,14 +3336,14 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
#define SWIG_From_long PyInt_FromLong
SWIGINTERNINLINE
PyObject
*
SWIG_From_int
(
int
value
)
{
return
PyInt_FromLong
((
long
)
value
);
}
SWIGINTERNINLINE
PyObject
*
#define SWIG_From_long PyLong_FromLong
SWIG_From_int
(
int
value
)
{
return
SWIG_From_long
(
value
);
}
#ifdef __cplusplus
#ifdef __cplusplus
extern
"C"
{
extern
"C"
{
...
@@ -5331,8 +5348,7 @@ SWIG_InitializeModule(void *clientdata) {
...
@@ -5331,8 +5348,7 @@ SWIG_InitializeModule(void *clientdata) {
size_t
i
;
size_t
i
;
swig_module_info
*
module_head
,
*
iter
;
swig_module_info
*
module_head
,
*
iter
;
int
found
,
init
;
int
found
,
init
;
(
void
*
)
clientdata
;
clientdata
=
clientdata
;
/* check to see if the circular list has been setup, if not, set it up */
/* check to see if the circular list has been setup, if not, set it up */
if
(
swig_module
.
next
==
0
)
{
if
(
swig_module
.
next
==
0
)
{
...
@@ -5906,6 +5922,7 @@ SWIG_init(void) {
...
@@ -5906,6 +5922,7 @@ SWIG_init(void) {
m
=
Py_InitModule
((
char
*
)
SWIG_name
,
SwigMethods
);
m
=
Py_InitModule
((
char
*
)
SWIG_name
,
SwigMethods
);
#endif
#endif
md
=
d
=
PyModule_GetDict
(
m
);
md
=
d
=
PyModule_GetDict
(
m
);
(
void
)
md
;
SWIG_InitializeModule
(
0
);
SWIG_InitializeModule
(
0
);
...
...
python/lib/pyUniSet/pyUExceptions.py
View file @
15a2734d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 2.0.
4
# Version 2.0.
8
#
#
# Do not make changes to this file unless you know what you are doing--modify
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.
# the SWIG interface file instead.
...
...
python/lib/pyUniSet/pyUModbus.py
View file @
15a2734d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 2.0.
4
# Version 2.0.
8
#
#
# Do not make changes to this file unless you know what you are doing--modify
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.
# the SWIG interface file instead.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment