package org.usfirst.frc330.wpilibj;

import edu.wpi.first.wpilibj.DoubleSolenoid;

public class BBDoubleSolenoid extends DoubleSolenoid {
	DoubleSolenoid.Value value;
	public BBDoubleSolenoid(int moduleNumber, int forwardChannel,
			int reverseChannel) {
		super(moduleNumber, forwardChannel, reverseChannel);
		value = get();
	}

	public BBDoubleSolenoid(int forwardChannel, int reverseChannel) {
		super(forwardChannel, reverseChannel);
		value = get();
	}

	@Override
	public void set(Value value) {
		this.value = value;
		super.set(value);
	}

	@Override
	public Value get() {
		return value;
	}
	
	public int getInt() {
		return value.value;
	}

}

@@ -654,26 +654,208 @@
 %0D%0A%09%09
-return value.value
+if (value == Value.kOff)%0D%0A%09%09%09return Value.kOff_val;%0D%0A%09%09else if (value == Value.kForward)%0D%0A%09%09%09return Value.kForward_val;%0D%0A%09%09else if (value == Value.kReverse)%0D%0A%09%09%09return Value.kReverse_val;%0D%0A%09%09return -1
 ;%0D%0A%09

Fix NPE