Пример #1
0
 public Bericht(string tekst, Persoon auteur, Bestand bestand, int berichtSoort)
 {
     this.tekst        = tekst;
     this.auteur       = auteur;
     datumGepost       = DateTime.Now;
     this.berichtSoort = (BerichtSoort)berichtSoort;
     this.bestand      = bestand;
     reacties          = new List <Reactie>();
     likes             = new List <Like>();
     rapportages       = new List <Rapportage>();
     id = -1;
 }
Пример #2
0
        //Methodes
        //Deze methode wordt gebruikt om een bestand toe te voegen
        public bool VoegBestandToe(Bestand bestand)
        {
            bool succes = true;

            foreach (Bestand b in bestanden)
            {
                if (b.Pad == bestand.Pad)
                {
                    succes = false;
                }
            }
            if (succes)
            {
                bestanden.Add(bestand);
            }
            return(succes);
        }