if (impl == null) throw new SocketException ("Cannot initialize Socket implementation");
if (isClosed()) throw new SocketException("socket is closed");
  public void setBroadcast(boolean on) throws SocketException  {    if (impl == null)      throw new SocketException ("Cannot initialize Socket implementation");    impl.setOption (SocketOptions.SO_BROADCAST, new Boolean (on));  }