Example #1
0
        /// <summary>
        /// Populates this <see cref="UnitConversion"/> instance from the data in the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML to get the UnitConversion data from.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// If <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _multiplier = XPathHelper.GetOptNavValueAsDouble(navigator, "multiplier");
            _offset     = XPathHelper.GetOptNavValueAsDouble(navigator, "offset");
        }
        /// <summary>
        /// Populates the data for the range from the XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML node representing the range.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _minimum = XPathHelper.GetOptNavValueAsDouble(navigator, "minimum-range");
            _maximum = XPathHelper.GetOptNavValueAsDouble(navigator, "maximum-range");
        }
        /// <summary>
        /// Populates the data from the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML containing the delivery.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _location       = XPathHelper.GetOptNavValue <Organization>(navigator, "location");
            _timeOfDelivery = XPathHelper.GetOptNavValue <ApproximateDateTime>(navigator, "time-of-delivery");
            _laborDuration  = XPathHelper.GetOptNavValueAsDouble(navigator, "labor-duration");

            _complications.Clear();
            foreach (XPathNavigator complicationNav in navigator.Select("complications"))
            {
                CodableValue complication = new CodableValue();
                complication.ParseXml(complicationNav);
                _complications.Add(complication);
            }

            _anesthesia.Clear();
            foreach (XPathNavigator anesthesiaNav in navigator.Select("anesthesia"))
            {
                CodableValue anesthesia = new CodableValue();
                anesthesia.ParseXml(anesthesiaNav);
                _anesthesia.Add(anesthesia);
            }

            _deliveryMethod = XPathHelper.GetOptNavValue <CodableValue>(navigator, "delivery-method");
            _outcome        = XPathHelper.GetOptNavValue <CodableValue>(navigator, "outcome");
            _baby           = XPathHelper.GetOptNavValue <Baby>(navigator, "baby");
            _note           = XPathHelper.GetOptNavValue(navigator, "note");
        }
Example #4
0
        /// <summary>
        /// Populates the data for the lap from the XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML node representing the lap.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            // activity
            _activity = XPathHelper.GetOptNavValue <CodableValue>(navigator, "activity");

            // title
            _title =
                XPathHelper.GetOptNavValue(navigator, "title");

            // distance
            _distance = XPathHelper.GetOptNavValue <Length>(navigator, "distance");

            // duration
            _duration =
                XPathHelper.GetOptNavValueAsDouble(navigator, "duration");

            // offset
            _offset =
                XPathHelper.GetOptNavValueAsDouble(navigator, "offset");

            // details
            XPathNodeIterator detailsIterator = navigator.Select("detail");

            _details.Clear();
            foreach (XPathNavigator detailsNavigator in detailsIterator)
            {
                ExerciseDetail exerciseDetail = new ExerciseDetail();
                exerciseDetail.ParseXml(detailsNavigator);

                _details.Add(exerciseDetail.Name.Value, exerciseDetail);
            }
        }
Example #5
0
        /// <summary>
        /// Populates this <see cref="PapSession"/> instance from the data in the specified XML.
        /// </summary>
        ///
        /// <param name="typeSpecificXml">
        /// The XML to get the PAP session data from.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// If <paramref name="typeSpecificXml"/> parameter is <b>null</b>.
        /// </exception>
        ///
        /// <exception cref="InvalidOperationException">
        /// If the first node in <paramref name="typeSpecificXml"/> is not
        /// a PAP session node.
        /// </exception>
        ///
        protected override void ParseXml(IXPathNavigable typeSpecificXml)
        {
            Validator.ThrowIfArgumentNull(typeSpecificXml, nameof(typeSpecificXml), Resources.ParseXmlNavNull);

            XPathNavigator itemNav =
                typeSpecificXml.CreateNavigator().SelectSingleNode("pap-session");

            Validator.ThrowInvalidIfNull(itemNav, Resources.PapSessionUnexpectedNode);

            _when = new HealthServiceDateTime();
            _when.ParseXml(itemNav.SelectSingleNode("when"));

            _durationMinutes    = itemNav.SelectSingleNode("duration-minutes").ValueAsDouble;
            _apneaHypopneaIndex = itemNav.SelectSingleNode("apnea-hypopnea-index").ValueAsDouble;

            _apneaIndex              = XPathHelper.GetOptNavValueAsDouble(itemNav, "apnea-index");
            _hypopneaIndex           = XPathHelper.GetOptNavValueAsDouble(itemNav, "hypopnea-index");
            _oxygenDesaturationIndex = XPathHelper.GetOptNavValueAsDouble(itemNav, "oxygen-desaturation-index");

            _pressure          = XPathHelper.GetOptNavValue <PapSessionMeasurements <PressureMeasurement> >(itemNav, "pressure");
            _leakRate          = XPathHelper.GetOptNavValue <PapSessionMeasurements <FlowMeasurement> >(itemNav, "leak-rate");
            _tidalVolume       = XPathHelper.GetOptNavValue <PapSessionMeasurements <VolumeMeasurement> >(itemNav, "tidal-volume");
            _minuteVentilation = XPathHelper.GetOptNavValue <PapSessionMeasurements <VolumeMeasurement> >(itemNav, "minute-ventilation");
            _respiratoryRate   = XPathHelper.GetOptNavValue <PapSessionMeasurements <RespiratoryRateMeasurement> >(itemNav, "respiratory-rate");
        }
