public static void main(String[] args) {
		Generator g = new Generator();
		Thread t = new Thread(g);
		t.start();

		g.addListener(new EventListener1());
		g.addListener(new EventListener2());
		
		try {
			t.join();
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
	}