package Impl;

import CTL.Serialize.*;
import CTL.Types.*;

import java.io.*;
import java.lang.reflect.*;

public class DoubleVector implements Writable {

private double x,y;

public DoubleVector(double x,double y){
	this.x = x;
	this.y = y;
}

public double getx(){
	return this.x;
}

public double gety(){
	return this.y;
}

public void read (SerialIn in) throws IOException, ClassNotFoundException, IllegalAccessException,
	   InvocationTargetException, InstantiationException
{
	x = in.readDouble();
	y = in.readDouble();
}

public void write (SerialOut out) throws IOException, IllegalAccessException,
		InvocationTargetException, CTLException
{
	out.writeDouble(x);
	out.writeDouble(y);
}

}
