package com.wecloud.dispatch.extend.impl;

import com.wecloud.dispatch.common.BaseRequest;
import com.wecloud.dispatch.extend.ActionMessage;
import io.netty.channel.Channel;

/**
 * @author lixiaozhong
 */
public class DefaultActionMessage implements ActionMessage {

	String action;
	BaseRequest message;
	Long senderClientId;
	Channel senderChannel;

	public DefaultActionMessage() {
	}

	public DefaultActionMessage(String action, BaseRequest message) {
		this.message = message;
		this.action = action;
	}

	public DefaultActionMessage(String action, BaseRequest message, Long senderClientId, Channel senderChannel) {
		this.message = message;
		this.action = action;
		this.senderClientId = senderClientId;
		this.senderChannel = senderChannel;
	}

	@Override
	public BaseRequest getMessage() {
		return message;
	}

	@Override
	public void setMessage(BaseRequest message) {
		this.message = message;
	}

	@Override
	public String getAction() {
		return action;
	}

	@Override
	public void setAction(String action) {
		this.action = action;
	}

	@Override
	public void setSenderClientId(Long senderClientId) {
		this.senderClientId = senderClientId;
	}

	@Override
	public Long getSenderClientId() {
		return senderClientId;
	}

	@Override
	public void setSenderChannel(Channel senderChannel) {
		this.senderChannel = senderChannel;
	}

	@Override
	public Channel getSenderChannel() {
		return this.senderChannel;
	}

}
