// fetch by Primary key into current object // links: // crud definition: https://en.wikipedia.org/wiki/Create,_read,_update_and_delete // docLink: http://sql2x.org/documentationLink/fdcc33b4-08f1-43c3-ae28-95fbf029c3bd // parameters: // CrudePassengerData: primary key of table CrudePassengerData public CrudePassengerModel FetchByPassengerId(System.Guid passengerId) { var dataAccessLayer = new CrudePassengerData(); var model = new CrudePassengerModel(); dataAccessLayer.FetchByPassengerId(passengerId); DataToModel(dataAccessLayer, model); return model; }
// fetch by Primary key into current object // links: // crud definition: https://en.wikipedia.org/wiki/Create,_read,_update_and_delete // docLink: http://sql2x.org/documentationLink/bbab4791-c9e7-49bf-90d5-fca19b1fedaa // parameters: // passengerId: primary key of table passenger public CrudePassengerContract FetchByPassengerId(System.Guid passengerId) { var dataAccessLayer = new CrudePassengerData(); var contract = new CrudePassengerContract(); dataAccessLayer.FetchByPassengerId(passengerId); DataToContract(dataAccessLayer, contract); return(contract); }