package org.frcbitbucketbase.control;

/**
 * A descriptor of movement in 2 dimensional vector format. Instances of this object allow classes such as <code>KinematicControllers</code> and <code>ValueControllers</code>
 * to communicate. This class is designed to be vague, so contextual meaning of the fields must be handled by the user.
 * <p>
 * For example, an action controlling a single motor requires a single vector, wherein the direction field indicates forward or backwards. A translational movement with
 * rotation may require use of several vectors, to indicate target translation and rotation, as well as instantaneous values such as target velocity.
 * 
 * @author Miles Marchant
 *
 */
public class MovementVector {
	
	/**
	 * Value of this vector. This may refer to any value; for example, position, velocity, or acceleration.
	 */
	public double value;
	/**
	 * Translational direction of this vector
	 */
	public double direction;
	
	/**
	 * Rotation of the vector
	 */
	public double rotation;
	
	/**
	 * Constructor for the MovementVector class. Simply sets the object's fields as the matching parameters.
	 * 
	 * @param value      is a value given to this MovementVector
	 * @param direction  is a direction given to this MovementVector
	 */
	public MovementVector(double value, double direction, double rotation){
		this.value = value;
		this.direction = direction;
		this.rotation = rotation;
	}

}

@@ -36,1388 +36,1415 @@
 l;%0A%0A
-/**%0A * A descriptor of movement in 2 dimensional vector format. Instances of this object allow classes such as %3Ccode%3EKinematicControllers%3C/code%3E and %3Ccode%3EValueControllers%3C/code%3E%0A * to communicate. This class is designed to be vague, so contextual meaning of the fields must be handled by the user.%0A * %3Cp%3E%0A * For example, an action controlling a single motor requires a single vector, wherein the direction field indicates forward or backwards. A translational movement with%0A * rotation may require use of several vectors, to indicate target translation and rotation, as well as instantaneous values such as target velocity.%0A * %0A * @author Miles Marchant%0A *%0A */%0Apublic class MovementVector %7B%0A%09%0A%09/**%0A%09 * Value of this vector. This may refer to any value; for example, position, velocity, or acceleration.%0A%09 */%0A%09public double value;%0A%09/**%0A%09 * Translational direction of this vector%0A%09 */%0A%09public double direction;%0A%09%0A%09/**%0A%09 * Rotation of the vector%0A%09 */%0A%09public double rotation;%0A%09%0A%09/**%0A%09 * Constructor for the MovementVector class. Simply sets the object's fields as the matching parameters.%0A%09 * %0A%09 * @param value      is a value given to this MovementVector%0A%09 * @param direction  is a direction given to this MovementVector%0A%09 */%0A%09public MovementVector(double value, double direction, double rotation)%7B%0A%09%09this.value = value;%0A%09%09this.direction = direction;%0A%09%09this.rotation = rotation
+import java.util.Hashtable;%0A%0A/**%0A * %0A * @author Miles Marchant%0A *%0A */%0Apublic class MovementVector extends Hashtable%3CString, Double%3E %7B%0A%09%0A%09public MovementVector()%7B%7D%0A%0A%09public static class VectorBuilder%7B%0A%09%09%0A%09%09MovementVector vector = new MovementVector();%0A%09%09%0A%09%09public VectorBuilder()%7B%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder translationAngle(double translationAngle)%7B%0A%09%09%09vector.put(%22translationAngle%22, translationAngle);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder position(double position)%7B%0A%09%09%09vector.put(%22position%22, position);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder veloctiy(double velocity)%7B%0A%09%09%09vector.put(%22velocity%22, velocity);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder acceleration(double acceleration)%7B%0A%09%09%09vector.put(%22acceleration%22, acceleration);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder jerk(double jerk)%7B%0A%09%09%09vector.put(%22jerk%22, jerk);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder angle(double angle)%7B%0A%09%09%09vector.put(%22angle%22, angle);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder angularVel(double angularVel)%7B%0A%09%09%09vector.put(%22angularVel%22, angularVel);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder angularAccel(double angularAccel)%7B%0A%09%09%09vector.put(%22angularAccel%22, angularAccel);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public VectorBuilder angularJerk(double angularJerk)%7B%0A%09%09%09vector.put(%22angularJerk%22, angularJerk);%0A%09%09%09return this;%0A%09%09%7D%0A%09%09%0A%09%09public MovementVector createVector()%7B%0A%09%09%09return this.vector
 ;%0A
+%09
 %09%7D%0A
+%09%09%0A%09%7D%0A%09%0A%09
 %0A%7D
-%0A

Refactor MovementVector to extend HashTable<K, v> and use the Builder pattern. This will make construction easier, and allow for easier passing between classes.