/** * Quark is a simple JavaBean. * * @author Thornton Rose */ public class Quark implements IQuark { private String flavor = "vanilla"; /** * Get the flavor. */ public String getFlavor() { return flavor; } /** * Set the flavor. */ public void setFlavor(String newFlavor) { flavor = newFlavor; } /** * Set the flavor. */ public void setFlavor(Object newFlavor) { setFlavor((String) newFlavor); } /** * Spin */ public void spin() { System.out.print("Spinning "); for (int i = 0; i < 5; i ++) { System.out.print("."); try { Thread.sleep(250); } catch(InterruptedException ex) { System.out.print(" interruped! "); } } System.out.println(" done."); } /* public static void main(String[] args) { Quark q = new Quark(); q.spin(); } */ }