public void LogFeatureRetire(IObject obj) { this.transaction.LastEditDate = DateTime.Now; this.transaction.ConflictDate = this.transaction.CreationDate; try { if (obj != null && this.transaction != null && obj is IFeature) { EditsDAO dao = new EditsDAO((IFeatureWorkspace)this.transaction.PGDBConnection, this.config); dao.log((IFeature)obj, IsdutEditEventType.Retired); } } catch (HandledException he) { Logger.Write(he); } catch (Exception e) { MessageBox.Show(e.Message + " : " + e.StackTrace, "EXCEPTION", MessageBoxButtons.OK, MessageBoxIcon.Error); } try { this.qaManager.Invalidate(); } catch (HandledException he) { Logger.Write(he); } catch (Exception e) { MessageBox.Show(e.Message + " : " + e.StackTrace, "EXCEPTION", MessageBoxButtons.OK, MessageBoxIcon.Error); } }
void LogFeatureInsert(IObject obj) { this.transaction.LastEditDate = DateTime.Now; this.transaction.ConflictDate = this.transaction.CreationDate; try { if(obj != null && this.transaction != null && obj is IFeature) { //string featureName = ((IFeature)obj).Class.AliasName.ToUpper(); string featureName = ((IDataset)((IFeature)obj).Table).Name; if (!featureName.StartsWith("P_") && !featureName.StartsWith("E_") && !featureName.StartsWith("C_") && !featureName.Equals("DATA_ERRORS") && !featureName.Equals("METADATA") && !featureName.Equals("ISDUT_SPATIAL_EDIT_EXTENTS_SP")) { EditsDAO dao = new EditsDAO((IFeatureWorkspace)this.transaction.PGDBConnection, this.config); dao.log((IFeature)obj, IsdutEditEventType.Insert); } } } catch(HandledException he) { Logger.Write(he); } catch(Exception e) { MessageBox.Show(e.Message+" : "+e.StackTrace, "EXCEPTION", MessageBoxButtons.OK, MessageBoxIcon.Error); } try { this.qaManager.Invalidate(); } catch(HandledException he) { Logger.Write(he); } catch(Exception e) { MessageBox.Show(e.Message+" : "+e.StackTrace, "EXCEPTION", MessageBoxButtons.OK, MessageBoxIcon.Error); } }