本文整理汇总了Python中OpenRTM_aist.uuid1方法的典型用法代码示例。如果您正苦于以下问题:Python OpenRTM_aist.uuid1方法的具体用法?Python OpenRTM_aist.uuid1怎么用?Python OpenRTM_aist.uuid1使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类OpenRTM_aist
的用法示例。
在下文中一共展示了OpenRTM_aist.uuid1方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: loadSheet
# 需要导入模块: import OpenRTM_aist [as 别名]
# 或者: from OpenRTM_aist import uuid1 [as 别名]
def loadSheet(self):
self.rtc.mRemoveAllPort()
count = 1
m_hostname = ''
_path = []
while True:
cell,sheet,m_len = self.rtc.m_excel.getCell(count,"A",'保存用',"",False)
if cell.Value2 == None:
return
m_name = re.split(':',cell.Value2)
if len(m_name) < 2:
return
if len(m_name) == 2:
for dn in CalcDataPort.DataType.DataTypeList:
if m_name[1] == dn:
m_name[1] = dn
#m_name[1] = m_name[1].decode("cp932").encode("utf-8")
F_Name = m_name[1] + str(OpenRTM_aist.uuid1())
row,col,mlen,sn,mstate,t_attachports = self.loadParam(count)
if m_name[0] == 'DataInPort':
self.rtc.mAddInPort(F_Name, [[m_name[0],m_name[1]],m_name[1]], row, col, mlen, sn, mstate, t_attachports, False)
elif m_name[0] == 'DataOutPort':
self.rtc.mAddOutPort(F_Name, [[m_name[0],m_name[1]],m_name[1]], row, col, mlen, sn, mstate, t_attachports, False)
else:
if m_hostname == m_name[1]:
pass
else:
_paths = OOoRTC.GetPathList(m_name[1], self.mgr, None)
m_hostname = m_name[1]
if _paths == None:
return
for p in _paths:
if p[0] == m_name:
F_Name = p[0][-2] + p[0][-1]
profile = p[1].get_port_profile()
#props = nvlist_to_dict(profile.properties)
row,col,mlen,sn,mstate,t_attachports = self.loadParam(count)
if OOoRTC.nvlist_getValue(profile.properties,'port.port_type') == 'DataInPort':
self.rtc.mAddOutPort(F_Name, p, row, col, mlen, sn, mstate, t_attachports)
elif OOoRTC.nvlist_getValue(profile.properties,'port.port_type') == 'DataOutPort':
self.rtc.mAddInPort(F_Name, p, row, col, mlen, sn, mstate, t_attachports)
count = count + 1
示例2: __init__
# 需要导入模块: import OpenRTM_aist [as 别名]
# 或者: from OpenRTM_aist import uuid1 [as 别名]
def __init__(self, sdo):
self._pId = str(OpenRTM_aist.uuid1())
self._org_mutex = threading.RLock()
self._orgProperty = SDOPackage.OrganizationProperty([])
self._varOwner = sdo
self._memberList = []
self._dependency = SDOPackage.OWN
self._objref = self._this()
self._rtcout = OpenRTM_aist.Manager.instance().getLogbuf("rtobject.sdo_organization")
示例3: getUUID
# 需要导入模块: import OpenRTM_aist [as 别名]
# 或者: from OpenRTM_aist import uuid1 [as 别名]
def getUUID(self):
return OpenRTM_aist.uuid1()
示例4: addSlot
# 需要导入模块: import OpenRTM_aist [as 别名]
# 或者: from OpenRTM_aist import uuid1 [as 别名]
def addSlot(self):
pn = str(self.portListcomboBox.currentText().toLocal8Bit())
if self.rtc.InPorts.has_key(pn) == True:
self.setPortParam(self.rtc.InPorts[pn])
self.updateSaveSheet()
return
elif self.rtc.OutPorts.has_key(pn) == True:
self.setPortParam(self.rtc.OutPorts[pn])
self.updateSaveSheet()
return
dt = str(self.datatypecomboBox.currentText().toLocal8Bit())
if dt != "":
F_Name = dt + str(OpenRTM_aist.uuid1())
pt = str(self.porttypecomboBox.currentText().toLocal8Bit())
if pt == "DataOutPort":
if self.compAddOutPort(F_Name, [[pt,dt],dt], False):
self.massageBoxFunc('',dt.decode("utf-8")+u"型のOutPortを作成しました。")
else:
if self.compAddInPort(F_Name, [[pt,dt],dt], False):
self.massageBoxFunc('',dt.decode("utf-8")+u"型のInPortを作成しました。")
self.updateInPortList()
self.updateDataPortList()
self.updateSaveSheet()
return
t_comp, nd = OOoRTC.JudgePort(self, self._paths)
if t_comp:
for n,o in self.rtc.OutPorts.items():
if o._port_a[0] == t_comp[0]:
self.setPortParam(o)
return
for n,i in self.rtc.InPorts.items():
if i._port_a[0] == t_comp[0]:
self.setPortParam(i)
return
F_Name = t_comp[0][-2] + t_comp[0][-1]
profile = t_comp[1].get_port_profile()
#props = nvlist_to_dict(profile.properties)
if OOoRTC.nvlist_getValue(profile.properties,'port.port_type') == 'DataInPort':
self.compAddOutPort(F_Name, t_comp)
elif OOoRTC.nvlist_getValue(profile.properties,'port.port_type') == 'DataOutPort':
self.compAddInPort(F_Name, t_comp)
self.updateSaveSheet()
self.infotextBox.setText(u"作成済み")
self.updateInPortList()
self.updateDataPortList()
self.massageBoxFunc('',t_comp[0][-2]+u"の"+t_comp[0][-1]+u"と通信するデータポートを作成しました。")
"""print self.coltextBox.text()