예제 #1
0
        public void CreateAnimeEpisode(ISession session, int animeSeriesID)
        {
            // check if there is an existing episode for this EpisodeID
            AnimeEpisode existingEp = RepoFactory.AnimeEpisode.GetByAniDBEpisodeID(EpisodeID);

            if (existingEp == null)
            {
                AnimeEpisode animeEp = new AnimeEpisode();
                animeEp.Populate(this);
                animeEp.AnimeSeriesID = animeSeriesID;
                RepoFactory.AnimeEpisode.Save(animeEp);
            }
        }
예제 #2
0
        public void CreateAnimeEpisode(ISession session, int animeSeriesID)
        {
            // check if there is an existing episode for this EpisodeID
            AnimeEpisodeRepository repEps     = new AnimeEpisodeRepository();
            AnimeEpisode           existingEp = repEps.GetByAniDBEpisodeID(session, EpisodeID);

            if (existingEp == null)
            {
                AnimeEpisode animeEp = new AnimeEpisode();
                animeEp.Populate(this);
                animeEp.AnimeSeriesID = animeSeriesID;
                repEps.Save(session, animeEp);
            }
        }
예제 #3
0
        public void CreateAnimeEpisode(ISession session, int animeSeriesID)
        {
            // check if there is an existing episode for this EpisodeID
            AnimeEpisode existingEp = RepoFactory.AnimeEpisode.GetByAniDBEpisodeID(EpisodeID);

            if (existingEp == null)
            {
                AnimeEpisode animeEp = new AnimeEpisode();
                animeEp.Populate(this);
                animeEp.AnimeSeriesID = animeSeriesID;
                RepoFactory.AnimeEpisode.Save(animeEp);
            }
        }
예제 #4
0
		public void CreateAnimeEpisode(ISession session, int animeSeriesID)
		{
			// check if there is an existing episode for this EpisodeID
			AnimeEpisodeRepository repEps = new AnimeEpisodeRepository();
			List<AnimeEpisode> existingEps = repEps.GetByAniEpisodeIDAndSeriesID(session, EpisodeID, animeSeriesID);

			if (existingEps.Count == 0)
			{
				AnimeEpisode animeEp = new AnimeEpisode();
				animeEp.Populate(this);
				animeEp.AnimeSeriesID = animeSeriesID;
				repEps.Save(session, animeEp);
			}
		}