コード例 #1
0
ファイル: Form.cs プロジェクト: DoctorMatt47/OOP_Lab_5
 private void additionButton_Click(object sender, EventArgs e)
 {
     TakeBoxes(_left.Matrix, _leftBoxes);
     TakeBoxes(_right.Matrix, _rightBoxes);
     _result = _left.Add(_right.Matrix);
     RefreshResultBoxes();
     if (_left is TimeDecorator timeDecorator)
     {
         timeLabel.Text = timeDecorator.Time + " ms";
     }
 }
コード例 #2
0
 /// <summary>
 /// Calls Add method of MatrixFacade instance.
 /// </summary>
 /// <param name="other">Other matrix to be added.</param>
 /// <returns>New matrix that equals to adddition of this and other matrixes.</returns>
 public virtual Matrix Add(Matrix other)
 {
     return(_facade.Add(other));
 }