
import java.util.LinkedList;

import CTL.Types.*;
import Impl.*;
import javaSys.*;

public class Client {

static double x,y;	
	
		public static void main (String args[])
		{
			LinkedList<Location> locs = Location.parseFile("locs.txt");
			if (locs.size() != 1)
				System.exit(1);
			CTL.Process proc = new CTL.Process(locs.get(0));
		
		TestPointsCI.use(proc);
		
			int repeat=100000;
			
			DoubleVector[] temp = new DoubleVector[repeat];
			
			for(int i=0;i<=repeat-1;i++){
				x = Math.random();
				y = Math.random();
				
				temp[i]=new DoubleVector(x,y);
			}
			
			double z = TestPointsCI.testpoints(temp);
			z=z/repeat;
			z *=4;
			
			System.out.println("Pi = "+z);

			proc.stopService();
	}
//${path.separator}${build}${path.separator}${ctl4j}
}
