@ -364,6 +364,23 @@ namespace WebSocketSharp.Server
return ret;
}
private bool canSet (out string message)
{
message = null;
if (_state == ServerState.Start) {
message = "The service has already started.";
return false;
if (_state == ServerState.ShuttingDown) {
message = "The service is shutting down.";
return true;
private static string createID ()
return Guid.NewGuid ().ToString ("N");