//public PrimeNumberCandidateController()
        //{
        //    Clients = GlobalHost.ConnectionManager.GetHubContext<PrimeHub>().Clients;
        //}

        // GET: PrimeNumberCandidate
        public ActionResult Index()
        {
            // This code executes an unbounded query; don't do this in a production app,
            // it could return too many rows for the web app to handle. For an example
            // of paging code, see:
            // http://www.asp.net/mvc/tutorials/getting-started-with-ef-using-mvc/sorting-filtering-and-paging-with-the-entity-framework-in-an-asp-net-mvc-application
            var list = _solver.Get(100, true);

            return(View(list));
        }
示例#2
0
 // GET api/<controller>
 public IEnumerable <PrimeCandidateViewModel> GetPrimes()
 {
     return(_solver.Get(100, true));
 }