コード例 #1
0
        public BookingPassengerWithExtraContract BookingPassengerWithExtraFromDal(BookingPassengerWithExtraData data)
        {
            var contract = new BookingPassengerWithExtraContract();

            DataToContract(data, contract);

            return(contract);
        }
コード例 #2
0
 // transfer serialized data contract to business wcf contract
 // links:
 //  how to generate durians: https://sql2x.org
 //  docLink: http://sql2x.org/documentationLink/6140089a-d7c9-4e92-b385-f6fd91026820
 // parameters:
 //  dalBookingPassengerWithExtra: from durian ansi sql select statement
 //  dataContract: business wcf contract
 public void DataToContract(BookingPassengerWithExtraData dalBookingPassengerWithExtra, BookingPassengerWithExtraContract dataContract)
 {
     dataContract.BookingPassengerId = dalBookingPassengerWithExtra.BookingPassengerId;
     dataContract.BookingId          = dalBookingPassengerWithExtra.BookingId;
     dataContract.PassengerId        = dalBookingPassengerWithExtra.PassengerId;
     dataContract.PassengerTypeRcd   = dalBookingPassengerWithExtra.PassengerTypeRcd;
     dataContract.PassengerName      = dalBookingPassengerWithExtra.PassengerName;
     dataContract.DefaultStateRcd    = dalBookingPassengerWithExtra.DefaultStateRcd;
     dataContract.UserId             = dalBookingPassengerWithExtra.UserId;
     dataContract.DateTime           = dalBookingPassengerWithExtra.DateTime;
 }