RTObject.cpp
Go to the documentation of this file.
1 // -*- C++ -*-
19 #include <assert.h>
20 #include <rtm/RTObject.h>
21 #include <rtm/SdoConfiguration.h>
22 #include <rtm/CORBA_SeqUtil.h>
23 #include <rtm/Manager.h>
24 #include <coil/stringutil.h>
25 #include <iostream>
26 #include <typeinfo>
27 
28 #ifdef __QNX__
29 using std::atof;
30 #endif
31 
32 namespace RTC
33 {
41  static const char* default_conf[] =
42  {
43  "implementation_id", "",
44  "type_name", "",
45  "description", "",
46  "version", "",
47  "vendor", "",
48  "category", "",
49  "activity_type", "",
50  "max_instance", "",
51  "language", "",
52  "lang_type", "",
53  "conf", "",
54  ""
55  };
56 
65  : m_pManager(manager),
66  m_pORB(CORBA::ORB::_duplicate(manager->getORB())),
67  m_pPOA(PortableServer::POA::_duplicate(manager->getPOA())),
68  m_portAdmin(manager->getORB(), manager->getPOA()),
69  m_created(true), m_exiting(false),
70  m_properties(default_conf), m_configsets(m_properties.getNode("conf")),
71  m_sdoservice(*this),
72  m_readAll(false),m_writeAll(false),
73  m_readAllCompletion(false),m_writeAllCompletion(false)
74  {
75  m_objref = this->_this();
77  m_sdoservice);
78  m_pSdoConfig = SDOPackage::Configuration::
79  _duplicate(m_pSdoConfigImpl->getObjRef());
80  }
81 
89  RTObject_impl::RTObject_impl(CORBA::ORB_ptr orb,
90  PortableServer::POA_ptr poa)
91  : m_pManager(NULL),
92  m_pORB(CORBA::ORB::_duplicate(orb)),
93  m_pPOA(PortableServer::POA::_duplicate(poa)),
94  m_portAdmin(orb, poa),
95  m_created(true), m_exiting(false),
96  m_properties(default_conf), m_configsets(m_properties.getNode("conf")),
97  m_sdoservice(*this),
98  m_readAll(false),m_writeAll(false),
100  {
101  m_objref = this->_this();
103  m_sdoservice);
104  m_pSdoConfig = SDOPackage::Configuration::
105  _duplicate(m_pSdoConfigImpl->getObjRef());
106  }
107 
116  {
117  RTC_TRACE(("~RTObject_impl()"));
118  m_pSdoConfigImpl->_remove_ref();
119  }
120 
121  //============================================================
122  // Overridden functions
123  //============================================================
131  // The initialize action (on CREATED->ALIVE transition)
132  // former rtc_init_entry()
134  {
135  RTC_TRACE(("onInitialize()"));
136  return RTC::RTC_OK;
137  }
138 
146  // The finalize action (on ALIVE->END transition)
147  // former rtc_exiting_entry()
149  {
150  RTC_TRACE(("onFinalize()"));
151  return RTC::RTC_OK;
152  }
153 
161  // The startup action when ExecutionContext startup
162  // former rtc_starting_entry()
164  {
165  RTC_TRACE(("onStartup(%d)", ec_id));
166  return RTC::RTC_OK;
167  }
168 
176  // The shutdown action when ExecutionContext stop
177  // former rtc_stopping_entry()
179  {
180  RTC_TRACE(("onShutdown(%d)", ec_id));
181  return RTC::RTC_OK;
182  }
183 
191  // The activated action (Active state entry action)
192  // former rtc_active_entry()
194  {
195  RTC_TRACE(("onActivated(%d)", ec_id));
196  return RTC::RTC_OK;
197  }
198 
206  // The deactivated action (Active state exit action)
207  // former rtc_active_exit()
209  {
210  RTC_TRACE(("onDeactivated(%d)", ec_id));
211  return RTC::RTC_OK;
212  }
213 
221  // The execution action that is invoked periodically
222  // former rtc_active_do()
224  {
225  RTC_PARANOID(("onExecute(%d)", ec_id));
226  return RTC::RTC_OK;
227  }
228 
236  // The aborting action when main logic error occurred.
237  // former rtc_aborting_entry()
239  {
240  RTC_TRACE(("onAborting(%d)", ec_id));
241  return RTC::RTC_OK;
242  }
243 
251  // The error action in ERROR state
252  // former rtc_error_do()
254  {
255  RTC_TRACE(("onError(%d)", ec_id));
256  return RTC::RTC_OK;
257  }
258 
266  // The reset action that is invoked resetting
267  // This is same but different the former rtc_init_entry()
269  {
270  RTC_TRACE(("onReset(%d)", ec_id));
271  return RTC::RTC_OK;
272  }
273 
281  // The state update action that is invoked after onExecute() action
282  // no corresponding operation exists in OpenRTm-aist-0.2.0
284  {
285  RTC_PARANOID(("onStateUpdate(%d)", ec_id));
286  return RTC::RTC_OK;
287  }
288 
296  // The action that is invoked when execution context's rate is changed
297  // no corresponding operation exists in OpenRTm-aist-0.2.0
299  {
300  RTC_TRACE(("onRatechanged(%d)", ec_id));
301  return RTC::RTC_OK;
302  }
303 
304  //============================================================
305  // RTC::LightweightRTObject
306  //============================================================
315  throw (CORBA::SystemException)
316  {
317  RTC_TRACE(("initialize()"));
318  std::string ec_args;
319 
320  ec_args += m_properties["exec_cxt.periodic.type"];
321  ec_args += "?";
322  ec_args += "rate=" + m_properties["exec_cxt.periodic.rate"];
323 
325  ec = RTC::Manager::instance().createContext(ec_args.c_str());
326  if (ec == NULL) return RTC::RTC_ERROR;
327 
328  ec->set_rate(atof(m_properties["exec_cxt.periodic.rate"].c_str()));
329  m_eclist.push_back(ec);
330  ExecutionContextService_var ecv;
331  ecv = RTC::ExecutionContextService::_duplicate(ec->getObjRef());
332  if (CORBA::is_nil(ecv)) return RTC::RTC_ERROR;
333 
334  ec->bindComponent(this);
335  // -- entering alive state --
336  // at least one EC must be attached
337  if (m_ecMine.length() == 0) return RTC::PRECONDITION_NOT_MET;
338 
340  ret = on_initialize();
341  if (ret != RTC::RTC_OK) return ret;
342  m_created = false;
343 
344  for (::CORBA::ULong i(0), len(m_ecMine.length()); i < len; ++i)
345  {
346  RTC_DEBUG(("EC[%d] starting.", i));
347  m_ecMine[i]->start();
348  }
349 
350  // ret must be RTC_OK
351  return ret;
352  }
353 
362  throw (CORBA::SystemException)
363  {
364  RTC_TRACE(("finalize()"));
367  // Return RTC::PRECONDITION_NOT_MET,
368  // When the component is registered in ExecutionContext.
369  // m_ecMine.length() != 0 ||
370  if(m_ecOther.length() != 0)
371  {
372 
373  for (CORBA::ULong ic(0), len(m_ecOther.length()); ic < len; ++ic)
374  {
375  if(! CORBA::is_nil(m_ecOther[ic]))
376  {
378  }
379  }
381  }
382 
384 
385  shutdown();
386  return ret;
387  }
388 
399  throw (CORBA::SystemException)
400  {
401  RTC_TRACE(("exit()"));
402  if (m_created) { return RTC::PRECONDITION_NOT_MET; }
403  if (m_exiting) { return RTC::RTC_OK; }
404 
405  // deactivate myself on owned EC
408  // deactivate myself on other EC
411 
412  // owned EC will be finalised later in finalizeContext().
413 
414  // detach myself from other EC
415  for (CORBA::ULong ic(0), len(m_ecOther.length()); ic < len; ++ic)
416  {
417  // m_ecOther[ic]->stop();
418  RTC::LightweightRTObject_var comp(this->_this());
419  if (! ::CORBA::is_nil(m_ecOther[ic]))
420  {
421  m_ecOther[ic]->remove_component(comp.in());
422  }
423  }
424  m_exiting = true;
426 
427  return ret;
428  }
429 
437  CORBA::Boolean RTObject_impl::is_alive(ExecutionContext_ptr exec_context)
438  throw (CORBA::SystemException)
439  {
440  RTC_TRACE(("is_alive()"));
441  for (::CORBA::ULong i(0), len(m_ecMine.length()); i < len; ++i)
442  {
443  if (exec_context->_is_equivalent(m_ecMine[i]))
444  return true;
445  }
446 
447  for (::CORBA::ULong i(0), len(m_ecOther.length()); i < len; ++i)
448  {
449  if (! ::CORBA::is_nil(m_ecOther[i]))
450  {
451  if (exec_context->_is_equivalent(m_ecOther[i]))
452  return true;
453  }
454  }
455  return false;
456  }
457 
466  throw (CORBA::SystemException)
467  {
468  RTC_TRACE(("get_context(%d)", ec_id));
469  // owned EC
470  if (ec_id < ECOTHER_OFFSET)
471  {
472  if ((::CORBA::ULong)ec_id < m_ecMine.length())
473  {
474  return ExecutionContext::_duplicate(m_ecMine[ec_id]);
475  }
476  else
477  {
478  return ExecutionContext::_nil();
479  }
480  }
481 
482  // participating EC
483  ::CORBA::ULong index(ec_id - ECOTHER_OFFSET);
484 
485  if (index < m_ecOther.length())
486  {
487  if (! ::CORBA::is_nil(m_ecOther[index]))
488  {
489  return ExecutionContext::_duplicate(m_ecOther[index]);
490  }
491  }
492 
493  return ExecutionContext::_nil();
494  }
495 
504  throw (CORBA::SystemException)
505  {
506  RTC_TRACE(("get_owned_context()"));
507 
508 #ifndef ORB_IS_RTORB
509  ExecutionContextList_var execlist;
510  execlist = new ExecutionContextList();
511 
513 #else // ORB_IS_RTORB
514  ExecutionContextList_var execlist;
515  execlist = new ExecutionContextList();
516 
517  int n = m_ecMine.length();
518  for(int i(0), j(0); i < n ; ++i)
519  {
520  RTC_ExecutionContext ec_mine = m_ecMine.cobj()->_buffer[i];
521 
522  if (ec_mine)
523  {
524  execlist.length(j+1);
525  execlist->cobj()->_buffer[j] = CORBA_Object_dup(ec_mine);
526  ++j;
527  }
528  }
529 #endif // ORB_IS_RTORB
530  return execlist._retn();
531  }
532 
541  throw (CORBA::SystemException)
542  {
543  RTC_TRACE(("get_participating_contexts()"));
544  ExecutionContextList_var execlist;
545  execlist = new ExecutionContextList();
546 
548 
549  return execlist._retn();
550  }
551 
552 
561  RTObject_impl::get_context_handle(ExecutionContext_ptr cxt)
562  throw (CORBA::SystemException)
563  {
564  RTC_TRACE(("get_context_handle()"));
565  CORBA::Long num;
566  num = CORBA_SeqUtil::find(m_ecMine, ec_find(cxt));
567  if (num != -1)
568  {
569  return (ExecutionContextHandle_t)num;
570  }
572  if (num != -1)
573  {
575  }
576  return (ExecutionContextHandle_t)(-1);
577  }
578 
579 
587  UniqueId RTObject_impl::attach_context(ExecutionContext_ptr exec_context)
588  throw (CORBA::SystemException)
589  {
590  RTC_TRACE(("attach_context()"));
591  // ID: 0 - (offset-1) : owned ec
592  // ID: offset - : participating ec
593  // owned ec index = ID
594  // participate ec index = ID - offset
595  ExecutionContextService_var ecs;
596  ecs = ExecutionContextService::_narrow(exec_context);
597  if (CORBA::is_nil(ecs))
598  {
599  return -1;
600  }
601 
602  // if m_ecOther has nil element, insert attached ec to there.
603  for (::CORBA::ULong i(0), len(m_ecOther.length()); i < len; ++i)
604  {
605  if (::CORBA::is_nil(m_ecOther[i]))
606  {
607  m_ecOther[i] = ExecutionContextService::_duplicate(ecs);
610  return ec_id;
611  }
612  }
613 
614  // no space in the list, push back ec to the last.
616  push_back(m_ecOther, ExecutionContextService::_duplicate(ecs));
617 
618  UniqueId ec_id((m_ecOther.length() - 1) + ECOTHER_OFFSET);
620  return ec_id;
621  }
622 
623  UniqueId
624  RTObject_impl::bindContext(ExecutionContext_ptr exec_context)
625  {
626  RTC_TRACE(("bindContext()"));
627  // ID: 0 - (offset-1) : owned ec
628  // ID: offset - : participating ec
629  // owned ec index = ID
630  // participate ec index = ID - offset
631  ExecutionContextService_var ecs;
632  ecs = ExecutionContextService::_narrow(exec_context);
633  if (CORBA::is_nil(ecs))
634  {
635  return -1;
636  }
637 
638  // if m_ecMine has nil element, insert attached ec to there.
639  for (::CORBA::ULong i(0), len(m_ecMine.length()); i < len; ++i)
640  {
641  if (::CORBA::is_nil(m_ecMine[i]))
642  {
643  m_ecMine[i] = ExecutionContextService::_duplicate(ecs);
645  return i;
646  }
647  }
648 
649  // no space in the list, push back ec to the last.
651  push_back(m_ecMine, ExecutionContextService::_duplicate(ecs));
652 
653  UniqueId ec_id(m_ecMine.length() - 1);
654  return ec_id;
655  }
656 
665  throw (CORBA::SystemException)
666  {
667  RTC_TRACE(("detach_context(%d)", ec_id));
668  ::CORBA::ULong len(m_ecOther.length());
669 
670  // ID: 0 - (offset-1) : owned ec
671  // ID: offset - : participating ec
672  // owned ec index = ID
673  // participate ec index = ID - offset
674  if ((CORBA::ULong)ec_id < ECOTHER_OFFSET ||
675  (CORBA::ULong)(ec_id - ECOTHER_OFFSET) > len)
676  {
677  return RTC::BAD_PARAMETER;
678  }
679  ::CORBA::ULong index(ec_id - ECOTHER_OFFSET);
680 
681  if (CORBA::is_nil(m_ecOther[index]))
682  {
683  return RTC::BAD_PARAMETER;
684  }
685 
686  m_ecOther[index] = ::RTC::ExecutionContextService::_nil();
688  return RTC::RTC_OK;
689  }
690 
691  //============================================================
692  // RTC::RTObject
693  //============================================================
694 
703  throw (CORBA::SystemException)
704  {
705  RTC_TRACE(("get_component_profile()"));
706  try
707  {
708  ComponentProfile_var profile
709  = new ComponentProfile();
710 #ifndef ORB_IS_RTORB
711  profile->instance_name =
712  CORBA::string_dup(m_properties["instance_name"].c_str());
713  profile->type_name =
714  CORBA::string_dup(m_properties["type_name"].c_str());
715  profile->description =
716  CORBA::string_dup(m_properties["description"].c_str());
717  profile->version =
718  CORBA::string_dup(m_properties["version"].c_str());
719  profile->vendor =
720  CORBA::string_dup(m_properties["vendor"].c_str());
721  profile->category =
722  CORBA::string_dup(m_properties["category"].c_str());
723  profile->port_profiles = m_portAdmin.getPortProfileList();
724 #else // ORB_IS_RTORB
725  profile->instance_name = (char *)m_properties["instance_name"].c_str();
726  profile->type_name = (char *)m_properties["type_name"].c_str();
727  profile->description = (char *)m_properties["description"].c_str();
728  profile->version = (char *)m_properties["version"].c_str();
729  profile->vendor = (char *)m_properties["vendor"].c_str();
730  profile->category = (char *)m_properties["category"].c_str();
732  profile->port_profiles = ppl._retn();
733 #endif // ORB_IS_RTORB
734  NVUtil::copyFromProperties(profile->properties, m_properties);
735  return profile._retn();
736  }
737  catch (...)
738  {
739  ; // This operation throws no exception.
740  }
741  assert(false);
742  return 0;
743  }
744 
753  throw (CORBA::SystemException)
754  {
755  RTC_TRACE(("get_ports()"));
756  try
757  {
759  }
760  catch (...)
761  {
762  ; // This operation throws no exception.
763  }
764  assert(false);
765  return 0;
766  }
767 
768 
769  //============================================================
770  // RTC::ComponentAction
771  //============================================================
780  throw (CORBA::SystemException)
781  {
782  RTC_TRACE(("on_initialize()"));
784  try
785  {
786  preOnInitialize(0);
787  ret = onInitialize();
788  }
789  catch (...)
790  {
791  ret = RTC::RTC_ERROR;
792  }
793  std::string active_set;
794  active_set = m_properties.getProperty("configuration.active_config",
795  "default");
796  if (m_configsets.haveConfig(active_set.c_str()))
797  {
798  m_configsets.update(active_set.c_str());
799  }
800  else
801  {
802  m_configsets.update("default");
803  }
804  postOnInitialize(0, ret);
805  return ret;
806  }
807 
816  throw (CORBA::SystemException)
817  {
818  RTC_TRACE(("on_finalize()"));
820  try
821  {
822  preOnFinalize(0);
823  ret = onFinalize();
824  }
825  catch (...)
826  {
827  ret = RTC::RTC_ERROR;
828  }
829  postOnFinalize(0, ret);
830  return ret;
831  }
832 
841  throw (CORBA::SystemException)
842  {
843  RTC_TRACE(("on_startup(%d)", ec_id));
845  try
846  {
848  ret = onStartup(ec_id);
849  }
850  catch (...)
851  {
852  ret = RTC::RTC_ERROR;
853  }
854  postOnStartup(ec_id, ret);
855  return ret;
856  }
857 
866  throw (CORBA::SystemException)
867  {
868  RTC_TRACE(("on_shutdown(%d)", ec_id));
870  try
871  {
873  ret = onShutdown(ec_id);
874  }
875  catch (...)
876  {
877  ret = RTC::RTC_ERROR;
878  }
879  postOnShutdown(ec_id, ret);
880  return ret;
881  }
882 
891  throw (CORBA::SystemException)
892  {
893  RTC_TRACE(("on_activated(%d)", ec_id));
895  try
896  {
899  ret = onActivated(ec_id);
901  }
902  catch (...)
903  {
904  ret = RTC::RTC_ERROR;
905  }
906  postOnActivated(ec_id, ret);
907  return ret;
908  }
909 
918  throw (CORBA::SystemException)
919  {
920  RTC_TRACE(("on_deactivated(%d)", ec_id));
922  try
923  {
926  ret = onDeactivated(ec_id);
927  }
928  catch (...)
929  {
930  ret = RTC::RTC_ERROR;
931  }
932  postOnDeactivated(ec_id, ret);
933  return ret;
934  }
935 
944  throw (CORBA::SystemException)
945  {
946  RTC_TRACE(("on_aborting(%d)", ec_id));
948  try
949  {
951  ret = onAborting(ec_id);
952  }
953  catch (...)
954  {
955  ret = RTC::RTC_ERROR;
956  }
957  postOnAborting(ec_id, ret);
958  return ret;
959  }
960 
969  throw (CORBA::SystemException)
970  {
971  RTC_TRACE(("on_error(%d)", ec_id));
973  try
974  {
975  preOnError(ec_id);
976  ret = onError(ec_id);
977  }
978  catch (...)
979  {
980  ret = RTC::RTC_ERROR;
981  }
983  postOnError(ec_id, ret);
984  return ret;
985  }
986 
995  throw (CORBA::SystemException)
996  {
997  RTC_TRACE(("on_reset(%d)", ec_id));
999  try
1000  {
1001  preOnReset(ec_id);
1002  ret = onReset(ec_id);
1003  }
1004  catch (...)
1005  {
1006  ret = RTC::RTC_ERROR;
1007  }
1008  postOnReset(ec_id, ret);
1009  return ret;
1010  }
1011 
1021  throw (CORBA::SystemException)
1022  {
1023  RTC_PARANOID(("on_execute(%d)", ec_id));
1025  try
1026  {
1028  if (m_readAll) {readAll(); }
1029  ret = onExecute(ec_id);
1030  if (m_writeAll) { writeAll();}
1031  }
1032  catch (...)
1033  {
1034  ret = RTC::RTC_ERROR;
1035  }
1036  postOnExecute(ec_id, ret);
1037  return ret;
1038  }
1039 
1049  throw (CORBA::SystemException)
1050  {
1051  RTC_PARANOID(("on_state_update(%d)", ec_id));
1053  try
1054  {
1056  ret = onStateUpdate(ec_id);
1057  m_configsets.update();
1058  }
1059  catch (...)
1060  {
1061  ret = RTC::RTC_ERROR;
1062  }
1063  postOnStateUpdate(ec_id, ret);
1064  return ret;
1065  }
1066 
1075  throw (CORBA::SystemException)
1076  {
1077  RTC_TRACE(("on_rate_changed(%d)", ec_id));
1079  try
1080  {
1082  ret = onRateChanged(ec_id);
1083  }
1084  catch (...)
1085  {
1086  ret = RTC::RTC_ERROR;
1087  }
1088  postOnRateChanged(ec_id, ret);
1089  return ret;
1090  }
1091 
1092  //============================================================
1093  // SDO interfaces
1094  //============================================================
1102  SDOPackage::OrganizationList* RTObject_impl::get_owned_organizations()
1103  throw (CORBA::SystemException,
1104  SDOPackage::NotAvailable, SDOPackage::InternalError)
1105  {
1106  RTC_TRACE(("get_owned_organizations()"));
1107  try
1108  {
1109  SDOPackage::OrganizationList_var org_list;
1110  org_list = new SDOPackage::OrganizationList(m_sdoOwnedOrganizations);
1111  return org_list._retn();
1112  }
1113  catch (...)
1114  {
1115  throw SDOPackage::NotAvailable();
1116  }
1117  return new SDOPackage::OrganizationList();
1118  }
1119 
1120  // SDOPackage::SDO
1129  throw (CORBA::SystemException,
1130  SDOPackage::NotAvailable, SDOPackage::InternalError)
1131  {
1132  RTC_TRACE(("get_sdo_id()"));
1133  try
1134  {
1135  CORBA::String_var sdo_id;
1136  sdo_id = CORBA::string_dup(m_profile.instance_name);
1137  return sdo_id._retn();
1138  }
1139  catch (...)
1140  {
1141  throw SDOPackage::InternalError("get_sdo_id()");
1142  }
1143  }
1144 
1153  throw (CORBA::SystemException,
1154  SDOPackage::NotAvailable, SDOPackage::InternalError)
1155  {
1156  RTC_TRACE(("get_sdo_type()"));
1157  CORBA::String_var sdo_type;
1158  try
1159  {
1160  sdo_type = CORBA::string_dup(m_profile.description);
1161  return sdo_type._retn();
1162  }
1163  catch (...)
1164  {
1165  throw SDOPackage::InternalError("get_sdo_type()");
1166  }
1167  sdo_type = "";
1168  return sdo_type._retn();
1169  }
1170 
1178  SDOPackage::DeviceProfile* RTObject_impl::get_device_profile()
1179  throw (CORBA::SystemException,
1180  SDOPackage::NotAvailable, SDOPackage::InternalError)
1181  {
1182  RTC_TRACE(("get_device_profile()"));
1183  try
1184  {
1185  SDOPackage::DeviceProfile_var dprofile;
1186  dprofile =
1187  new SDOPackage::DeviceProfile(m_pSdoConfigImpl->getDeviceProfile());
1188  return dprofile._retn();
1189  }
1190  catch (...)
1191  {
1192  throw SDOPackage::InternalError("get_device_profile()");
1193  }
1194  return new SDOPackage::DeviceProfile();
1195  }
1196 
1197  //------------------------------------------------------------
1198  // SDO service
1199  //------------------------------------------------------------
1207  SDOPackage::ServiceProfileList* RTObject_impl::get_service_profiles()
1208  throw (CORBA::SystemException,
1209  SDOPackage::NotAvailable, SDOPackage::InternalError)
1210  {
1211  RTC_TRACE(("get_service_profiles()"));
1212 
1213  SDOPackage::ServiceProfileList_var sprofiles;
1214  try
1215  {
1217  RTC_DEBUG(("SDO ServiceProfiles[%d]", sprofiles->length()));
1218  }
1219  catch (...)
1220  {
1221  RTC_ERROR(("Unknown exception cought in get_service_profiles()."));
1222  throw SDOPackage::InternalError("get_service_profiles()");
1223  }
1224  return sprofiles._retn();
1225  }
1226 
1234  SDOPackage::ServiceProfile*
1236  throw (CORBA::SystemException,
1237  SDOPackage::InvalidParameter, SDOPackage::NotAvailable,
1238  SDOPackage::InternalError)
1239  {
1240  if (!id)
1241  {
1242  throw SDOPackage::
1243  InvalidParameter("get_service_profile(): Empty name.");
1244  }
1245  RTC_TRACE(("get_service_profile(%s))", id));
1246 
1247  SDOPackage::ServiceProfile_var prof;
1248  try
1249  {
1251  }
1252  catch (SDOPackage::InvalidParameter &e)
1253  {
1254  RTC_ERROR(("InvalidParameter exception: name (%s) is not found", id));
1255  throw e;
1256  }
1257  catch (...)
1258  {
1259  RTC_ERROR(("Unknown exception cought in get_service_profile(%s).", id));
1260  throw SDOPackage::InternalError("get_service_profile()");
1261  }
1262  return prof._retn();
1263  }
1264 
1272  SDOPackage::SDOService_ptr RTObject_impl::get_sdo_service(const char* id)
1273  throw (CORBA::SystemException,
1274  SDOPackage::InvalidParameter, SDOPackage::NotAvailable,
1275  SDOPackage::InternalError)
1276  {
1277  RTC_TRACE(("get_sdo_service(%s))", id));
1278  if (!id)
1279  {
1280  throw SDOPackage::InvalidParameter("get_service(): Empty name.");
1281  }
1282 
1283  SDOPackage::SDOService_var sdo;
1284  try
1285  {
1286  sdo = m_sdoservice.getServiceProvider(id);
1287  }
1288  catch (SDOPackage::InvalidParameter &e)
1289  {
1290  throw e;
1291  }
1292  catch (...)
1293  {
1294  throw SDOPackage::InternalError("get_service()");
1295  }
1296  return sdo;
1297  }
1298 
1306  SDOPackage::Configuration_ptr RTObject_impl::get_configuration()
1307  throw (CORBA::SystemException,
1308  SDOPackage::InterfaceNotImplemented, SDOPackage::NotAvailable,
1309  SDOPackage::InternalError)
1310  {
1311  RTC_TRACE(("get_configuration()"));
1312  if (m_pSdoConfig == NULL)
1313  throw SDOPackage::InterfaceNotImplemented();
1314  try
1315  {
1316 #ifdef ORB_IS_RTORB
1317  SDOPackage::Configuration_ptr config;
1318  config = m_pSdoConfig;
1319  return config;
1320 #else // ORB_IS_RTORB
1321  SDOPackage::Configuration_var config;
1322  config = m_pSdoConfig;
1323  return config._retn();
1324 #endif // ORB_IS_RTORB
1325  }
1326  catch (...)
1327  {
1328  SDOPackage::InternalError("get_configuration()");
1329  }
1330  return SDOPackage::Configuration::_nil();
1331  }
1332 
1340  SDOPackage::Monitoring_ptr RTObject_impl::get_monitoring()
1341  throw (CORBA::SystemException,
1342  SDOPackage::InterfaceNotImplemented, SDOPackage::NotAvailable,
1343  SDOPackage::InternalError)
1344  {
1345  RTC_TRACE(("get_monitoring()"));
1346  throw SDOPackage::InterfaceNotImplemented();
1347  return SDOPackage::Monitoring::_nil();
1348  }
1349 
1357  SDOPackage::OrganizationList* RTObject_impl::get_organizations()
1358  throw (CORBA::SystemException,
1359  SDOPackage::NotAvailable, SDOPackage::InternalError)
1360  {
1361  RTC_TRACE(("get_organizations()"));
1363  try
1364  {
1365  SDOPackage::OrganizationList_var org;
1366  org = new SDOPackage::OrganizationList(m_sdoOrganizations);
1367  return org._retn();
1368  }
1369  catch (...)
1370  {
1371  throw SDOPackage::InternalError("get_organizations()");
1372  }
1373  return new SDOPackage::OrganizationList(0);
1374  }
1375 
1384  throw (CORBA::SystemException,
1385  SDOPackage::NotAvailable, SDOPackage::InternalError)
1386  {
1387  RTC_TRACE(("get_status_list()"));
1388  try
1389  {
1390  NVList_var status;
1391  status = new NVList(m_sdoStatus);
1392  return status._retn();
1393  }
1394  catch (...)
1395  {
1396  SDOPackage::InternalError("get_status_list()");
1397  }
1398  return new SDOPackage::NVList(0);
1399  }
1400 
1408  CORBA::Any* RTObject_impl::get_status(const char* name)
1409  throw (CORBA::SystemException,
1410  SDOPackage::InvalidParameter, SDOPackage::NotAvailable,
1411  SDOPackage::InternalError)
1412  {
1413  RTC_TRACE(("get_status(%s)", name));
1414  CORBA::Long index;
1415  index = CORBA_SeqUtil::find(m_sdoStatus, nv_name(name));
1416  if (index < 0)
1417  throw SDOPackage::InvalidParameter("get_status(): Not found");
1418  try
1419  {
1420  CORBA::Any_var status;
1421  status = new CORBA::Any(m_sdoStatus[index].value);
1422  return status._retn();
1423  }
1424  catch (...)
1425  {
1426  throw SDOPackage::InternalError("get_status()");
1427  }
1428  return new CORBA::Any();
1429  }
1430 
1431  //============================================================
1432  // Local methods
1433  //============================================================
1441  void RTObject_impl::setInstanceName(const char* instance_name)
1442  {
1443  rtclog.setName(instance_name);
1444  RTC_TRACE(("setInstanceName(%s)", instance_name));
1445 
1446  m_properties["instance_name"] = instance_name;
1447 #ifndef ORB_IS_RTORB
1448  m_profile.instance_name = m_properties["instance_name"].c_str();
1449 #else // ORB_IS_RTORB
1450  m_profile.instance_name = (char *)m_properties["instance_name"].c_str();
1451 #endif // ORB_IS_RTORB
1452  }
1453 
1461  std::vector<std::string> RTObject_impl::getNamingNames()
1462  {
1463  RTC_TRACE(("getNamingNames()"));
1464  return coil::split(m_properties["naming.names"], ",");
1465  }
1466 
1474  void RTObject_impl::setObjRef(const RTObject_ptr rtobj)
1475  {
1476  RTC_TRACE(("setObjRef()"));
1477  m_objref = RTC::RTObject::_duplicate(rtobj);
1478  }
1479 
1487  RTObject_ptr RTObject_impl::getObjRef() const
1488  {
1489  RTC_TRACE(("getObjRef()"));
1490 
1491  return m_objref;
1492  }
1493 
1502  {
1503  RTC_TRACE(("setProperties()"));
1504  m_properties << prop;
1505 #ifndef ORB_IS_RTORB
1506  m_profile.instance_name = m_properties["instance_name"].c_str();
1507  m_profile.type_name = m_properties["type_name"].c_str();
1508  m_profile.description = m_properties["description"].c_str();
1509  m_profile.version = m_properties["version"].c_str();
1510  m_profile.vendor = m_properties["vendor"].c_str();
1511  m_profile.category = m_properties["category"].c_str();
1512 #else // ORB_IS_RTORB
1513  m_profile.instance_name = (char*)m_properties["instance_name"].c_str();
1514  m_profile.type_name = (char*)m_properties["type_name"].c_str();
1515  m_profile.description = (char*)m_properties["description"].c_str();
1516  m_profile.version = (char*)m_properties["version"].c_str();
1517  m_profile.vendor = (char*)m_properties["vendor"].c_str();
1518  m_profile.category = (char*)m_properties["category"].c_str();
1519 #endif //ORB_IS_RTORB
1520  }
1521 
1530  {
1531  RTC_TRACE(("getProperties()"));
1532  return m_properties;
1533  }
1534 
1542  void RTObject_impl::updateParameters(const char* config_set)
1543  {
1544  RTC_TRACE(("updateParameters(%s)", config_set));
1545  m_configsets.update(config_set);
1546  return;
1547  }
1548 
1557  {
1558  RTC_TRACE(("registerPort(PortBase&)"));
1559  if (!addPort(port))
1560  RTC_ERROR(("addPort(PortBase&) failed."));
1561  }
1563  {
1564  RTC_TRACE(("addPort(PortBase&)"));
1565  port.setOwner(this->getObjRef());
1567  onAddPort(port.getPortProfile());
1568  return m_portAdmin.addPort(port);
1569  }
1570 
1571  void RTObject_impl::registerPort(PortService_ptr port)
1572  {
1573  RTC_TRACE(("registerPort(PortBase&)"));
1574  if (!addPort(port))
1575  RTC_ERROR(("addPort(PortBase&) failed."));
1576  }
1577  bool RTObject_impl::addPort(PortService_ptr port)
1578  {
1579  RTC_TRACE(("addPort(PortService_ptr)"));
1580  return m_portAdmin.addPort(port);
1581  }
1582 
1584  {
1585  RTC_TRACE(("registerPort(CorbaPort&)"));
1586  if (!addPort(port))
1587  RTC_ERROR(("addPort(CorbaPort&) failed."));
1588  }
1589 
1591  {
1592  RTC_TRACE(("addPort(CrobaPort)"));
1593  std::string propkey("port.corbaport.");
1594  m_properties.getNode(propkey)
1595  << m_properties.getNode("port.corba");
1596 
1597  port.init(m_properties.getNode(propkey));
1598  return addPort((PortBase&)port);
1599  }
1600 
1608  bool RTObject_impl::addInPort(const char* name,
1609  InPortBase& inport)
1610  {
1611  RTC_TRACE(("addInPort(%s)", name));
1612 
1613  std::string propkey("port.inport.");
1614  propkey += name;
1615  m_properties.getNode(propkey)
1616  << m_properties.getNode("port.inport.dataport");
1617 
1618  bool ret(addPort(inport));
1619 
1620  if (!ret)
1621  {
1622  RTC_ERROR(("addInPort() failed."));
1623  return ret;
1624  }
1625 
1626  inport.init(m_properties.getNode(propkey));
1627  m_inports.push_back(&inport);
1628  return ret;
1629  }
1630 
1631  void RTObject_impl::registerInPort(const char* name,
1632  InPortBase& inport)
1633  {
1634  RTC_TRACE(("registerInPort(%s)", name));
1635 
1636  if (!addInPort(name, inport))
1637  {
1638  RTC_ERROR(("addInPort(%s) failed.", name));
1639  }
1640  }
1641 
1649  bool RTObject_impl::addOutPort(const char* name,
1651  {
1652  RTC_TRACE(("addOutPort(%s)", name));
1653 
1654  std::string propkey("port.outport.");
1655  propkey += name;
1656  m_properties.getNode(propkey)
1657  << m_properties.getNode("port.outport.dataport");
1658 
1659  bool ret(addPort(outport));
1660 
1661  if (!ret)
1662  {
1663  RTC_ERROR(("addOutPort() failed."));
1664  return ret;
1665  }
1666 
1667  outport.init(m_properties.getNode(propkey));
1668  m_outports.push_back(&outport);
1669  return ret;
1670  }
1671 
1672  void RTObject_impl::registerOutPort(const char* name,
1674  {
1675  RTC_TRACE(("registerOutPort(%s)", name));
1676 
1677  if (!addOutPort(name, outport))
1678  {
1679  RTC_ERROR(("addOutPort(%s) failed.", name));
1680  }
1681  }
1682 
1691  {
1692  RTC_TRACE(("removeInPort()"));
1693  bool ret(removePort(inport));
1694 
1695  std::vector<InPortBase*>::iterator it = m_inports.begin();
1696 
1697  if (ret)
1698  {
1699  while (it != m_inports.end())
1700  {
1701  if ( (*it) == &inport )
1702  {
1703  m_inports.erase(it);
1704  return true;
1705  }
1706  ++it;
1707  }
1708  }
1709 
1710  return false;
1711  }
1712 
1721  {
1722  RTC_TRACE(("removeOutPort()"));
1723 
1724  bool ret(removePort(outport));
1725 
1726  if (ret)
1727  {
1728  std::vector<OutPortBase*>::iterator it = m_outports.begin();
1729  while (it != m_outports.end())
1730  {
1731  if ( (*it) == &outport )
1732  {
1733  m_outports.erase(it);
1734  return true;
1735  }
1736  ++it;
1737  }
1738  }
1739 
1740  return false;
1741  }
1742 
1751  {
1752  RTC_TRACE(("removePort(PortBase&)"));
1753  onRemovePort(port.getPortProfile());
1754  return m_portAdmin.removePort(port);
1755  }
1756  bool RTObject_impl::removePort(PortService_ptr port)
1757  {
1758  RTC_TRACE(("removePort(PortService_pt)"));
1759  return m_portAdmin.removePort(port);
1760  }
1762  {
1763  RTC_TRACE(("removePort(PortBase&)"));
1764  onRemovePort(port.getPortProfile());
1765  return m_portAdmin.removePort((PortBase&)port);
1766  }
1767 
1769  {
1770  RTC_TRACE(("deletePort(PortBase&)"));
1771  if (!removePort(port))
1772  RTC_ERROR(("removePort(PortBase&) failed."));
1773  return;
1774  }
1775  void RTObject_impl::deletePort(PortService_ptr port)
1776  {
1777  RTC_TRACE(("deletePort(PortService_pt)"));
1778  if (!removePort(port))
1779  RTC_ERROR(("removePort(PortService_pt) failed."));
1780  return;
1781  }
1783  {
1784  RTC_TRACE(("deletePort(CorbaPort)"));
1785  if (!removePort(port))
1786  RTC_ERROR(("removePort(CorbaPort) failed."));
1787  return;
1788  }
1789 
1797  void RTObject_impl::deletePortByName(const char* port_name)
1798  {
1799  RTC_TRACE(("deletePortByName(%s)", port_name));
1800  m_portAdmin.deletePortByName(port_name);
1801  return;
1802  }
1803 
1811  ExecutionContext_ptr
1813  {
1814  return get_context(ec_id);
1815  }
1816 
1825  {
1826  ExecutionContext_var ec(getExecutionContext(ec_id));
1827  if (CORBA::is_nil(ec))
1828  {
1829  return 0.0;
1830  }
1831  return ec->get_rate();
1832  }
1833 
1841  ReturnCode_t
1843  {
1844  ExecutionContext_var ec(getExecutionContext(ec_id));
1845  if (CORBA::is_nil(ec))
1846  {
1847  return RTC::RTC_ERROR;
1848  }
1849  ec->set_rate(rate);
1850  return RTC::RTC_OK;
1851  }
1852 
1861  {
1862  if (ec_id < ECOTHER_OFFSET)
1863  {
1864  return true;
1865  }
1866  return false;
1867  }
1868 
1877  {
1878  ExecutionContext_var ec(getExecutionContext(ec_id));
1879  if (CORBA::is_nil(ec))
1880  {
1881  return RTC::RTC_ERROR;
1882  }
1883  return ec->deactivate_component(::RTC::RTObject::_duplicate(getObjRef()));
1884  }
1885 
1894  {
1895  ExecutionContext_var ec(getExecutionContext(ec_id));
1896  if (CORBA::is_nil(ec))
1897  {
1898  return RTC::RTC_ERROR;
1899  }
1900  return ec->activate_component(::RTC::RTObject::_duplicate(getObjRef()));
1901  }
1902 
1911  {
1912  ExecutionContext_var ec(getExecutionContext(ec_id));
1913  if (CORBA::is_nil(ec))
1914  {
1915  return RTC::RTC_ERROR;
1916  }
1917  return ec->reset_component(::RTC::RTObject::_duplicate(getObjRef()));
1918  }
1919 
1927  bool RTObject_impl::
1928  addSdoServiceProvider(const SDOPackage::ServiceProfile& prof,
1930  {
1931  return m_sdoservice.addSdoServiceProvider(prof, provider);
1932  }
1933 
1942  {
1944  }
1945 
1953  bool RTObject_impl::
1954  addSdoServiceConsumer(const SDOPackage::ServiceProfile& prof)
1955  {
1956  return m_sdoservice.addSdoServiceConsumer(prof);
1957  }
1958 
1967  {
1969  }
1970 
1981  {
1982  RTC_TRACE(("readAll()"));
1983  std::vector<InPortBase*>::iterator it = m_inports.begin();
1984  std::vector<InPortBase*>::iterator it_end = m_inports.end();
1985  bool ret(true);
1986 
1987  while( it != it_end )
1988  {
1989 
1990  if (!((*it)->read()))
1991  {
1992  RTC_DEBUG(("The error occurred in readAll()."));
1993  ret = false;
1994  if (!m_readAllCompletion)
1995  return false;
1996  }
1997  ++it;
1998  }
1999 
2000  return ret;
2001  }
2002 
2013  {
2014  RTC_TRACE(("writeAll()"));
2015  std::vector<OutPortBase*>::iterator it = m_outports.begin();
2016  std::vector<OutPortBase*>::iterator it_end = m_outports.end();
2017 
2018  bool ret(true);
2019 
2020  while( it != it_end )
2021  {
2022  if (!((*it)->write()))
2023  {
2024  RTC_DEBUG(("The error occurred in writeAll()."));
2025  ret = false;
2026  if (!m_writeAllCompletion)
2027  return false;
2028  }
2029  ++it;
2030  }
2031  return ret;
2032  }
2033 
2058  void RTObject_impl::setReadAll(bool read, bool completion)
2059  {
2060  m_readAll = read;
2061  m_readAllCompletion = completion;
2062  }
2063 
2088  void RTObject_impl::setWriteAll(bool write, bool completion)
2089  {
2090  m_writeAll = write;
2091  m_writeAllCompletion = completion;
2092  }
2093 
2102  {
2103  RTC_TRACE(("finalizePorts()"));
2105  m_inports.clear();
2106  m_outports.clear();
2107  }
2108 
2110  {
2111  RTC_TRACE(("finalizeContexts()"));
2112  for (int i(0), len(m_eclist.size()); i < len; ++i)
2113  {
2114  m_eclist[i]->stop();
2115  try
2116  {
2117  PortableServer::ObjectId_var oid
2118  = m_pPOA->servant_to_id(m_eclist[i]);
2119  m_pPOA->deactivate_object(oid);
2120  }
2121  catch (PortableServer::POA::ServantNotActive &e)
2122  {
2123  RTC_ERROR(("%s", e._name()));
2124  }
2125  catch (PortableServer::POA::WrongPolicy &e)
2126  {
2127  RTC_ERROR(("%s", e._name()));
2128  }
2129  catch (...)
2130  {
2131  // never throws exception
2132  RTC_ERROR(("Unknown exception caught."));
2133  }
2134  delete m_eclist[i];
2135  }
2136  if (!m_eclist.empty())
2137  {
2138  m_eclist.clear();
2139  }
2140  }
2141 
2151  void RTObject_impl::
2153  PreComponentActionListener* listener,
2154  bool autoclean)
2155  {
2157  preaction_[listener_type].addListener(listener, autoclean);
2158  }
2159 
2160 
2170  void RTObject_impl::
2172  PreComponentActionListenerType listener_type,
2173  PreComponentActionListener* listener)
2174  {
2176  preaction_[listener_type].removeListener(listener);
2177  }
2178 
2179 
2189  void RTObject_impl::
2191  PostComponentActionListenerType listener_type,
2192  PostComponentActionListener* listener,
2193  bool autoclean)
2194  {
2196  postaction_[listener_type].addListener(listener, autoclean);
2197  }
2198 
2199 
2209  void RTObject_impl::
2211  PostComponentActionListenerType listener_type,
2212  PostComponentActionListener* listener)
2213  {
2215  postaction_[listener_type].removeListener(listener);
2216  }
2217 
2227  void RTObject_impl::
2229  PortActionListener* listener,
2230  bool autoclean)
2231  {
2233  portaction_[listener_type].addListener(listener, autoclean);
2234  }
2235 
2236 
2246  void RTObject_impl::
2248  PortActionListener* listener)
2249  {
2251  portaction_[listener_type].removeListener(listener);
2252  }
2253 
2254 
2264  void RTObject_impl::
2266  ECActionListener* listener,
2267  bool autoclean)
2268  {
2270  ecaction_[listener_type].addListener(listener, autoclean);
2271  }
2272 
2273 
2283  void RTObject_impl::
2285  ECActionListener* listener)
2286  {
2288  ecaction_[listener_type].removeListener(listener);
2289  }
2290 
2298  void RTObject_impl::
2300  PortConnectListener* listener,
2301  bool autoclean)
2302  {
2304  portconnect_[listener_type].addListener(listener, autoclean);
2305  }
2306 
2314  void RTObject_impl::
2316  PortConnectListener* listener)
2317  {
2319  portconnect_[listener_type].removeListener(listener);
2320  }
2321 
2329  void RTObject_impl::
2331  PortConnectRetListener* listener,
2332  bool autoclean)
2333  {
2335  portconnret_[listener_type].addListener(listener, autoclean);
2336  }
2337 
2345  void RTObject_impl::
2347  PortConnectRetListener* listener)
2348  {
2350  portconnret_[listener_type].removeListener(listener);
2351  }
2352 
2360  void RTObject_impl::
2362  ConfigurationParamListener* listener,
2363  bool autoclean)
2364  {
2365  m_configsets.addConfigurationParamListener(type, listener, autoclean);
2366  }
2367 
2375  void RTObject_impl::
2377  ConfigurationParamListener* listener)
2378  {
2380  }
2381 
2389  void RTObject_impl::
2391  ConfigurationSetListener* listener,
2392  bool autoclean)
2393  {
2394  m_configsets.addConfigurationSetListener(type, listener, autoclean);
2395  }
2396 
2404  void RTObject_impl::
2406  ConfigurationSetListener* listener)
2407  {
2409  }
2410 
2418  void RTObject_impl::
2420  ConfigurationSetNameListener* listener,
2421  bool autoclean)
2422  {
2423  m_configsets.addConfigurationSetNameListener(type, listener, autoclean);
2424  }
2425 
2433  void RTObject_impl::
2435  ConfigurationSetNameListener* listener)
2436  {
2438  }
2439 
2440 
2449  {
2450  RTC_TRACE(("shutdown()"));
2451  try
2452  {
2453  finalizePorts();
2454  finalizeContexts();
2455  PortableServer::ObjectId_var oid1;
2456  oid1 = m_pPOA->servant_to_id(m_pSdoConfigImpl);
2457  PortableServer::ObjectId_var oid2;
2458  oid2 = m_pPOA->servant_to_id(this);
2459  m_pPOA->deactivate_object(oid1);
2460  m_pPOA->deactivate_object(oid2);
2461  }
2462  catch (PortableServer::POA::ServantNotActive &e)
2463  {
2464  RTC_ERROR(("%s", e._name()));
2465  }
2466  catch (PortableServer::POA::WrongPolicy &e)
2467  {
2468  RTC_ERROR(("%s", e._name()));
2469  }
2470  catch (...)
2471  {
2472  // never throws exception
2473  RTC_ERROR(("Unknown exception caught."));
2474  }
2475 
2476  if (m_pManager != NULL)
2477  {
2478  RTC_DEBUG(("Cleanup on Manager"));
2479  m_pManager->notifyFinalized(this);
2480  }
2481  }
2482 
2483 
2484 
2485 }
ComponentProfile m_profile
ComponentProfile.
Definition: RTObject.h:4588
virtual ReturnCode_t onRateChanged(RTC::UniqueId exec_handle)
Callback function to change execution cycle.
Definition: RTObject.cpp:298
PortAdmin m_portAdmin
List of Port Object reference.
Definition: RTObject.h:4606
PortConnectListenerType
The types of ConnectorDataListener.
Logger rtclog
Logger stream.
Definition: RTObject.h:4485
virtual ReturnCode_t on_shutdown(UniqueId exec_handle)
[ComponentAction CORBA interface] Shutdown RTC
Definition: RTObject.cpp:865
void onAddPort(const PortProfile &pprof)
Definition: RTObject.h:4457
void postOnStateUpdate(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4447
#define RTC_ERROR(fmt)
Error log output macro.
Definition: SystemLogger.h:422
void removeConfigurationSetNameListener(ConfigurationSetNameListenerType type, ConfigurationSetNameListener *listener)
Removing ConfigurationSetNameListener.
void postOnReset(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4437
void preOnAborting(UniqueId ec_id)
Definition: RTObject.h:4367
virtual SDOPackage::ServiceProfileList * get_service_profiles()
[SDO interface] Get SDO ServiceProfile
Definition: RTObject.cpp:1207
void finalizeContexts()
The ExecutionContextBase list is deleted.
Definition: RTObject.cpp:2109
std::vector< InPortBase * > m_inports
List of InPortBase*.
Definition: RTObject.h:4615
virtual ComponentProfile * get_component_profile()
[RTObject CORBA interface] Get RTC&#39;s profile
Definition: RTObject.cpp:702
void onRemovePort(const PortProfile &pprof)
Definition: RTObject.h:4462
EXECUTION_HANDLE_TYPE_NATIVE ExecutionContextHandle_t
Definition: IRTC.h:63
virtual ExecutionContextHandle_t get_context_handle(ExecutionContext_ptr cxt)
[CORBA interface] Return a handle of a ExecutionContext
Definition: RTObject.cpp:561
PortConnectRetListener class.
virtual char * get_sdo_id()
[SDO interface] Get the SDO ID
Definition: RTObject.cpp:1128
RT-Component.
PostComponentActionListenerType
The types of ConnectorDataListener.
virtual ReturnCode_t onExecute(RTC::UniqueId exec_handle)
Callback function to execute periodically.
Definition: RTObject.cpp:223
virtual SDOPackage::Monitoring_ptr get_monitoring()
[SDO interface] Get Monitoring object
Definition: RTObject.cpp:1340
ExecutionContextServiceList m_ecOther
List of participating ExecutionContextService.
Definition: RTObject.h:4651
virtual ReturnCode_t onStateUpdate(RTC::UniqueId exec_handle)
Callback function to update the state.
Definition: RTObject.cpp:283
void finalizePorts()
Deactivate all Ports and unregister them.
Definition: PortAdmin.cpp:368
virtual ReturnCode_t initialize()
[CORBA interface] Initialize the RTC that realizes this interface.
Definition: RTObject.cpp:314
void addConfigurationSetNameListener(ConfigurationSetNameListenerType type, ConfigurationSetNameListener *listener, bool autoclean=true)
Adding ConfigurationSetNameListener.
void clear(CorbaSequence &seq)
Erase all the elements of the CORBA sequence.
bool m_readAllCompletion
flag for readAll()
Definition: RTObject.h:4741
SDOPackage::Configuration_impl * m_pSdoConfigImpl
The pointer to the SDO Configuration Object.
Definition: RTObject.h:4549
virtual ReturnCode_t on_activated(UniqueId exec_handle)
[ComponentAction CORBA interface] Activate RTC
Definition: RTObject.cpp:890
void preOnShutdown(UniqueId ec_id)
Definition: RTObject.h:4352
virtual ReturnCode_t on_startup(UniqueId exec_handle)
[ComponentAction CORBA interface] Startup RTC
Definition: RTObject.cpp:840
UniqueId bindContext(ExecutionContext_ptr exec_context)
Definition: RTObject.cpp:624
ReturnCode_t detach_context(UniqueId exec_handle)
[CORBA interface] Detach ExecutionContext.
Definition: RTObject.cpp:664
void updateParameters(const char *config_set)
Update configuration parameters (by ID)
Definition: RTObject.cpp:1542
virtual SDOPackage::OrganizationList * get_owned_organizations()
[SDO interface] Get Organization list
Definition: RTObject.cpp:1102
SDOPackage::OrganizationList m_sdoOrganizations
SDO organization.
Definition: RTObject.h:4567
void onAttachExecutionContext(UniqueId ec_id)
Definition: RTObject.h:4467
ReturnCode_t
Definition: doil.h:53
void addPortConnectRetListener(PortConnectRetListenerType listener_type, PortConnectRetListener *listener, bool autoclean=true)
Adding PortConnectRet type listener.
Definition: RTObject.cpp:2330
void removeConfigurationSetListener(ConfigurationSetListenerType type, ConfigurationSetListener *listener)
Removing ConfigurationSetListener.
Definition: RTObject.cpp:2405
std::vector< std::pair< std::string, std::string > > NVList
Definition: IRTC.h:67
void addConfigurationSetListener(ConfigurationSetListenerType type, ConfigurationSetListener *listener, bool autoclean=true)
Adding ConfigurationSetListener.
Definition: RTObject.cpp:2390
bool isOwnExecutionContext(RTC::UniqueId ec_id)
[local interface] Checking if the current context is own context
Definition: RTObject.cpp:1860
CORBA::ORB_var m_pORB
The pointer to the ORB.
Definition: RTObject.h:4502
PortActionListenerType
The types of PortActionListener.
void postOnExecute(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4442
void removeConfigurationParamListener(ConfigurationParamListenerType type, ConfigurationParamListener *listener)
Removing ConfigurationParamListener.
Definition: RTObject.cpp:2376
void removePortConnectRetListener(PortConnectRetListenerType listener_type, PortConnectRetListener *listener)
Removing PortConnectRet type listener.
Definition: RTObject.cpp:2346
void removePortConnectListener(PortConnectListenerType listener_type, PortConnectListener *listener)
Removing PortConnect type listener.
Definition: RTObject.cpp:2315
A base class for ExecutionContext.
bool removeInPort(InPortBase &port)
[local interface] Unregister InPort
Definition: RTObject.cpp:1690
ReturnCode_t reset(RTC::UniqueId ec_id)
[local interface] Resetting and go to Inactive state
Definition: RTObject.cpp:1910
RTC::ReturnCode_t ret(RTC::Local::ReturnCode_t r)
void init(coil::Properties &prop)
Initializing properties.
Definition: CorbaPort.cpp:60
bool m_exiting
RTC Finalize Status Flag.
Definition: RTObject.h:4669
std::vector< std::string > getNamingNames()
[local interface] Get Naming Server information
Definition: RTObject.cpp:1461
bool addSdoServiceProvider(const SDOPackage::ServiceProfile &prof, SdoServiceProviderBase *provider)
[local interface] Set a SDO service provider
Definition: RTObject.cpp:1928
SDOPackage::Configuration_var m_pSdoConfig
The pointer to the SDO Configuration Interface.
Definition: RTObject.h:4558
virtual ~RTObject_impl(void)
Virtual destructor.
Definition: RTObject.cpp:115
ConfigurationSetListener class.
ConfigurationSetNameListener class.
ComponentActionListeners m_actionListeners
ComponentActionListener holder.
Definition: RTObject.h:4774
void setOwner(RTObject_ptr owner)
Set the owner RTObject of the Port.
Definition: PortBase.cpp:559
vstring split(const std::string &input, const std::string &delimiter, bool ignore_empty)
Split string by delimiter.
Definition: stringutil.cpp:346
ConfigurationParamListener class.
void registerPort(PortBase &port)
[local interface] Register Port
Definition: RTObject.cpp:1556
Manager class.
Definition: Manager.h:80
virtual ExecutionContextList * get_participating_contexts()
[CORBA interface] Get participating ExecutionContextList.
Definition: RTObject.cpp:540
ConfigurationSetNameListenerType
The types of ConfigurationSetNameListener.
void addExecutionContextActionListener(ECActionListenerType listener_type, ECActionListener *listener, bool autoclean=true)
Adding ExecutionContextAction type listener.
Definition: RTObject.cpp:2265
PreComponentActionListenerType
The types of ConnectorDataListener.
void postOnShutdown(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4412
bool removeSdoServiceProvider(const char *id)
Remove a SDO service provider.
virtual PortServiceList * get_ports()
[RTObject CORBA interface] Get Ports
Definition: RTObject.cpp:752
bool removePort(PortBase &port)
[local interface] Unregister Port
Definition: RTObject.cpp:1750
double getExecutionRate(RTC::UniqueId ec_id)
[local interface] Getting current context&#39; execution rate
Definition: RTObject.cpp:1824
SDOPackage::SDOService_ptr getServiceProvider(const char *id)
Get ServiceProfile of an SDO Service.
void addConfigurationSetListener(ConfigurationSetListenerType type, ConfigurationSetListener *listener, bool autoclean=true)
Adding ConfigurationSetListener.
void setName(const char *name)
Set suffix of date/time string of header.
void postOnError(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4432
bool m_readAll
flag for readAll()
Definition: RTObject.h:4714
static const char * default_conf[]
RT-Component default profile.
Definition: RTObject.cpp:41
ReturnCode_t activate(RTC::UniqueId ec_id)
[local interface] Make transition to Active state
Definition: RTObject.cpp:1893
void removeConfigurationSetListener(ConfigurationSetListenerType type, ConfigurationSetListener *listener)
Removing ConfigurationSetListener.
Manager * m_pManager
Manager object.
Definition: RTObject.h:4493
coil::Properties & getProperties()
[local interface] Get RTC property
Definition: RTObject.cpp:1529
virtual SDOPackage::Configuration_ptr get_configuration()
[SDO interface] Get Configuration object
Definition: RTObject.cpp:1306
static Manager & instance()
Get instance of the manager.
Definition: Manager.cpp:140
UniqueId attach_context(ExecutionContext_ptr exec_context)
[CORBA interface] Attach ExecutionContext
Definition: RTObject.cpp:587
PortProfileList getPortProfileList() const
Get PorProfileList.
Definition: PortAdmin.cpp:122
virtual ReturnCode_t on_reset(UniqueId exec_handle)
[ComponentAction CORBA interface] Resetting RTC
Definition: RTObject.cpp:994
SdoServiceAdmin m_sdoservice
SDO Service Administrator Object.
Definition: RTObject.h:4705
void addConfigurationSetNameListener(ConfigurationSetNameListenerType type, ConfigurationSetNameListener *listener, bool autoclean=true)
Adding ConfigurationSetNameListener.
Definition: RTObject.cpp:2419
bool m_created
Created Status Flag.
Definition: RTObject.h:4660
SDOPackage::NVList m_sdoStatus
SDO Status.
Definition: RTObject.h:4576
string outport
Definition: README_gen.py:115
void preOnRateChanged(UniqueId ec_id)
Definition: RTObject.h:4392
PreComponentActionListener class.
PortableServer::POA_var m_pPOA
The pointer to the POA.
Definition: RTObject.h:4511
bool addOutPort(const char *name, OutPortBase &outport)
[local interface] Register DataOutPort
Definition: RTObject.cpp:1649
virtual ReturnCode_t on_finalize()
[ComponentAction CORBA interface] Finalize RTC
Definition: RTObject.cpp:815
virtual ReturnCode_t onDeactivated(RTC::UniqueId exec_handle)
Callback function to deactivate.
Definition: RTObject.cpp:208
SDO Package.
void activatePorts()
Activate all Port interfaces.
Definition: PortAdmin.cpp:334
void postOnAborting(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4427
RTComponent manager class.
virtual ReturnCode_t finalize()
[CORBA interface] Finalize the RTC for destruction
Definition: RTObject.cpp:361
#define RTC_PARANOID(fmt)
Paranoid level log output macro.
Definition: SystemLogger.h:555
Functor to copy ExecutionContext.
Definition: RTObject.h:4818
PortConnectListener class.
std::vector< ExecutionContext * > ExecutionContextList
Definition: IRTC.h:69
ReturnCode_t setExecutionRate(RTC::UniqueId ec_id, double rate)
[local interface] Setting current context&#39; execution rate
Definition: RTObject.cpp:1842
void preOnError(UniqueId ec_id)
Definition: RTObject.h:4372
SDOPackage::OrganizationList m_sdoOwnedOrganizations
SDO owned organization list.
Definition: RTObject.h:4523
PortServiceList * getPortServiceList() const
Get PortServiceList.
Definition: PortAdmin.cpp:108
string inport
Definition: README_gen.py:90
void setObjRef(const RTObject_ptr rtobj)
[local interface] Set the object reference
Definition: RTObject.cpp:1474
bool removeOutPort(OutPortBase &port)
[local interface] Unregister OutPort
Definition: RTObject.cpp:1720
void update(void)
Update the values of configuration parameters (Active configuration set)
Definition: ConfigAdmin.cpp:64
void onDetachExecutionContext(UniqueId ec_id)
Definition: RTObject.h:4472
ExecutionContextHandle_t UniqueId
void notifyFinalized(RTObject_impl *comp)
This method deletes RT-Components.
Definition: Manager.cpp:1669
#define RTC_DEBUG(fmt)
Debug level log output macro.
Definition: SystemLogger.h:488
const std::string & getProperty(const std::string &key) const
Search for the property with the specified key in this property.
Definition: Properties.cpp:160
virtual ReturnCode_t on_deactivated(UniqueId exec_handle)
[ComponentAction CORBA interface] Deactivate RTC
Definition: RTObject.cpp:917
void setPortConnectListenerHolder(PortConnectListeners *portconnListeners)
Setting PortConnectListener holder.
Definition: PortBase.cpp:610
void addPortConnectListener(PortConnectListenerType listener_type, PortConnectListener *listener, bool autoclean=true)
Adding PortConnect type listener.
Definition: RTObject.cpp:2299
Functor to find NVList.
Definition: RTObject.h:4801
bool removeSdoServiceProvider(const char *id)
[local interface] Remove a SDO service provider
Definition: RTObject.cpp:1941
#define RTC_TRACE(fmt)
std::vector< ExecutionContextBase * > m_eclist
List of ExecutionContextBase.
Definition: RTObject.h:4642
RTObject_impl(Manager *manager)
Constructor.
Definition: RTObject.cpp:64
CORBA::Long find(const CorbaSequence &seq, Functor f)
Return the index of CORBA sequence element that functor matches.
list index
Definition: rtimages.py:10
const OrganizationList getOrganizations()
Get a list of Organization of SDO.
void addConfigurationParamListener(ConfigurationParamListenerType type, ConfigurationParamListener *listener, bool autoclean=true)
Adding ConfigurationParamListener.
virtual ExecutionContext_ptr get_context(UniqueId exec_handle)
[CORBA interface] Get ExecutionContext.
Definition: RTObject.cpp:465
bool removeSdoServiceConsumer(const char *id)
[local interface] Remove a SDO service provider
Definition: RTObject.cpp:1966
ExecutionContextServiceList m_ecMine
List of owned ExecutionContextService.
Definition: RTObject.h:4633
CORBA sequence utility template functions.
bool m_writeAllCompletion
flag for writeAll()
Definition: RTObject.h:4759
ExecutionContextBase * createContext(const char *ec_args)
Create Context.
Definition: Manager.cpp:848
void removePortActionListener(PortActionListenerType listener_type, PortActionListener *listener)
Removing PortAction type listener.
Definition: RTObject.cpp:2247
void addConfigurationParamListener(ConfigurationParamListenerType type, ConfigurationParamListener *listener, bool autoclean=true)
Adding ConfigurationParamListener.
Definition: RTObject.cpp:2361
void init(coil::Properties &prop)
Initializing properties.
ConfigAdmin m_configsets
Configuration Administrator Object.
Definition: RTObject.h:4696
void preOnReset(UniqueId ec_id)
Definition: RTObject.h:4377
Functor to deactivate RTC.
Definition: RTObject.h:4876
virtual ReturnCode_t onAborting(RTC::UniqueId exec_handle)
Callback function to abort.
Definition: RTObject.cpp:238
virtual ReturnCode_t exit()
[CORBA interface]top the RTC&#39;s execution context(s) and finalize it along with its contents...
Definition: RTObject.cpp:398
#define ECOTHER_OFFSET
Definition: RTObject.h:38
bool addSdoServiceProvider(const SDOPackage::ServiceProfile &prof, SdoServiceProviderBase *provider)
Set a SDO service provider.
virtual SDOPackage::NVList * get_status_list()
[SDO interface] Get SDO Status list
Definition: RTObject.cpp:1383
void deletePort(PortBase &port)
[local interface] Unregister Port
Definition: RTObject.cpp:1768
void removePostComponentActionListener(PostComponentActionListenerType listener_type, PostComponentActionListener *listener)
Removing PostComponentAction type listener.
Definition: RTObject.cpp:2210
virtual SDOPackage::DeviceProfile * get_device_profile()
[SDO interface] Get SDO DeviceProfile list
Definition: RTObject.cpp:1178
virtual ReturnCode_t onReset(RTC::UniqueId exec_handle)
Callback function to reset.
Definition: RTObject.cpp:268
RTObject_ptr getObjRef() const
[local interface] Get the object reference
Definition: RTObject.cpp:1487
void removeConfigurationSetNameListener(ConfigurationSetNameListenerType type, ConfigurationSetNameListener *listener)
Removing ConfigurationSetNameListener.
Definition: RTObject.cpp:2434
prop
Organization::get_organization_property ();.
void postOnFinalize(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4402
PortConnectRetListenerType
The types of PortConnectRetListenerType.
void deactivatePorts()
Deactivate all Port interfaces.
Definition: PortAdmin.cpp:351
virtual ExecutionContextList * get_owned_contexts()
[CORBA interface] Get ExecutionContextList.
Definition: RTObject.cpp:503
void removePreComponentActionListener(PreComponentActionListenerType listener_type, PreComponentActionListener *listener)
Removing PreComponentAction type listener.
Definition: RTObject.cpp:2171
bool removePort(PortBase &port)
Unregister the Port registration.
Definition: PortAdmin.cpp:262
void removeExecutionContextActionListener(ECActionListenerType listener_type, ECActionListener *listener)
Removing ExecutionContextAction type listener.
Definition: RTObject.cpp:2284
void preOnStateUpdate(UniqueId ec_id)
Definition: RTObject.h:4387
Class represents a set of properties.
Definition: Properties.h:101
void postOnActivated(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4417
void shutdown()
Shutdown RTC.
Definition: RTObject.cpp:2448
void postOnInitialize(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4397
ExecutionContext_ptr getExecutionContext(RTC::UniqueId ec_id)
[local interface] Getting current execution context
Definition: RTObject.cpp:1812
std::vector< IPortService * > PortServiceList
Definition: IPortService.h:39
void registerInPort(const char *name, InPortBase &inport)
[local interface] Register DataInPort
Definition: RTObject.cpp:1631
virtual ReturnCode_t onError(RTC::UniqueId exec_handle)
Callback function for error handling.
Definition: RTObject.cpp:253
virtual ReturnCode_t on_error(UniqueId exec_handle)
[ComponentAction CORBA interface] Error Processing of RTC
Definition: RTObject.cpp:968
void setWriteAll(bool write=true, bool completion=false)
Set whether to execute the writeAll() method.
Definition: RTObject.cpp:2088
void deletePortByName(const char *port_name)
Unregister the Port&#39;s registration by its name.
Definition: PortAdmin.cpp:320
void preOnStartup(UniqueId ec_id)
Definition: RTObject.h:4347
bool addSdoServiceConsumer(const SDOPackage::ServiceProfile &sProfile)
Add Service Consumer.
SDOPackage::ServiceProfile * getServiceProviderProfile(const char *id)
Get ServiceProfile of an SDO Service Provider.
virtual ReturnCode_t on_initialize()
[RTObject CORBA interface] Get ExecutionContextAdmin
Definition: RTObject.cpp:779
void deletePortByName(const char *port_name)
[local interface] Delete Port by specifying its name
Definition: RTObject.cpp:1797
bool addPort(PortBase &port)
[local interface] Register Port
Definition: RTObject.cpp:1562
virtual ReturnCode_t onShutdown(RTC::UniqueId exec_handle)
Callback function for shutdown action.
Definition: RTObject.cpp:178
bool addPort(PortBase &port)
Regsiter the Port.
Definition: PortAdmin.cpp:191
virtual ReturnCode_t onActivated(RTC::UniqueId exec_handle)
Callback function to activate.
Definition: RTObject.cpp:193
virtual ReturnCode_t onInitialize()
Callback function to initialize.
Definition: RTObject.cpp:133
bool writeAll()
The write() method of all OutPort is called.
Definition: RTObject.cpp:2012
void push_back(CorbaSequence &seq, SequenceElement elem)
Push the new element back to the CORBA sequence.
virtual SDOPackage::SDOService_ptr get_sdo_service(const char *id)
[SDO interface] Get specified SDO Service&#39;s reference
Definition: RTObject.cpp:1272
void setInstanceName(const char *instance_name)
[local interface] Set instance name
Definition: RTObject.cpp:1441
void setReadAll(bool read=true, bool completion=false)
Set whether to execute the readAll() method.
Definition: RTObject.cpp:2058
PortConnectListeners m_portconnListeners
PortConnectListener holder.
Definition: RTObject.h:4789
Configuration implementation class.
void copyFromProperties(SDOPackage::NVList &nv, const coil::Properties &prop)
Copy the properties to NVList.
Definition: NVUtil.cpp:108
SDOPackage::ServiceProfileList * getServiceProviderProfiles()
Get ServiceProfileList of SDO Service Provider.
virtual ReturnCode_t on_aborting(UniqueId exec_handle)
[ComponentAction CORBA interface] Transition to Error State
Definition: RTObject.cpp:943
Properties & getNode(const std::string &key)
Get node of properties.
Definition: Properties.cpp:460
virtual SDOPackage::OrganizationList * get_organizations()
[SDO interface] Get Organization list
Definition: RTObject.cpp:1357
void finalizePorts()
Unregister All Ports.
Definition: RTObject.cpp:2101
void init(coil::Properties &prop)
Initializing properties.
Definition: InPortBase.cpp:96
void preOnActivated(UniqueId ec_id)
Definition: RTObject.h:4357
void postOnStartup(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4407
virtual ReturnCode_t on_state_update(UniqueId exec_handle)
[DataFlowComponentAction CORBA interface] Secondary Periodic Operation of RTC
Definition: RTObject.cpp:1048
virtual CORBA::Boolean is_alive(ExecutionContext_ptr exec_context)
[CORBA interface] Confirm whether RTC is the alive state
Definition: RTObject.cpp:437
coil::Properties m_properties
Alive Status Flag.
Definition: RTObject.h:4687
virtual RTC::ExecutionContextService_ptr getObjRef()=0
Get the reference of the object.
ExecutionContextActionListenerType
The types of ExecutionContextActionListener.
virtual ReturnCode_t onStartup(RTC::UniqueId exec_handle)
Callback function for startup action.
Definition: RTObject.cpp:163
void preOnInitialize(UniqueId ec_id)
Definition: RTObject.h:4337
bool addInPort(const char *name, InPortBase &inport)
[local interface] Register DataInPort
Definition: RTObject.cpp:1608
bool m_writeAll
flag for writeAll()
Definition: RTObject.h:4723
ConfigurationSetListenerType
The types of ConfigurationSetListener.
virtual ReturnCode_t on_execute(UniqueId exec_handle)
[DataFlowComponentAction CORBA interface] Primary Periodic Operation of RTC
Definition: RTObject.cpp:1020
RTObject_var m_objref
Object reference.
Definition: RTObject.h:4597
void addPreComponentActionListener(PreComponentActionListenerType listener_type, PreComponentActionListener *listener, bool autoclean=true)
Adding PreComponentAction type listener.
Definition: RTObject.cpp:2152
virtual char * get_sdo_type()
[SDO interface] Get SDO type
Definition: RTObject.cpp:1152
void removeConfigurationParamListener(ConfigurationParamListenerType type, ConfigurationParamListener *listener)
Removing ConfigurationParamListener.
Configuration_ptr getObjRef()
Get object reference.
void registerOutPort(const char *name, OutPortBase &outport)
[local interface] Register DataOutPort
Definition: RTObject.cpp:1672
PortActionListener class.
bool haveConfig(const char *config_id)
Check the existence of configuration set.
Definition: ConfigAdmin.h:822
bool addSdoServiceConsumer(const SDOPackage::ServiceProfile &prof)
[local interface] Set a SDO service provider
Definition: RTObject.cpp:1954
void addPostComponentActionListener(PostComponentActionListenerType listener_type, PostComponentActionListener *listener, bool autoclean=true)
Adding PostComponentAction type listener.
Definition: RTObject.cpp:2190
virtual RTC::ReturnCode_t bindComponent(RTObject_impl *rtc)=0
Bind the component.
std::vector< PortProfile * > PortProfileList
Definition: IPortService.h:63
bool readAll()
Readout the value from All InPorts.
Definition: RTObject.cpp:1980
std::vector< OutPortBase * > m_outports
List of OutPortBase*.
Definition: RTObject.h:4624
Functor to find ExecutionContext.
Definition: RTObject.h:4841
void setProperties(const coil::Properties &prop)
[local interface] Set RTC property
Definition: RTObject.cpp:1501
virtual CORBA::Any * get_status(const char *name)
[SDO interface] Get SDO Status
Definition: RTObject.cpp:1408
Functor for_each(CorbaSequence &seq, Functor f)
Apply the functor to all CORBA sequence elements.
Definition: CORBA_SeqUtil.h:98
PostComponentActionListener class.
const DeviceProfile getDeviceProfile()
Get the DeviceProfile of SDO.
RT component base class.
bool removeSdoServiceConsumer(const char *id)
Remove Service Consumer.
virtual SDOPackage::ServiceProfile * get_service_profile(const char *id)
[SDO interface] Get specified ServiceProfile
Definition: RTObject.cpp:1235
void postOnDeactivated(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4422
void preOnFinalize(UniqueId ec_id)
Definition: RTObject.h:4342
ConfigurationParamListenerType
The types of ConnectorDataListener.
ExecutionContextActionListener class.
virtual ReturnCode_t on_rate_changed(UniqueId exec_handle)
[DataFlowComponentAction CORBA interface] Notify rate changed
Definition: RTObject.cpp:1074
void postOnRateChanged(UniqueId ec_id, ReturnCode_t ret)
Definition: RTObject.h:4452
ReturnCode_t deactivate(RTC::UniqueId ec_id)
[local interface] Make transition to Inactive state
Definition: RTObject.cpp:1876
virtual ReturnCode_t onFinalize()
Callback function to finalize.
Definition: RTObject.cpp:148
void preOnDeactivated(UniqueId ec_id)
Definition: RTObject.h:4362
void preOnExecute(UniqueId ec_id)
Definition: RTObject.h:4382
void addPortActionListener(PortActionListenerType listener_type, PortActionListener *listener, bool autoclean=true)
Adding PortAction type listener.
Definition: RTObject.cpp:2228
const PortProfile & getPortProfile() const
Get the PortProfile of the Port.
Definition: PortBase.cpp:119


openrtm_aist
Author(s): Noriaki Ando
autogenerated on Mon Feb 28 2022 23:00:44