Example #6
0
        /// <summary>
        /// Populates this <see cref="CarePlanGoalRange"/> instance from the data in the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML to get the CarePlanGoalRange data from.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// If <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _statusIndicator = XPathHelper.GetOptNavValueAsInt(navigator, "status-indicator").Value;
            _minimumValue    = XPathHelper.GetOptNavValueAsDouble(navigator, "minimum-value");
            _maximumValue    = XPathHelper.GetOptNavValueAsDouble(navigator, "maximum-value");
        }
        /// <summary>
        /// Populates this <see cref="DietaryIntakeItem"/> instance from the data in the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML to get the DietaryIntake data from.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// If <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        /// <exception cref="InvalidOperationException">
        /// If the node identified by the <paramref name="navigator"/> is not a DietaryIntake node.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _foodItem = new CodableValue();
            _foodItem.ParseXml(navigator.SelectSingleNode("food-item"));
            _servingSize        = XPathHelper.GetOptNavValue <CodableValue>(navigator, "serving-size");
            _servingsConsumed   = XPathHelper.GetOptNavValueAsDouble(navigator, "servings-consumed");
            _meal               = XPathHelper.GetOptNavValue <CodableValue>(navigator, "meal");
            _when               = XPathHelper.GetOptNavValue <HealthServiceDateTime>(navigator, "when");
            _energy             = XPathHelper.GetOptNavValue <FoodEnergyValue>(navigator, "energy");
            _energyFromFat      = XPathHelper.GetOptNavValue <FoodEnergyValue>(navigator, "energy-from-fat");
            _totalFat           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "total-fat");
            _saturatedFat       = XPathHelper.GetOptNavValue <WeightValue>(navigator, "saturated-fat");
            _transFat           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "trans-fat");
            _monounsaturatedFat = XPathHelper.GetOptNavValue <WeightValue>(navigator, "monounsaturated-fat");
            _polyunsaturatedFat = XPathHelper.GetOptNavValue <WeightValue>(navigator, "polyunsaturated-fat");
            _protein            = XPathHelper.GetOptNavValue <WeightValue>(navigator, "protein");
            _carbohydrates      = XPathHelper.GetOptNavValue <WeightValue>(navigator, "carbohydrates");
            _dietaryFiber       = XPathHelper.GetOptNavValue <WeightValue>(navigator, "dietary-fiber");
            _sugars             = XPathHelper.GetOptNavValue <WeightValue>(navigator, "sugars");
            _sodium             = XPathHelper.GetOptNavValue <WeightValue>(navigator, "sodium");
            _cholesterol        = XPathHelper.GetOptNavValue <WeightValue>(navigator, "cholesterol");
            _calcium            = XPathHelper.GetOptNavValue <WeightValue>(navigator, "calcium");
            _iron               = XPathHelper.GetOptNavValue <WeightValue>(navigator, "iron");
            _magnesium          = XPathHelper.GetOptNavValue <WeightValue>(navigator, "magnesium");
            _phosphorus         = XPathHelper.GetOptNavValue <WeightValue>(navigator, "phosphorus");
            _potassium          = XPathHelper.GetOptNavValue <WeightValue>(navigator, "potassium");
            _zinc               = XPathHelper.GetOptNavValue <WeightValue>(navigator, "zinc");
            _vitaminARAE        = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-A-RAE");
            _vitaminE           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-E");
            _vitaminD           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-D");
            _vitaminC           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-C");
            _thiamin            = XPathHelper.GetOptNavValue <WeightValue>(navigator, "thiamin");
            _riboflavin         = XPathHelper.GetOptNavValue <WeightValue>(navigator, "riboflavin");
            _niacin             = XPathHelper.GetOptNavValue <WeightValue>(navigator, "niacin");
            _vitaminB6          = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-B-6");
            _folateDFE          = XPathHelper.GetOptNavValue <WeightValue>(navigator, "folate-DFE");
            _vitaminB12         = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-B-12");
            _vitaminK           = XPathHelper.GetOptNavValue <WeightValue>(navigator, "vitamin-K");

            _additionalNutritionFacts.Clear();
            XPathNavigator additionalFactsNav = navigator.SelectSingleNode("additional-nutrition-facts");

            if (additionalFactsNav != null)
            {
                foreach (XPathNavigator nav in additionalFactsNav.Select("nutrition-fact"))
                {
                    NutritionFact nutritionFact = new NutritionFact();
                    nutritionFact.ParseXml(nav);
                    _additionalNutritionFacts.Add(nutritionFact);
                }
            }
        }
        /// <summary>
        /// Populates this <see cref="Exercise"/> instance from the data in the XML.
        /// </summary>
        ///
        /// <param name="typeSpecificXml">
        /// The XML to get the exercise data from.
        /// </param>
        ///
        /// <exception cref="InvalidOperationException">
        /// If the first node in <paramref name="typeSpecificXml"/> is not
        /// an "exercise" node.
        /// </exception>
        ///
        protected override void ParseXml(IXPathNavigable typeSpecificXml)
        {
            XPathNavigator itemNav =
                typeSpecificXml.CreateNavigator().SelectSingleNode("exercise");

            Validator.ThrowInvalidIfNull(itemNav, Resources.ExerciseUnexpectedNode);

            // when
            _when = new ApproximateDateTime();
            _when.ParseXml(itemNav.SelectSingleNode("when"));

            // activity
            _activity = XPathHelper.GetOptNavValue <CodableValue>(itemNav, "activity");

            // title
            _title =
                XPathHelper.GetOptNavValue(itemNav, "title");

            _distance =
                XPathHelper.GetOptNavValue <Length>(itemNav, "distance");

            // duration
            _duration =
                XPathHelper.GetOptNavValueAsDouble(itemNav, "duration");

            // detail
            XPathNodeIterator detailsIterator = itemNav.Select("detail");

            _details.Clear();
            foreach (XPathNavigator detailsNavigator in detailsIterator)
            {
                ExerciseDetail exerciseDetail = new ExerciseDetail();
                exerciseDetail.ParseXml(detailsNavigator);

                _details[exerciseDetail.Name.Value] = exerciseDetail;
            }

            // segment
            XPathNodeIterator segmentsIterator = itemNav.Select("segment");

            _segments.Clear();
            foreach (XPathNavigator segmentsNavigator in segmentsIterator)
            {
                ExerciseSegment exerciseSegment = new ExerciseSegment();
                exerciseSegment.ParseXml(segmentsNavigator);

                _segments.Add(exerciseSegment);
            }
        }
