예제 #1
0
 internal void Remove(Context context, bool updateParentType)
 {
     if (types != null)
     {
         foreach (GType type in types)
         {
             type.Remove(context, false);
         }
         types.Clear();
         types = null;
     }
     if (ranges != null)
     {
         foreach (GRange range in ranges)
         {
             range.Remove(context, false);
         }
         ranges.Clear();
         ranges = null;
     }
     if (context != null && id != 0)
     {
         GmCommand cmd = context.Conn.CreateCommandById("deleteFromGisTypesWhereId");
         cmd.AddInt("Id", id);
         cmd.ExecuteNonQuery();
     }
     if (updateParentType)
     {
         ParentComposite.Remove(this);
     }
     else
     {
         lib.Unregister(this);
     }
 }
예제 #2
0
 internal void Remove(GRange range)
 {
     if (ranges != null)
     {
         ranges.Remove(range); Lib.Unregister(range);
     }
 }