public static void BuildApp(IAppBuilder builder, PeerCastApplication application) { var app = new YPChannelsHostOwinApp(application); builder.MapGET("/ypchannels/index.txt", sub => { sub.UseAuth(OutputStreamType.Interface); sub.Run(app.Invoke); }); }
public static void BuildApp(IAppBuilder builder, PeerCastApplication application) { var app = new YPChannelsHostOwinApp(application); builder.Map("/ypchannels/index.txt", sub => { sub.UseAllowMethods("GET"); sub.MapMethod("GET", withmethod => { withmethod.UseAuth(OutputStreamType.Interface); withmethod.Run(app.Invoke); }); }); }
protected override void OnStart() { var owin = Application.Plugins.OfType <OwinHostPlugin>().FirstOrDefault(); appRegistration = owin?.OwinHost?.Register(builder => YPChannelsHostOwinApp.BuildApp(builder, Application)); }