/**
 * CMDispatcher.java
 * Created on Apr 10, 2009
 * (C) Copyright TANDBERG Television Ltd.
 */
package com.tandbergtv.watchpoint.contentmgmt.communication;

import com.tandbergtv.workflow.adaptor.conf.IDispatcherConfiguration;
import com.tandbergtv.workflow.adaptor.dispatcher.AbstractDispatcher;
import com.tandbergtv.workflow.adaptor.dispatcher.DispatcherException;
import com.tandbergtv.workflow.comm.IDestination;
import com.tandbergtv.workflow.core.service.ServiceRegistry;
import com.tandbergtv.workflow.message.IMessage;

/**
 * @author Vlada Jakobac
 *
 */
public class CMDispatcher extends AbstractDispatcher {

	/**
	 * Constructor.
	 */
	public CMDispatcher(IDispatcherConfiguration conf, IDestination destination) {
		super(conf, destination);
	}

	/* (non-Javadoc)
	 * @see com.tandbergtv.workflow.adaptor.dispatcher.IDispatcher#send(com.tandbergtv.workflow.message.IMessage)
	 */
	public IMessage send(IMessage msg) throws DispatcherException {
		return ServiceRegistry.getDefault().lookup(CMMessageService.class).receive(msg);
	}
	
	

}
