/// <summary> /// Determines whether the specified <see cref="T:Dt.CalcEngine.CalcCellIdentity" /> /// is equal to the current <see cref="T:Dt.CalcEngine.CalcCellIdentity" />. /// </summary> /// <param name="other"> /// The <see cref="T:Dt.CalcEngine.CalcCellIdentity" /> to compare with the /// current <see cref="T:Dt.CalcEngine.CalcCellIdentity" />. /// </param> /// <returns> /// <see langword="true" /> if the specified <see cref="T:Dt.CalcEngine.CalcCellIdentity" /> /// is equal to the current <see cref="T:Dt.CalcEngine.CalcCellIdentity" />; /// otherwise, <see langword="false" />. /// </returns> protected override bool CompareTo(CalcIdentity other) { CalcExternalCellIdentity objA = other as CalcExternalCellIdentity; if (object.ReferenceEquals(objA, null)) { return(false); } return(((base._source == objA._source) && (this._rowIndex == objA._rowIndex)) && (this._columnIndex == objA._columnIndex)); }
/// <summary> /// Initializes a new instance of the <see cref="T:Dt.CalcEngine.CalcExternalCellIdentity" /> class. /// </summary> /// <param name="cellIdentity"> /// The source <see cref="T:Dt.CalcEngine.CalcExternalCellIdentity" /> /// from which to create the new <see cref="T:Dt.CalcEngine.CalcExternalCellIdentity" />. /// </param> /// <param name="rowOffset"> /// The amount to offset the row index. /// </param> /// <param name="columnOffset"> /// The amount to offset the column index. /// </param> public CalcExternalCellIdentity(CalcExternalCellIdentity cellIdentity, int rowOffset, int columnOffset) : this(cellIdentity.Source, cellIdentity.RowIndex + rowOffset, cellIdentity.ColumnIndex + columnOffset) { }