You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
jellyfin/MediaBrowser.Server.Impleme.../HttpServer/ServerFactory.cs

36 lines
1.3 KiB

using MediaBrowser.Common;
using MediaBrowser.Controller.Net;
12 years ago
using MediaBrowser.Model.Logging;
using ServiceStack.Logging;
12 years ago
namespace MediaBrowser.Server.Implementations.HttpServer
12 years ago
{
/// <summary>
/// Class ServerFactory
/// </summary>
public static class ServerFactory
{
/// <summary>
/// Creates the server.
/// </summary>
/// <param name="applicationHost">The application host.</param>
/// <param name="logManager">The log manager.</param>
12 years ago
/// <param name="serverName">Name of the server.</param>
/// <param name="handlerPath">The handler path.</param>
12 years ago
/// <param name="defaultRedirectpath">The default redirectpath.</param>
/// <param name="supportsNativeWebSocket">if set to <c>true</c> [supports native web socket].</param>
12 years ago
/// <returns>IHttpServer.</returns>
public static IHttpServer CreateServer(IApplicationHost applicationHost,
ILogManager logManager,
string serverName,
string handlerPath,
string defaultRedirectpath,
bool supportsNativeWebSocket)
12 years ago
{
LogManager.LogFactory = new ServerLogFactory(logManager);
return new HttpListenerHost(applicationHost, logManager, serverName, handlerPath, defaultRedirectpath, supportsNativeWebSocket);
12 years ago
}
}
}