package com.eactive.eai.common.logger.async;

import java.util.Properties;

import com.eactive.eai.common.message.EAIMessage;
import com.lmax.disruptor.EventFactory;

public class LoggingEvent {
	EAIMessage message;
	Properties prop;
	
	public EAIMessage getMessage() {
		return message;
	}

	public void setMessage(EAIMessage message) {
		this.message = message;
	}

	public Properties getProperty() {
		return prop;
	}

	public void setProperty(Properties prop) {
		this.prop = prop;
	}
	
	public void clear() {
		if(this.message != null) {
			this.message.clear();
		}
		this.message = null;
		this.prop = null;
	}
	
	public final static EventFactory<LoggingEvent> EVENT_FACTORY = new EventFactory<LoggingEvent>() {
        public LoggingEvent newInstance() {
            return new LoggingEvent();
        }
    };
}
