Skip to content
This repository has been archived by the owner on Dec 19, 2018. It is now read-only.

Create WebApplication class for starting web apps application entry points (static void Main) #430

Closed
DamianEdwards opened this issue Oct 20, 2015 · 0 comments
Assignees
Milestone

Comments

@DamianEdwards
Copy link
Member

Create a new type that will be called from web applications in their static void Main(string args). Note this depends on #425

public static class WebApplication
{
    public static void Start<TStartup>()
    {
        Start(typeof(TStartup), null);
    }

    public static void Start<TStartup>(string[] args)
    {
        Start(typeof(TStartup), args);
    }

    public static void Start(Type startupType)
    {
        Start(startupType, null);
    }

    public static void Start(Type startupType, string[] args)
    {
        // Basically the body of Microsoft.AspNet.Hosting.Program.Main, which will now call into this instead
        ...
    }
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants