[pytango] 21/98: Implement AttributeConfig and AttributeInfo changes
Sandor Bodo-Merle
sbodomerle-guest at moszumanska.debian.org
Thu Sep 28 19:17:41 UTC 2017
This is an automated email from the git hooks/post-receive script.
sbodomerle-guest pushed a commit to tag v9.2.0
in repository pytango.
commit cd99a22915d0362b8467b0c0631cd5d03790c489
Author: Jose Tiago Coutinho Macara <tiago.coutinho at esrf.fr>
Date: Tue Dec 1 09:05:25 2015 +0100
Implement AttributeConfig and AttributeInfo changes
---
src/boost/cpp/enums.cpp | 8 -------
src/boost/cpp/from_py.h | 3 ---
src/boost/cpp/server/attribute.cpp | 48 --------------------------------------
src/boost/cpp/to_py.cpp | 29 -----------------------
src/boost/cpp/to_py.h | 6 -----
src/boost/python/device_server.py | 13 +++++------
6 files changed, 6 insertions(+), 101 deletions(-)
diff --git a/src/boost/cpp/enums.cpp b/src/boost/cpp/enums.cpp
index 0f80c13..c86ddff 100644
--- a/src/boost/cpp/enums.cpp
+++ b/src/boost/cpp/enums.cpp
@@ -226,14 +226,6 @@ void export_enums()
.value("PIPE_WT_UNKNOWN", Tango::PIPE_WT_UNKNOWN)
;
- enum_<Tango::PipeSerialModel>("PipeSerialModel")
- .value("PIPE_NO_SYNC", Tango::PIPE_NO_SYNC)
- .value("PIPE_BY_KERNEL", Tango::PIPE_BY_KERNEL)
- .value("PIPE_BY_USER", Tango::PIPE_BY_USER)
- ;
-
- scope().attr("PipeReqType") = scope().attr("AttReqType");
-
enum_<Tango::AttrMemorizedType>("AttrMemorizedType")
.value("NOT_KNOWN", Tango::NOT_KNOWN)
.value("NONE", Tango::NONE)
diff --git a/src/boost/cpp/from_py.h b/src/boost/cpp/from_py.h
index d86cd65..efe33a5 100644
--- a/src/boost/cpp/from_py.h
+++ b/src/boost/cpp/from_py.h
@@ -701,6 +701,3 @@ void from_py_object(bopy::object &, Tango::AttributeConfigList &);
void from_py_object(bopy::object &, Tango::AttributeConfigList_2 &);
void from_py_object(bopy::object &, Tango::AttributeConfigList_3 &);
void from_py_object(bopy::object &, Tango::AttributeConfigList_5 &);
-
-void from_py_object(bopy::object &, Tango::PipeConfig &);
-void from_py_object(bopy::object &, Tango::PipeConfigList &);
diff --git a/src/boost/cpp/server/attribute.cpp b/src/boost/cpp/server/attribute.cpp
index e92ad9b..ebfdbc6 100644
--- a/src/boost/cpp/server/attribute.cpp
+++ b/src/boost/cpp/server/attribute.cpp
@@ -393,34 +393,6 @@ namespace PyAttribute
long x, long y)
{ __set_value("set_value_date_quality", att, value, &x, &y, t, &quality); }
- /* According to tango attribute.h these "methods not usable for
- the external world (outside the lib)" */
- /*
- inline bopy::object get_properties(Tango::Attribute &att,
- bopy::object &attr_cfg)
- {
- Tango::AttributeConfig tg_attr_cfg;
- att.get_properties(tg_attr_cfg);
- return to_py(tg_attr_cfg, attr_cfg);
- }
-
- inline bopy::object get_properties_2(Tango::Attribute &att,
- bopy::object &attr_cfg)
- {
- Tango::AttributeConfig_2 tg_attr_cfg;
- att.get_properties(tg_attr_cfg);
- return to_py(tg_attr_cfg, attr_cfg);
- }
-
- inline bopy::object get_properties_3(Tango::Attribute &att,
- bopy::object &attr_cfg)
- {
- Tango::AttributeConfig_3 tg_attr_cfg;
- att.get_properties(tg_attr_cfg);
- return to_py(tg_attr_cfg, attr_cfg);
- }
- */
-
template<typename TangoScalarType>
inline void _get_properties_multi_attr_prop(Tango::Attribute &att, bopy::object &multi_attr_prop)
{
@@ -439,26 +411,6 @@ namespace PyAttribute
return multi_attr_prop;
}
- /*
- void set_properties(Tango::Attribute &att, bopy::object &attr_cfg,
- bopy::object &dev)
- {
- Tango::AttributeConfig tg_attr_cfg;
- from_py_object(attr_cfg, tg_attr_cfg);
- Tango::DeviceImpl *dev_ptr = extract<Tango::DeviceImpl*>(dev);
- att.set_properties(tg_attr_cfg, dev_ptr);
- }
-
- void set_properties_3(Tango::Attribute &att, bopy::object &attr_cfg,
- bopy::object &dev)
- {
- Tango::AttributeConfig_3 tg_attr_cfg;
- from_py_object(attr_cfg, tg_attr_cfg);
- Tango::DeviceImpl *dev_ptr = extract<Tango::DeviceImpl*>(dev);
- att.set_properties(tg_attr_cfg, dev_ptr);
- }
- */
-
template<typename TangoScalarType>
inline void _set_properties_multi_attr_prop(Tango::Attribute &att, bopy::object &multi_attr_prop)
{
diff --git a/src/boost/cpp/to_py.cpp b/src/boost/cpp/to_py.cpp
index 66eff51..ea57a03 100644
--- a/src/boost/cpp/to_py.cpp
+++ b/src/boost/cpp/to_py.cpp
@@ -257,32 +257,3 @@ boost::python::list to_py(const Tango::AttributeConfigList_5 &attr_conf_list)
}
return py_attr_conf_list;
}
-
-object to_py(const Tango::PipeConfig &pipe_conf, object py_pipe_conf)
-{
- if(py_pipe_conf.ptr() == Py_None)
- {
- PYTANGO_MOD
- py_pipe_conf = pytango.attr("PipeConfig")();
- }
-
- py_pipe_conf.attr("name") = str(pipe_conf.name.in());
- py_pipe_conf.attr("description") = str(pipe_conf.description.in());
- py_pipe_conf.attr("label") = str(pipe_conf.label.in());
- py_pipe_conf.attr("level") = pipe_conf.level;
- py_pipe_conf.attr("writable") = pipe_conf.writable;
- py_pipe_conf.attr("extensions") = CORBA_sequence_to_list<Tango::DevVarStringArray>::to_list(pipe_conf.extensions);
- return py_pipe_conf;
-}
-
-boost::python::list to_py(const Tango::PipeConfigList &pipe_conf_list)
-{
- boost::python::list py_pipe_conf_list;
- boost::python::object none;
- for(unsigned long index = 0; index < pipe_conf_list.length(); ++index)
- {
- const Tango::PipeConfig &pipe_conf = pipe_conf_list[index];
- py_pipe_conf_list.append(to_py(pipe_conf, none));
- }
- return py_pipe_conf_list;
-}
diff --git a/src/boost/cpp/to_py.h b/src/boost/cpp/to_py.h
index d04bb63..0fdd1cb 100644
--- a/src/boost/cpp/to_py.h
+++ b/src/boost/cpp/to_py.h
@@ -361,12 +361,6 @@ boost::python::list to_py(const Tango::AttributeConfigList_2 &);
boost::python::list to_py(const Tango::AttributeConfigList_3 &);
boost::python::list to_py(const Tango::AttributeConfigList_5 &);
-boost::python::object to_py(const Tango::PipeConfig &,
- boost::python::object);
-
-boost::python::object to_py(const Tango::PipeConfigList &,
- boost::python::object);
-
template<class T>
inline boost::python::object to_py_list(const T *seq)
{
diff --git a/src/boost/python/device_server.py b/src/boost/python/device_server.py
index b31d844..88e12f9 100644
--- a/src/boost/python/device_server.py
+++ b/src/boost/python/device_server.py
@@ -18,18 +18,19 @@ from __future__ import print_function
__all__ = [ "ChangeEventProp", "PeriodicEventProp",
"ArchiveEventProp","AttributeAlarm", "EventProperties",
"AttributeConfig", "AttributeConfig_2",
- "AttributeConfig_3", "AttributeConfig_5",
- "MultiAttrProp", "device_server_init"]
+ "AttributeConfig_3", "AttributeConfig_5", "PipeConfig",
+ "MultiAttrProp",
+ "device_server_init"]
__docformat__ = "restructuredtext"
import copy
-from ._PyTango import DeviceImpl, Device_3Impl, Device_4Impl, Device_5Impl, \
+from ._PyTango import DeviceImpl, Device_3Impl, Device_4Impl, \
DevFailed, Attribute, WAttribute, \
MultiAttribute, MultiClassAttribute, \
- Attr, Logger, AttrWriteType, AttrDataFormat, CmdArgType, \
- DispLevel, UserDefaultAttrProp, StdStringVector
+ Attr, Logger, AttrWriteType, PipeWriteType, AttrDataFormat, \
+ DispLevel, UserDefaultAttrProp
from .utils import document_method as __document_method
from .utils import copy_doc
@@ -176,8 +177,6 @@ class AttributeConfig_5(object):
self.event_prop = EventProperties()
self.sys_extensions = []
-
-
def __Attribute__get_properties(self, attr_cfg = None):
"""get_properties(self, attr_cfg = None) -> AttributeConfig
--
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