Example #1
0
 public void addMusic(Music music)
 {
     Contract.Requires(music != null);
     Contract.Ensures(this.MusicList.Count == Contract.OldValue(this.MusicList.Count) + 1);
     this.MusicList.Add(music);
 }
Example #2
0
 public void removeMusic(Music music)
 {
     Contract.Requires(music != null);
     Contract.Ensures(this.MusicList.Count == Contract.OldValue(this.MusicList.Count) - 1);
     this.MusicList.Remove(music);
 }
Example #3
0
 public void removeMusic(Music music)
 {
     Contract.Requires(music != null);
     Contract.Ensures(this.MusicList.Count == Contract.OldValue(this.MusicList.Count) - 1);
     this.MusicList.Remove(music);
 }
Example #4
0
 public void addMusic(Music music)
 {
     Contract.Requires(music != null);
     Contract.Ensures(this.MusicList.Count == Contract.OldValue(this.MusicList.Count) + 1);
     this.MusicList.Add(music);
 }