All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.refcodes.checkerboard.impls.AbstractCheckerboardViewerEvent Maven / Gradle / Ivy

Go to download

Artifact for providing some easy means to visualize (state of) board games or (state of) cellular automatons.

There is a newer version: 1.1.1
Show newest version
package org.refcodes.checkerboard.impls;

import org.refcodes.checkerboard.CheckerboardViewer;
import org.refcodes.checkerboard.CheckerboardViewerAction;
import org.refcodes.checkerboard.CheckerboardViewerEvent;

public abstract class AbstractCheckerboardViewerEvent implements CheckerboardViewerEvent {

	// /////////////////////////////////////////////////////////////////////////
	// STATICS:
	// /////////////////////////////////////////////////////////////////////////

	// /////////////////////////////////////////////////////////////////////////
	// CONSTANTS:
	// /////////////////////////////////////////////////////////////////////////

	// /////////////////////////////////////////////////////////////////////////
	// VARIABLES:
	// /////////////////////////////////////////////////////////////////////////

	private CheckerboardViewer _source;
	private CheckerboardViewerAction _action;

	// /////////////////////////////////////////////////////////////////////////
	// CONSTRUCTORS:
	// /////////////////////////////////////////////////////////////////////////

	public AbstractCheckerboardViewerEvent( CheckerboardViewerAction aAction, CheckerboardViewer aSource ) {
		_source = aSource;
		_action = aAction;
	}

	// /////////////////////////////////////////////////////////////////////////
	// INJECTION:
	// /////////////////////////////////////////////////////////////////////////

	// /////////////////////////////////////////////////////////////////////////
	// METHODS:
	// /////////////////////////////////////////////////////////////////////////

	@Override
	public CheckerboardViewerAction getAction() {
		return _action;
	}

	@Override
	public CheckerboardViewer getSource() {
		return _source;
	}

	@Override
	public String toString() {
		return "action := " + _action;

	}

	// /////////////////////////////////////////////////////////////////////////
	// HOOKS:
	// /////////////////////////////////////////////////////////////////////////

	// /////////////////////////////////////////////////////////////////////////
	// HELPER:
	// /////////////////////////////////////////////////////////////////////////

	// /////////////////////////////////////////////////////////////////////////
	// INNER CLASSES:
	// /////////////////////////////////////////////////////////////////////////
}