Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
ReportDoubleAttribute.cs
1using System;
2using System.Xml;
3using Waher.Content;
4
6{
11 {
17 public ReportDoubleAttribute(XmlElement Xml, string AttributeName)
18 : base(Xml, AttributeName)
19 {
20 }
21
27 public override double ParseValue(string s)
28 {
29 if (CommonTypes.TryParse(s, out double Value))
30 return Value;
31 else
32 throw new ArgumentException("Invalid double value: " + s, nameof(s));
33 }
34 }
35}
Helps with parsing of commong data types.
Definition: CommonTypes.cs:15
static bool TryParse(string s, out double Value)
Tries to decode a string encoded double.
Definition: CommonTypes.cs:48
Abstract base class for report attributes.
ReportDoubleAttribute(XmlElement Xml, string AttributeName)
Report Double attribute.
override double ParseValue(string s)
Parses a string representation of a value.