public boolean start() {
    assert myState == State.CREATED : "Already started";

    myThread.start();

    try {
      synchronized (theLock) {
        while (myState == State.CREATED) {
          theLock.wait();
        }
      }
      return true;
    } catch (InterruptedException e) {
      //
    }
    return false;
  }
public boolean start()