Add Lauris paragraph parser.
This commit is contained in:
@@ -30,7 +30,7 @@ namespace zaaReloaded2.Dictionaries
|
||||
/// canonical parameter names, and to assign categories and determine
|
||||
/// which parameters always require the output of reference intervals.
|
||||
/// </summary>
|
||||
class ParameterDictionary : DictionaryBase
|
||||
public class ParameterDictionary : DictionaryBase
|
||||
{
|
||||
#region Public methods
|
||||
|
||||
@@ -49,19 +49,18 @@ namespace zaaReloaded2.Dictionaries
|
||||
/// Looks up the material for a given <paramref name="laurisName"/>.
|
||||
/// </summary>
|
||||
/// <param name="laurisName">Lauris item name to look up.</param>
|
||||
/// <returns><see cref="zaaReloaded2.Models.Materials"/> enum; if no material is
|
||||
/// <returns><see cref="zaaReloaded2.Models.Material"/> enum; if no material is
|
||||
/// found in the dictionary, the default material "S" (serum) is returned.</returns>
|
||||
public Materials GetMaterial(string laurisName)
|
||||
public Material GetMaterial(string laurisName)
|
||||
{
|
||||
string textValue = LookUpValue(laurisName, 2);
|
||||
try
|
||||
{
|
||||
Materials m = (Materials)Enum.Parse(typeof(Materials), textValue, true);
|
||||
return m;
|
||||
return MaterialFactory.FromAbbreviation(textValue);
|
||||
}
|
||||
catch
|
||||
{
|
||||
return Materials.S;
|
||||
return Material.B;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace zaaReloaded2.Dictionaries
|
||||
/// Dictionary that is used to convert Lauris units to canonical
|
||||
/// zaaReloaded2 units.
|
||||
/// </summary>
|
||||
class UnitDictionary : DictionaryBase
|
||||
public class UnitDictionary : DictionaryBase
|
||||
{
|
||||
#region Public methods
|
||||
|
||||
|
||||
Reference in New Issue
Block a user