public UniversalElectronicCard(PassportData passportData,
                                InsurancePolicy insurancePolicy,
                                CardData cardData,
                                Ticket ticket,
                                DriversLicense driversLicense)
 {
     PassportData    = passportData;
     InsurancePolicy = insurancePolicy;
     CardData        = cardData;
     Ticket          = ticket;
     DriversLicense  = driversLicense;
 }
Ejemplo n.º 2
0
        private static UniversalElectronicCard InitCard()
        {
            DateTime dateOfBirth = Convert.ToDateTime("04.08.1997");
            string   fullName    = "Karina Fomina";

            PassportData passportData = new PassportData(fullName,
                                                         Sex.FEMALE,
                                                         dateOfBirth,
                                                         "TM", "9371284",
                                                         "70YUW0CEY6N3SQ",
                                                         Convert.ToDateTime("20.12.2010"),
                                                         Convert.ToDateTime("20.01.2021"),
                                                         "Russia,  Voronezhskaya oblast,  Voronezh",
                                                         "Ministry of Internal Affairs of Russia in the city of Voronezh");

            InsurancePolicy insurancePolicy = new InsurancePolicy(fullName,
                                                                  Sex.FEMALE,
                                                                  dateOfBirth,
                                                                  "70YUW0CEY6N3SQ");

            CardData cardData = new CardData("4485754016244293", Convert.ToDateTime("20.01.2025"), fullName, "123", 500);

            Ticket ticket = new Ticket(Convert.ToDateTime("20.08.2020"), 34);

            DriversLicense driversLicense = new DriversLicense(fullName,
                                                               dateOfBirth,
                                                               "Russia,  Voronezhskaya oblast,  Voronezh",
                                                               Convert.ToDateTime("20.10.2018"),
                                                               Convert.ToDateTime("20.10.2023"),
                                                               "Ministry of Internal Affairs of Russia in the city of Voronezh",
                                                               "576BM78",
                                                               CarCategory.B);

            UniversalElectronicCard universalElectronicCard = new UniversalElectronicCard(passportData,
                                                                                          insurancePolicy,
                                                                                          cardData,
                                                                                          ticket,
                                                                                          driversLicense);

            return(universalElectronicCard);
        }