[pytango] 29/483: improved support for usage without numpy
Sandor Bodo-Merle
sbodomerle-guest at moszumanska.debian.org
Thu Sep 28 19:14:21 UTC 2017
This is an automated email from the git hooks/post-receive script.
sbodomerle-guest pushed a commit to annotated tag bliss_8.10
in repository pytango.
commit 0fff4b405f50fc8a961110794732846287d2c1a8
Author: tiagocoutinho <tiagocoutinho at 4e9c00fd-8f2e-0410-aa12-93ce3db5e235>
Date: Thu May 5 07:17:45 2011 +0000
improved support for usage without numpy
git-svn-id: http://svn.code.sf.net/p/tango-cs/code/bindings/PyTango/trunk@16786 4e9c00fd-8f2e-0410-aa12-93ce3db5e235
---
Makefile | 2 +-
PyTango/encoded_attribute.py | 18 +--
PyTango/tango_numpy.py | 228 +++++++++++++++---------------
doc/_static/default.css | 323 +++++++++++++++++++++++++++++++++++++++++++
setup.py | 34 +++--
src/constants.cpp | 63 +++++----
6 files changed, 503 insertions(+), 165 deletions(-)
diff --git a/Makefile b/Makefile
index 5d80c60..635ef96 100644
--- a/Makefile
+++ b/Makefile
@@ -59,7 +59,7 @@ OBJS_DIR = objs
endif
CC = gcc
-CCFLAGS = -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O0 -Wall -fPIC $(INCLUDE_DIRS)
+CCFLAGS = -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -fPIC $(INCLUDE_DIRS)
LN = g++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions
LN_VER = -Wl,-h -Wl,--strip-all
diff --git a/PyTango/encoded_attribute.py b/PyTango/encoded_attribute.py
index 236fe99..d469a1e 100644
--- a/PyTango/encoded_attribute.py
+++ b/PyTango/encoded_attribute.py
@@ -36,12 +36,15 @@ from _PyTango import EncodedAttribute
from _PyTango import ExtractAs
from _PyTango import _ImageFormat
-try:
- import numpy
- np = numpy
-except:
+if _PyTango.constants.NUMPY_SUPPORT:
+ try:
+ import numpy
+ np = numpy
+ except:
+ np = None
+else:
np = None
-
+
_allowed_extract = ExtractAs.Numpy, ExtractAs.String, ExtractAs.Tuple, \
ExtractAs.List, ExtractAs.PyTango3
@@ -221,7 +224,7 @@ def __EncodedAttribute_encode_gray16(self, gray16, width=0, height=0):
if gray16.flags.aligned != True:
raise TypeError("Currently, only contiguous, aligned numpy arrays "
"are supported")
-
+
if not is_str and (not width or not height):
height = len(gray16)
if height < 1:
@@ -234,10 +237,9 @@ def __EncodedAttribute_encode_gray16(self, gray16, width=0, height=0):
width = len(row0)
if type(row0) in types.StringTypes or type(row0) == bytearray:
width /= 2
-
+
self._encode_gray16(gray16, width, height)
-
def __EncodedAttribute_encode_jpeg_rgb24(self, rgb24, width=0, height=0, quality=100.0):
"""Encode a 24 bit rgb color image as JPEG format.
diff --git a/PyTango/tango_numpy.py b/PyTango/tango_numpy.py
index 1b35942..37868d5 100644
--- a/PyTango/tango_numpy.py
+++ b/PyTango/tango_numpy.py
@@ -38,115 +38,119 @@ def _numpy_invalid(*args, **kwds):
"NumpyType.tango_to_numpy"
)
-try:
- import numpy
- import operator
-
- from attribute_proxy import AttributeProxy
-
- ArgType = _PyTango.CmdArgType
- AttributeInfo = _PyTango.AttributeInfo
- Attribute = _PyTango.Attribute
-
- class NumpyType(object):
-
- DevShort = numpy.int16
- DevLong = numpy.int32
- DevDouble = numpy.float64
- DevFloat = numpy.float32
- DevBoolean = numpy.bool8
- DevUShort = numpy.uint16
- DevULong = numpy.uint32
- DevUChar = numpy.ubyte
- DevLong64 = numpy.int64
- DevULong64 = numpy.uint64
-
- mapping = {
- ArgType.DevShort: DevShort,
- ArgType.DevLong: DevLong,
- ArgType.DevDouble: DevDouble,
- ArgType.DevFloat: DevFloat,
- ArgType.DevBoolean: DevBoolean,
- ArgType.DevUShort: DevUShort,
- ArgType.DevULong: DevULong,
- ArgType.DevUChar: DevUChar,
- ArgType.DevLong64: DevLong64,
- ArgType.DevULong: DevULong64,
- }
-
- @staticmethod
- def tango_to_numpy(param):
- if isinstance(param, ArgType):
- tg_type = param
- if isinstance(param, AttributeInfo): # or AttributeInfoEx
- tg_type = param.data_type
- elif isinstance(param, Attribute):
- tg_type = param.get_data_type()
- elif isinstance(param, AttributeProxy):
- tg_type = param.get_config().data_type
- else:
- tg_type = param
- try:
- return NumpyType.mapping[tg_type]
- except Exception:
- _numpy_invalid()
-
- @staticmethod
- def spectrum(tg_type, dim_x):
- """
- numpy_spectrum(self, tg_type, dim_x, dim_y) -> numpy.array
- numpy_spectrum(self, tg_type, sequence) -> numpy.array
-
- Get a square numpy array to be used with PyTango.
- One version gets dim_x and creates an object with
- this size. The other version expects any sequence to
- convert.
-
- Parameters:
- - tg_type : (ArgType): The tango type. For convenience, it
- can also extract this information from an
- Attribute, AttributeInfo or AttributeProxy
- object.
- - dim_x : (int)
- - sequence:
- """
- np_type = NumpyType.tango_to_numpy(tg_type)
- if operator.isSequenceType(dim_x):
- return numpy.array(dim_x, dtype=np_type)
- else:
- return numpy.ndarray(shape=(dim_x,), dtype=np_type)
-
- @staticmethod
- def image(tg_type, dim_x, dim_y=None):
- """
- numpy_image(self, tg_type, dim_x, dim_y) -> numpy.array
- numpy_image(self, tg_type, sequence) -> numpy.array
-
- Get a square numpy array to be used with PyTango.
- One version gets dim_x and dim_y and creates an object with
- this size. The other version expects a square sequence of
- sequences to convert.
-
- Parameters:
- - tg_type : (ArgType): The tango type. For convenience, it
- can also extract this information from an
- Attribute, AttributeInfo or AttributeProxy
- object.
- - dim_x : (int)
- - dim_y : (int)
- - sequence:
- """
- np_type = NumpyType.tango_to_numpy(tg_type)
- if dim_y is None:
- return numpy.array(dim_x, dtype=np_type)
- else:
- return numpy.ndarray(shape=(dim_y,dim_x,), dtype=np_type)
-
- numpy_spectrum = NumpyType.spectrum
- numpy_image = NumpyType.image
- numpy_type = NumpyType.tango_to_numpy
-except Exception:
- NumpyType = None
- numpy_spectrum = _numpy_invalid
- numpy_image = _numpy_invalid
- numpy_type = _numpy_invalid
+def _define_numpy():
+ if not _PyTango.constants.NUMPY_SUPPORT:
+ return None, _numpy_invalid, _numpy_invalid, _numpy_invalid
+
+ try:
+ import numpy
+ import operator
+
+ from attribute_proxy import AttributeProxy
+
+ ArgType = _PyTango.CmdArgType
+ AttributeInfo = _PyTango.AttributeInfo
+ Attribute = _PyTango.Attribute
+
+ class NumpyType(object):
+
+ DevShort = numpy.int16
+ DevLong = numpy.int32
+ DevDouble = numpy.float64
+ DevFloat = numpy.float32
+ DevBoolean = numpy.bool8
+ DevUShort = numpy.uint16
+ DevULong = numpy.uint32
+ DevUChar = numpy.ubyte
+ DevLong64 = numpy.int64
+ DevULong64 = numpy.uint64
+
+ mapping = {
+ ArgType.DevShort: DevShort,
+ ArgType.DevLong: DevLong,
+ ArgType.DevDouble: DevDouble,
+ ArgType.DevFloat: DevFloat,
+ ArgType.DevBoolean: DevBoolean,
+ ArgType.DevUShort: DevUShort,
+ ArgType.DevULong: DevULong,
+ ArgType.DevUChar: DevUChar,
+ ArgType.DevLong64: DevLong64,
+ ArgType.DevULong: DevULong64,
+ }
+
+ @staticmethod
+ def tango_to_numpy(param):
+ if isinstance(param, ArgType):
+ tg_type = param
+ if isinstance(param, AttributeInfo): # or AttributeInfoEx
+ tg_type = param.data_type
+ elif isinstance(param, Attribute):
+ tg_type = param.get_data_type()
+ elif isinstance(param, AttributeProxy):
+ tg_type = param.get_config().data_type
+ else:
+ tg_type = param
+ try:
+ return NumpyType.mapping[tg_type]
+ except Exception:
+ _numpy_invalid()
+
+ @staticmethod
+ def spectrum(tg_type, dim_x):
+ """
+ numpy_spectrum(self, tg_type, dim_x, dim_y) -> numpy.array
+ numpy_spectrum(self, tg_type, sequence) -> numpy.array
+
+ Get a square numpy array to be used with PyTango.
+ One version gets dim_x and creates an object with
+ this size. The other version expects any sequence to
+ convert.
+
+ Parameters:
+ - tg_type : (ArgType): The tango type. For convenience, it
+ can also extract this information from an
+ Attribute, AttributeInfo or AttributeProxy
+ object.
+ - dim_x : (int)
+ - sequence:
+ """
+ np_type = NumpyType.tango_to_numpy(tg_type)
+ if operator.isSequenceType(dim_x):
+ return numpy.array(dim_x, dtype=np_type)
+ else:
+ return numpy.ndarray(shape=(dim_x,), dtype=np_type)
+
+ @staticmethod
+ def image(tg_type, dim_x, dim_y=None):
+ """
+ numpy_image(self, tg_type, dim_x, dim_y) -> numpy.array
+ numpy_image(self, tg_type, sequence) -> numpy.array
+
+ Get a square numpy array to be used with PyTango.
+ One version gets dim_x and dim_y and creates an object with
+ this size. The other version expects a square sequence of
+ sequences to convert.
+
+ Parameters:
+ - tg_type : (ArgType): The tango type. For convenience, it
+ can also extract this information from an
+ Attribute, AttributeInfo or AttributeProxy
+ object.
+ - dim_x : (int)
+ - dim_y : (int)
+ - sequence:
+ """
+ np_type = NumpyType.tango_to_numpy(tg_type)
+ if dim_y is None:
+ return numpy.array(dim_x, dtype=np_type)
+ else:
+ return numpy.ndarray(shape=(dim_y,dim_x,), dtype=np_type)
+
+ return NumpyType, NumpyType.spectrum, NumpyType.image, NumpyType.tango_to_numpy
+ numpy_spectrum = NumpyType.spectrum
+ numpy_image = NumpyType.image
+ numpy_type = NumpyType.tango_to_numpy
+ except Exception:
+ return None, _numpy_invalid, _numpy_invalid, _numpy_invalid
+
+NumpyType, numpy_spectrum, numpy_image, numpy_type = _define_numpy()
diff --git a/doc/_static/default.css b/doc/_static/default.css
new file mode 100644
index 0000000..db3b120
--- /dev/null
+++ b/doc/_static/default.css
@@ -0,0 +1,323 @@
+/**
+ * Sphinx stylesheet -- sphinxdoc theme
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * Originally created by Armin Ronacher for Werkzeug, adapted by Georg Brandl.
+ */
+
+ at import url("basic.css");
+
+/* -- page layout ----------------------------------------------------------- */
+
+body {
+ font-family: 'Lucida Grande', 'Lucida Sans Unicode', 'Geneva',
+ 'Verdana', sans-serif;
+ font-size: 14px;
+ letter-spacing: -0.01em;
+ line-height: 150%;
+ text-align: center;
+ background-color: #BFD1D4;
+ color: black;
+ padding: 0;
+ border: 1px solid #aaa;
+
+ margin: 0px 40px 0px 40px;
+ min-width: 740px;
+}
+
+div.document {
+ background-color: white;
+ text-align: left;
+ background-image: url(contents.png);
+ background-repeat: repeat-x;
+}
+
+div.bodywrapper {
+ margin: 0 240px 0 0;
+ border-right: 1px solid #ccc;
+}
+
+div.body {
+ margin: 0;
+ padding: 0.5em 20px 20px 20px;
+}
+
+div.related {
+ font-size: 12px;
+}
+
+div.related ul {
+ background-image: url(navigation.png);
+ height: 2em;
+ border-top: 1px solid #ddd;
+ border-bottom: 1px solid #ddd;
+}
+
+div.related ul li {
+ margin: 0;
+ padding: 0;
+ height: 2em;
+ float: left;
+}
+
+div.related ul li.right {
+ float: right;
+ margin-right: 5px;
+}
+
+div.related ul li a {
+ margin: 0;
+ padding: 0 5px 0 5px;
+ line-height: 1.75em;
+ color: #EE9816;
+}
+
+div.related ul li a:hover {
+ color: #3CA8E7;
+}
+
+div.sphinxsidebarwrapper {
+ padding: 0;
+}
+
+div.sphinxsidebar {
+ margin: 0;
+ padding: 0.5em 15px 15px 0;
+ width: 210px;
+ float: right;
+ font-size: 1em;
+ text-align: left;
+}
+
+div.sphinxsidebar h3, div.sphinxsidebar h4 {
+ margin: 1em 0 0.5em 0;
+ font-size: 1em;
+ padding: 0.1em 0 0.1em 0.5em;
+ color: white;
+ border: 1px solid #86989B;
+ background-color: #AFC1C4;
+}
+
+div.sphinxsidebar h3 a {
+ color: white;
+}
+
+div.sphinxsidebar ul {
+ padding-left: 1.5em;
+ margin-top: 7px;
+ padding: 0;
+ line-height: 130%;
+}
+
+div.sphinxsidebar ul ul {
+ margin-left: 20px;
+}
+
+div.footer {
+ background-color: #E3EFF1;
+ color: #86989B;
+ padding: 3px 8px 3px 0;
+ clear: both;
+ font-size: 0.8em;
+ text-align: right;
+}
+
+div.footer a {
+ color: #86989B;
+ text-decoration: underline;
+}
+
+/* -- body styles ----------------------------------------------------------- */
+
+p {
+ margin: 0.8em 0 0.5em 0;
+}
+
+a {
+ color: #CA7900;
+ text-decoration: none;
+}
+
+a:hover {
+ color: #2491CF;
+}
+
+div.body a {
+ text-decoration: underline;
+}
+
+h1 {
+ margin: 0;
+ padding: 0.7em 0 0.3em 0;
+ font-size: 1.5em;
+ color: #11557C;
+}
+
+h2 {
+ margin: 1.3em 0 0.2em 0;
+ font-size: 1.35em;
+ padding: 0;
+}
+
+h3 {
+ margin: 1em 0 -0.3em 0;
+ font-size: 1.2em;
+}
+
+div.body h1 a, div.body h2 a, div.body h3 a, div.body h4 a, div.body h5 a, div.body h6 a {
+ color: black!important;
+}
+
+h1 a.anchor, h2 a.anchor, h3 a.anchor, h4 a.anchor, h5 a.anchor, h6 a.anchor {
+ display: none;
+ margin: 0 0 0 0.3em;
+ padding: 0 0.2em 0 0.2em;
+ color: #aaa!important;
+}
+
+h1:hover a.anchor, h2:hover a.anchor, h3:hover a.anchor, h4:hover a.anchor,
+h5:hover a.anchor, h6:hover a.anchor {
+ display: inline;
+}
+
+h1 a.anchor:hover, h2 a.anchor:hover, h3 a.anchor:hover, h4 a.anchor:hover,
+h5 a.anchor:hover, h6 a.anchor:hover {
+ color: #777;
+ background-color: #eee;
+}
+
+a.headerlink {
+ color: #c60f0f!important;
+ font-size: 1em;
+ margin-left: 6px;
+ padding: 0 4px 0 4px;
+ text-decoration: none!important;
+}
+
+a.headerlink:hover {
+ background-color: #ccc;
+ color: white!important;
+}
+
+cite, code, tt {
+ font-family: 'Consolas', 'Deja Vu Sans Mono',
+ 'Bitstream Vera Sans Mono', monospace;
+ font-size: 0.95em;
+ letter-spacing: 0.01em;
+}
+
+tt {
+ background-color: #f2f2f2;
+ border-bottom: 1px solid #ddd;
+ color: #333;
+}
+
+tt.descname, tt.descclassname, tt.xref {
+ border: 0;
+}
+
+hr {
+ border: 1px solid #abc;
+ margin: 2em;
+}
+
+a tt {
+ border: 0;
+ color: #CA7900;
+}
+
+a tt:hover {
+ color: #2491CF;
+}
+
+pre {
+ font-family: 'Consolas', 'Deja Vu Sans Mono',
+ 'Bitstream Vera Sans Mono', monospace;
+ font-size: 0.95em;
+ letter-spacing: 0.015em;
+ line-height: 120%;
+ padding: 0.5em;
+ border: 1px solid #ccc;
+ background-color: #f8f8f8;
+}
+
+pre a {
+ color: inherit;
+ text-decoration: underline;
+}
+
+td.linenos pre {
+ padding: 0.5em 0;
+}
+
+div.quotebar {
+ background-color: #f8f8f8;
+ max-width: 250px;
+ float: right;
+ padding: 2px 7px;
+ border: 1px solid #ccc;
+}
+
+div.topic {
+ background-color: #f8f8f8;
+}
+
+table {
+ border-collapse: collapse;
+ margin: 0 -0.5em 0 -0.5em;
+}
+
+table td, table th {
+ padding: 0.2em 0.5em 0.2em 0.5em;
+}
+
+div.admonition, div.warning {
+ font-size: 0.9em;
+ margin: 1em 0 1em 0;
+ border: 1px solid #86989B;
+ background-color: #f7f7f7;
+ padding: 0;
+}
+
+div.admonition p, div.warning p {
+ margin: 0.5em 1em 0.5em 1em;
+ padding: 0;
+}
+
+div.admonition pre, div.warning pre {
+ margin: 0.4em 1em 0.4em 1em;
+}
+
+div.admonition p.admonition-title,
+div.warning p.admonition-title {
+ margin: 0;
+ padding: 0.1em 0 0.1em 0.5em;
+ color: white;
+ border-bottom: 1px solid #86989B;
+ font-weight: bold;
+ background-color: #AFC1C4;
+}
+
+div.warning {
+ border: 1px solid #940000;
+}
+
+div.warning p.admonition-title {
+ background-color: #CF0000;
+ border-bottom-color: #940000;
+}
+
+div.admonition ul, div.admonition ol,
+div.warning ul, div.warning ol {
+ margin: 0.1em 0.5em 0.5em 3em;
+ padding: 0;
+}
+
+div.versioninfo {
+ margin: 1em 0 0 0;
+ border: 1px solid #ccc;
+ background-color: #DDEAF0;
+ padding: 8px;
+ line-height: 1.3em;
+ font-size: 0.9em;
+}
\ No newline at end of file
diff --git a/setup.py b/setup.py
index e44de5f..a967380 100644
--- a/setup.py
+++ b/setup.py
@@ -36,6 +36,7 @@ import distutils.sysconfig
try:
import sphinx
+ raise Exception()
from sphinx.setup_command import BuildDoc
except:
sphinx = None
@@ -120,12 +121,15 @@ class build(dftbuild):
d = abspath(self.build_lib, "PyTango")
orig_dir = os.path.abspath(os.curdir)
so = "_PyTango.so"
- dbg = so + ".debug"
+ dbg = so + ".dbg"
try:
os.chdir(d)
- os.system("objcopy --only-keep-debug %s %s" % (so, dbg))
- os.system("objcopy --strip-debug --strip-unneeded %s" % (so,))
- os.system("objcopy --add-gnu-debuglink=%s %s" % (dbg, so))
+ is_stripped = os.system('file %s | grep -q "not stripped" || exit 1' % so) != 0
+ if not is_stripped:
+ os.system("objcopy --only-keep-debug %s %s" % (so, dbg))
+ os.system("objcopy --strip-debug --strip-unneeded %s" % (so,))
+ os.system("objcopy --add-gnu-debuglink=%s %s" % (dbg, so))
+ os.system("chmod -x %s" % (dbg,))
finally:
os.chdir(orig_dir)
@@ -147,18 +151,18 @@ class build_ext(dftbuild_ext):
#self.compiler.compiler_so = " ".join(compiler_pars)
dftbuild_ext.build_extensions(self)
-
-class build_doc(BuildDoc):
-
- def run(self):
- # make sure the python path is pointing to the newly built
- # code so that the documentation is built on this and not a
- # previously installed version
+if sphinx:
+ class build_doc(BuildDoc):
- build = self.get_finalized_command('build')
- sys.path.insert(0, os.path.abspath(build.build_lib))
- sphinx.setup_command.BuildDoc.run(self)
- sys.path.pop(0)
+ def run(self):
+ # make sure the python path is pointing to the newly built
+ # code so that the documentation is built on this and not a
+ # previously installed version
+
+ build = self.get_finalized_command('build')
+ sys.path.insert(0, os.path.abspath(build.build_lib))
+ sphinx.setup_command.BuildDoc.run(self)
+ sys.path.pop(0)
class install_html(Command):
diff --git a/src/constants.cpp b/src/constants.cpp
index 75dc218..63ee39a 100644
--- a/src/constants.cpp
+++ b/src/constants.cpp
@@ -35,20 +35,25 @@ void export_constants()
consts_scope.attr("__doc__") = "module containing several Tango constants.\n"
"\nNew in PyTango 7.0.0";
+#ifdef DISABLE_PYTANGO_NUMPY
+ consts_scope.attr("NUMPY_SUPPORT") = false;
+#else
+ consts_scope.attr("NUMPY_SUPPORT") = true;
+#endif
//
// From tango_const.h
//
-
+
//
// Some general interest define
//
-
+
consts_scope.attr("TgLibVers") = TgLibVers;
consts_scope.attr("DevVersion") = DevVersion;
consts_scope.attr("DefaultMaxSeq") = DefaultMaxSeq;
consts_scope.attr("DefaultBlackBoxDepth") = DefaultBlackBoxDepth;
consts_scope.attr("DefaultPollRingDepth") = DefaultPollRingDepth;
-
+
consts_scope.attr("InitialOutput") = InitialOutput;
consts_scope.attr("DSDeviceDomain") = DSDeviceDomain;
consts_scope.attr("DefaultDocUrl") = DefaultDocUrl;
@@ -58,14 +63,14 @@ void export_constants()
consts_scope.attr("ResNotDefined") = ResNotDefined;
consts_scope.attr("MessBoxTitle") = MessBoxTitle;
consts_scope.attr("StatusNotSet") = StatusNotSet;
-
+
consts_scope.attr("DefaultWritAttrProp") = DefaultWritAttrProp;
consts_scope.attr("AllAttr") = AllAttr;
consts_scope.attr("AllAttr_3") = AllAttr_3;
-
+
consts_scope.attr("PollCommand") = PollCommand;
consts_scope.attr("PollAttribute") = PollAttribute;
-
+
consts_scope.attr("MIN_POLL_PERIOD") = MIN_POLL_PERIOD;
consts_scope.attr("DELTA_T") = DELTA_T;
consts_scope.attr("MIN_DELTA_WORK") = MIN_DELTA_WORK;
@@ -73,93 +78,93 @@ void export_constants()
consts_scope.attr("POLL_LOOP_NB") = POLL_LOOP_NB;
consts_scope.attr("ONE_SECOND") = ONE_SECOND;
consts_scope.attr("DISCARD_THRESHOLD") = DISCARD_THRESHOLD;
-
+
consts_scope.attr("DEFAULT_TIMEOUT") = DEFAULT_TIMEOUT;
consts_scope.attr("DEFAULT_POLL_OLD_FACTOR") = DEFAULT_POLL_OLD_FACTOR;
-
+
consts_scope.attr("TG_IMP_MINOR_TO") = TG_IMP_MINOR_TO;
consts_scope.attr("TG_IMP_MINOR_DEVFAILED") = TG_IMP_MINOR_DEVFAILED;
consts_scope.attr("TG_IMP_MINOR_NON_DEVFAILED") = TG_IMP_MINOR_NON_DEVFAILED;
-
+
consts_scope.attr("TANGO_PY_MOD_NAME") = TANGO_PY_MOD_NAME;
consts_scope.attr("DATABASE_CLASS") = DATABASE_CLASS;
-
+
//
// Event related define
//
-
+
consts_scope.attr("EVENT_HEARTBEAT_PERIOD") = EVENT_HEARTBEAT_PERIOD;
consts_scope.attr("EVENT_RESUBSCRIBE_PERIOD") = EVENT_RESUBSCRIBE_PERIOD;
consts_scope.attr("DEFAULT_EVENT_PERIOD") = DEFAULT_EVENT_PERIOD;
consts_scope.attr("DELTA_PERIODIC") = DELTA_PERIODIC;
consts_scope.attr("DELTA_PERIODIC_LONG") = DELTA_PERIODIC_LONG;
consts_scope.attr("HEARTBEAT") = HEARTBEAT;
-
+
//
// Locking feature related defines
//
-
+
consts_scope.attr("DEFAULT_LOCK_VALIDITY") = DEFAULT_LOCK_VALIDITY;
consts_scope.attr("DEVICE_UNLOCKED_REASON") = DEVICE_UNLOCKED_REASON;
consts_scope.attr("MIN_LOCK_VALIDITY") = MIN_LOCK_VALIDITY;
-
+
//
// Client timeout as defined by omniORB4.0.0
//
-
+
consts_scope.attr("CLNT_TIMEOUT_STR") = CLNT_TIMEOUT_STR;
consts_scope.attr("CLNT_TIMEOUT") = CLNT_TIMEOUT;
-
+
//
// Connection and call timeout for database device
//
-
+
consts_scope.attr("DB_CONNECT_TIMEOUT") = DB_CONNECT_TIMEOUT;
consts_scope.attr("DB_RECONNECT_TIMEOUT") = DB_RECONNECT_TIMEOUT;
consts_scope.attr("DB_TIMEOUT") = DB_TIMEOUT;
consts_scope.attr("DB_START_PHASE_RETRIES") = DB_START_PHASE_RETRIES;
-
+
//
// Time to wait before trying to reconnect after
// a connevtion failure
//
consts_scope.attr("RECONNECTION_DELAY") = RECONNECTION_DELAY;
-
+
//
// Access Control related defines
// WARNING: these string are also used within the Db stored procedure
// introduced in Tango V6.1. If you chang eit here, don't forget to
// also update the stored procedure
//
-
+
consts_scope.attr("CONTROL_SYSTEM") = CONTROL_SYSTEM;
consts_scope.attr("SERVICE_PROP_NAME") = SERVICE_PROP_NAME;
consts_scope.attr("ACCESS_SERVICE") = ACCESS_SERVICE;
-
+
//
// Polling threads pool related defines
//
-
+
consts_scope.attr("DEFAULT_POLLING_THREADS_POOL_SIZE") = DEFAULT_POLLING_THREADS_POOL_SIZE;
-
+
//
// Max transfer size 256 MBytes (in byte). Needed by omniORB
//
-
+
consts_scope.attr("MAX_TRANSFER_SIZE") = MAX_TRANSFER_SIZE;
-
+
//
// Tango name length
//
-
+
consts_scope.attr("MaxServerNameLength") = MaxServerNameLength;
-
+
//
// Files used to retrieve env. variables
//
-
+
consts_scope.attr("USER_ENV_VAR_FILE") = USER_ENV_VAR_FILE;
-
+
consts_scope.attr("kLogTargetConsole") = kLogTargetConsole;
consts_scope.attr("kLogTargetFile") = kLogTargetFile;
consts_scope.attr("kLogTargetDevice") = kLogTargetDevice;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/pytango.git
More information about the debian-science-commits
mailing list