Exemple #1
0
        static void LaundryMachineFunc()
        {
            LaundryMachine lMachine = new LaundryMachine();

            lMachine.IsOn          = true;
            lMachine.RotationSpeed = 1400;
            lMachine.ProgramLenght = 90;
            lMachine.Temperature   = 60;

            Console.WriteLine(lMachine.PrintProgram(lMachine));
        }
Exemple #2
0
 public string PrintProgram(LaundryMachine x)
 {
     // x edustaa tuntematonta oliota joka syötetään pääohjelmasta
     return(String.Format("Is on: {0}, RPM: {1}, Program Time: {2} min, Temperature {3} C",
                          x.IsOn, x.RotationSpeed, x.ProgramLenght, x.Temperature));
 }