Beispiel #1
0
 public static IDictionary <string, object> ToDictionary(this CustomerDemographics item)
 {
     return(new Dictionary <string, object>()
     {
         [_CUSTOMERTYPEID] = item.CustomerTypeID,
         [_CUSTOMERDESC] = item.CustomerDesc
     });
 }
Beispiel #2
0
 public static void UpdateRow(this CustomerDemographics item, DataRow row)
 {
     row.SetField(_CUSTOMERTYPEID, item.CustomerTypeID);
     row.SetField(_CUSTOMERDESC, item.CustomerDesc);
 }
Beispiel #3
0
 public static void FillObject(this CustomerDemographics item, DataRow row)
 {
     item.CustomerTypeID = row.GetField <string>(_CUSTOMERTYPEID);
     item.CustomerDesc   = row.GetField <string>(_CUSTOMERDESC);
 }
Beispiel #4
0
 public static string ToSimpleString(this CustomerDemographics obj)
 {
     return(string.Format("{{CustomerTypeID:{0}, CustomerDesc:{1}}}",
                          obj.CustomerTypeID,
                          obj.CustomerDesc));
 }
Beispiel #5
0
 public static CustomerDemographicsAssociation GetAssociation(this CustomerDemographics entity)
 {
     return(entity.AsEnumerable().GetAssociation().FirstOrDefault());
 }
Beispiel #6
0
 public static void CopyTo(this CustomerDemographics from, CustomerDemographics to)
 {
     to.CustomerTypeID = from.CustomerTypeID;
     to.CustomerDesc   = from.CustomerDesc;
 }
Beispiel #7
0
 public static bool CompareTo(this CustomerDemographics a, CustomerDemographics b)
 {
     return(a.CustomerTypeID == b.CustomerTypeID &&
            a.CustomerDesc == b.CustomerDesc);
 }