/// <summary> /// Raises the <see cref="ColumnChanged" /> event. /// </summary> /// <param name="column">The <see cref="JobCandidateColumn"/> which has raised the event.</param> /// <param name="value">The changed value.</param> public virtual void OnColumnChanged(JobCandidateColumn column, object value) { if (!SuppressEntityEvents) { JobCandidateEventHandler handler = ColumnChanged; if (handler != null) { handler(this, new JobCandidateEventArgs(column, value)); } // warn the parent list that i have changed OnEntityChanged(); } }
/// <summary> /// Raises the <see cref="ColumnChanging" /> event. /// </summary> /// <param name="column">The <see cref="JobCandidateColumn"/> which has raised the event.</param> /// <param name="value">The changed value.</param> public virtual void OnColumnChanging(JobCandidateColumn column, object value) { if (IsEntityTracked && EntityState != EntityState.Added && !EntityManager.TrackChangedEntities) { EntityManager.StopTracking(entityTrackingKey); } if (!SuppressEntityEvents) { JobCandidateEventHandler handler = ColumnChanging; if (handler != null) { handler(this, new JobCandidateEventArgs(column, value)); } } }
/// <summary> /// Determines whether the property value has changed from the original data. /// </summary> /// <param name="column">The column.</param> /// <returns> /// <c>true</c> if the property value has changed; otherwise, <c>false</c>. /// </returns> public bool IsPropertyChanged(JobCandidateColumn column) { switch (column) { case JobCandidateColumn.JobCandidateId: return(entityData.JobCandidateId != _originalData.JobCandidateId); case JobCandidateColumn.EmployeeId: return(entityData.EmployeeId != _originalData.EmployeeId); case JobCandidateColumn.Resume: return(entityData.Resume != _originalData.Resume); case JobCandidateColumn.ModifiedDate: return(entityData.ModifiedDate != _originalData.ModifiedDate); default: return(false); } }
/// <summary> /// Initializes a new instance of the <see cref="T:JobCandidateComparer"/> class. /// </summary> /// <param name="column">The column to sort on.</param> public JobCandidateComparer(JobCandidateColumn column) { this.whichComparison = column; }
///<summary> /// Initalizes a new Instance of the JobCandidateEventArgs class. ///</summary> public JobCandidateEventArgs(JobCandidateColumn column, object value) { this.column = column; this.value = value; }
///<summary> /// Initalizes a new Instance of the JobCandidateEventArgs class. ///</summary> public JobCandidateEventArgs(JobCandidateColumn column) { this.column = column; }
/// <summary> /// Raises the <see cref="ColumnChanged" /> event. /// </summary> /// <param name="column">The <see cref="JobCandidateColumn"/> which has raised the event.</param> public virtual void OnColumnChanged(JobCandidateColumn column) { OnColumnChanged(column, null); return; }