1
0
Fork 0
mirror of https://github.com/sbrl/Nibriboard.git synced 2018-01-10 21:33:49 +00:00
Nibriboard/Nibriboard/NibriboardServer.cs

43 lines
723 B
C#
Raw Normal View History

using System;
using System.Reflection;
using IotWeb.Server;
using IotWeb.Common.Http;
using System.Net;
namespace Nibriboard
{
public class NibriboardServer
{
private HttpServer httpServer;
public readonly int Port = 31586;
public NibriboardServer()
{
}
public void Setup()
{
httpServer = new HttpServer(Port);
httpServer.AddHttpRequestHandler(
2017-01-10 19:51:49 +00:00
"/",
new HttpResourceHandler(
Assembly.GetExecutingAssembly(),
"Nibriboard",
"index.html"
2017-01-10 19:51:49 +00:00
)
);
httpServer.AddWebSocketRequestHandler(
"/RipplespaceConnection",
);
2017-01-10 19:51:49 +00:00
httpServer.Start();
Log.WriteLine("[NibriboardServer] Started on port {0}", Port);
}
private void Test()
{
HttpListener.
}
}
}