Ejemplo n.º 1
0
 private static void GetBooking()
 {
     SqlOption option = new SqlOption { ConnectionString = "Server=localhost;Port=3306;Database=yue;Uid=root;Pwd=123456;" };
     BookingRepository bookingRepository = new BookingRepository(option);
     BookingService bookingService = new BookingService(bookingRepository);
     var booking = bookingService.Get(100, true);
 }
Ejemplo n.º 2
0
        private static void Subscribe()
        {
            SubscribeResource sr = new SubscribeResource(1, 1, 100, "test", 1000, DateTime.Now,
                new Bookings.Contract.TimeSlot(DateTime.Now, DateTime.Now.AddHours(4).AddSeconds(32)));

            SqlOption option = new SqlOption { ConnectionString = "Server=localhost;Port=3306;Database=yue;Uid=root;Pwd=123456;" };
            BookingWriteRepository bookingWriteRepository = new BookingWriteRepository(option);
            BookingHandler bookingHandler = new BookingHandler(bookingWriteRepository);
            bookingHandler.Execute(sr);
        }
Ejemplo n.º 3
0
 public BookingRepository(SqlOption option)
     : base(option)
 {
 }
Ejemplo n.º 4
0
 public BaseRepository(SqlOption option)
 {
     this.ConnectionString = option.ConnectionString;
 }
Ejemplo n.º 5
0
 public UserWriteRepository(SqlOption option)
     : base(option)
 {
 }
Ejemplo n.º 6
0
 public UserSecurityRepository(SqlOption option)
     : base(option)
 {
 }