Files
LeafWeb/Core/Models/CurveData.cs
T
2015-12-02 12:40:00 -05:00

59 lines
1.3 KiB
C#

using System;
using System.IO;
namespace LeafWeb.Core.Models
{
[Serializable]
public class CurveData
{
private readonly string _curveId;
private readonly CurveParamSet _paramSet1;
private readonly CurveParamSet _paramSet2;
private readonly CurveParamSet _paramSet3;
private readonly CurveParamSet _paramSet4;
public CurveData(StreamReader sr, ref string errMsg, ref int lineNbr)
{
// For each curve in the output file there are four sets of data.
_paramSet1 = new CurveParamSet(sr, ref errMsg, ref lineNbr, ref _curveId);
if (errMsg.Length > 0)
return;
_paramSet2 = new CurveParamSet(sr, ref errMsg, ref lineNbr, ref _curveId);
if (errMsg.Length > 0)
return;
_paramSet3 = new CurveParamSet(sr, ref errMsg, ref lineNbr, ref _curveId);
if (errMsg.Length > 0)
return;
_paramSet4 = new CurveParamSet(sr, ref errMsg, ref lineNbr, ref _curveId);
}
public string GetCurveId()
{
return _curveId;
}
public CurveParamSet CndctFixedCmpPntFixedParams()
{
return _paramSet1;
}
public CurveParamSet CndctFixedCmpPntEstimatedParams()
{
return _paramSet2;
}
public CurveParamSet CndctEstimatedCmpPntFixedParams()
{
return _paramSet3;
}
public CurveParamSet CndctEstimatedCmpPntEstimatedParams()
{
return _paramSet4;
}
}
}