/*
 * Copyright 2006 Phidgets Inc.  All rights reserved.
 */

package com.phidgets.event;

import com.phidgets.Phidget;

public class InputChangeEvent
{
	Phidget source;
	int index;
	boolean state;

	public InputChangeEvent(Phidget source, int index, boolean state) {
		this.source = source;
		this.index = index;
		this.state = state;
	}

	public Phidget getSource() {
		return source;
	}

	public int getIndex() {
		return index;
	}

	public boolean getState() {
		return state;
	}

	public String toString() {
		return source.toString() + " input " + index + " changed to "
		  + state;
	}
}
