Exemplo n.º 1
0
 public ConceptTwo(Storage _storage)
     : base(_storage)
 {
     this.prototypeManager = new PrototypeManager();
     prototypeManager["movie"] = new Movie();
     prototypeManager["actor"] = new Actor();
 }
Exemplo n.º 2
0
 public void assignMovieToActor(Actor actor, Movie movie)
 {
     if (actor != null && movie != null)
     {
         actor.Movies.Add(movie);
         movie.Actors.Add(actor);
     }
 }
Exemplo n.º 3
0
        /* Actor */
        public Actor saveNewActor(string firstName, string lastName, string text)
        {
            Actor newActor = new Actor();
            newActor.FirstName = firstName;
            newActor.LastName = lastName;
            newActor.Text = text;

            // id wird beim Insert automatisch generiert
            return storage.Actors.Insert(newActor); // insert
        }
Exemplo n.º 4
0
 private void UpdateActor(Actor actor)
 {
     if (actor != null)
     {
         tbxSurname.Text = actor.FirstName;
         tbxName.Text = actor.LastName;
         tbxDescriptionActor.Text = actor.Text;
     }
 }
Exemplo n.º 5
0
 public void deleteActor(Actor actor)
 {
     if (actor != null)
         storage.Actors.Delete(actor);
 }