Exemple #1
0
void DDGNode::addOutput(DDGNode* n)
{
    doAddOutput(n);
    n->doAddInput(this);
    n->setDirtyValue();
}
Exemple #2
0
void Transfer::ExecCommand(const Uuid& tranId, unsigned int step, const Message* m)
{
	switch(m->type())
	{
	case TRANSFER_CMD_ADD_SIGNAL:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_ADD_SIGNAL\r\n");

			Uuid id(*reinterpret_cast<const Uuid*>(m->data()));
			doAddSignal(tranId, step, id);
		}
		break;
	case TRANSFER_CMD_DEL_SIGNAL:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_DEL_SIGNAL\r\n");

			Uuid id(*reinterpret_cast<const Uuid*>(m->data()));
			doDelSignal(tranId, step, id);
		}
		break;
	case TRANSFER_CMD_ADD_OUTPUT:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_ADD_OUTPUT\r\n");

			const VS_ADD_OUTPUT* p = reinterpret_cast<const VS_ADD_OUTPUT*>(m->data());
			doAddOutput(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_DEL_OUTPUT:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_DEL_OUTPUT\r\n");

			const VS_DEL_OUTPUT* p = reinterpret_cast<const VS_DEL_OUTPUT*>(m->data());
			doDelOutput(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_MULTICAST:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_MULTICAST\r\n");

			const VS_SWITCH_MULTICAST* p = reinterpret_cast<const VS_SWITCH_MULTICAST*>(m->data());
			doSwitchMulticast(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_UNICAST:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_UNICAST\r\n");

			const VS_SWITCH_UNICAST* p = reinterpret_cast<const VS_SWITCH_UNICAST*>(m->data());
			doSwitchUnicast(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_RESET_BASE:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_RESET_BASE\r\n");

			const VS_BASE* p = reinterpret_cast<const VS_BASE*>(m->data());
			doResetBase(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_ONLINE:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_ONLINE\r\n");

			const VS_DISP_CHANGE* p = reinterpret_cast<const VS_DISP_CHANGE*>(m->data());
			doOnline(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_OFFLINE:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_OFFLINE\r\n");

			const VS_DISP_CHANGE* p = reinterpret_cast<const VS_DISP_CHANGE*>(m->data());
			doOffline(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_UPDATE_DESC:
		{
			LOG(LEVEL_INFO, "TRANSFER: type=TRANSFER_CMD_UPDATE_DESC\r\n");

			const VS_SIGNAL_DESC* p = reinterpret_cast<const VS_SIGNAL_DESC*>(m->data());
			doDesc(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_AUDIO_DATA:
		{
			const P_AUDIO* p = reinterpret_cast<const P_AUDIO*>(m->data());
			doAudio(tranId, step, p);
		}
		break;
	case TRANSFER_CMD_VIDEO_DATA:
		{
			const P_VIDEO* p = reinterpret_cast<const P_VIDEO*>(m->data());
			doVideo(tranId, step, p);
		}
		break;
	}

}