예제 #1
0
 /// <summary>
 /// Update a database row from a class
 /// </summary>
 public static void UpdateRowFromPolineretrievecriteria(ref DataRow row, Polineretrievecriteria entity)
 {
     row.SetField("pono", entity.pono);
     row.SetField("posuf", entity.posuf);
     row.SetField("lineno", entity.lineno);
     row.SetField("maintmode", entity.maintmode);
     row.SetField("readonlyfl", entity.readonlyfl);
     row.SetField("secure", entity.secure);
     row.SetField("userfield", entity.userfield);
 }
예제 #2
0
        public static Polineretrievecriteria BuildPolineretrievecriteriaFromRow(DataRow row)
        {
            Polineretrievecriteria entity = new Polineretrievecriteria();

            entity.pono       = row.IsNull("pono") ? 0 : row.Field <int>("pono");
            entity.posuf      = row.IsNull("posuf") ? 0 : row.Field <int>("posuf");
            entity.lineno     = row.IsNull("lineno") ? 0 : row.Field <int>("lineno");
            entity.maintmode  = row.Field <bool>("maintmode");
            entity.readonlyfl = row.Field <bool>("readonlyfl");
            entity.secure     = row.IsNull("secure") ? 0 : row.Field <int>("secure");
            entity.userfield  = row.IsNull("userfield") ? string.Empty : row.Field <string>("userfield");
            return(entity);
        }