using System;
using System.Collections.Generic;
using System.Web.Http;
using WebApi.SelfHostingExample.Models;

namespace WebApi.SelfHostingExample.Controllers
{
    public class EpisodeController : ApiController
    {
        public IList<Episode> GetAllEpisodes()
        {
            return new List<Episode>
                {
                    new Episode {Id = 1, Name = "Episode 1", ReleasedOn = DateTime.Now.AddDays( -2 )},
                    new Episode {Id = 2, Name = "Episode 2", ReleasedOn = DateTime.Now.AddDays( -1 )},
                    new Episode {Id = 3, Name = "Episode 3", ReleasedOn = DateTime.Now.AddDays( 0 )},
                };
        }
         
    }
}