Exemplo n.º 1
0
void RhrController::sendConfigObject() const {

    if (m_module->rank() == 0) {
        CERR << "sending rhr config object" << std::endl;
        static_cast<Module *>(m_module)->addObject(m_imageOutPort, getConfigObject());
    }
}
Exemplo n.º 2
0
Arquivo: json.cpp Projeto: Jesna/jucpp
	void Config::Close(){
		if(_innerobj==0) return;
		config_struct* cfg = (config_struct*)_innerobj;
		_innerobj = 0;
		if(_cfglock){
			cfg->Tree.SaveToFile(cfg->FileName);
			cfg->Lock.Unlock();
			_cfglock = false;
		}
		getConfigObject(0,cfg);
	}
Exemplo n.º 3
0
void RhrController::removeClient(const Port *client) {

    auto it = m_clients.find(client);
    if (it == m_clients.end()) {
        CERR << "did not find disconnected destination port " << *client << std::endl;
        return;
    }

    m_clients.erase(it);

    if (m_clients.empty()) {
        m_rhr.reset();
    }

    if (m_module->rank() == 0) {
        CERR << "sending rhr config object" << std::endl;
        static_cast<Module *>(m_module)->addObject(m_imageOutPort, getConfigObject());
    }
}
Exemplo n.º 4
0
Arquivo: json.cpp Projeto: Jesna/jucpp
	bool Config::Create(LPCWSTR fname){
		if(_innerobj) return 1;
		_innerobj = getConfigObject(fname);
		return _innerobj!=NULL;
	}
Exemplo n.º 5
0
Arquivo: json.cpp Projeto: Jesna/jucpp
	Config::Config(LPCWSTR fname):_innerobj(0){
		_innerobj = getConfigObject(fname);
		if(_innerobj==NULL) Print(L"Config Error: _innerobj is NULL");
	}