21 using namespace evf::rb_statemachine;
26 rcmsStateNotifier_(app_->getApplicationLogger(),
27 app_->getApplicationDescriptor(),
28 app_->getApplicationContext()), visibleStateName_(
"N/A"),
29 internalStateName_(
"N/A"), firstTimeInHalted_(
true) {
35 pthread_rwlockattr_t
attr;
36 pthread_rwlockattr_init(&attr);
40 pthread_rwlockattr_setkind_np(&attr,
41 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP);
50 cout <<
"State machine DESTROYED!" << endl;
84 app->getApplicationInfoSpace());
90 cout <<
"-->RCMS state change notify: " << state << endl;
92 "ResourceBroker has reached target state " + state);
94 cout <<
"Failed to notify state change: " << state << endl;
xdata::Boolean * foundRcmsStateListener()
boost::shared_ptr< SharedResources > SharedResourcesPtr_t
xdaq2rc::RcmsStateNotifier rcmsStateNotifier_
RBStateMachine(xdaq::Application *app, SharedResourcesPtr_t sr)
void rcmsStateChangeNotify()
void updateWebGUIInternalState(std::string newStateName) const
void updateWebGUIExternalState(std::string newStateName) const
pthread_rwlock_t transitionLock_
BaseState & getCurrentStateNC() const
void findRcmsStateListener(xdaq::Application *app)
SharedResourcesPtr_t sharedResources_
xdata::String visibleStateName_
xdata::Bag< xdaq2rc::ClassnameAndInstance > * rcmsStateListener()
std::string getExternallyVisibleState()
void setInternalStateName(const std::string &s)
void setExternallyVisibleState(const std::string &s)
BaseState const & getCurrentState() const
std::string internalStateName_