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
1d72749d
Commit
1d72749d
authored
Nov 01, 2015
by
Pavel Vainerman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Потихоньку избавляюсь от char*
parent
89edf1eb
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
765 additions
and
630 deletions
+765
-630
DBServer_MySQL.h
extensions/DBServer-MySQL/DBServer_MySQL.h
+1
-1
DBServer_PostgreSQL.h
extensions/DBServer-PostgreSQL/DBServer_PostgreSQL.h
+2
-2
DBServer_SQLite.h
extensions/DBServer-SQLite/DBServer_SQLite.h
+2
-2
ObjectRepositoryFactory.h
include/ObjectRepositoryFactory.h
+2
-7
ThreadCreator.h
include/ThreadCreator.h
+0
-5
UInterface.h
include/UInterface.h
+1
-5
UniSetTypes.h
include/UniSetTypes.h
+1
-1
VMonitor.h
include/VMonitor.h
+1
-1
PyUInterface.cc
python/lib/pyUniSet/PyUInterface.cc
+11
-11
PyUInterface.h
python/lib/pyUniSet/PyUInterface.h
+7
-7
UConnector.cc
python/lib/pyUniSet/UConnector.cc
+12
-12
UConnector.h
python/lib/pyUniSet/UConnector.h
+11
-12
UConnector.i
python/lib/pyUniSet/UConnector.i
+1
-0
UConnector_wrap.cxx
python/lib/pyUniSet/UConnector_wrap.cxx
+122
-70
UExceptions.h
python/lib/pyUniSet/UExceptions.h
+2
-2
UExceptions.i
python/lib/pyUniSet/UExceptions.i
+1
-0
UExceptions_wrap.cxx
python/lib/pyUniSet/UExceptions_wrap.cxx
+111
-65
UInterface_wrap.cxx
python/lib/pyUniSet/UInterface_wrap.cxx
+141
-167
UModbus.cc
python/lib/pyUniSet/UModbus.cc
+12
-17
UModbus.h
python/lib/pyUniSet/UModbus.h
+8
-9
UModbus.i
python/lib/pyUniSet/UModbus.i
+1
-0
UModbus_wrap.cxx
python/lib/pyUniSet/UModbus_wrap.cxx
+293
-197
pyUConnector.py
python/lib/pyUniSet/pyUConnector.py
+5
-5
pyUExceptions.py
python/lib/pyUniSet/pyUExceptions.py
+1
-1
pyUModbus.py
python/lib/pyUniSet/pyUModbus.py
+5
-5
pyUniSet.py
python/lib/pyUniSet/pyUniSet.py
+3
-3
ObjectRepositoryFactory.cc
src/ObjectRepository/ObjectRepositoryFactory.cc
+8
-23
No files found.
extensions/DBServer-MySQL/DBServer_MySQL.h
View file @
1d72749d
...
@@ -169,7 +169,7 @@ class DBServer_MySQL:
...
@@ -169,7 +169,7 @@ class DBServer_MySQL:
bool
writeToBase
(
const
string
&
query
);
bool
writeToBase
(
const
string
&
query
);
void
createTables
(
MySQLInterface
*
db
);
void
createTables
(
MySQLInterface
*
db
);
inline
const
char
*
tblName
(
int
key
)
inline
std
::
string
tblName
(
int
key
)
{
{
return
tblMap
[
key
].
c_str
();
return
tblMap
[
key
].
c_str
();
}
}
...
...
extensions/DBServer-PostgreSQL/DBServer_PostgreSQL.h
View file @
1d72749d
...
@@ -46,9 +46,9 @@ class DBServer_PostgreSQL:
...
@@ -46,9 +46,9 @@ class DBServer_PostgreSQL:
bool
writeToBase
(
const
string
&
query
);
bool
writeToBase
(
const
string
&
query
);
void
createTables
(
std
::
shared_ptr
<
PostgreSQLInterface
>&
db
);
void
createTables
(
std
::
shared_ptr
<
PostgreSQLInterface
>&
db
);
inline
const
char
*
tblName
(
int
key
)
inline
std
::
string
tblName
(
int
key
)
{
{
return
tblMap
[
key
]
.
c_str
()
;
return
tblMap
[
key
];
}
}
enum
Timers
enum
Timers
...
...
extensions/DBServer-SQLite/DBServer_SQLite.h
View file @
1d72749d
...
@@ -169,9 +169,9 @@ class DBServer_SQLite:
...
@@ -169,9 +169,9 @@ class DBServer_SQLite:
bool
writeToBase
(
const
string
&
query
);
bool
writeToBase
(
const
string
&
query
);
void
createTables
(
SQLiteInterface
*
db
);
void
createTables
(
SQLiteInterface
*
db
);
inline
const
char
*
tblName
(
int
key
)
inline
std
::
string
tblName
(
int
key
)
{
{
return
tblMap
[
key
]
.
c_str
()
;
return
tblMap
[
key
];
}
}
enum
Timers
enum
Timers
...
...
include/ObjectRepositoryFactory.h
View file @
1d72749d
...
@@ -38,21 +38,16 @@
...
@@ -38,21 +38,16 @@
class
ObjectRepositoryFactory
:
private
ObjectRepository
class
ObjectRepositoryFactory
:
private
ObjectRepository
{
{
public
:
public
:
// ObjectRepositoryFactory();
// ObjectRepositoryFactory(int* argc=argc_ptr, char* **argv=argv_ptr); // параметры инициализации ORB
ObjectRepositoryFactory
(
const
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>&
conf
);
ObjectRepositoryFactory
(
const
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>&
conf
);
~
ObjectRepositoryFactory
();
~
ObjectRepositoryFactory
();
//! Создание секции
//! Создание секции
bool
createSection
(
const
char
*
name
,
const
char
*
in_section
)
throw
(
UniSetTypes
::
ORepFailed
,
UniSetTypes
::
InvalidObjectName
);
/*! \overload */
bool
createSection
(
const
std
::
string
&
name
,
const
std
::
string
&
in_section
)
throw
(
UniSetTypes
::
ORepFailed
,
UniSetTypes
::
InvalidObjectName
);
bool
createSection
(
const
std
::
string
&
name
,
const
std
::
string
&
in_section
)
throw
(
UniSetTypes
::
ORepFailed
,
UniSetTypes
::
InvalidObjectName
);
/*! Создание секции по полному имени */
/*! Создание секции по полному имени */
bool
createSectionF
(
const
std
::
string
&
fullName
)
throw
(
UniSetTypes
::
ORepFailed
,
UniSetTypes
::
InvalidObjectName
);
bool
createSectionF
(
const
std
::
string
&
fullName
)
throw
(
UniSetTypes
::
ORepFailed
,
UniSetTypes
::
InvalidObjectName
);
//! Функция создания секции в корневом 'каталоге'
//! Функция создания секции в корневом 'каталоге'
bool
createRootSection
(
const
char
*
name
);
/*! \overload */
bool
createRootSection
(
const
std
::
string
&
name
);
bool
createRootSection
(
const
std
::
string
&
name
);
...
@@ -76,7 +71,7 @@ class ObjectRepositoryFactory: private ObjectRepository
...
@@ -76,7 +71,7 @@ class ObjectRepositoryFactory: private ObjectRepository
private
:
private
:
/*! Создание нового контекста(секции) */
/*! Создание нового контекста(секции) */
bool
createContext
(
const
char
*
cname
,
CosNaming
::
NamingContext_ptr
ctx
);
bool
createContext
(
const
std
::
string
&
cname
,
CosNaming
::
NamingContext_ptr
ctx
);
};
};
//};
//};
...
...
include/ThreadCreator.h
View file @
1d72749d
...
@@ -112,11 +112,6 @@ class ThreadCreator:
...
@@ -112,11 +112,6 @@ class ThreadCreator:
ost
::
PosixThread
::
setName
(
name
.
c_str
()
);
ost
::
PosixThread
::
setName
(
name
.
c_str
()
);
}
}
inline
void
setName
(
const
char
*
name
)
{
ost
::
PosixThread
::
setName
(
name
);
}
inline
void
setCancel
(
ost
::
Thread
::
Cancel
mode
)
inline
void
setCancel
(
ost
::
Thread
::
Cancel
mode
)
{
{
ost
::
PosixThread
::
setCancel
(
mode
);
ost
::
PosixThread
::
setCancel
(
mode
);
...
...
include/UInterface.h
View file @
1d72749d
...
@@ -199,13 +199,9 @@ class UInterface
...
@@ -199,13 +199,9 @@ class UInterface
// Работа с ID, Name
// Работа с ID, Name
/*! получение идентификатора объекта по имени */
/*! получение идентификатора объекта по имени */
inline
UniSetTypes
::
ObjectId
getIdByName
(
const
char
*
name
)
const
{
return
oind
->
getIdByName
(
name
);
}
inline
UniSetTypes
::
ObjectId
getIdByName
(
const
std
::
string
&
name
)
const
inline
UniSetTypes
::
ObjectId
getIdByName
(
const
std
::
string
&
name
)
const
{
{
return
getIdByName
(
name
.
c_str
()
);
return
oind
->
getIdByName
(
name
);
}
}
/*! получение имени по идентификатору объекта */
/*! получение имени по идентификатору объекта */
...
...
include/UniSetTypes.h
View file @
1d72749d
...
@@ -189,7 +189,7 @@ namespace UniSetTypes
...
@@ -189,7 +189,7 @@ namespace UniSetTypes
/*! Функция разбора строки вида: id1@node1=val1,id2@node2=val2,...
/*! Функция разбора строки вида: id1@node1=val1,id2@node2=val2,...
Если '=' не указано, возвращается val=0
Если '=' не указано, возвращается val=0
Если @node не указано, возвращается node=DefaultObjectId */
Если @node не указано, возвращается node=DefaultObjectId */
std
::
list
<
ParamSInfo
>
getSInfoList
(
const
std
::
string
&
s
,
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>
conf
=
nullptr
);
std
::
list
<
ParamSInfo
>
getSInfoList
(
const
std
::
string
&
s
,
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>
conf
=
nullptr
);
...
...
include/VMonitor.h
View file @
1d72749d
...
@@ -109,7 +109,7 @@
...
@@ -109,7 +109,7 @@
\endcode
\endcode
*
*
*
*
* \todo Нужно добавить поддержку "пользователских типов" (возможно нужно использовать variadic templates)
* \todo Нужно добавить поддержку "пользовател
ь
ских типов" (возможно нужно использовать variadic templates)
*/
*/
class
VMonitor
class
VMonitor
{
{
...
...
python/lib/pyUniSet/PyUInterface.cc
View file @
1d72749d
...
@@ -10,13 +10,13 @@ using namespace std;
...
@@ -10,13 +10,13 @@ using namespace std;
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
static
UInterface
*
ui
=
0
;
static
UInterface
*
ui
=
0
;
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
void
pyUInterface
::
uniset_init_params
(
UTypes
::
Params
*
p
,
const
char
*
xmlfile
)
throw
(
UException
)
void
pyUInterface
::
uniset_init_params
(
UTypes
::
Params
*
p
,
const
std
::
string
&
xmlfile
)
throw
(
UException
)
{
{
pyUInterface
::
uniset_init
(
p
->
argc
,
p
->
argv
,
xmlfile
);
pyUInterface
::
uniset_init
(
p
->
argc
,
p
->
argv
,
xmlfile
);
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
void
pyUInterface
::
uniset_init
(
int
argc
,
char
*
argv
[],
const
char
*
xmlfile
)
throw
(
UException
)
void
pyUInterface
::
uniset_init
(
int
argc
,
char
*
argv
[],
const
std
::
string
&
xmlfile
)
throw
(
UException
)
{
{
try
try
{
{
...
@@ -118,7 +118,7 @@ void pyUInterface::setValue( long id, long val )throw(UException)
...
@@ -118,7 +118,7 @@ void pyUInterface::setValue( long id, long val )throw(UException)
}
}
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
long
pyUInterface
::
getSensorID
(
const
char
*
name
)
long
pyUInterface
::
getSensorID
(
const
string
&
name
)
{
{
auto
conf
=
UniSetTypes
::
uniset_conf
();
auto
conf
=
UniSetTypes
::
uniset_conf
();
...
@@ -128,42 +128,42 @@ long pyUInterface::getSensorID( const char* name )
...
@@ -128,42 +128,42 @@ long pyUInterface::getSensorID( const char* name )
return
UniSetTypes
::
DefaultObjectId
;
return
UniSetTypes
::
DefaultObjectId
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
pyUInterface
::
getName
(
long
id
)
std
::
string
pyUInterface
::
getName
(
long
id
)
{
{
auto
conf
=
UniSetTypes
::
uniset_conf
();
auto
conf
=
UniSetTypes
::
uniset_conf
();
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
oind
->
getMapName
(
id
)
);
return
conf
->
oind
->
getMapName
(
id
);
return
""
;
return
""
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
pyUInterface
::
getShortName
(
long
id
)
string
pyUInterface
::
getShortName
(
long
id
)
{
{
auto
conf
=
UniSetTypes
::
uniset_conf
();
auto
conf
=
UniSetTypes
::
uniset_conf
();
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
ORepHelpers
::
getShortName
(
conf
->
oind
->
getMapName
(
id
)
));
return
ORepHelpers
::
getShortName
(
conf
->
oind
->
getMapName
(
id
));
return
""
;
return
""
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
pyUInterface
::
getTextName
(
long
id
)
std
::
string
pyUInterface
::
getTextName
(
long
id
)
{
{
auto
conf
=
UniSetTypes
::
uniset_conf
();
auto
conf
=
UniSetTypes
::
uniset_conf
();
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
oind
->
getTextName
(
id
)
);
return
conf
->
oind
->
getTextName
(
id
);
return
""
;
return
""
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
pyUInterface
::
getConfFileName
()
string
pyUInterface
::
getConfFileName
()
{
{
auto
conf
=
UniSetTypes
::
uniset_conf
();
auto
conf
=
UniSetTypes
::
uniset_conf
();
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
getConfFileName
()
);
return
conf
->
getConfFileName
(
);
return
""
;
return
""
;
...
...
python/lib/pyUniSet/PyUInterface.h
View file @
1d72749d
...
@@ -7,20 +7,20 @@
...
@@ -7,20 +7,20 @@
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
namespace
pyUInterface
namespace
pyUInterface
{
{
void
uniset_init_params
(
UTypes
::
Params
*
p
,
const
char
*
xmlfile
)
throw
(
UException
);
void
uniset_init_params
(
UTypes
::
Params
*
p
,
const
std
::
string
&
xmlfile
)
throw
(
UException
);
void
uniset_init
(
int
argc
,
char
**
argv
,
const
char
*
xmlfile
)
throw
(
UException
);
void
uniset_init
(
int
argc
,
char
**
argv
,
const
std
::
string
&
xmlfile
)
throw
(
UException
);
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
long
getValue
(
long
id
)
throw
(
UException
);
long
getValue
(
long
id
)
throw
(
UException
);
void
setValue
(
long
id
,
long
val
)
throw
(
UException
);
void
setValue
(
long
id
,
long
val
)
throw
(
UException
);
long
getSensorID
(
const
char
*
);
long
getSensorID
(
const
std
::
string
&
name
);
const
char
*
getShortName
(
long
id
);
std
::
string
getShortName
(
long
id
);
const
char
*
getName
(
long
id
);
std
::
string
getName
(
long
id
);
const
char
*
getTextName
(
long
id
);
std
::
string
getTextName
(
long
id
);
const
char
*
getConfFileName
();
std
::
string
getConfFileName
();
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
...
...
python/lib/pyUniSet/UConnector.cc
View file @
1d72749d
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
using
namespace
std
;
using
namespace
std
;
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
UConnector
::
UConnector
(
UTypes
::
Params
*
p
,
const
char
*
xfile
)
throw
(
UException
)
:
UConnector
::
UConnector
(
UTypes
::
Params
*
p
,
const
std
::
string
&
xfile
)
throw
(
UException
)
:
conf
(
0
),
conf
(
0
),
ui
(
0
),
ui
(
0
),
xmlfile
(
xfile
)
xmlfile
(
xfile
)
...
@@ -23,7 +23,7 @@ UConnector::UConnector( UTypes::Params* p, const char* xfile )throw(UException):
...
@@ -23,7 +23,7 @@ UConnector::UConnector( UTypes::Params* p, const char* xfile )throw(UException):
}
}
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
UConnector
::
UConnector
(
int
argc
,
char
**
argv
,
const
char
*
xfile
)
throw
(
UException
)
:
UConnector
::
UConnector
(
int
argc
,
char
**
argv
,
const
string
&
xfile
)
throw
(
UException
)
:
conf
(
0
),
conf
(
0
),
ui
(
0
),
ui
(
0
),
xmlfile
(
xfile
)
xmlfile
(
xfile
)
...
@@ -47,11 +47,11 @@ UConnector::~UConnector()
...
@@ -47,11 +47,11 @@ UConnector::~UConnector()
{
{
}
}
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
const
char
*
UConnector
::
getConfFileName
()
string
UConnector
::
getConfFileName
()
{
{
// return xmlfile;
// return xmlfile;
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
getConfFileName
()
);
return
conf
->
getConfFileName
(
);
return
""
;
return
""
;
...
@@ -102,7 +102,7 @@ void UConnector::setValue( long id, long val, long node )throw(UException)
...
@@ -102,7 +102,7 @@ void UConnector::setValue( long id, long val, long node )throw(UException)
}
}
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
long
UConnector
::
getSensorID
(
const
char
*
name
)
long
UConnector
::
getSensorID
(
const
string
&
name
)
{
{
if
(
conf
)
if
(
conf
)
return
conf
->
getSensorID
(
name
);
return
conf
->
getSensorID
(
name
);
...
@@ -110,7 +110,7 @@ long UConnector::getSensorID( const char* name )
...
@@ -110,7 +110,7 @@ long UConnector::getSensorID( const char* name )
return
UTypes
::
DefaultID
;
return
UTypes
::
DefaultID
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
long
UConnector
::
getNodeID
(
const
char
*
name
)
long
UConnector
::
getNodeID
(
const
string
&
name
)
{
{
if
(
conf
)
if
(
conf
)
return
conf
->
getNodeID
(
name
);
return
conf
->
getNodeID
(
name
);
...
@@ -118,26 +118,26 @@ long UConnector::getNodeID( const char* name )
...
@@ -118,26 +118,26 @@ long UConnector::getNodeID( const char* name )
return
UTypes
::
DefaultID
;
return
UTypes
::
DefaultID
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
UConnector
::
getName
(
long
id
)
string
UConnector
::
getName
(
long
id
)
{
{
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
oind
->
getMapName
(
id
)
);
return
conf
->
oind
->
getMapName
(
id
);
return
""
;
return
""
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
UConnector
::
getShortName
(
long
id
)
string
UConnector
::
getShortName
(
long
id
)
{
{
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
ORepHelpers
::
getShortName
(
conf
->
oind
->
getMapName
(
id
)
));
return
ORepHelpers
::
getShortName
(
conf
->
oind
->
getMapName
(
id
));
return
""
;
return
""
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
const
char
*
UConnector
::
getTextName
(
long
id
)
string
UConnector
::
getTextName
(
long
id
)
{
{
if
(
conf
)
if
(
conf
)
return
UniSetTypes
::
uni_strdup
(
conf
->
oind
->
getTextName
(
id
)
);
return
conf
->
oind
->
getTextName
(
id
);
return
""
;
return
""
;
}
}
...
...
python/lib/pyUniSet/UConnector.h
View file @
1d72749d
...
@@ -11,31 +11,30 @@
...
@@ -11,31 +11,30 @@
class
UConnector
class
UConnector
{
{
public
:
public
:
UConnector
(
int
argc
,
char
**
argv
,
const
char
*
xmlfile
)
throw
(
UException
);
UConnector
(
int
argc
,
char
**
argv
,
const
std
::
string
&
xmlfile
)
throw
(
UException
);
UConnector
(
UTypes
::
Params
*
p
,
const
char
*
xmlfile
)
throw
(
UException
);
UConnector
(
UTypes
::
Params
*
p
,
const
std
::
string
&
xmlfile
)
throw
(
UException
);
~
UConnector
();
~
UConnector
();
inline
const
char
*
getUIType
()
inline
std
::
string
getUIType
()
{
{
return
"uniset"
;
return
string
(
"uniset"
)
;
}
}
const
char
*
getConfFileName
();
std
::
string
getConfFileName
();
long
getValue
(
long
id
,
long
node
)
throw
(
UException
);
long
getValue
(
long
id
,
long
node
)
throw
(
UException
);
void
setValue
(
long
id
,
long
val
,
long
node
)
throw
(
UException
);
void
setValue
(
long
id
,
long
val
,
long
node
)
throw
(
UException
);
long
getSensorID
(
const
char
*
);
long
getSensorID
(
const
std
::
string
&
name
);
long
getNodeID
(
const
char
*
);
long
getNodeID
(
const
std
::
string
&
name
);
const
char
*
getShortName
(
long
id
);
const
char
*
getName
(
long
id
);
const
char
*
getTextName
(
long
id
);
std
::
string
getShortName
(
long
id
);
std
::
string
getName
(
long
id
);
std
::
string
getTextName
(
long
id
);
private
:
private
:
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>
conf
;
std
::
shared_ptr
<
UniSetTypes
::
Configuration
>
conf
;
std
::
shared_ptr
<
UInterface
>
ui
;
std
::
shared_ptr
<
UInterface
>
ui
;
const
char
*
xmlfile
;
std
::
string
xmlfile
;
};
};
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
#endif
#endif
...
...
python/lib/pyUniSet/UConnector.i
View file @
1d72749d
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
* to regenerate the wrappers run:
* to regenerate the wrappers run:
* swig -python UInterface.i
* swig -python UInterface.i
***********************************************************/
***********************************************************/
%include <std_string.i>
%module pyUConnector
%module pyUConnector
%{
%{
...
...
python/lib/pyUniSet/UConnector_wrap.cxx
View file @
1d72749d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.
6
* Version 3.0.
7
*
*
* 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
...
@@ -2998,7 +2998,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
...
@@ -2998,7 +2998,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
#endif
#endif
#define SWIG_name "_pyUConnector"
#define SWIG_name "_pyUConnector"
#define SWIGVERSION 0x03000
6
#define SWIGVERSION 0x03000
7
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3079,6 +3079,9 @@ namespace swig {
...
@@ -3079,6 +3079,9 @@ namespace swig {
}
}
#include <string>
#include "UConnector.h"
#include "UConnector.h"
...
@@ -3336,6 +3339,37 @@ SWIG_AsVal_int (PyObject * obj, int *val)
...
@@ -3336,6 +3339,37 @@ SWIG_AsVal_int (PyObject * obj, int *val)
}
}
SWIGINTERN
int
SWIG_AsPtr_std_string
(
PyObject
*
obj
,
std
::
string
**
val
)
{
char
*
buf
=
0
;
size_t
size
=
0
;
int
alloc
=
SWIG_OLDOBJ
;
if
(
SWIG_IsOK
((
SWIG_AsCharPtrAndSize
(
obj
,
&
buf
,
&
size
,
&
alloc
))))
{
if
(
buf
)
{
if
(
val
)
*
val
=
new
std
::
string
(
buf
,
size
-
1
);
if
(
alloc
==
SWIG_NEWOBJ
)
delete
[]
buf
;
return
SWIG_NEWOBJ
;
}
else
{
if
(
val
)
*
val
=
0
;
return
SWIG_OLDOBJ
;
}
}
else
{
static
int
init
=
0
;
static
swig_type_info
*
descriptor
=
0
;
if
(
!
init
)
{
descriptor
=
SWIG_TypeQuery
(
"std::string"
" *"
);
init
=
1
;
}
if
(
descriptor
)
{
std
::
string
*
vptr
;
int
res
=
SWIG_ConvertPtr
(
obj
,
(
void
**
)
&
vptr
,
descriptor
,
0
);
if
(
SWIG_IsOK
(
res
)
&&
val
)
*
val
=
vptr
;
return
res
;
}
}
return
SWIG_ERROR
;
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
SWIG_FromCharPtrAndSize
(
const
char
*
carray
,
size_t
size
)
SWIG_FromCharPtrAndSize
(
const
char
*
carray
,
size_t
size
)
{
{
...
@@ -3361,10 +3395,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
...
@@ -3361,10 +3395,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
}
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
SWIG_From
CharPtr
(
const
char
*
cptr
)
SWIG_From
_std_string
(
const
std
::
string
&
s
)
{
{
return
SWIG_FromCharPtrAndSize
(
cptr
,
(
cptr
?
strlen
(
cptr
)
:
0
));
return
SWIG_FromCharPtrAndSize
(
s
.
data
(),
s
.
size
(
));
}
}
#ifdef __cplusplus
#ifdef __cplusplus
...
@@ -3587,14 +3621,12 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3587,14 +3621,12 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
int
arg1
;
int
arg1
;
char
**
arg2
=
(
char
**
)
0
;
char
**
arg2
=
(
char
**
)
0
;
char
*
arg3
=
(
char
*
)
0
;
std
::
string
*
arg3
=
0
;
int
val1
;
int
val1
;
int
ecode1
=
0
;
int
ecode1
=
0
;
void
*
argp2
=
0
;
void
*
argp2
=
0
;
int
res2
=
0
;
int
res2
=
0
;
int
res3
;
int
res3
=
SWIG_OLDOBJ
;
char
*
buf3
=
0
;
int
alloc3
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj2
=
0
;
PyObject
*
obj2
=
0
;
...
@@ -3611,23 +3643,29 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3611,23 +3643,29 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"new_UConnector"
"', argument "
"2"" of type '"
"char **""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"new_UConnector"
"', argument "
"2"" of type '"
"char **""'"
);
}
}
arg2
=
reinterpret_cast
<
char
**
>
(
argp2
);
arg2
=
reinterpret_cast
<
char
**
>
(
argp2
);
res3
=
SWIG_AsCharPtrAndSize
(
obj2
,
&
buf3
,
NULL
,
&
alloc3
);
{
if
(
!
SWIG_IsOK
(
res3
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res3
),
"in method '"
"new_UConnector"
"', argument "
"3"" of type '"
"char const *""'"
);
res3
=
SWIG_AsPtr_std_string
(
obj2
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res3
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res3
),
"in method '"
"new_UConnector"
"', argument "
"3"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UConnector"
"', argument "
"3"" of type '"
"std::string const &""'"
);
}
arg3
=
ptr
;
}
}
arg3
=
reinterpret_cast
<
char
*
>
(
buf3
);
try
{
try
{
result
=
(
UConnector
*
)
new
UConnector
(
arg1
,
arg2
,(
char
const
*
)
arg3
);
result
=
(
UConnector
*
)
new
UConnector
(
arg1
,
arg2
,(
std
::
string
const
&
)
*
arg3
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UConnector
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UConnector
,
SWIG_POINTER_NEW
|
0
);
if
(
alloc3
==
SWIG_NEWOBJ
)
delete
[]
buf
3
;
if
(
SWIG_IsNewObj
(
res3
))
delete
arg
3
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc3
==
SWIG_NEWOBJ
)
delete
[]
buf
3
;
if
(
SWIG_IsNewObj
(
res3
))
delete
arg
3
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3635,12 +3673,10 @@ fail:
...
@@ -3635,12 +3673,10 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UConnector__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UConnector__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UTypes
::
Params
*
arg1
=
(
UTypes
::
Params
*
)
0
;
UTypes
::
Params
*
arg1
=
(
UTypes
::
Params
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
int
res2
=
SWIG_OLDOBJ
;
char
*
buf2
=
0
;
int
alloc2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
UConnector
*
result
=
0
;
UConnector
*
result
=
0
;
...
@@ -3651,30 +3687,38 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3651,30 +3687,38 @@ SWIGINTERN PyObject *_wrap_new_UConnector__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UConnector"
"', argument "
"1"" of type '"
"UTypes::Params *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UConnector"
"', argument "
"1"" of type '"
"UTypes::Params *""'"
);
}
}
arg1
=
reinterpret_cast
<
UTypes
::
Params
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UTypes
::
Params
*
>
(
argp1
);
res2
=
SWIG_AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
{
if
(
!
SWIG_IsOK
(
res2
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"new_UConnector"
"', argument "
"2"" of type '"
"char const *""'"
);
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"new_UConnector"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UConnector"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
try
{
try
{
result
=
(
UConnector
*
)
new
UConnector
(
arg1
,(
char
const
*
)
arg2
);
result
=
(
UConnector
*
)
new
UConnector
(
arg1
,(
std
::
string
const
&
)
*
arg2
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UConnector
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UConnector
,
SWIG_POINTER_NEW
|
0
);
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_new_UConnector
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UConnector
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
4
];
PyObject
*
argv
[
4
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -3688,7 +3732,7 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
...
@@ -3688,7 +3732,7 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
int
res
=
SWIG_ConvertPtr
(
argv
[
0
],
&
vptr
,
SWIGTYPE_p_UTypes__Params
,
0
);
int
res
=
SWIG_ConvertPtr
(
argv
[
0
],
&
vptr
,
SWIGTYPE_p_UTypes__Params
,
0
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
1
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
1
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UConnector__SWIG_1
(
self
,
args
);
return
_wrap_new_UConnector__SWIG_1
(
self
,
args
);
...
@@ -3706,7 +3750,7 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
...
@@ -3706,7 +3750,7 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
int
res
=
SWIG_ConvertPtr
(
argv
[
1
],
&
vptr
,
SWIGTYPE_p_p_char
,
0
);
int
res
=
SWIG_ConvertPtr
(
argv
[
1
],
&
vptr
,
SWIGTYPE_p_p_char
,
0
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
2
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
2
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UConnector__SWIG_0
(
self
,
args
);
return
_wrap_new_UConnector__SWIG_0
(
self
,
args
);
...
@@ -3718,8 +3762,8 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
...
@@ -3718,8 +3762,8 @@ SWIGINTERN PyObject *_wrap_new_UConnector(PyObject *self, PyObject *args) {
fail
:
fail
:
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'new_UConnector'.
\n
"
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'new_UConnector'.
\n
"
" Possible C/C++ prototypes are:
\n
"
" Possible C/C++ prototypes are:
\n
"
" UConnector::UConnector(int,char **,
char const *
)
\n
"
" UConnector::UConnector(int,char **,
std::string const &
)
\n
"
" UConnector::UConnector(UTypes::Params *,
char const *
)
\n
"
);
" UConnector::UConnector(UTypes::Params *,
std::string const &
)
\n
"
);
return
0
;
return
0
;
}
}
...
@@ -3751,7 +3795,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getUIType(PyObject *SWIGUNUSEDPARM(self),
...
@@ -3751,7 +3795,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getUIType(PyObject *SWIGUNUSEDPARM(self),
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UConnector_getUIType"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UConnector_getUIType"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
...
@@ -3759,8 +3803,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getUIType(PyObject *SWIGUNUSEDPARM(self),
...
@@ -3759,8 +3803,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getUIType(PyObject *SWIGUNUSEDPARM(self),
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getUIType"
"', argument "
"1"" of type '"
"UConnector *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getUIType"
"', argument "
"1"" of type '"
"UConnector *""'"
);
}
}
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getUIType
();
result
=
(
arg1
)
->
getUIType
();
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3773,7 +3817,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getConfFileName(PyObject *SWIGUNUSEDPARM(s
...
@@ -3773,7 +3817,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getConfFileName(PyObject *SWIGUNUSEDPARM(s
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UConnector_getConfFileName"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UConnector_getConfFileName"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
...
@@ -3781,8 +3825,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getConfFileName(PyObject *SWIGUNUSEDPARM(s
...
@@ -3781,8 +3825,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getConfFileName(PyObject *SWIGUNUSEDPARM(s
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getConfFileName"
"', argument "
"1"" of type '"
"UConnector *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getConfFileName"
"', argument "
"1"" of type '"
"UConnector *""'"
);
}
}
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getConfFileName
();
result
=
(
arg1
)
->
getConfFileName
();
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3892,12 +3936,10 @@ fail:
...
@@ -3892,12 +3936,10 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UConnector_getSensorID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UConnector_getSensorID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UConnector
*
arg1
=
(
UConnector
*
)
0
;
UConnector
*
arg1
=
(
UConnector
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
int
res2
=
SWIG_OLDOBJ
;
char
*
buf2
=
0
;
int
alloc2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
long
result
;
long
result
;
...
@@ -3908,17 +3950,23 @@ SWIGINTERN PyObject *_wrap_UConnector_getSensorID(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3908,17 +3950,23 @@ SWIGINTERN PyObject *_wrap_UConnector_getSensorID(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getSensorID"
"', argument "
"1"" of type '"
"UConnector *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getSensorID"
"', argument "
"1"" of type '"
"UConnector *""'"
);
}
}
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
res2
=
SWIG_AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
{
if
(
!
SWIG_IsOK
(
res2
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UConnector_getSensorID"
"', argument "
"2"" of type '"
"char const *""'"
);
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UConnector_getSensorID"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UConnector_getSensorID"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
result
=
(
long
)(
arg1
)
->
getSensorID
((
std
::
string
const
&
)
*
arg2
);
result
=
(
long
)(
arg1
)
->
getSensorID
((
char
const
*
)
arg2
);
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3926,12 +3974,10 @@ fail:
...
@@ -3926,12 +3974,10 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UConnector_getNodeID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UConnector_getNodeID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UConnector
*
arg1
=
(
UConnector
*
)
0
;
UConnector
*
arg1
=
(
UConnector
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
int
res2
=
SWIG_OLDOBJ
;
char
*
buf2
=
0
;
int
alloc2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
long
result
;
long
result
;
...
@@ -3942,17 +3988,23 @@ SWIGINTERN PyObject *_wrap_UConnector_getNodeID(PyObject *SWIGUNUSEDPARM(self),
...
@@ -3942,17 +3988,23 @@ SWIGINTERN PyObject *_wrap_UConnector_getNodeID(PyObject *SWIGUNUSEDPARM(self),
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getNodeID"
"', argument "
"1"" of type '"
"UConnector *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UConnector_getNodeID"
"', argument "
"1"" of type '"
"UConnector *""'"
);
}
}
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UConnector
*
>
(
argp1
);
res2
=
SWIG_AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
{
if
(
!
SWIG_IsOK
(
res2
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UConnector_getNodeID"
"', argument "
"2"" of type '"
"char const *""'"
);
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UConnector_getNodeID"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UConnector_getNodeID"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
result
=
(
long
)(
arg1
)
->
getNodeID
((
std
::
string
const
&
)
*
arg2
);
result
=
(
long
)(
arg1
)
->
getNodeID
((
char
const
*
)
arg2
);
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3967,7 +4019,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getShortName(PyObject *SWIGUNUSEDPARM(self
...
@@ -3967,7 +4019,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getShortName(PyObject *SWIGUNUSEDPARM(self
int
ecode2
=
0
;
int
ecode2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getShortName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getShortName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
...
@@ -3980,8 +4032,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getShortName(PyObject *SWIGUNUSEDPARM(self
...
@@ -3980,8 +4032,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getShortName(PyObject *SWIGUNUSEDPARM(self
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getShortName"
"', argument "
"2"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getShortName"
"', argument "
"2"" of type '"
"long""'"
);
}
}
arg2
=
static_cast
<
long
>
(
val2
);
arg2
=
static_cast
<
long
>
(
val2
);
result
=
(
char
*
)(
arg1
)
->
getShortName
(
arg2
);
result
=
(
arg1
)
->
getShortName
(
arg2
);
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3998,7 +4050,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getName(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -3998,7 +4050,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getName(PyObject *SWIGUNUSEDPARM(self), Py
int
ecode2
=
0
;
int
ecode2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
...
@@ -4011,8 +4063,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getName(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -4011,8 +4063,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getName(PyObject *SWIGUNUSEDPARM(self), Py
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getName"
"', argument "
"2"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getName"
"', argument "
"2"" of type '"
"long""'"
);
}
}
arg2
=
static_cast
<
long
>
(
val2
);
arg2
=
static_cast
<
long
>
(
val2
);
result
=
(
char
*
)(
arg1
)
->
getName
(
arg2
);
result
=
(
arg1
)
->
getName
(
arg2
);
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -4029,7 +4081,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getTextName(PyObject *SWIGUNUSEDPARM(self)
...
@@ -4029,7 +4081,7 @@ SWIGINTERN PyObject *_wrap_UConnector_getTextName(PyObject *SWIGUNUSEDPARM(self)
int
ecode2
=
0
;
int
ecode2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getTextName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"OO:UConnector_getTextName"
,
&
obj0
,
&
obj1
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UConnector
,
0
|
0
);
...
@@ -4042,8 +4094,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getTextName(PyObject *SWIGUNUSEDPARM(self)
...
@@ -4042,8 +4094,8 @@ SWIGINTERN PyObject *_wrap_UConnector_getTextName(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getTextName"
"', argument "
"2"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode2
),
"in method '"
"UConnector_getTextName"
"', argument "
"2"" of type '"
"long""'"
);
}
}
arg2
=
static_cast
<
long
>
(
val2
);
arg2
=
static_cast
<
long
>
(
val2
);
result
=
(
char
*
)(
arg1
)
->
getTextName
(
arg2
);
result
=
(
arg1
)
->
getTextName
(
arg2
);
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
...
python/lib/pyUniSet/UExceptions.h
View file @
1d72749d
...
@@ -8,9 +8,9 @@ struct UException
...
@@ -8,9 +8,9 @@ struct UException
explicit
UException
(
const
char
*
e
)
:
err
(
std
::
string
(
e
))
{}
explicit
UException
(
const
char
*
e
)
:
err
(
std
::
string
(
e
))
{}
~
UException
()
{}
~
UException
()
{}
const
char
*
getError
()
const
std
::
string
getError
()
{
{
return
err
.
c_str
()
;
return
err
;
}
}
std
::
string
err
;
std
::
string
err
;
...
...
python/lib/pyUniSet/UExceptions.i
View file @
1d72749d
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
* to regenerate the wrappers run:
* to regenerate the wrappers run:
* swig -python UException.i
* swig -python UException.i
***********************************************************/
***********************************************************/
%include <std_string.i>
%module pyUExceptions
%module pyUExceptions
%{
%{
...
...
python/lib/pyUniSet/UExceptions_wrap.cxx
View file @
1d72749d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.
6
* Version 3.0.
7
*
*
* 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
...
@@ -2972,9 +2972,8 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2972,9 +2972,8 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
#define SWIGTYPE_p_USysError swig_types[1]
#define SWIGTYPE_p_USysError swig_types[1]
#define SWIGTYPE_p_UTimeOut swig_types[2]
#define SWIGTYPE_p_UTimeOut swig_types[2]
#define SWIGTYPE_p_char swig_types[3]
#define SWIGTYPE_p_char swig_types[3]
#define SWIGTYPE_p_std__string swig_types[4]
static
swig_type_info
*
swig_types
[
5
];
static
swig_type_info
*
swig_types
[
6
];
static
swig_module_info
swig_module
=
{
swig_types
,
4
,
0
,
0
,
0
,
0
};
static
swig_module_info
swig_module
=
{
swig_types
,
5
,
0
,
0
,
0
,
0
};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
...
@@ -2998,7 +2997,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
...
@@ -2998,7 +2997,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 0x03000
6
#define SWIGVERSION 0x03000
7
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3079,6 +3078,9 @@ namespace swig {
...
@@ -3079,6 +3078,9 @@ namespace swig {
}
}
#include <string>
#include "UExceptions.h"
#include "UExceptions.h"
...
@@ -3171,6 +3173,37 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
...
@@ -3171,6 +3173,37 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
}
}
SWIGINTERN
int
SWIG_AsPtr_std_string
(
PyObject
*
obj
,
std
::
string
**
val
)
{
char
*
buf
=
0
;
size_t
size
=
0
;
int
alloc
=
SWIG_OLDOBJ
;
if
(
SWIG_IsOK
((
SWIG_AsCharPtrAndSize
(
obj
,
&
buf
,
&
size
,
&
alloc
))))
{
if
(
buf
)
{
if
(
val
)
*
val
=
new
std
::
string
(
buf
,
size
-
1
);
if
(
alloc
==
SWIG_NEWOBJ
)
delete
[]
buf
;
return
SWIG_NEWOBJ
;
}
else
{
if
(
val
)
*
val
=
0
;
return
SWIG_OLDOBJ
;
}
}
else
{
static
int
init
=
0
;
static
swig_type_info
*
descriptor
=
0
;
if
(
!
init
)
{
descriptor
=
SWIG_TypeQuery
(
"std::string"
" *"
);
init
=
1
;
}
if
(
descriptor
)
{
std
::
string
*
vptr
;
int
res
=
SWIG_ConvertPtr
(
obj
,
(
void
**
)
&
vptr
,
descriptor
,
0
);
if
(
SWIG_IsOK
(
res
)
&&
val
)
*
val
=
vptr
;
return
res
;
}
}
return
SWIG_ERROR
;
}
...
@@ -3199,10 +3232,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
...
@@ -3199,10 +3232,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
}
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
SWIG_From
CharPtr
(
const
char
*
cptr
)
SWIG_From
_std_string
(
const
std
::
string
&
s
)
{
{
return
SWIG_FromCharPtrAndSize
(
cptr
,
(
cptr
?
strlen
(
cptr
)
:
0
));
return
SWIG_FromCharPtrAndSize
(
s
.
data
(),
s
.
size
(
));
}
}
#ifdef __cplusplus
#ifdef __cplusplus
...
@@ -3224,24 +3257,28 @@ fail:
...
@@ -3224,24 +3257,28 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UException__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UException__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
UException
*
result
=
0
;
UException
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UException"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UException"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
UException
*
)
new
UException
((
std
::
string
const
&
)
*
arg1
);
result
=
(
UException
*
)
new
UException
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UException
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UException
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3273,7 +3310,9 @@ fail:
...
@@ -3273,7 +3310,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -3286,7 +3325,7 @@ SWIGINTERN PyObject *_wrap_new_UException(PyObject *self, PyObject *args) {
...
@@ -3286,7 +3325,7 @@ SWIGINTERN PyObject *_wrap_new_UException(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UException__SWIG_1
(
self
,
args
);
return
_wrap_new_UException__SWIG_1
(
self
,
args
);
...
@@ -3338,7 +3377,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -3338,7 +3377,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
...
@@ -3346,8 +3385,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -3346,8 +3385,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getError
();
result
=
(
arg1
)
->
getError
();
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3357,11 +3396,10 @@ fail:
...
@@ -3357,11 +3396,10 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UException_err_set
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UException_err_set
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UException
*
arg1
=
(
UException
*
)
0
;
UException
*
arg1
=
(
UException
*
)
0
;
std
::
string
arg2
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
void
*
argp2
;
int
res2
=
SWIG_OLDOBJ
;
int
res2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
...
@@ -3372,22 +3410,22 @@ SWIGINTERN PyObject *_wrap_UException_err_set(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -3372,22 +3410,22 @@ SWIGINTERN PyObject *_wrap_UException_err_set(PyObject *SWIGUNUSEDPARM(self), Py
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
{
{
res2
=
SWIG_ConvertPtr
(
obj1
,
&
argp2
,
SWIGTYPE_p_std__string
,
0
|
0
);
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
}
if
(
!
argp2
)
{
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
else
{
std
::
string
*
temp
=
reinterpret_cast
<
std
::
string
*
>
(
argp2
);
arg2
=
*
temp
;
if
(
SWIG_IsNewObj
(
res2
))
delete
temp
;
}
}
arg2
=
ptr
;
}
}
if
(
arg1
)
(
arg1
)
->
err
=
arg2
;
if
(
arg1
)
(
arg1
)
->
err
=
*
arg2
;
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
SWIG_IsNewObj
(
res2
))
delete
arg2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res2
))
delete
arg2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3398,7 +3436,7 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -3398,7 +3436,7 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
std
::
string
result
;
std
::
string
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_err_get"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_err_get"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
...
@@ -3406,8 +3444,8 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -3406,8 +3444,8 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_err_get"
"', argument "
"1"" of type '"
"UException *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_err_get"
"', argument "
"1"" of type '"
"UException *""'"
);
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
result
=
((
arg1
)
->
err
);
result
=
(
std
::
string
*
)
&
((
arg1
)
->
err
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
resultobj
=
SWIG_
From_std_string
(
static_cast
<
std
::
string
>
(
*
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3437,31 +3475,37 @@ fail:
...
@@ -3437,31 +3475,37 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
UTimeOut
*
result
=
0
;
UTimeOut
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UTimeOut"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UTimeOut"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
UTimeOut
*
)
new
UTimeOut
((
std
::
string
const
&
)
*
arg1
);
result
=
(
UTimeOut
*
)
new
UTimeOut
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UTimeOut
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UTimeOut
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -3474,7 +3518,7 @@ SWIGINTERN PyObject *_wrap_new_UTimeOut(PyObject *self, PyObject *args) {
...
@@ -3474,7 +3518,7 @@ SWIGINTERN PyObject *_wrap_new_UTimeOut(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UTimeOut__SWIG_1
(
self
,
args
);
return
_wrap_new_UTimeOut__SWIG_1
(
self
,
args
);
...
@@ -3534,31 +3578,37 @@ fail:
...
@@ -3534,31 +3578,37 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_USysError__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_USysError__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
USysError
*
result
=
0
;
USysError
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_USysError"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_USysError"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
USysError
*
)
new
USysError
((
std
::
string
const
&
)
*
arg1
);
result
=
(
USysError
*
)
new
USysError
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_USysError
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_USysError
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -3571,7 +3621,7 @@ SWIGINTERN PyObject *_wrap_new_USysError(PyObject *self, PyObject *args) {
...
@@ -3571,7 +3621,7 @@ SWIGINTERN PyObject *_wrap_new_USysError(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_USysError__SWIG_1
(
self
,
args
);
return
_wrap_new_USysError__SWIG_1
(
self
,
args
);
...
@@ -3645,28 +3695,24 @@ static swig_type_info _swigt__p_UException = {"_p_UException", "UException *", 0
...
@@ -3645,28 +3695,24 @@ static swig_type_info _swigt__p_UException = {"_p_UException", "UException *", 0
static
swig_type_info
_swigt__p_USysError
=
{
"_p_USysError"
,
"USysError *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_USysError
=
{
"_p_USysError"
,
"USysError *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_UTimeOut
=
{
"_p_UTimeOut"
,
"UTimeOut *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_UTimeOut
=
{
"_p_UTimeOut"
,
"UTimeOut *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_char
=
{
"_p_char"
,
"char *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_char
=
{
"_p_char"
,
"char *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_std__string
=
{
"_p_std__string"
,
"std::string *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
*
swig_type_initial
[]
=
{
static
swig_type_info
*
swig_type_initial
[]
=
{
&
_swigt__p_UException
,
&
_swigt__p_UException
,
&
_swigt__p_USysError
,
&
_swigt__p_USysError
,
&
_swigt__p_UTimeOut
,
&
_swigt__p_UTimeOut
,
&
_swigt__p_char
,
&
_swigt__p_char
,
&
_swigt__p_std__string
,
};
};
static
swig_cast_info
_swigc__p_UException
[]
=
{
{
&
_swigt__p_UException
,
0
,
0
,
0
},
{
&
_swigt__p_UTimeOut
,
_p_UTimeOutTo_p_UException
,
0
,
0
},
{
&
_swigt__p_USysError
,
_p_USysErrorTo_p_UException
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_UException
[]
=
{
{
&
_swigt__p_UException
,
0
,
0
,
0
},
{
&
_swigt__p_UTimeOut
,
_p_UTimeOutTo_p_UException
,
0
,
0
},
{
&
_swigt__p_USysError
,
_p_USysErrorTo_p_UException
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_USysError
[]
=
{
{
&
_swigt__p_USysError
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_USysError
[]
=
{
{
&
_swigt__p_USysError
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_UTimeOut
[]
=
{
{
&
_swigt__p_UTimeOut
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_UTimeOut
[]
=
{
{
&
_swigt__p_UTimeOut
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_char
[]
=
{
{
&
_swigt__p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_char
[]
=
{
{
&
_swigt__p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_std__string
[]
=
{
{
&
_swigt__p_std__string
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
*
swig_cast_initial
[]
=
{
static
swig_cast_info
*
swig_cast_initial
[]
=
{
_swigc__p_UException
,
_swigc__p_UException
,
_swigc__p_USysError
,
_swigc__p_USysError
,
_swigc__p_UTimeOut
,
_swigc__p_UTimeOut
,
_swigc__p_char
,
_swigc__p_char
,
_swigc__p_std__string
,
};
};
...
...
python/lib/pyUniSet/UInterface_wrap.cxx
View file @
1d72749d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.
6
* Version 3.0.
7
*
*
* 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
...
@@ -3000,7 +3000,7 @@ static swig_module_info swig_module = {swig_types, 7, 0, 0, 0, 0};
...
@@ -3000,7 +3000,7 @@ static swig_module_info swig_module = {swig_types, 7, 0, 0, 0, 0};
#endif
#endif
#define SWIG_name "_pyUniSet"
#define SWIG_name "_pyUniSet"
#define SWIGVERSION 0x03000
6
#define SWIGVERSION 0x03000
7
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3084,98 +3084,6 @@ namespace swig {
...
@@ -3084,98 +3084,6 @@ namespace swig {
#include "PyUInterface.h"
#include "PyUInterface.h"
SWIGINTERN
swig_type_info
*
SWIG_pchar_descriptor
(
void
)
{
static
int
init
=
0
;
static
swig_type_info
*
info
=
0
;
if
(
!
init
)
{
info
=
SWIG_TypeQuery
(
"_p_char"
);
init
=
1
;
}
return
info
;
}
SWIGINTERN
int
SWIG_AsCharPtrAndSize
(
PyObject
*
obj
,
char
**
cptr
,
size_t
*
psize
,
int
*
alloc
)
{
#if PY_VERSION_HEX>=0x03000000
if
(
PyUnicode_Check
(
obj
))
#else
if
(
PyString_Check
(
obj
))
#endif
{
char
*
cstr
;
Py_ssize_t
len
;
#if PY_VERSION_HEX>=0x03000000
if
(
!
alloc
&&
cptr
)
{
/* We can't allow converting without allocation, since the internal
representation of string in Python 3 is UCS-2/UCS-4 but we require
a UTF-8 representation.
TODO(bhy) More detailed explanation */
return
SWIG_RuntimeError
;
}
obj
=
PyUnicode_AsUTF8String
(
obj
);
PyBytes_AsStringAndSize
(
obj
,
&
cstr
,
&
len
);
if
(
alloc
)
*
alloc
=
SWIG_NEWOBJ
;
#else
PyString_AsStringAndSize
(
obj
,
&
cstr
,
&
len
);
#endif
if
(
cptr
)
{
if
(
alloc
)
{
/*
In python the user should not be able to modify the inner
string representation. To warranty that, if you define
SWIG_PYTHON_SAFE_CSTRINGS, a new/copy of the python string
buffer is always returned.
The default behavior is just to return the pointer value,
so, be careful.
*/
#if defined(SWIG_PYTHON_SAFE_CSTRINGS)
if
(
*
alloc
!=
SWIG_OLDOBJ
)
#else
if
(
*
alloc
==
SWIG_NEWOBJ
)
#endif
{
*
cptr
=
reinterpret_cast
<
char
*
>
(
memcpy
((
new
char
[
len
+
1
]),
cstr
,
sizeof
(
char
)
*
(
len
+
1
)));
*
alloc
=
SWIG_NEWOBJ
;
}
else
{
*
cptr
=
cstr
;
*
alloc
=
SWIG_OLDOBJ
;
}
}
else
{
#if PY_VERSION_HEX>=0x03000000
assert
(
0
);
/* Should never reach here in Python 3 */
#endif
*
cptr
=
SWIG_Python_str_AsChar
(
obj
);
}
}
if
(
psize
)
*
psize
=
len
+
1
;
#if PY_VERSION_HEX>=0x03000000
Py_XDECREF
(
obj
);
#endif
return
SWIG_OK
;
}
else
{
swig_type_info
*
pchar_descriptor
=
SWIG_pchar_descriptor
();
if
(
pchar_descriptor
)
{
void
*
vptr
=
0
;
if
(
SWIG_ConvertPtr
(
obj
,
&
vptr
,
pchar_descriptor
,
0
)
==
SWIG_OK
)
{
if
(
cptr
)
*
cptr
=
(
char
*
)
vptr
;
if
(
psize
)
*
psize
=
vptr
?
(
strlen
((
char
*
)
vptr
)
+
1
)
:
0
;
if
(
alloc
)
*
alloc
=
SWIG_OLDOBJ
;
return
SWIG_OK
;
}
}
}
return
SWIG_TypeError
;
}
#include <limits.h>
#include <limits.h>
#if !defined(SWIG_NO_LLONG_MAX)
#if !defined(SWIG_NO_LLONG_MAX)
# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
...
@@ -3324,43 +3232,103 @@ SWIG_AsVal_int (PyObject * obj, int *val)
...
@@ -3324,43 +3232,103 @@ SWIG_AsVal_int (PyObject * obj, int *val)
#define SWIG_From_long PyLong_FromLong
#define SWIG_From_long PyLong_FromLong
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
SWIG_FromCharPtrAndSize
(
const
char
*
carray
,
size_t
siz
e
)
SWIG_From_int
(
int
valu
e
)
{
{
if
(
carray
)
{
return
PyInt_FromLong
((
long
)
value
);
if
(
size
>
INT_MAX
)
{
}
swig_type_info
*
pchar_descriptor
=
SWIG_pchar_descriptor
();
return
pchar_descriptor
?
SWIG_InternalNewPointerObj
(
const_cast
<
char
*
>
(
carray
),
pchar_descriptor
,
0
)
:
SWIG_Py_Void
();
SWIGINTERN
swig_type_info
*
}
else
{
SWIG_pchar_descriptor
(
void
)
#if PY_VERSION_HEX >= 0x03000000
{
#if PY_VERSION_HEX >= 0x03010000
static
int
init
=
0
;
return
PyUnicode_DecodeUTF8
(
carray
,
static_cast
<
int
>
(
size
),
"surrogateescape"
);
static
swig_type_info
*
info
=
0
;
if
(
!
init
)
{
info
=
SWIG_TypeQuery
(
"_p_char"
);
init
=
1
;
}
return
info
;
}
SWIGINTERN
int
SWIG_AsCharPtrAndSize
(
PyObject
*
obj
,
char
**
cptr
,
size_t
*
psize
,
int
*
alloc
)
{
#if PY_VERSION_HEX>=0x03000000
if
(
PyUnicode_Check
(
obj
))
#else
if
(
PyString_Check
(
obj
))
#endif
{
char
*
cstr
;
Py_ssize_t
len
;
#if PY_VERSION_HEX>=0x03000000
if
(
!
alloc
&&
cptr
)
{
/* We can't allow converting without allocation, since the internal
representation of string in Python 3 is UCS-2/UCS-4 but we require
a UTF-8 representation.
TODO(bhy) More detailed explanation */
return
SWIG_RuntimeError
;
}
obj
=
PyUnicode_AsUTF8String
(
obj
);
PyBytes_AsStringAndSize
(
obj
,
&
cstr
,
&
len
);
if
(
alloc
)
*
alloc
=
SWIG_NEWOBJ
;
#else
#else
return
PyUnicode_FromStringAndSize
(
carray
,
static_cast
<
int
>
(
size
)
);
PyString_AsStringAndSize
(
obj
,
&
cstr
,
&
len
);
#endif
#endif
if
(
cptr
)
{
if
(
alloc
)
{
/*
In python the user should not be able to modify the inner
string representation. To warranty that, if you define
SWIG_PYTHON_SAFE_CSTRINGS, a new/copy of the python string
buffer is always returned.
The default behavior is just to return the pointer value,
so, be careful.
*/
#if defined(SWIG_PYTHON_SAFE_CSTRINGS)
if
(
*
alloc
!=
SWIG_OLDOBJ
)
#else
#else
return
PyString_FromStringAndSize
(
carray
,
static_cast
<
int
>
(
size
));
if
(
*
alloc
==
SWIG_NEWOBJ
)
#endif
#endif
{
*
cptr
=
reinterpret_cast
<
char
*
>
(
memcpy
((
new
char
[
len
+
1
]),
cstr
,
sizeof
(
char
)
*
(
len
+
1
)));
*
alloc
=
SWIG_NEWOBJ
;
}
else
{
*
cptr
=
cstr
;
*
alloc
=
SWIG_OLDOBJ
;
}
}
else
{
#if PY_VERSION_HEX>=0x03000000
assert
(
0
);
/* Should never reach here in Python 3 */
#endif
*
cptr
=
SWIG_Python_str_AsChar
(
obj
);
}
}
}
if
(
psize
)
*
psize
=
len
+
1
;
#if PY_VERSION_HEX>=0x03000000
Py_XDECREF
(
obj
);
#endif
return
SWIG_OK
;
}
else
{
}
else
{
return
SWIG_Py_Void
();
swig_type_info
*
pchar_descriptor
=
SWIG_pchar_descriptor
();
if
(
pchar_descriptor
)
{
void
*
vptr
=
0
;
if
(
SWIG_ConvertPtr
(
obj
,
&
vptr
,
pchar_descriptor
,
0
)
==
SWIG_OK
)
{
if
(
cptr
)
*
cptr
=
(
char
*
)
vptr
;
if
(
psize
)
*
psize
=
vptr
?
(
strlen
((
char
*
)
vptr
)
+
1
)
:
0
;
if
(
alloc
)
*
alloc
=
SWIG_OLDOBJ
;
return
SWIG_OK
;
}
}
}
}
return
SWIG_TypeError
;
}
}
SWIGINTERNINLINE
PyObject
*
SWIG_FromCharPtr
(
const
char
*
cptr
)
{
return
SWIG_FromCharPtrAndSize
(
cptr
,
(
cptr
?
strlen
(
cptr
)
:
0
));
}
SWIGINTERNINLINE
PyObject
*
SWIG_From_int
(
int
value
)
{
return
PyInt_FromLong
((
long
)
value
);
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
...
@@ -3375,12 +3343,11 @@ extern "C" {
...
@@ -3375,12 +3343,11 @@ extern "C" {
SWIGINTERN
PyObject
*
_wrap_uniset_init_params
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_uniset_init_params
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UTypes
::
Params
*
arg1
=
(
UTypes
::
Params
*
)
0
;
UTypes
::
Params
*
arg1
=
(
UTypes
::
Params
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
void
*
argp2
=
0
;
char
*
buf2
=
0
;
int
res2
=
0
;
int
alloc2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
...
@@ -3390,23 +3357,24 @@ SWIGINTERN PyObject *_wrap_uniset_init_params(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -3390,23 +3357,24 @@ SWIGINTERN PyObject *_wrap_uniset_init_params(PyObject *SWIGUNUSEDPARM(self), Py
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"uniset_init_params"
"', argument "
"1"" of type '"
"UTypes::Params *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"uniset_init_params"
"', argument "
"1"" of type '"
"UTypes::Params *""'"
);
}
}
arg1
=
reinterpret_cast
<
UTypes
::
Params
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UTypes
::
Params
*
>
(
argp1
);
res2
=
SWIG_
AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
res2
=
SWIG_
ConvertPtr
(
obj1
,
&
argp2
,
SWIGTYPE_p_std__string
,
0
|
0
);
if
(
!
SWIG_IsOK
(
res2
))
{
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"uniset_init_params"
"', argument "
"2"" of type '"
"
char const *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"uniset_init_params"
"', argument "
"2"" of type '"
"
std::string const &""'"
);
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
if
(
!
argp2
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"uniset_init_params"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
reinterpret_cast
<
std
::
string
*
>
(
argp2
);
try
{
try
{
pyUInterface
::
uniset_init_params
(
arg1
,(
char
const
*
)
arg2
);
pyUInterface
::
uniset_init_params
(
arg1
,(
std
::
string
const
&
)
*
arg2
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3415,14 +3383,13 @@ SWIGINTERN PyObject *_wrap_uniset_init(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3415,14 +3383,13 @@ SWIGINTERN PyObject *_wrap_uniset_init(PyObject *SWIGUNUSEDPARM(self), PyObject
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
int
arg1
;
int
arg1
;
char
**
arg2
=
(
char
**
)
0
;
char
**
arg2
=
(
char
**
)
0
;
char
*
arg3
=
(
char
*
)
0
;
std
::
string
*
arg3
=
0
;
int
val1
;
int
val1
;
int
ecode1
=
0
;
int
ecode1
=
0
;
void
*
argp2
=
0
;
void
*
argp2
=
0
;
int
res2
=
0
;
int
res2
=
0
;
int
res3
;
void
*
argp3
=
0
;
char
*
buf3
=
0
;
int
res3
=
0
;
int
alloc3
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj2
=
0
;
PyObject
*
obj2
=
0
;
...
@@ -3438,23 +3405,24 @@ SWIGINTERN PyObject *_wrap_uniset_init(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3438,23 +3405,24 @@ SWIGINTERN PyObject *_wrap_uniset_init(PyObject *SWIGUNUSEDPARM(self), PyObject
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"uniset_init"
"', argument "
"2"" of type '"
"char **""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"uniset_init"
"', argument "
"2"" of type '"
"char **""'"
);
}
}
arg2
=
reinterpret_cast
<
char
**
>
(
argp2
);
arg2
=
reinterpret_cast
<
char
**
>
(
argp2
);
res3
=
SWIG_
AsCharPtrAndSize
(
obj2
,
&
buf3
,
NULL
,
&
alloc3
);
res3
=
SWIG_
ConvertPtr
(
obj2
,
&
argp3
,
SWIGTYPE_p_std__string
,
0
|
0
);
if
(
!
SWIG_IsOK
(
res3
))
{
if
(
!
SWIG_IsOK
(
res3
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res3
),
"in method '"
"uniset_init"
"', argument "
"3"" of type '"
"char const *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res3
),
"in method '"
"uniset_init"
"', argument "
"3"" of type '"
"std::string const &""'"
);
}
if
(
!
argp3
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"uniset_init"
"', argument "
"3"" of type '"
"std::string const &""'"
);
}
}
arg3
=
reinterpret_cast
<
char
*
>
(
buf
3
);
arg3
=
reinterpret_cast
<
std
::
string
*
>
(
argp
3
);
try
{
try
{
pyUInterface
::
uniset_init
(
arg1
,
arg2
,(
char
const
*
)
arg3
);
pyUInterface
::
uniset_init
(
arg1
,
arg2
,(
std
::
string
const
&
)
*
arg3
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc3
==
SWIG_NEWOBJ
)
delete
[]
buf3
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc3
==
SWIG_NEWOBJ
)
delete
[]
buf3
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3525,25 +3493,25 @@ fail:
...
@@ -3525,25 +3493,25 @@ fail:
SWIGINTERN
PyObject
*
_wrap_getSensorID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_getSensorID
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
char
*
arg1
=
(
char
*
)
0
;
std
::
string
*
arg1
=
0
;
int
res1
;
void
*
argp1
=
0
;
char
*
buf1
=
0
;
int
res1
=
0
;
int
alloc1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
long
result
;
long
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getSensorID"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getSensorID"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_
AsCharPtrAndSize
(
obj0
,
&
buf1
,
NULL
,
&
alloc1
);
res1
=
SWIG_
ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
SWIG_IsOK
(
res1
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"getSensorID"
"', argument "
"1"" of type '"
"
char const *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"getSensorID"
"', argument "
"1"" of type '"
"
std::string const &""'"
);
}
}
arg1
=
reinterpret_cast
<
char
*
>
(
buf1
);
if
(
!
argp1
)
{
result
=
(
long
)
pyUInterface
::
getSensorID
((
char
const
*
)
arg1
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"getSensorID"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
long
)
pyUInterface
::
getSensorID
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc1
==
SWIG_NEWOBJ
)
delete
[]
buf1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc1
==
SWIG_NEWOBJ
)
delete
[]
buf1
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3554,7 +3522,7 @@ SWIGINTERN PyObject *_wrap_getShortName(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3554,7 +3522,7 @@ SWIGINTERN PyObject *_wrap_getShortName(PyObject *SWIGUNUSEDPARM(self), PyObject
long
val1
;
long
val1
;
int
ecode1
=
0
;
int
ecode1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getShortName"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getShortName"
,
&
obj0
))
SWIG_fail
;
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
...
@@ -3562,8 +3530,8 @@ SWIGINTERN PyObject *_wrap_getShortName(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3562,8 +3530,8 @@ SWIGINTERN PyObject *_wrap_getShortName(PyObject *SWIGUNUSEDPARM(self), PyObject
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getShortName"
"', argument "
"1"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getShortName"
"', argument "
"1"" of type '"
"long""'"
);
}
}
arg1
=
static_cast
<
long
>
(
val1
);
arg1
=
static_cast
<
long
>
(
val1
);
result
=
(
char
*
)
pyUInterface
::
getShortName
(
arg1
);
result
=
pyUInterface
::
getShortName
(
arg1
);
resultobj
=
SWIG_
FromCharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3576,7 +3544,7 @@ SWIGINTERN PyObject *_wrap_getName(PyObject *SWIGUNUSEDPARM(self), PyObject *arg
...
@@ -3576,7 +3544,7 @@ SWIGINTERN PyObject *_wrap_getName(PyObject *SWIGUNUSEDPARM(self), PyObject *arg
long
val1
;
long
val1
;
int
ecode1
=
0
;
int
ecode1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getName"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getName"
,
&
obj0
))
SWIG_fail
;
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
...
@@ -3584,8 +3552,8 @@ SWIGINTERN PyObject *_wrap_getName(PyObject *SWIGUNUSEDPARM(self), PyObject *arg
...
@@ -3584,8 +3552,8 @@ SWIGINTERN PyObject *_wrap_getName(PyObject *SWIGUNUSEDPARM(self), PyObject *arg
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getName"
"', argument "
"1"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getName"
"', argument "
"1"" of type '"
"long""'"
);
}
}
arg1
=
static_cast
<
long
>
(
val1
);
arg1
=
static_cast
<
long
>
(
val1
);
result
=
(
char
*
)
pyUInterface
::
getName
(
arg1
);
result
=
pyUInterface
::
getName
(
arg1
);
resultobj
=
SWIG_
FromCharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3598,7 +3566,7 @@ SWIGINTERN PyObject *_wrap_getTextName(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3598,7 +3566,7 @@ SWIGINTERN PyObject *_wrap_getTextName(PyObject *SWIGUNUSEDPARM(self), PyObject
long
val1
;
long
val1
;
int
ecode1
=
0
;
int
ecode1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getTextName"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:getTextName"
,
&
obj0
))
SWIG_fail
;
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
ecode1
=
SWIG_AsVal_long
(
obj0
,
&
val1
);
...
@@ -3606,8 +3574,8 @@ SWIGINTERN PyObject *_wrap_getTextName(PyObject *SWIGUNUSEDPARM(self), PyObject
...
@@ -3606,8 +3574,8 @@ SWIGINTERN PyObject *_wrap_getTextName(PyObject *SWIGUNUSEDPARM(self), PyObject
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getTextName"
"', argument "
"1"" of type '"
"long""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode1
),
"in method '"
"getTextName"
"', argument "
"1"" of type '"
"long""'"
);
}
}
arg1
=
static_cast
<
long
>
(
val1
);
arg1
=
static_cast
<
long
>
(
val1
);
result
=
(
char
*
)
pyUInterface
::
getTextName
(
arg1
);
result
=
pyUInterface
::
getTextName
(
arg1
);
resultobj
=
SWIG_
FromCharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3616,11 +3584,11 @@ fail:
...
@@ -3616,11 +3584,11 @@ fail:
SWIGINTERN
PyObject
*
_wrap_getConfFileName
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_getConfFileName
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
":getConfFileName"
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
":getConfFileName"
))
SWIG_fail
;
result
=
(
char
*
)
pyUInterface
::
getConfFileName
();
result
=
pyUInterface
::
getConfFileName
();
resultobj
=
SWIG_
FromCharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3905,7 +3873,9 @@ fail:
...
@@ -3905,7 +3873,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -3970,7 +3940,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -3970,7 +3940,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
...
@@ -3978,8 +3948,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -3978,8 +3948,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getError
();
result
=
(
arg1
)
->
getError
();
resultobj
=
SWIG_
FromCharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -4093,7 +4063,9 @@ fail:
...
@@ -4093,7 +4063,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4190,7 +4162,9 @@ fail:
...
@@ -4190,7 +4162,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
...
python/lib/pyUniSet/UModbus.cc
View file @
1d72749d
...
@@ -52,16 +52,14 @@ UModbus::~UModbus()
...
@@ -52,16 +52,14 @@ UModbus::~UModbus()
delete
mb
;
delete
mb
;
}
}
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
void
UModbus
::
prepare
(
const
char
*
_ip
,
int
_port
)
throw
(
UException
)
void
UModbus
::
prepare
(
const
string
&
_ip
,
int
_port
)
throw
(
UException
)
{
{
if
(
!
mb
)
if
(
!
mb
)
throw
UException
(
"(connect): mb=NULL?!"
);
throw
UException
(
"(connect): mb=NULL?!"
);
string
s
(
_ip
);
if
(
mb
->
isConnection
()
)
if
(
mb
->
isConnection
()
)
{
{
if
(
_port
==
port
&&
s
==
ip
)
if
(
_port
==
port
&&
_ip
==
ip
)
return
;
return
;
mb
->
disconnect
();
mb
->
disconnect
();
...
@@ -69,28 +67,26 @@ void UModbus::prepare( const char* _ip, int _port )throw(UException)
...
@@ -69,28 +67,26 @@ void UModbus::prepare( const char* _ip, int _port )throw(UException)
//cerr << "************** Prepare: " << string(_ip) << ":" << port << endl;
//cerr << "************** Prepare: " << string(_ip) << ":" << port << endl;
// strncpy(char *dest, const char *src, size_t n);
// strncpy(char *dest, const char *src, size_t n);
ip
=
s
;
ip
=
_ip
;
port
=
_port
;
port
=
_port
;
}
}
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
void
UModbus
::
connect
(
const
char
*
_ip
,
int
_port
)
throw
(
UException
)
void
UModbus
::
connect
(
const
string
&
_ip
,
int
_port
)
throw
(
UException
)
{
{
if
(
!
mb
)
if
(
!
mb
)
throw
UException
(
"(connect): mb=NULL?!"
);
throw
UException
(
"(connect): mb=NULL?!"
);
string
s
(
_ip
);
if
(
mb
->
isConnection
()
)
if
(
mb
->
isConnection
()
)
{
{
if
(
_port
==
port
&&
s
==
ip
)
if
(
_port
==
port
&&
_ip
==
ip
)
return
;
return
;
mb
->
disconnect
();
mb
->
disconnect
();
}
}
ip
=
s
;
ip
=
_ip
;
port
=
_port
;
port
=
_port
;
ost
::
InetAddress
ia
(
_ip
);
ost
::
InetAddress
ia
(
_ip
.
c_str
()
);
try
try
{
{
...
@@ -126,13 +122,12 @@ bool UModbus::getBit( int addr, int mbreg, int mbfunc )throw(UException)
...
@@ -126,13 +122,12 @@ bool UModbus::getBit( int addr, int mbreg, int mbfunc )throw(UException)
return
mbread
(
addr
,
mbreg
,
mbfunc
,
"unsigned"
);
return
mbread
(
addr
,
mbreg
,
mbfunc
,
"unsigned"
);
}
}
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
long
UModbus
::
mbread
(
int
mbaddr
,
int
mbreg
,
int
mbfunc
,
const
char
*
s_vtype
,
int
nbit
,
long
UModbus
::
mbread
(
int
mbaddr
,
int
mbreg
,
int
mbfunc
,
const
string
&
s_vtype
,
int
nbit
,
const
char
*
new_ip
,
int
new_port
)
throw
(
UException
)
const
string
&
new_ip
,
int
new_port
)
throw
(
UException
)
{
{
using
namespace
VTypes
;
using
namespace
VTypes
;
// const char* n_ip = strcmp(new_ip,"") ? new_ip : ip;
string
n_ip
(
(
new_ip
.
empty
()
?
ip
:
new_ip
)
);
const
char
*
n_ip
=
(
new_ip
!=
0
)
?
new_ip
:
ip
.
c_str
();
int
n_port
=
(
new_port
>
0
)
?
new_port
:
port
;
int
n_port
=
(
new_port
>
0
)
?
new_port
:
port
;
connect
(
n_ip
,
n_port
);
connect
(
n_ip
,
n_port
);
...
@@ -290,9 +285,9 @@ long UModbus::data2value( VTypes::VType vtype, ModbusRTU::ModbusData* data )
...
@@ -290,9 +285,9 @@ long UModbus::data2value( VTypes::VType vtype, ModbusRTU::ModbusData* data )
return
0
;
return
0
;
}
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
void
UModbus
::
mbwrite
(
int
mbaddr
,
int
mbreg
,
int
val
,
int
mbfunc
,
const
char
*
new_ip
,
int
new_port
)
throw
(
UException
)
void
UModbus
::
mbwrite
(
int
mbaddr
,
int
mbreg
,
int
val
,
int
mbfunc
,
const
string
&
new_ip
,
int
new_port
)
throw
(
UException
)
{
{
const
char
*
n_ip
=
(
new_ip
!=
0
)
?
new_ip
:
ip
.
c_str
(
);
string
n_ip
(
(
new_ip
.
empty
()
?
ip
:
new_ip
)
);
int
n_port
=
(
new_port
>
0
)
?
new_port
:
port
;
int
n_port
=
(
new_port
>
0
)
?
new_port
:
port
;
connect
(
n_ip
,
n_port
);
connect
(
n_ip
,
n_port
);
...
...
python/lib/pyUniSet/UModbus.h
View file @
1d72749d
...
@@ -13,14 +13,13 @@
...
@@ -13,14 +13,13 @@
class
UModbus
class
UModbus
{
{
public
:
public
:
// UModbus( int argc, char** argv )throw(UException);
// UModbus( UTypes::Params* p )throw(UException);
UModbus
();
UModbus
();
~
UModbus
();
~
UModbus
();
inline
const
char
*
getUIType
()
inline
std
::
string
getUIType
()
{
{
return
"modbus"
;
return
string
(
"modbus"
)
;
}
}
inline
bool
isWriteFunction
(
int
mbfunc
)
inline
bool
isWriteFunction
(
int
mbfunc
)
...
@@ -29,9 +28,9 @@ class UModbus
...
@@ -29,9 +28,9 @@ class UModbus
}
}
// выставление паметров связи, без установления соединения (!)
// выставление паметров связи, без установления соединения (!)
void
prepare
(
const
char
*
ip
,
int
port
)
throw
(
UException
);
void
prepare
(
const
std
::
string
&
ip
,
int
port
)
throw
(
UException
);
void
connect
(
const
char
*
ip
,
int
port
)
throw
(
UException
);
void
connect
(
const
std
::
string
&
ip
,
int
port
)
throw
(
UException
);
inline
int
conn_port
()
inline
int
conn_port
()
{
{
return
port
;
return
port
;
...
@@ -56,8 +55,8 @@ class UModbus
...
@@ -56,8 +55,8 @@ class UModbus
* будет сделано переподключение..
* будет сделано переподключение..
*/
*/
long
mbread
(
int
addr
,
int
mbreg
,
int
mbfunc
,
long
mbread
(
int
addr
,
int
mbreg
,
int
mbfunc
,
const
char
*
vtype
,
int
nbit
=
-
1
,
const
std
::
string
&
vtype
,
int
nbit
=
-
1
,
const
char
*
ip
=
0
,
int
port
=
-
1
)
throw
(
UException
);
const
std
::
string
&
ip
=
""
,
int
port
=
-
1
)
throw
(
UException
);
long
getWord
(
int
addr
,
int
mbreg
,
int
mbfunc
=
0x4
)
throw
(
UException
);
long
getWord
(
int
addr
,
int
mbreg
,
int
mbfunc
=
0x4
)
throw
(
UException
);
long
getByte
(
int
addr
,
int
mbreg
,
int
mbfunc
=
0x4
)
throw
(
UException
);
long
getByte
(
int
addr
,
int
mbreg
,
int
mbfunc
=
0x4
)
throw
(
UException
);
...
@@ -68,7 +67,7 @@ class UModbus
...
@@ -68,7 +67,7 @@ class UModbus
* чтобы были заданы в UModbus::connect(). Если заданы другие ip и port,
* чтобы были заданы в UModbus::connect(). Если заданы другие ip и port,
* будет сделана переподключение..
* будет сделана переподключение..
*/
*/
void
mbwrite
(
int
addr
,
int
mbreg
,
int
val
,
int
mbfunc
,
const
char
*
ip
=
0
,
int
port
=
-
1
)
throw
(
UException
);
void
mbwrite
(
int
addr
,
int
mbreg
,
int
val
,
int
mbfunc
,
const
std
::
string
&
ip
=
""
,
int
port
=
-
1
)
throw
(
UException
);
protected
:
protected
:
long
data2value
(
VTypes
::
VType
vt
,
ModbusRTU
::
ModbusData
*
data
);
long
data2value
(
VTypes
::
VType
vt
,
ModbusRTU
::
ModbusData
*
data
);
...
...
python/lib/pyUniSet/UModbus.i
View file @
1d72749d
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
* to regenerate the wrappers run:
* to regenerate the wrappers run:
* swig -python UInterface.i
* swig -python UInterface.i
***********************************************************/
***********************************************************/
%include <std_string.i>
%module pyUModbus
%module pyUModbus
%{
%{
...
...
python/lib/pyUniSet/UModbus_wrap.cxx
View file @
1d72749d
/* ----------------------------------------------------------------------------
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.
6
* Version 3.0.
7
*
*
* 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
...
@@ -2975,9 +2975,8 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
...
@@ -2975,9 +2975,8 @@ SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
#define SWIGTYPE_p_UTypes__Params swig_types[4]
#define SWIGTYPE_p_UTypes__Params swig_types[4]
#define SWIGTYPE_p_char swig_types[5]
#define SWIGTYPE_p_char swig_types[5]
#define SWIGTYPE_p_p_char swig_types[6]
#define SWIGTYPE_p_p_char swig_types[6]
#define SWIGTYPE_p_std__string swig_types[7]
static
swig_type_info
*
swig_types
[
8
];
static
swig_type_info
*
swig_types
[
9
];
static
swig_module_info
swig_module
=
{
swig_types
,
7
,
0
,
0
,
0
,
0
};
static
swig_module_info
swig_module
=
{
swig_types
,
8
,
0
,
0
,
0
,
0
};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
...
@@ -3001,7 +3000,7 @@ static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0};
...
@@ -3001,7 +3000,7 @@ static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0};
#endif
#endif
#define SWIG_name "_pyUModbus"
#define SWIG_name "_pyUModbus"
#define SWIGVERSION 0x03000
6
#define SWIGVERSION 0x03000
7
#define SWIG_VERSION SWIGVERSION
#define SWIG_VERSION SWIGVERSION
...
@@ -3082,6 +3081,9 @@ namespace swig {
...
@@ -3082,6 +3081,9 @@ namespace swig {
}
}
#include <string>
#include "UModbus.h"
#include "UModbus.h"
...
@@ -3123,10 +3125,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
...
@@ -3123,10 +3125,10 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
}
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
SWIG_From
CharPtr
(
const
char
*
cptr
)
SWIG_From
_std_string
(
const
std
::
string
&
s
)
{
{
return
SWIG_FromCharPtrAndSize
(
cptr
,
(
cptr
?
strlen
(
cptr
)
:
0
));
return
SWIG_FromCharPtrAndSize
(
s
.
data
(),
s
.
size
(
));
}
}
...
@@ -3358,7 +3360,35 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
...
@@ -3358,7 +3360,35 @@ SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
}
}
SWIGINTERN
int
SWIG_AsPtr_std_string
(
PyObject
*
obj
,
std
::
string
**
val
)
{
char
*
buf
=
0
;
size_t
size
=
0
;
int
alloc
=
SWIG_OLDOBJ
;
if
(
SWIG_IsOK
((
SWIG_AsCharPtrAndSize
(
obj
,
&
buf
,
&
size
,
&
alloc
))))
{
if
(
buf
)
{
if
(
val
)
*
val
=
new
std
::
string
(
buf
,
size
-
1
);
if
(
alloc
==
SWIG_NEWOBJ
)
delete
[]
buf
;
return
SWIG_NEWOBJ
;
}
else
{
if
(
val
)
*
val
=
0
;
return
SWIG_OLDOBJ
;
}
}
else
{
static
int
init
=
0
;
static
swig_type_info
*
descriptor
=
0
;
if
(
!
init
)
{
descriptor
=
SWIG_TypeQuery
(
"std::string"
" *"
);
init
=
1
;
}
if
(
descriptor
)
{
std
::
string
*
vptr
;
int
res
=
SWIG_ConvertPtr
(
obj
,
(
void
**
)
&
vptr
,
descriptor
,
0
);
if
(
SWIG_IsOK
(
res
)
&&
val
)
*
val
=
vptr
;
return
res
;
}
}
return
SWIG_ERROR
;
}
SWIGINTERNINLINE
PyObject
*
SWIGINTERNINLINE
PyObject
*
...
@@ -3370,6 +3400,9 @@ SWIGINTERNINLINE PyObject*
...
@@ -3370,6 +3400,9 @@ SWIGINTERNINLINE PyObject*
#define SWIG_From_long PyLong_FromLong
#define SWIG_From_long PyLong_FromLong
#ifdef __cplusplus
#ifdef __cplusplus
extern
"C"
{
extern
"C"
{
#endif
#endif
...
@@ -3413,7 +3446,7 @@ SWIGINTERN PyObject *_wrap_UModbus_getUIType(PyObject *SWIGUNUSEDPARM(self), PyO
...
@@ -3413,7 +3446,7 @@ SWIGINTERN PyObject *_wrap_UModbus_getUIType(PyObject *SWIGUNUSEDPARM(self), PyO
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UModbus_getUIType"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UModbus_getUIType"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UModbus
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UModbus
,
0
|
0
);
...
@@ -3421,8 +3454,8 @@ SWIGINTERN PyObject *_wrap_UModbus_getUIType(PyObject *SWIGUNUSEDPARM(self), PyO
...
@@ -3421,8 +3454,8 @@ SWIGINTERN PyObject *_wrap_UModbus_getUIType(PyObject *SWIGUNUSEDPARM(self), PyO
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_getUIType"
"', argument "
"1"" of type '"
"UModbus *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_getUIType"
"', argument "
"1"" of type '"
"UModbus *""'"
);
}
}
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getUIType
();
result
=
(
arg1
)
->
getUIType
();
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3463,13 +3496,11 @@ fail:
...
@@ -3463,13 +3496,11 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_prepare
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_prepare
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UModbus
*
arg1
=
(
UModbus
*
)
0
;
UModbus
*
arg1
=
(
UModbus
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
int
arg3
;
int
arg3
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
int
res2
=
SWIG_OLDOBJ
;
char
*
buf2
=
0
;
int
alloc2
=
0
;
int
val3
;
int
val3
;
int
ecode3
=
0
;
int
ecode3
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
...
@@ -3482,28 +3513,34 @@ SWIGINTERN PyObject *_wrap_UModbus_prepare(PyObject *SWIGUNUSEDPARM(self), PyObj
...
@@ -3482,28 +3513,34 @@ SWIGINTERN PyObject *_wrap_UModbus_prepare(PyObject *SWIGUNUSEDPARM(self), PyObj
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_prepare"
"', argument "
"1"" of type '"
"UModbus *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_prepare"
"', argument "
"1"" of type '"
"UModbus *""'"
);
}
}
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
res2
=
SWIG_AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
{
if
(
!
SWIG_IsOK
(
res2
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UModbus_prepare"
"', argument "
"2"" of type '"
"char const *""'"
);
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UModbus_prepare"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_prepare"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
ecode3
=
SWIG_AsVal_int
(
obj2
,
&
val3
);
ecode3
=
SWIG_AsVal_int
(
obj2
,
&
val3
);
if
(
!
SWIG_IsOK
(
ecode3
))
{
if
(
!
SWIG_IsOK
(
ecode3
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode3
),
"in method '"
"UModbus_prepare"
"', argument "
"3"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode3
),
"in method '"
"UModbus_prepare"
"', argument "
"3"" of type '"
"int""'"
);
}
}
arg3
=
static_cast
<
int
>
(
val3
);
arg3
=
static_cast
<
int
>
(
val3
);
try
{
try
{
(
arg1
)
->
prepare
((
char
const
*
)
arg2
,
arg3
);
(
arg1
)
->
prepare
((
std
::
string
const
&
)
*
arg2
,
arg3
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3511,13 +3548,11 @@ fail:
...
@@ -3511,13 +3548,11 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_connect
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_connect
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UModbus
*
arg1
=
(
UModbus
*
)
0
;
UModbus
*
arg1
=
(
UModbus
*
)
0
;
char
*
arg2
=
(
char
*
)
0
;
std
::
string
*
arg2
=
0
;
int
arg3
;
int
arg3
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
res2
;
int
res2
=
SWIG_OLDOBJ
;
char
*
buf2
=
0
;
int
alloc2
=
0
;
int
val3
;
int
val3
;
int
ecode3
=
0
;
int
ecode3
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
...
@@ -3530,28 +3565,34 @@ SWIGINTERN PyObject *_wrap_UModbus_connect(PyObject *SWIGUNUSEDPARM(self), PyObj
...
@@ -3530,28 +3565,34 @@ SWIGINTERN PyObject *_wrap_UModbus_connect(PyObject *SWIGUNUSEDPARM(self), PyObj
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_connect"
"', argument "
"1"" of type '"
"UModbus *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UModbus_connect"
"', argument "
"1"" of type '"
"UModbus *""'"
);
}
}
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
res2
=
SWIG_AsCharPtrAndSize
(
obj1
,
&
buf2
,
NULL
,
&
alloc2
);
{
if
(
!
SWIG_IsOK
(
res2
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UModbus_connect"
"', argument "
"2"" of type '"
"char const *""'"
);
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UModbus_connect"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_connect"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
arg2
=
reinterpret_cast
<
char
*
>
(
buf2
);
ecode3
=
SWIG_AsVal_int
(
obj2
,
&
val3
);
ecode3
=
SWIG_AsVal_int
(
obj2
,
&
val3
);
if
(
!
SWIG_IsOK
(
ecode3
))
{
if
(
!
SWIG_IsOK
(
ecode3
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode3
),
"in method '"
"UModbus_connect"
"', argument "
"3"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode3
),
"in method '"
"UModbus_connect"
"', argument "
"3"" of type '"
"int""'"
);
}
}
arg3
=
static_cast
<
int
>
(
val3
);
arg3
=
static_cast
<
int
>
(
val3
);
try
{
try
{
(
arg1
)
->
connect
((
char
const
*
)
arg2
,
arg3
);
(
arg1
)
->
connect
((
std
::
string
const
&
)
*
arg2
,
arg3
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc2
==
SWIG_NEWOBJ
)
delete
[]
buf
2
;
if
(
SWIG_IsNewObj
(
res2
))
delete
arg
2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3593,7 +3634,7 @@ SWIGINTERN PyObject *_wrap_UModbus_conn_ip(PyObject *SWIGUNUSEDPARM(self), PyObj
...
@@ -3593,7 +3634,7 @@ SWIGINTERN PyObject *_wrap_UModbus_conn_ip(PyObject *SWIGUNUSEDPARM(self), PyObj
}
}
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UModbus
*
>
(
argp1
);
result
=
(
arg1
)
->
conn_ip
();
result
=
(
arg1
)
->
conn_ip
();
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
resultobj
=
SWIG_
From_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -3658,9 +3699,9 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3658,9 +3699,9 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
int
arg2
;
int
arg2
;
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
char
*
arg5
=
(
char
*
)
0
;
std
::
string
*
arg5
=
0
;
int
arg6
;
int
arg6
;
char
*
arg7
=
(
char
*
)
0
;
std
::
string
*
arg7
=
0
;
int
arg8
;
int
arg8
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
...
@@ -3670,14 +3711,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3670,14 +3711,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
int
ecode3
=
0
;
int
ecode3
=
0
;
int
val4
;
int
val4
;
int
ecode4
=
0
;
int
ecode4
=
0
;
int
res5
;
int
res5
=
SWIG_OLDOBJ
;
char
*
buf5
=
0
;
int
alloc5
=
0
;
int
val6
;
int
val6
;
int
ecode6
=
0
;
int
ecode6
=
0
;
int
res7
;
int
res7
=
SWIG_OLDOBJ
;
char
*
buf7
=
0
;
int
alloc7
=
0
;
int
val8
;
int
val8
;
int
ecode8
=
0
;
int
ecode8
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
...
@@ -3711,40 +3748,52 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3711,40 +3748,52 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_0(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
}
}
arg4
=
static_cast
<
int
>
(
val4
);
arg4
=
static_cast
<
int
>
(
val4
);
res5
=
SWIG_AsCharPtrAndSize
(
obj4
,
&
buf5
,
NULL
,
&
alloc5
);
{
if
(
!
SWIG_IsOK
(
res5
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"char const *""'"
);
res5
=
SWIG_AsPtr_std_string
(
obj4
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res5
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
arg5
=
ptr
;
}
}
arg5
=
reinterpret_cast
<
char
*
>
(
buf5
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
if
(
!
SWIG_IsOK
(
ecode6
))
{
if
(
!
SWIG_IsOK
(
ecode6
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
}
}
arg6
=
static_cast
<
int
>
(
val6
);
arg6
=
static_cast
<
int
>
(
val6
);
res7
=
SWIG_AsCharPtrAndSize
(
obj6
,
&
buf7
,
NULL
,
&
alloc7
);
{
if
(
!
SWIG_IsOK
(
res7
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res7
),
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"char const *""'"
);
res7
=
SWIG_AsPtr_std_string
(
obj6
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res7
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res7
),
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"std::string const &""'"
);
}
arg7
=
ptr
;
}
}
arg7
=
reinterpret_cast
<
char
*
>
(
buf7
);
ecode8
=
SWIG_AsVal_int
(
obj7
,
&
val8
);
ecode8
=
SWIG_AsVal_int
(
obj7
,
&
val8
);
if
(
!
SWIG_IsOK
(
ecode8
))
{
if
(
!
SWIG_IsOK
(
ecode8
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode8
),
"in method '"
"UModbus_mbread"
"', argument "
"8"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode8
),
"in method '"
"UModbus_mbread"
"', argument "
"8"" of type '"
"int""'"
);
}
}
arg8
=
static_cast
<
int
>
(
val8
);
arg8
=
static_cast
<
int
>
(
val8
);
try
{
try
{
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
char
const
*
)
arg5
,
arg6
,(
char
const
*
)
arg7
,
arg8
);
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
std
::
string
const
&
)
*
arg5
,
arg6
,(
std
::
string
const
&
)
*
arg7
,
arg8
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
if
(
alloc7
==
SWIG_NEWOBJ
)
delete
[]
buf
7
;
if
(
SWIG_IsNewObj
(
res7
))
delete
arg
7
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
if
(
alloc7
==
SWIG_NEWOBJ
)
delete
[]
buf
7
;
if
(
SWIG_IsNewObj
(
res7
))
delete
arg
7
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3755,9 +3804,9 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3755,9 +3804,9 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
int
arg2
;
int
arg2
;
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
char
*
arg5
=
(
char
*
)
0
;
std
::
string
*
arg5
=
0
;
int
arg6
;
int
arg6
;
char
*
arg7
=
(
char
*
)
0
;
std
::
string
*
arg7
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
val2
;
int
val2
;
...
@@ -3766,14 +3815,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3766,14 +3815,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
int
ecode3
=
0
;
int
ecode3
=
0
;
int
val4
;
int
val4
;
int
ecode4
=
0
;
int
ecode4
=
0
;
int
res5
;
int
res5
=
SWIG_OLDOBJ
;
char
*
buf5
=
0
;
int
alloc5
=
0
;
int
val6
;
int
val6
;
int
ecode6
=
0
;
int
ecode6
=
0
;
int
res7
;
int
res7
=
SWIG_OLDOBJ
;
char
*
buf7
=
0
;
int
alloc7
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj2
=
0
;
PyObject
*
obj2
=
0
;
...
@@ -3804,35 +3849,47 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3804,35 +3849,47 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_1(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
}
}
arg4
=
static_cast
<
int
>
(
val4
);
arg4
=
static_cast
<
int
>
(
val4
);
res5
=
SWIG_AsCharPtrAndSize
(
obj4
,
&
buf5
,
NULL
,
&
alloc5
);
{
if
(
!
SWIG_IsOK
(
res5
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"char const *""'"
);
res5
=
SWIG_AsPtr_std_string
(
obj4
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res5
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
arg5
=
ptr
;
}
}
arg5
=
reinterpret_cast
<
char
*
>
(
buf5
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
if
(
!
SWIG_IsOK
(
ecode6
))
{
if
(
!
SWIG_IsOK
(
ecode6
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
}
}
arg6
=
static_cast
<
int
>
(
val6
);
arg6
=
static_cast
<
int
>
(
val6
);
res7
=
SWIG_AsCharPtrAndSize
(
obj6
,
&
buf7
,
NULL
,
&
alloc7
);
{
if
(
!
SWIG_IsOK
(
res7
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res7
),
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"char const *""'"
);
res7
=
SWIG_AsPtr_std_string
(
obj6
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res7
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res7
),
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"7"" of type '"
"std::string const &""'"
);
}
arg7
=
ptr
;
}
}
arg7
=
reinterpret_cast
<
char
*
>
(
buf7
);
try
{
try
{
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
char
const
*
)
arg5
,
arg6
,(
char
const
*
)
arg7
);
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
std
::
string
const
&
)
*
arg5
,
arg6
,(
std
::
string
const
&
)
*
arg7
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
if
(
alloc7
==
SWIG_NEWOBJ
)
delete
[]
buf
7
;
if
(
SWIG_IsNewObj
(
res7
))
delete
arg
7
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
if
(
alloc7
==
SWIG_NEWOBJ
)
delete
[]
buf
7
;
if
(
SWIG_IsNewObj
(
res7
))
delete
arg
7
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3843,7 +3900,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3843,7 +3900,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
int
arg2
;
int
arg2
;
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
char
*
arg5
=
(
char
*
)
0
;
std
::
string
*
arg5
=
0
;
int
arg6
;
int
arg6
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
...
@@ -3853,9 +3910,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3853,9 +3910,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
int
ecode3
=
0
;
int
ecode3
=
0
;
int
val4
;
int
val4
;
int
ecode4
=
0
;
int
ecode4
=
0
;
int
res5
;
int
res5
=
SWIG_OLDOBJ
;
char
*
buf5
=
0
;
int
alloc5
=
0
;
int
val6
;
int
val6
;
int
ecode6
=
0
;
int
ecode6
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
...
@@ -3887,28 +3942,34 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3887,28 +3942,34 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_2(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
}
}
arg4
=
static_cast
<
int
>
(
val4
);
arg4
=
static_cast
<
int
>
(
val4
);
res5
=
SWIG_AsCharPtrAndSize
(
obj4
,
&
buf5
,
NULL
,
&
alloc5
);
{
if
(
!
SWIG_IsOK
(
res5
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"char const *""'"
);
res5
=
SWIG_AsPtr_std_string
(
obj4
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res5
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
arg5
=
ptr
;
}
}
arg5
=
reinterpret_cast
<
char
*
>
(
buf5
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
ecode6
=
SWIG_AsVal_int
(
obj5
,
&
val6
);
if
(
!
SWIG_IsOK
(
ecode6
))
{
if
(
!
SWIG_IsOK
(
ecode6
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode6
),
"in method '"
"UModbus_mbread"
"', argument "
"6"" of type '"
"int""'"
);
}
}
arg6
=
static_cast
<
int
>
(
val6
);
arg6
=
static_cast
<
int
>
(
val6
);
try
{
try
{
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
char
const
*
)
arg5
,
arg6
);
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
std
::
string
const
&
)
*
arg5
,
arg6
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
return
NULL
;
return
NULL
;
}
}
...
@@ -3919,7 +3980,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3919,7 +3980,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
int
arg2
;
int
arg2
;
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
char
*
arg5
=
(
char
*
)
0
;
std
::
string
*
arg5
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
val2
;
int
val2
;
...
@@ -3928,9 +3989,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3928,9 +3989,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
int
ecode3
=
0
;
int
ecode3
=
0
;
int
val4
;
int
val4
;
int
ecode4
=
0
;
int
ecode4
=
0
;
int
res5
;
int
res5
=
SWIG_OLDOBJ
;
char
*
buf5
=
0
;
int
alloc5
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj2
=
0
;
PyObject
*
obj2
=
0
;
...
@@ -3959,30 +4018,38 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
...
@@ -3959,30 +4018,38 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread__SWIG_3(PyObject *SWIGUNUSEDPARM(self)
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode4
),
"in method '"
"UModbus_mbread"
"', argument "
"4"" of type '"
"int""'"
);
}
}
arg4
=
static_cast
<
int
>
(
val4
);
arg4
=
static_cast
<
int
>
(
val4
);
res5
=
SWIG_AsCharPtrAndSize
(
obj4
,
&
buf5
,
NULL
,
&
alloc5
);
{
if
(
!
SWIG_IsOK
(
res5
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"char const *""'"
);
res5
=
SWIG_AsPtr_std_string
(
obj4
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res5
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res5
),
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbread"
"', argument "
"5"" of type '"
"std::string const &""'"
);
}
arg5
=
ptr
;
}
}
arg5
=
reinterpret_cast
<
char
*
>
(
buf5
);
try
{
try
{
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
char
const
*
)
arg5
);
result
=
(
long
)(
arg1
)
->
mbread
(
arg2
,
arg3
,
arg4
,(
std
::
string
const
&
)
*
arg5
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
resultobj
=
SWIG_From_long
(
static_cast
<
long
>
(
result
));
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc5
==
SWIG_NEWOBJ
)
delete
[]
buf
5
;
if
(
SWIG_IsNewObj
(
res5
))
delete
arg
5
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_UModbus_mbread
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_mbread
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
9
];
PyObject
*
argv
[
9
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4011,7 +4078,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4011,7 +4078,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
4
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
4
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_UModbus_mbread__SWIG_3
(
self
,
args
);
return
_wrap_UModbus_mbread__SWIG_3
(
self
,
args
);
...
@@ -4042,7 +4109,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4042,7 +4109,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
4
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
4
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
{
{
...
@@ -4079,7 +4146,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4079,7 +4146,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
4
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
4
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
{
{
...
@@ -4087,7 +4154,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4087,7 +4154,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
6
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
6
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_UModbus_mbread__SWIG_1
(
self
,
args
);
return
_wrap_UModbus_mbread__SWIG_1
(
self
,
args
);
...
@@ -4120,7 +4187,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4120,7 +4187,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
4
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
4
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
{
{
...
@@ -4128,7 +4195,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4128,7 +4195,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
6
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
6
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
{
{
...
@@ -4150,10 +4217,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
...
@@ -4150,10 +4217,10 @@ SWIGINTERN PyObject *_wrap_UModbus_mbread(PyObject *self, PyObject *args) {
fail
:
fail
:
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'UModbus_mbread'.
\n
"
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'UModbus_mbread'.
\n
"
" Possible C/C++ prototypes are:
\n
"
" Possible C/C++ prototypes are:
\n
"
" UModbus::mbread(int,int,int,
char const *,int,char const *
,int)
\n
"
" UModbus::mbread(int,int,int,
std::string const &,int,std::string const &
,int)
\n
"
" UModbus::mbread(int,int,int,
char const *,int,char const *
)
\n
"
" UModbus::mbread(int,int,int,
std::string const &,int,std::string const &
)
\n
"
" UModbus::mbread(int,int,int,
char const *
,int)
\n
"
" UModbus::mbread(int,int,int,
std::string const &
,int)
\n
"
" UModbus::mbread(int,int,int,
char const *
)
\n
"
);
" UModbus::mbread(int,int,int,
std::string const &
)
\n
"
);
return
0
;
return
0
;
}
}
...
@@ -4261,7 +4328,9 @@ fail:
...
@@ -4261,7 +4328,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_getWord
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_getWord
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
5
];
PyObject
*
argv
[
5
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4430,7 +4499,9 @@ fail:
...
@@ -4430,7 +4499,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_getByte
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_getByte
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
5
];
PyObject
*
argv
[
5
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4599,7 +4670,9 @@ fail:
...
@@ -4599,7 +4670,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_getBit
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_getBit
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
5
];
PyObject
*
argv
[
5
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4672,7 +4745,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
...
@@ -4672,7 +4745,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
int
arg5
;
int
arg5
;
char
*
arg6
=
(
char
*
)
0
;
std
::
string
*
arg6
=
0
;
int
arg7
;
int
arg7
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
...
@@ -4684,9 +4757,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
...
@@ -4684,9 +4757,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
int
ecode4
=
0
;
int
ecode4
=
0
;
int
val5
;
int
val5
;
int
ecode5
=
0
;
int
ecode5
=
0
;
int
res6
;
int
res6
=
SWIG_OLDOBJ
;
char
*
buf6
=
0
;
int
alloc6
=
0
;
int
val7
;
int
val7
;
int
ecode7
=
0
;
int
ecode7
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
...
@@ -4723,28 +4794,34 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
...
@@ -4723,28 +4794,34 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_0(PyObject *SWIGUNUSEDPARM(self
SWIG_exception_fail
(
SWIG_ArgError
(
ecode5
),
"in method '"
"UModbus_mbwrite"
"', argument "
"5"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode5
),
"in method '"
"UModbus_mbwrite"
"', argument "
"5"" of type '"
"int""'"
);
}
}
arg5
=
static_cast
<
int
>
(
val5
);
arg5
=
static_cast
<
int
>
(
val5
);
res6
=
SWIG_AsCharPtrAndSize
(
obj5
,
&
buf6
,
NULL
,
&
alloc6
);
{
if
(
!
SWIG_IsOK
(
res6
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res6
),
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"char const *""'"
);
res6
=
SWIG_AsPtr_std_string
(
obj5
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res6
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res6
),
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"std::string const &""'"
);
}
arg6
=
ptr
;
}
}
arg6
=
reinterpret_cast
<
char
*
>
(
buf6
);
ecode7
=
SWIG_AsVal_int
(
obj6
,
&
val7
);
ecode7
=
SWIG_AsVal_int
(
obj6
,
&
val7
);
if
(
!
SWIG_IsOK
(
ecode7
))
{
if
(
!
SWIG_IsOK
(
ecode7
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
ecode7
),
"in method '"
"UModbus_mbwrite"
"', argument "
"7"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode7
),
"in method '"
"UModbus_mbwrite"
"', argument "
"7"" of type '"
"int""'"
);
}
}
arg7
=
static_cast
<
int
>
(
val7
);
arg7
=
static_cast
<
int
>
(
val7
);
try
{
try
{
(
arg1
)
->
mbwrite
(
arg2
,
arg3
,
arg4
,
arg5
,(
char
const
*
)
arg6
,
arg7
);
(
arg1
)
->
mbwrite
(
arg2
,
arg3
,
arg4
,
arg5
,(
std
::
string
const
&
)
*
arg6
,
arg7
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc6
==
SWIG_NEWOBJ
)
delete
[]
buf
6
;
if
(
SWIG_IsNewObj
(
res6
))
delete
arg
6
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc6
==
SWIG_NEWOBJ
)
delete
[]
buf
6
;
if
(
SWIG_IsNewObj
(
res6
))
delete
arg
6
;
return
NULL
;
return
NULL
;
}
}
...
@@ -4756,7 +4833,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
...
@@ -4756,7 +4833,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
int
arg3
;
int
arg3
;
int
arg4
;
int
arg4
;
int
arg5
;
int
arg5
;
char
*
arg6
=
(
char
*
)
0
;
std
::
string
*
arg6
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
int
val2
;
int
val2
;
...
@@ -4767,9 +4844,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
...
@@ -4767,9 +4844,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
int
ecode4
=
0
;
int
ecode4
=
0
;
int
val5
;
int
val5
;
int
ecode5
=
0
;
int
ecode5
=
0
;
int
res6
;
int
res6
=
SWIG_OLDOBJ
;
char
*
buf6
=
0
;
int
alloc6
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj2
=
0
;
PyObject
*
obj2
=
0
;
...
@@ -4803,23 +4878,29 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
...
@@ -4803,23 +4878,29 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite__SWIG_1(PyObject *SWIGUNUSEDPARM(self
SWIG_exception_fail
(
SWIG_ArgError
(
ecode5
),
"in method '"
"UModbus_mbwrite"
"', argument "
"5"" of type '"
"int""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
ecode5
),
"in method '"
"UModbus_mbwrite"
"', argument "
"5"" of type '"
"int""'"
);
}
}
arg5
=
static_cast
<
int
>
(
val5
);
arg5
=
static_cast
<
int
>
(
val5
);
res6
=
SWIG_AsCharPtrAndSize
(
obj5
,
&
buf6
,
NULL
,
&
alloc6
);
{
if
(
!
SWIG_IsOK
(
res6
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res6
),
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"char const *""'"
);
res6
=
SWIG_AsPtr_std_string
(
obj5
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res6
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res6
),
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UModbus_mbwrite"
"', argument "
"6"" of type '"
"std::string const &""'"
);
}
arg6
=
ptr
;
}
}
arg6
=
reinterpret_cast
<
char
*
>
(
buf6
);
try
{
try
{
(
arg1
)
->
mbwrite
(
arg2
,
arg3
,
arg4
,
arg5
,(
char
const
*
)
arg6
);
(
arg1
)
->
mbwrite
(
arg2
,
arg3
,
arg4
,
arg5
,(
std
::
string
const
&
)
*
arg6
);
}
}
catch
(
UException
&
_e
)
{
catch
(
UException
&
_e
)
{
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
SWIG_Python_Raise
(
SWIG_NewPointerObj
((
new
UException
(
static_cast
<
const
UException
&
>
(
_e
))),
SWIGTYPE_p_UException
,
SWIG_POINTER_OWN
),
"UException"
,
SWIGTYPE_p_UException
);
SWIG_fail
;
}
}
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
alloc6
==
SWIG_NEWOBJ
)
delete
[]
buf
6
;
if
(
SWIG_IsNewObj
(
res6
))
delete
arg
6
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
alloc6
==
SWIG_NEWOBJ
)
delete
[]
buf
6
;
if
(
SWIG_IsNewObj
(
res6
))
delete
arg
6
;
return
NULL
;
return
NULL
;
}
}
...
@@ -4889,7 +4970,9 @@ fail:
...
@@ -4889,7 +4970,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UModbus_mbwrite
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UModbus_mbwrite
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
8
];
PyObject
*
argv
[
8
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -4956,7 +5039,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
...
@@ -4956,7 +5039,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
5
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
5
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_UModbus_mbwrite__SWIG_1
(
self
,
args
);
return
_wrap_UModbus_mbwrite__SWIG_1
(
self
,
args
);
...
@@ -4993,7 +5076,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
...
@@ -4993,7 +5076,7 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
}
}
if
(
_v
)
{
if
(
_v
)
{
int
res
=
SWIG_As
CharPtrAndSize
(
argv
[
5
],
0
,
NULL
,
0
);
int
res
=
SWIG_As
Ptr_std_string
(
argv
[
5
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
{
{
...
@@ -5014,8 +5097,8 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
...
@@ -5014,8 +5097,8 @@ SWIGINTERN PyObject *_wrap_UModbus_mbwrite(PyObject *self, PyObject *args) {
fail
:
fail
:
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'UModbus_mbwrite'.
\n
"
SWIG_SetErrorMsg
(
PyExc_NotImplementedError
,
"Wrong number or type of arguments for overloaded function 'UModbus_mbwrite'.
\n
"
" Possible C/C++ prototypes are:
\n
"
" Possible C/C++ prototypes are:
\n
"
" UModbus::mbwrite(int,int,int,int,
char const *
,int)
\n
"
" UModbus::mbwrite(int,int,int,int,
std::string const &
,int)
\n
"
" UModbus::mbwrite(int,int,int,int,
char const *
)
\n
"
" UModbus::mbwrite(int,int,int,int,
std::string const &
)
\n
"
" UModbus::mbwrite(int,int,int,int)
\n
"
);
" UModbus::mbwrite(int,int,int,int)
\n
"
);
return
0
;
return
0
;
}
}
...
@@ -5257,24 +5340,28 @@ fail:
...
@@ -5257,24 +5340,28 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UException__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UException__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
UException
*
result
=
0
;
UException
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UException"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UException"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UException"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
UException
*
)
new
UException
((
std
::
string
const
&
)
*
arg1
);
result
=
(
UException
*
)
new
UException
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UException
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UException
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
...
@@ -5306,7 +5393,9 @@ fail:
...
@@ -5306,7 +5393,9 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UException
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -5319,7 +5408,7 @@ SWIGINTERN PyObject *_wrap_new_UException(PyObject *self, PyObject *args) {
...
@@ -5319,7 +5408,7 @@ SWIGINTERN PyObject *_wrap_new_UException(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UException__SWIG_1
(
self
,
args
);
return
_wrap_new_UException__SWIG_1
(
self
,
args
);
...
@@ -5371,7 +5460,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -5371,7 +5460,7 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
char
*
result
=
0
;
std
::
string
result
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_getError"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
...
@@ -5379,8 +5468,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
...
@@ -5379,8 +5468,8 @@ SWIGINTERN PyObject *_wrap_UException_getError(PyObject *SWIGUNUSEDPARM(self), P
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_getError"
"', argument "
"1"" of type '"
"UException *""'"
);
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
result
=
(
char
*
)(
arg1
)
->
getError
();
result
=
(
arg1
)
->
getError
();
resultobj
=
SWIG_From
CharPtr
((
const
char
*
)
result
);
resultobj
=
SWIG_From
_std_string
(
static_cast
<
std
::
string
>
(
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -5390,11 +5479,10 @@ fail:
...
@@ -5390,11 +5479,10 @@ fail:
SWIGINTERN
PyObject
*
_wrap_UException_err_set
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_UException_err_set
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
UException
*
arg1
=
(
UException
*
)
0
;
UException
*
arg1
=
(
UException
*
)
0
;
std
::
string
arg2
;
std
::
string
*
arg2
=
0
;
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
void
*
argp2
;
int
res2
=
SWIG_OLDOBJ
;
int
res2
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj1
=
0
;
PyObject
*
obj1
=
0
;
...
@@ -5405,22 +5493,22 @@ SWIGINTERN PyObject *_wrap_UException_err_set(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -5405,22 +5493,22 @@ SWIGINTERN PyObject *_wrap_UException_err_set(PyObject *SWIGUNUSEDPARM(self), Py
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
{
{
res2
=
SWIG_ConvertPtr
(
obj1
,
&
argp2
,
SWIGTYPE_p_std__string
,
0
|
0
);
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
res2
=
SWIG_AsPtr_std_string
(
obj1
,
&
ptr
);
if
(
!
SWIG_IsOK
(
res2
))
{
if
(
!
SWIG_IsOK
(
res2
))
{
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res2
),
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
if
(
!
argp2
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string""'"
);
}
else
{
std
::
string
*
temp
=
reinterpret_cast
<
std
::
string
*
>
(
argp2
);
arg2
=
*
temp
;
if
(
SWIG_IsNewObj
(
res2
))
delete
temp
;
}
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"UException_err_set"
"', argument "
"2"" of type '"
"std::string const &""'"
);
}
arg2
=
ptr
;
}
}
if
(
arg1
)
(
arg1
)
->
err
=
arg2
;
if
(
arg1
)
(
arg1
)
->
err
=
*
arg2
;
resultobj
=
SWIG_Py_Void
();
resultobj
=
SWIG_Py_Void
();
if
(
SWIG_IsNewObj
(
res2
))
delete
arg2
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res2
))
delete
arg2
;
return
NULL
;
return
NULL
;
}
}
...
@@ -5431,7 +5519,7 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -5431,7 +5519,7 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
void
*
argp1
=
0
;
void
*
argp1
=
0
;
int
res1
=
0
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
std
::
string
result
;
std
::
string
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_err_get"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:UException_err_get"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_UException
,
0
|
0
);
...
@@ -5439,8 +5527,8 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
...
@@ -5439,8 +5527,8 @@ SWIGINTERN PyObject *_wrap_UException_err_get(PyObject *SWIGUNUSEDPARM(self), Py
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_err_get"
"', argument "
"1"" of type '"
"UException *""'"
);
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"UException_err_get"
"', argument "
"1"" of type '"
"UException *""'"
);
}
}
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
arg1
=
reinterpret_cast
<
UException
*
>
(
argp1
);
result
=
((
arg1
)
->
err
);
result
=
(
std
::
string
*
)
&
((
arg1
)
->
err
);
resultobj
=
SWIG_
NewPointerObj
((
new
std
::
string
(
static_cast
<
const
std
::
string
&
>
(
result
))),
SWIGTYPE_p_std__string
,
SWIG_POINTER_OWN
|
0
);
resultobj
=
SWIG_
From_std_string
(
static_cast
<
std
::
string
>
(
*
result
)
);
return
resultobj
;
return
resultobj
;
fail
:
fail
:
return
NULL
;
return
NULL
;
...
@@ -5470,31 +5558,37 @@ fail:
...
@@ -5470,31 +5558,37 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
UTimeOut
*
result
=
0
;
UTimeOut
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UTimeOut"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_UTimeOut"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_UTimeOut"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
UTimeOut
*
)
new
UTimeOut
((
std
::
string
const
&
)
*
arg1
);
result
=
(
UTimeOut
*
)
new
UTimeOut
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UTimeOut
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_UTimeOut
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_UTimeOut
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -5507,7 +5601,7 @@ SWIGINTERN PyObject *_wrap_new_UTimeOut(PyObject *self, PyObject *args) {
...
@@ -5507,7 +5601,7 @@ SWIGINTERN PyObject *_wrap_new_UTimeOut(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_UTimeOut__SWIG_1
(
self
,
args
);
return
_wrap_new_UTimeOut__SWIG_1
(
self
,
args
);
...
@@ -5567,31 +5661,37 @@ fail:
...
@@ -5567,31 +5661,37 @@ fail:
SWIGINTERN
PyObject
*
_wrap_new_USysError__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_USysError__SWIG_1
(
PyObject
*
SWIGUNUSEDPARM
(
self
),
PyObject
*
args
)
{
PyObject
*
resultobj
=
0
;
PyObject
*
resultobj
=
0
;
std
::
string
*
arg1
=
0
;
std
::
string
*
arg1
=
0
;
void
*
argp1
=
0
;
int
res1
=
SWIG_OLDOBJ
;
int
res1
=
0
;
PyObject
*
obj0
=
0
;
PyObject
*
obj0
=
0
;
USysError
*
result
=
0
;
USysError
*
result
=
0
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_USysError"
,
&
obj0
))
SWIG_fail
;
if
(
!
PyArg_ParseTuple
(
args
,(
char
*
)
"O:new_USysError"
,
&
obj0
))
SWIG_fail
;
res1
=
SWIG_ConvertPtr
(
obj0
,
&
argp1
,
SWIGTYPE_p_std__string
,
0
|
0
);
{
if
(
!
SWIG_IsOK
(
res1
))
{
std
::
string
*
ptr
=
(
std
::
string
*
)
0
;
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
res1
=
SWIG_AsPtr_std_string
(
obj0
,
&
ptr
);
}
if
(
!
SWIG_IsOK
(
res1
))
{
if
(
!
argp1
)
{
SWIG_exception_fail
(
SWIG_ArgError
(
res1
),
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
if
(
!
ptr
)
{
SWIG_exception_fail
(
SWIG_ValueError
,
"invalid null reference "
"in method '"
"new_USysError"
"', argument "
"1"" of type '"
"std::string const &""'"
);
}
arg1
=
ptr
;
}
}
arg1
=
reinterpret_cast
<
std
::
string
*
>
(
argp1
);
result
=
(
USysError
*
)
new
USysError
((
std
::
string
const
&
)
*
arg1
);
result
=
(
USysError
*
)
new
USysError
((
std
::
string
const
&
)
*
arg1
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_USysError
,
SWIG_POINTER_NEW
|
0
);
resultobj
=
SWIG_NewPointerObj
(
SWIG_as_voidptr
(
result
),
SWIGTYPE_p_USysError
,
SWIG_POINTER_NEW
|
0
);
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
resultobj
;
return
resultobj
;
fail
:
fail
:
if
(
SWIG_IsNewObj
(
res1
))
delete
arg1
;
return
NULL
;
return
NULL
;
}
}
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
SWIGINTERN
PyObject
*
_wrap_new_USysError
(
PyObject
*
self
,
PyObject
*
args
)
{
int
argc
;
int
argc
;
PyObject
*
argv
[
2
];
PyObject
*
argv
[
2
]
=
{
0
};
int
ii
;
int
ii
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
if
(
!
PyTuple_Check
(
args
))
SWIG_fail
;
...
@@ -5604,7 +5704,7 @@ SWIGINTERN PyObject *_wrap_new_USysError(PyObject *self, PyObject *args) {
...
@@ -5604,7 +5704,7 @@ SWIGINTERN PyObject *_wrap_new_USysError(PyObject *self, PyObject *args) {
}
}
if
(
argc
==
1
)
{
if
(
argc
==
1
)
{
int
_v
;
int
_v
;
int
res
=
SWIG_
ConvertPtr
(
argv
[
0
],
0
,
SWIGTYPE_p_std__string
,
0
);
int
res
=
SWIG_
AsPtr_std_string
(
argv
[
0
],
(
std
::
string
**
)(
0
)
);
_v
=
SWIG_CheckState
(
res
);
_v
=
SWIG_CheckState
(
res
);
if
(
_v
)
{
if
(
_v
)
{
return
_wrap_new_USysError__SWIG_1
(
self
,
args
);
return
_wrap_new_USysError__SWIG_1
(
self
,
args
);
...
@@ -5706,7 +5806,6 @@ static swig_type_info _swigt__p_UTimeOut = {"_p_UTimeOut", "UTimeOut *", 0, 0, (
...
@@ -5706,7 +5806,6 @@ static swig_type_info _swigt__p_UTimeOut = {"_p_UTimeOut", "UTimeOut *", 0, 0, (
static
swig_type_info
_swigt__p_UTypes__Params
=
{
"_p_UTypes__Params"
,
"UTypes::Params *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_UTypes__Params
=
{
"_p_UTypes__Params"
,
"UTypes::Params *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_char
=
{
"_p_char"
,
"char *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_char
=
{
"_p_char"
,
"char *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_p_char
=
{
"_p_p_char"
,
"char **"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_p_char
=
{
"_p_p_char"
,
"char **"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
_swigt__p_std__string
=
{
"_p_std__string"
,
"std::string *"
,
0
,
0
,
(
void
*
)
0
,
0
};
static
swig_type_info
*
swig_type_initial
[]
=
{
static
swig_type_info
*
swig_type_initial
[]
=
{
&
_swigt__p_UException
,
&
_swigt__p_UException
,
...
@@ -5716,7 +5815,6 @@ static swig_type_info *swig_type_initial[] = {
...
@@ -5716,7 +5815,6 @@ static swig_type_info *swig_type_initial[] = {
&
_swigt__p_UTypes__Params
,
&
_swigt__p_UTypes__Params
,
&
_swigt__p_char
,
&
_swigt__p_char
,
&
_swigt__p_p_char
,
&
_swigt__p_p_char
,
&
_swigt__p_std__string
,
};
};
static
swig_cast_info
_swigc__p_UException
[]
=
{
{
&
_swigt__p_UException
,
0
,
0
,
0
},
{
&
_swigt__p_UTimeOut
,
_p_UTimeOutTo_p_UException
,
0
,
0
},
{
&
_swigt__p_USysError
,
_p_USysErrorTo_p_UException
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_UException
[]
=
{
{
&
_swigt__p_UException
,
0
,
0
,
0
},
{
&
_swigt__p_UTimeOut
,
_p_UTimeOutTo_p_UException
,
0
,
0
},
{
&
_swigt__p_USysError
,
_p_USysErrorTo_p_UException
,
0
,
0
},{
0
,
0
,
0
,
0
}};
...
@@ -5726,7 +5824,6 @@ static swig_cast_info _swigc__p_UTimeOut[] = { {&_swigt__p_UTimeOut, 0, 0, 0},{
...
@@ -5726,7 +5824,6 @@ static swig_cast_info _swigc__p_UTimeOut[] = { {&_swigt__p_UTimeOut, 0, 0, 0},{
static
swig_cast_info
_swigc__p_UTypes__Params
[]
=
{
{
&
_swigt__p_UTypes__Params
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_UTypes__Params
[]
=
{
{
&
_swigt__p_UTypes__Params
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_char
[]
=
{
{
&
_swigt__p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_char
[]
=
{
{
&
_swigt__p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_p_char
[]
=
{
{
&
_swigt__p_p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_p_char
[]
=
{
{
&
_swigt__p_p_char
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
_swigc__p_std__string
[]
=
{
{
&
_swigt__p_std__string
,
0
,
0
,
0
},{
0
,
0
,
0
,
0
}};
static
swig_cast_info
*
swig_cast_initial
[]
=
{
static
swig_cast_info
*
swig_cast_initial
[]
=
{
_swigc__p_UException
,
_swigc__p_UException
,
...
@@ -5736,7 +5833,6 @@ static swig_cast_info *swig_cast_initial[] = {
...
@@ -5736,7 +5833,6 @@ static swig_cast_info *swig_cast_initial[] = {
_swigc__p_UTypes__Params
,
_swigc__p_UTypes__Params
,
_swigc__p_char
,
_swigc__p_char
,
_swigc__p_p_char
,
_swigc__p_p_char
,
_swigc__p_std__string
,
};
};
...
...
python/lib/pyUniSet/pyUConnector.py
View file @
1d72749d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.
6
# Version 3.0.
7
#
#
# 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.
...
@@ -134,11 +134,11 @@ class UConnector:
...
@@ -134,11 +134,11 @@ class UConnector:
def
setValue
(
self
,
id
,
val
,
node
):
def
setValue
(
self
,
id
,
val
,
node
):
return
_pyUConnector
.
UConnector_setValue
(
self
,
id
,
val
,
node
)
return
_pyUConnector
.
UConnector_setValue
(
self
,
id
,
val
,
node
)
def
getSensorID
(
self
,
arg2
):
def
getSensorID
(
self
,
name
):
return
_pyUConnector
.
UConnector_getSensorID
(
self
,
arg2
)
return
_pyUConnector
.
UConnector_getSensorID
(
self
,
name
)
def
getNodeID
(
self
,
arg2
):
def
getNodeID
(
self
,
name
):
return
_pyUConnector
.
UConnector_getNodeID
(
self
,
arg2
)
return
_pyUConnector
.
UConnector_getNodeID
(
self
,
name
)
def
getShortName
(
self
,
id
):
def
getShortName
(
self
,
id
):
return
_pyUConnector
.
UConnector_getShortName
(
self
,
id
)
return
_pyUConnector
.
UConnector_getShortName
(
self
,
id
)
...
...
python/lib/pyUniSet/pyUExceptions.py
View file @
1d72749d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.
6
# Version 3.0.
7
#
#
# 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 @
1d72749d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.
6
# Version 3.0.
7
#
#
# 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.
...
@@ -113,8 +113,8 @@ class UModbus:
...
@@ -113,8 +113,8 @@ class UModbus:
def
setTimeout
(
self
,
msec
):
def
setTimeout
(
self
,
msec
):
return
_pyUModbus
.
UModbus_setTimeout
(
self
,
msec
)
return
_pyUModbus
.
UModbus_setTimeout
(
self
,
msec
)
def
mbread
(
self
,
addr
,
mbreg
,
mbfunc
,
vtype
,
nbit
=-
1
,
ip
=
None
,
port
=-
1
):
def
mbread
(
self
,
*
args
):
return
_pyUModbus
.
UModbus_mbread
(
self
,
addr
,
mbreg
,
mbfunc
,
vtype
,
nbit
,
ip
,
port
)
return
_pyUModbus
.
UModbus_mbread
(
self
,
*
args
)
def
getWord
(
self
,
addr
,
mbreg
,
mbfunc
=
0x4
):
def
getWord
(
self
,
addr
,
mbreg
,
mbfunc
=
0x4
):
return
_pyUModbus
.
UModbus_getWord
(
self
,
addr
,
mbreg
,
mbfunc
)
return
_pyUModbus
.
UModbus_getWord
(
self
,
addr
,
mbreg
,
mbfunc
)
...
@@ -125,8 +125,8 @@ class UModbus:
...
@@ -125,8 +125,8 @@ class UModbus:
def
getBit
(
self
,
addr
,
mbreg
,
mbfunc
=
0x2
):
def
getBit
(
self
,
addr
,
mbreg
,
mbfunc
=
0x2
):
return
_pyUModbus
.
UModbus_getBit
(
self
,
addr
,
mbreg
,
mbfunc
)
return
_pyUModbus
.
UModbus_getBit
(
self
,
addr
,
mbreg
,
mbfunc
)
def
mbwrite
(
self
,
addr
,
mbreg
,
val
,
mbfunc
,
ip
=
None
,
port
=-
1
):
def
mbwrite
(
self
,
*
args
):
return
_pyUModbus
.
UModbus_mbwrite
(
self
,
addr
,
mbreg
,
val
,
mbfunc
,
ip
,
port
)
return
_pyUModbus
.
UModbus_mbwrite
(
self
,
*
args
)
UModbus_swigregister
=
_pyUModbus
.
UModbus_swigregister
UModbus_swigregister
=
_pyUModbus
.
UModbus_swigregister
UModbus_swigregister
(
UModbus
)
UModbus_swigregister
(
UModbus
)
...
...
python/lib/pyUniSet/pyUniSet.py
View file @
1d72749d
# This file was automatically generated by SWIG (http://www.swig.org).
# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.
6
# Version 3.0.
7
#
#
# 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.
...
@@ -90,8 +90,8 @@ def setValue(id, val):
...
@@ -90,8 +90,8 @@ def setValue(id, val):
return
_pyUniSet
.
setValue
(
id
,
val
)
return
_pyUniSet
.
setValue
(
id
,
val
)
setValue
=
_pyUniSet
.
setValue
setValue
=
_pyUniSet
.
setValue
def
getSensorID
(
arg1
):
def
getSensorID
(
name
):
return
_pyUniSet
.
getSensorID
(
arg1
)
return
_pyUniSet
.
getSensorID
(
name
)
getSensorID
=
_pyUniSet
.
getSensorID
getSensorID
=
_pyUniSet
.
getSensorID
def
getShortName
(
id
):
def
getShortName
(
id
):
...
...
src/ObjectRepository/ObjectRepositoryFactory.cc
View file @
1d72749d
...
@@ -51,25 +51,23 @@ ObjectRepositoryFactory::~ObjectRepositoryFactory()
...
@@ -51,25 +51,23 @@ ObjectRepositoryFactory::~ObjectRepositoryFactory()
* \param section - полное имя секции начиная с Root.
* \param section - полное имя секции начиная с Root.
* \exception ORepFailed - генерируется если произошла при получении доступа к секции
* \exception ORepFailed - генерируется если произошла при получении доступа к секции
*/
*/
bool
ObjectRepositoryFactory
::
createSection
(
const
char
*
name
,
const
char
*
in_section
)
throw
(
ORepFailed
,
InvalidObjectName
)
bool
ObjectRepositoryFactory
::
createSection
(
const
string
&
name
,
const
string
&
in_section
)
throw
(
ORepFailed
,
InvalidObjectName
)
{
{
char
bad
=
ORepHelpers
::
checkBadSymbols
(
name
);
const
string
str
(
name
);
char
bad
=
ORepHelpers
::
checkBadSymbols
(
str
);
if
(
bad
!=
0
)
if
(
bad
!=
0
)
{
{
ostringstream
err
;
ostringstream
err
;
err
<<
"ObjectRepository(registration): (InvalidObjectName) "
<<
str
;
err
<<
"ObjectRepository(registration): (InvalidObjectName) "
<<
name
;
err
<<
" содержит недопустимый символ "
<<
bad
;
err
<<
" содержит недопустимый символ "
<<
bad
;
throw
(
InvalidObjectName
(
err
.
str
().
c_str
())
);
throw
(
InvalidObjectName
(
err
.
str
().
c_str
())
);
}
}
ulogrep
<<
"CreateSection: name = "
<<
name
<<
" in section = "
<<
in_section
<<
endl
;
ulogrep
<<
"CreateSection: name = "
<<
name
<<
" in section = "
<<
in_section
<<
endl
;
if
(
sizeof
(
in_section
)
==
0
)
if
(
in_section
.
empty
()
)
{
{
ulogrep
<<
"CreateSection: in_section
=0
"
<<
endl
;
ulogrep
<<
"CreateSection: in_section
..empty
"
<<
endl
;
return
createRootSection
(
name
);
return
createRootSection
(
name
);
}
}
...
@@ -78,12 +76,6 @@ bool ObjectRepositoryFactory::createSection( const char* name, const char* in_se
...
@@ -78,12 +76,6 @@ bool ObjectRepositoryFactory::createSection( const char* name, const char* in_se
CosNaming
::
NamingContext_var
ctx
=
ORepHelpers
::
getContext
(
in_section
,
argc
,
argv
,
uconf
->
getNSName
()
);
CosNaming
::
NamingContext_var
ctx
=
ORepHelpers
::
getContext
(
in_section
,
argc
,
argv
,
uconf
->
getNSName
()
);
return
createContext
(
name
,
ctx
.
in
()
);
return
createContext
(
name
,
ctx
.
in
()
);
}
}
bool
ObjectRepositoryFactory
::
createSection
(
const
string
&
name
,
const
string
&
in_section
)
throw
(
ORepFailed
,
InvalidObjectName
)
{
return
createSection
(
name
.
c_str
(),
in_section
.
c_str
());
}
// -------------------------------------------------------------------------------------------------------
// -------------------------------------------------------------------------------------------------------
/*!
/*!
* \param fullName - полное имя создаваемой секции
* \param fullName - полное имя создаваемой секции
...
@@ -108,23 +100,16 @@ bool ObjectRepositoryFactory::createSectionF(const string& fullName)throw(ORepFa
...
@@ -108,23 +100,16 @@ bool ObjectRepositoryFactory::createSectionF(const string& fullName)throw(ORepFa
}
}
// ---------------------------------------------------------------------------------------------------------------
// ---------------------------------------------------------------------------------------------------------------
bool
ObjectRepositoryFactory
::
createRootSection
(
const
char
*
name
)
bool
ObjectRepositoryFactory
::
createRootSection
(
const
string
&
name
)
{
{
CORBA
::
ORB_var
orb
=
uconf
->
getORB
();
CORBA
::
ORB_var
orb
=
uconf
->
getORB
();
CosNaming
::
NamingContext_var
ctx
=
ORepHelpers
::
getRootNamingContext
(
orb
,
uconf
->
getNSName
());
CosNaming
::
NamingContext_var
ctx
=
ORepHelpers
::
getRootNamingContext
(
orb
,
uconf
->
getNSName
());
return
createContext
(
name
,
ctx
);
return
createContext
(
name
,
ctx
);
}
}
bool
ObjectRepositoryFactory
::
createRootSection
(
const
string
&
name
)
{
return
createRootSection
(
name
.
c_str
()
);
}
// -----------------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------------
bool
ObjectRepositoryFactory
::
createContext
(
const
char
*
cname
,
CosNaming
::
NamingContext_ptr
ctx
)
bool
ObjectRepositoryFactory
::
createContext
(
const
string
&
cname
,
CosNaming
::
NamingContext_ptr
ctx
)
{
{
CosNaming
::
Name_var
nc
=
omniURI
::
stringToName
(
cname
.
c_str
());
CosNaming
::
Name_var
nc
=
omniURI
::
stringToName
(
cname
);
try
try
{
{
...
...
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