Example #1
0
 public Show(Movie movie, String date, Hall hall, String timeStart, String timeEnd, double price) 
 {
     Movie = movie;
     Date = date;
     Hall = hall;
     TimeStart = timeStart;
     TimeEnd = timeEnd;
     Price = price;
 }
Example #2
0
        public Seat(Hall hall, String name)
        {
            //String p1 = @"^[a-zA-Z]";
            //Regex r1 = new Regex(p1);

            //String[] substrings = r1.Split(name);
            Hall = hall;
            this.name = name;
            try {
                Row = name.Substring(0, 1);
                Num = Convert.ToInt32(name.Substring(1, name.Length - 1));
            } catch (FormatException) {
                Row = "-";
                Num = 0;
            } catch (IndexOutOfRangeException) {
                Row = "-";
                Num = 0;
            } catch (InvalidCastException) {
                Row = "-";
                Num = 0;
            }
        }
Example #3
0
 public Seat(Hall hall, String row, int num)
 {
     Hall = hall;
     Row = row;
     Num = num;
 }