if (ok) selector ().selectedKeys ().add (this);  ok = false;
if (isValid()) { ((AbstractSelector) selector()).cancelKey(this); cancelled = true; }
  public final void cancel ()  {    if (ok)      selector ().selectedKeys ().add (this);        ok = false;  }