From 9a06b646d7092ba66cca67e3757c77c775cfc32f Mon Sep 17 00:00:00 2001 From: sta Date: Tue, 20 Jan 2015 17:57:09 +0900 Subject: [PATCH] Added the IsNoStatusCode (ushort) method --- websocket-sharp/Ext.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/websocket-sharp/Ext.cs b/websocket-sharp/Ext.cs index f0d27a08..b22335a9 100644 --- a/websocket-sharp/Ext.cs +++ b/websocket-sharp/Ext.cs @@ -584,6 +584,11 @@ namespace WebSocketSharp return value.StartsWith ("permessage-"); } + internal static bool IsNoStatusCode (this ushort code) + { + return code == (ushort) CloseStatusCode.NoStatusCode; + } + internal static bool IsPortNumber (this int value) { return value > 0 && value < 65536;