Example #9
0
        /// <summary>
        /// Populates this <see cref="Insight"/> instance from the data in the XML.
        /// </summary>
        ///
        /// <param name="typeSpecificXml">
        /// The XML to get the insight data from.
        /// </param>
        ///
        /// <exception cref="InvalidOperationException">
        /// The first node in <paramref name="typeSpecificXml"/> is not
        /// an insight node.
        /// </exception>
        ///
        protected override void ParseXml(IXPathNavigable typeSpecificXml)
        {
            XPathNavigator itemNav =
                typeSpecificXml.CreateNavigator().SelectSingleNode(
                    "insight");

            Validator.ThrowInvalidIfNull(itemNav, Resources.InsightUnexpectedNode);

            _when = new HealthServiceDateTime();
            _when.ParseXml(itemNav.SelectSingleNode("when"));

            _raisedInsightId = itemNav.SelectSingleNode("raised-insight-id").Value;
            _catalogId       = itemNav.SelectSingleNode("catalog-id").Value;

            _expirationDate = new HealthServiceDateTime();
            _expirationDate.ParseXml(itemNav.SelectSingleNode("expiration-date"));

            _channel         = XPathHelper.GetOptNavValue(itemNav, "channel");
            _algoClass       = XPathHelper.GetOptNavValue(itemNav, "algo-class");
            _directionality  = XPathHelper.GetOptNavValue(itemNav, "directionality");
            _timespanPivot   = XPathHelper.GetOptNavValue(itemNav, "time-span-pivot");
            _comparisonPivot = XPathHelper.GetOptNavValue(itemNav, "comparison-pivot");
            _tonePivot       = XPathHelper.GetOptNavValue(itemNav, "tone-pivot");
            _scopePivot      = XPathHelper.GetOptNavValue(itemNav, "scope-pivot");

            XPathNavigator dataUsedNav = itemNav.SelectSingleNode("data-used-pivot");

            _dataUsedPivot = GetStringList(dataUsedNav, "data-used");

            _annotation = XPathHelper.GetOptNavValue(itemNav, "annotation");
            _strength   = XPathHelper.GetOptNavValueAsDouble(itemNav, "strength");
            _confidence = XPathHelper.GetOptNavValueAsDouble(itemNav, "confidence");
            _origin     = XPathHelper.GetOptNavValue(itemNav, "origin");

            XPathNavigator tagsNav = itemNav.SelectSingleNode("tags");

            _insightTags = GetStringList(tagsNav, "tag");

            XPathNavigator valueNav = itemNav.SelectSingleNode("values");

            _values = GetDictionary(valueNav, "value");

            XPathNavigator callToActionNav = itemNav.SelectSingleNode("links");

            _links = GetDictionary(callToActionNav, "value");
        }
        /// <summary>
        /// Populates this <see cref="ClaimAmounts"/> instance from the data in the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML to get the ClaimAmounts data from.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// If <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _chargedAmount       = XPathHelper.GetDecimal(navigator, "charged-amount");
            _negotiatedAmount    = XPathHelper.GetDecimal(navigator, "negotiated-amount");
            _coPayment           = XPathHelper.GetDecimal(navigator, "copay");
            _deductible          = XPathHelper.GetDecimal(navigator, "deductible");
            _amountNotCovered    = XPathHelper.GetDecimal(navigator, "amount-not-covered");
            _eligibleForBenefits = XPathHelper.GetDecimal(navigator, "eligible-for-benefits");

            _percentageCovered = XPathHelper.GetOptNavValueAsDouble(navigator, "percentage-covered");

            _coinsurance = XPathHelper.GetDecimal(navigator, "coinsurance");
            _miscellaneousAdjustments = XPathHelper.GetDecimal(navigator, "miscellaneous-adjustments");
            _benefitsPaid             = XPathHelper.GetDecimal(navigator, "benefits-paid");
            _patientResponsibility    = XPathHelper.GetDecimal(navigator, "patient-responsibility");
        }
        /// <summary>
        /// Populates the data from the specified XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML containing the vital sign result information.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _title = new CodableValue();
            _title.ParseXml(navigator.SelectSingleNode("title"));

            _value =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "value");

            // <unit>
            _unit =
                XPathHelper.GetOptNavValue <CodableValue>(
                    navigator,
                    "unit");

            // <reference-minimum>
            _referenceMinimum =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "reference-minimum");

            // <reference-maximum>
            _referenceMaximum =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "reference-maximum");

            // <text-value>
            _textValue =
                XPathHelper.GetOptNavValue(
                    navigator,
                    "text-value");

            // <flag>
            _flag =
                XPathHelper.GetOptNavValue <CodableValue>(
                    navigator,
                    "flag");
        }
        /// <summary>
        /// Populates the data for the lab result type from the XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML node representing the lab result type.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _value          = XPathHelper.GetOptNavValueAsDouble(navigator, "value");
            _unit           = XPathHelper.GetOptNavValue <CodableValue>(navigator, "unit");
            _referenceRange = XPathHelper.GetOptNavValue <DoubleRange>(navigator, "reference-range");
            _toxicRange     = XPathHelper.GetOptNavValue <DoubleRange>(navigator, "toxic-range");
            _textValue      = XPathHelper.GetOptNavValue(navigator, "text-value");

            _flag.Clear();
            XPathNodeIterator flagIterator = navigator.Select("flag");

            foreach (XPathNavigator flagNav in flagIterator)
            {
                CodableValue flagValue = new CodableValue();
                flagValue.ParseXml(flagNav);
                _flag.Add(flagValue);
            }
        }
        /// <summary>
        /// Populates the data for the dose value from the XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML node representing the dose value.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is null.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            _description =
                XPathHelper.GetOptNavValue(navigator, "description");

            _exactDose =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "exact-dose");

            _minDose =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "min-dose");

            _maxDose =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "max-dose");
        }
        /// <summary>
        /// Populates the data for the length from the XML.
        /// </summary>
        ///
        /// <param name="navigator">
        /// The XML node representing the length.
        /// </param>
        ///
        /// <exception cref="ArgumentNullException">
        /// The <paramref name="navigator"/> parameter is <b>null</b>.
        /// </exception>
        ///
        public override void ParseXml(XPathNavigator navigator)
        {
            Validator.ThrowIfNavigatorNull(navigator);

            XPathNavigator modeNav =
                navigator.SelectSingleNode("mode");

            _mode.Clear();
            if (modeNav != null)
            {
                _mode.ParseXml(modeNav);
            }

            XPathNavigator distanceNav =
                navigator.SelectSingleNode("distance");

            if (distanceNav != null)
            {
                _distance = new Length();
                _distance.ParseXml(distanceNav);
            }

            _minutes =
                XPathHelper.GetOptNavValueAsDouble(navigator, "minutes");

            int?currentIntensity =
                XPathHelper.GetOptNavValueAsInt(navigator, "intensity");

            if (currentIntensity != null)
            {
                _intensity = (RelativeRating)(int)currentIntensity;
            }

            _peakHr =
                XPathHelper.GetOptNavValueAsInt(navigator, "peak-heartrate");

            _averageHr =
                XPathHelper.GetOptNavValueAsInt(navigator, "avg-heartrate");

            _minHr =
                XPathHelper.GetOptNavValueAsInt(navigator, "min-heartrate");

            _energy =
                XPathHelper.GetOptNavValueAsDouble(navigator, "energy");

            _energyFromFat =
                XPathHelper.GetOptNavValueAsDouble(navigator, "energy-from-fat");

            _peakSpeed =
                XPathHelper.GetOptNavValue <SpeedMeasurement>(
                    navigator,
                    "peak-speed");

            _averageSpeed =
                XPathHelper.GetOptNavValue <SpeedMeasurement>(
                    navigator,
                    "avg-speed");

            _minSpeed =
                XPathHelper.GetOptNavValue <SpeedMeasurement>(
                    navigator,
                    "min-speed");

            _peakPace =
                XPathHelper.GetOptNavValue <PaceMeasurement>(
                    navigator,
                    "peak-pace");

            _averagePace =
                XPathHelper.GetOptNavValue <PaceMeasurement>(
                    navigator,
                    "avg-pace");

            _minPace =
                XPathHelper.GetOptNavValue <PaceMeasurement>(
                    navigator,
                    "min-pace");

            _peakPower =
                XPathHelper.GetOptNavValue <PowerMeasurement>(
                    navigator,
                    "peak-power");

            _averagePower =
                XPathHelper.GetOptNavValue <PowerMeasurement>(
                    navigator,
                    "avg-power");

            _minPower =
                XPathHelper.GetOptNavValue <PowerMeasurement>(
                    navigator,
                    "min-power");

            _peakTorque =
                XPathHelper.GetOptNavValue <TorqueMeasurement>(
                    navigator,
                    "peak-torque");

            _averageTorque =
                XPathHelper.GetOptNavValue <TorqueMeasurement>(
                    navigator,
                    "avg-torque");

            _minTorque =
                XPathHelper.GetOptNavValue <TorqueMeasurement>(
                    navigator,
                    "min-torque");

            _leftRightBalance =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "left-right-balance");

            _peakCadence =
                XPathHelper.GetOptNavValueAsDouble(navigator, "peak-cadence");

            _averageCadence =
                XPathHelper.GetOptNavValueAsDouble(navigator, "avg-cadence");

            _minCadence =
                XPathHelper.GetOptNavValueAsDouble(navigator, "min-cadence");

            _peakTemperature =
                XPathHelper.GetOptNavValue <TemperatureMeasurement>(
                    navigator,
                    "peak-temperature");

            _averageTemperature =
                XPathHelper.GetOptNavValue <TemperatureMeasurement>(
                    navigator,
                    "avg-temperature");

            _minTemperature =
                XPathHelper.GetOptNavValue <TemperatureMeasurement>(
                    navigator,
                    "min-temperature");

            _peakAltitude =
                XPathHelper.GetOptNavValue <AltitudeMeasurement>(
                    navigator,
                    "peak-altitude");

            _averageAltitude =
                XPathHelper.GetOptNavValue <AltitudeMeasurement>(
                    navigator,
                    "avg-altitude");

            _minAltitude =
                XPathHelper.GetOptNavValue <AltitudeMeasurement>(
                    navigator,
                    "min-altitude");

            _elevationGain =
                XPathHelper.GetOptNavValue <Length>(
                    navigator,
                    "elevation-gain");

            _elevationLoss =
                XPathHelper.GetOptNavValue <Length>(
                    navigator,
                    "elevation-loss");

            _numberOfSteps =
                XPathHelper.GetOptNavValueAsInt(
                    navigator,
                    "number-of-steps");

            _numberOfAerobicSteps =
                XPathHelper.GetOptNavValueAsInt(
                    navigator,
                    "number-of-aerobic-steps");

            _aerobicStepMinutes =
                XPathHelper.GetOptNavValueAsDouble(
                    navigator,
                    "aerobic-step-minutes");
        }