private static async Task <bool> SaveAsync(IDictionary <Feature, Geometry> result) { // create an edit operation var editOperation = new EditOperation(); EditorTransaction transaction = new EditorTransaction(editOperation); return(await transaction.ExecuteAsync( editContext => Store(editContext, result), "Erase polygon from feature(s)", GetDatasets(result.Keys))); }
public static bool SaveInOperation( [NotNull] string description, [CanBeNull] IDictionary <Feature, Geometry> updates, [CanBeNull] IDictionary <Feature, IList <Geometry> > copies = null) { var editOperation = new EditOperation(); EditorTransaction transaction = new EditorTransaction(editOperation); return(transaction.Execute( editContext => StoreTx(editContext, updates, copies), description, GetDatasets(updates?.Keys, copies?.Keys))); }