Beispiel #1
0
        public override Computer MakePC()
        {
            var ramMemory = new RAMMemory(2);
            var videoCard = new ColorVideoCard();
            var cpu = new Cpu(2, 32);
            var hdd = new[] { new HardDriver(500, false, 0) };
            var pc = new Computer("PC", cpu, ramMemory, hdd, videoCard, null);

            return pc;
        }
Beispiel #2
0
        public override Computer MakeLaptop()
        {
            var videoCard = new ColorVideoCard();
            var ramMemory = new RAMMemory(4);
            var cpu = new Cpu(2, 64);
            var hdd = new[] { new HardDriver(500, false, 0) };
            var battery = new LaptopBattery();
            var laptop = new Computer("LAPTOP", cpu, ramMemory, hdd, videoCard, new LaptopBattery());

            return laptop;
        }
Beispiel #3
0
        public override Computer MakeServer()
        {
            var serverRam = new RAMMemory(8);
            var serverVideo = new MonochromeVideoCard();
            var cpu = new Cpu(2, 128);
            var hdd = new List<HardDriver>
                          {
                              new HardDriver(
                                  0,
                                  true,
                                  2,
                                  new List<HardDriver>
                                      {
                                          new HardDriver(500, false, 0),
                                          new HardDriver(500, false, 0)
                                      })
                          };
            var server = new Computer("SERVER", cpu, serverRam, hdd, serverVideo, null);

            return server;
        }
Beispiel #4
0
 public MotherBoard(Cpu cpu, RAMMemory ram, IVideoCard videoCard)
 {
     this.cpu = cpu;
     this.ram = ram;
     this.videoCard = videoCard;
 }