// Copyright (C) Stichting Deltares 2017. All rights reserved.
//
// This file is part of Ringtoets.
//
// Ringtoets is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see .
//
// All names, logos, and references to "Deltares" are registered trademarks of
// Stichting Deltares and remain full property of Stichting Deltares at all times.
// All rights reserved.
using System;
using Core.Common.Base;
using Ringtoets.Common.Data.Calculation;
using Ringtoets.Common.Data.DikeProfiles;
namespace Ringtoets.Common.Data.TestUtil
{
///
/// A simple test calculation that has input parameters containing a
/// property.
///
public class TestCalculationWithForeshoreProfile : Observable,
ICalculation
{
private TestCalculationWithForeshoreProfile(bool hasOutput)
{
InputParameters = new TestCalculationInputWithForeshoreProfile();
HasOutput = hasOutput;
}
public string Name { get; set; }
public bool HasOutput { get; private set; }
public Comment Comments { get; }
///
/// Gets the input parameters of the calculation.
///
public TestCalculationInputWithForeshoreProfile InputParameters { get; }
///
/// Create a calculation with a and output.
///
/// The foreshore profile assigned to the calculation.
/// A with a foreshore and
/// calculation output.
public static TestCalculationWithForeshoreProfile CreateCalculationWithOutput(ForeshoreProfile foreshoreProfile)
{
return new TestCalculationWithForeshoreProfile(true)
{
InputParameters =
{
ForeshoreProfile = foreshoreProfile
}
};
}
///
/// Create a calculation with a and
/// without output.
///
/// The foreshore profile assigned to the calculation.
/// A with a foreshore and
/// without calculation output.
public static TestCalculationWithForeshoreProfile CreateCalculationWithoutOutput(ForeshoreProfile foreshoreProfile)
{
return new TestCalculationWithForeshoreProfile(false)
{
InputParameters =
{
ForeshoreProfile = foreshoreProfile
}
};
}
///
/// Creates a default calculation without a
/// and calculation output.
///
/// A without
/// a foreshore and calculation output.
public static TestCalculationWithForeshoreProfile CreateDefaultCalculation()
{
return new TestCalculationWithForeshoreProfile(false);
}
public void ClearOutput()
{
HasOutput = false;
}
///
/// A simple input class with a .
///
public class TestCalculationInputWithForeshoreProfile : ICalculationInput, IHasForeshoreProfile
{
public void Attach(IObserver observer)
{
throw new NotImplementedException();
}
public void Detach(IObserver observer)
{
throw new NotImplementedException();
}
public void NotifyObservers()
{
throw new NotImplementedException();
}
public ForeshoreProfile ForeshoreProfile { get; set; }
public bool IsForeshoreProfileInputSynchronized { get; }
public void SynchronizeForeshoreProfileInput()
{
throw new NotImplementedException();
}
}
}
}