BotSense.BotSenseServer
index
/prj/rnr-sdk/botsense/bsPython/modules/BotSense/BotSenseServer.py

## \package BotSense.BotSenseServer
#
# \file 
#
# \brief \h_botsense client - server connection and request functions.

# \pkgsynopsis
#   \h_bs_plain Python Interface

# \pkgcomponent{Module}
#   \h_bs_plain.BotSenseServer
#
# \pkgfile{BotSense/BotSenseServer.py}
#
# \sa
# \htmlonly
#  <a href="../pydoc/BotSense.BotSenseServer.html">PyDoc Generated Documentation</a>
# \endhtmlonly
#
# \author Robin Knight (robin.knight@roadnarrows.com)
#  
# \license{MIT}
#  
# \copyright
#   \h_copy 2010-2017. RoadNarrows LLC.\n
#   http://www.roadnarrows.com\n
#   All Rights Reserved
#
# \EulaBegin
# Permission is hereby granted, without written agreement and without
# license or royalty fees, to use, copy, modify, and distribute this
# software and its documentation for any purpose, provided that
# (1) The above copyright notice and the following two paragraphs
# appear in all copies of the source code and (2) redistributions
# including binaries reproduces these notices in the supporting
# documentation.   Substantial modifications to this software may be
# copyrighted by their authors and need not follow the licensing terms
# described here, provided that the new terms are clearly indicated in
# all files where they apply.
# \n\n
# IN NO EVENT SHALL THE AUTHOR, ROADNARROWS LLC, OR ANY MEMBERS/EMPLOYEES
# OF ROADNARROW LLC OR DISTRIBUTORS OF THIS SOFTWARE BE LIABLE TO ANY
# PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL
# DAMAGES ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION,
# EVEN IF THE AUTHORS OR ANY OF THE ABOVE PARTIES HAVE BEEN ADVISED OF
# THE POSSIBILITY OF SUCH DAMAGE.
# \n\n
# THE AUTHOR AND ROADNARROWS LLC SPECIFICALLY DISCLAIM ANY WARRANTIES,
# INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
# FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN
# "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE NO OBLIGATION TO
# PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
# \EulaEnd

 
Modules
       
BotSense.BotSenseCore
BotSense.BotSenseError
BotSense.BotSenseTypes

 
Functions
       
ServerConnect(client, serverHostName='localhost', serverPort=9195)
## \brief Connect to the bsProxy server.
#
# Raises a BotSenseError exception on failure.
#
# \param client         BotSenseTypes.BsClient instance.
# \param serverHostName Server's hostname in either a network or a 
#                       dotted IP address.
# \param serverPort     Server's listen port number.
ServerDisconnect(client)
## \brief Disconnect from the bsProxy server.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
ServerReqCloseDev(client, hndVConn)
## \brief Proxy server request to close a client's virtual connection.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
# \param hndVConn Virtual connection handle to close.
ServerReqGetVConnInfo(client, hndVConn)
## \brief Proxy server request to retrieve the servers's information for a
#         given virtual connection.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
# \param hndVConn Virtual connection handle.
#
# \return Proxied device info.
ServerReqGetVConnList(client)
## \brief Proxy server request to retrieve the server's list of virtual
#         connection handles for this client.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
#
# \return List of handles.
ServerReqGetVersion(client)
## \brief Proxy server request to get the bsProxy server's version string.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
#
# \return Version string response.
ServerReqLoopback(client, loopbackMsg)
## \brief Proxy server request to loopback the given message.
#
# Raises a BotSenseError exception on failure.
#
# \param client       BotSenseTypes.BsClient instance.
# \param loopbackMsg  Message string to loopback.
#
# \return Loopbacked message response.
ServerReqMsgTrace(client, hndVConn, trace)
## \brief Proxy server request to enable/disable message tracing on a virtual
#         connection.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
# \param hndVConn Virtual connection handle.
# \param trace    Enable(true) or disable(false) message tracing.
ServerReqOpenDev(client, devName, modName, argbuf, appInfo, trace=False)
## \brief Proxy server request to establish a virtual connection to the device
#         end point.
#
# The device is open if not already opened by another virtual connection.
# Otherwise it is attached to this vconn.
#
# The interface module is dynamically loaded into the server and provides
# the set of services for the client application communicating with the
# device.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
# \param devName  Device path name string.
# \param modName  Interface module path name string.
# \param argbuf   Packed buffer of module-specific open parameters.
# \param appInfo  Application-specific information and callbacks (optional).
#                 Set to None if no info. Set any member to None to ignore
#                 that value.
# \param trace    Initial message tracing enable(true)/disable(false) state.
#
# \return New virtual connection handle.
ServerReqSetLogging(client, level)
## \brief Proxy server request to set the server's diagnostics logging level.
#
# Raises a BotSenseError exception on failure.
#
# \param client   BotSenseTypes.BsClient instance.
# \param level    Log level.