Skip to content

Instantly share code, notes, and snippets.

@devdays
Created November 30, 2014 19:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save devdays/d554b772eea2007ebb4a to your computer and use it in GitHub Desktop.
Save devdays/d554b772eea2007ebb4a to your computer and use it in GitHub Desktop.
using System;
using System.Web;
using Microsoft.Web.WebSockets;
namespace MyWebSocket
{
public class ws : IHttpHandler
{
public bool IsReusable
{
get { return false; }
}
public void ProcessRequest(HttpContext context)
{
if (context.IsWebSocketRequest)
context.AcceptWebSocketRequest(new MyWebSocketHandler());
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment