示例#1
0
        /// <inheritdoc/>
        public string ToDelimitedString()
        {
            CultureInfo culture = CultureInfo.CurrentCulture;

            return(string.Format(
                       culture,
                       StringHelper.StringFormatSequence(0, 26, Configuration.FieldSeparator),
                       Id,
                       ActionCode,
                       ActionDateTime.HasValue ? ActionDateTime.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ProblemId?.ToDelimitedString(),
                       ProblemInstanceId?.ToDelimitedString(),
                       EpisodeOfCareId?.ToDelimitedString(),
                       ProblemListPriority.HasValue ? ProblemListPriority.Value.ToString(Consts.NumericFormat, culture) : null,
                       ProblemEstablishedDateTime.HasValue ? ProblemEstablishedDateTime.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       AnticipatedProblemResolutionDateTime.HasValue ? AnticipatedProblemResolutionDateTime.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ActualProblemResolutionDateTime.HasValue ? ActualProblemResolutionDateTime.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ProblemClassification?.ToDelimitedString(),
                       ProblemManagementDiscipline != null ? string.Join(Configuration.FieldRepeatSeparator, ProblemManagementDiscipline.Select(x => x.ToDelimitedString())) : null,
                       ProblemPersistence?.ToDelimitedString(),
                       ProblemConfirmationStatus?.ToDelimitedString(),
                       ProblemLifeCycleStatus?.ToDelimitedString(),
                       ProblemLifeCycleStatusDateTime.HasValue ? ProblemLifeCycleStatusDateTime.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ProblemDateOfOnset.HasValue ? ProblemDateOfOnset.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ProblemOnsetText,
                       ProblemRanking?.ToDelimitedString(),
                       CertaintyOfProblem?.ToDelimitedString(),
                       ProbabilityOfProblem01.HasValue ? ProbabilityOfProblem01.Value.ToString(Consts.NumericFormat, culture) : null,
                       IndividualAwarenessOfProblem?.ToDelimitedString(),
                       ProblemPrognosis?.ToDelimitedString(),
                       IndividualAwarenessOfPrognosis?.ToDelimitedString(),
                       FamilySignificantOtherAwarenessOfProblemPrognosis,
                       SecuritySensitivity?.ToDelimitedString()
                       ).TrimEnd(Configuration.FieldSeparator.ToCharArray()));
        }
示例#2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (Ver != 0)
            {
                hash ^= Ver.GetHashCode();
            }
            hash ^= exceptions_.GetHashCode();
            if (SeverityLevel != 0)
            {
                hash ^= SeverityLevel.GetHashCode();
            }
            if (ProblemId.Length != 0)
            {
                hash ^= ProblemId.GetHashCode();
            }
            hash ^= Properties.GetHashCode();
            hash ^= Measurements.GetHashCode();
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }