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

            return(string.Format(
                       culture,
                       StringHelper.StringFormatSequence(0, 42, Configuration.FieldSeparator),
                       Id,
                       PrimaryKeyValueStf?.ToDelimitedString(),
                       StaffIdentifierList != null ? string.Join(Configuration.FieldRepeatSeparator, StaffIdentifierList.Select(x => x.ToDelimitedString())) : null,
                       StaffName != null ? string.Join(Configuration.FieldRepeatSeparator, StaffName.Select(x => x.ToDelimitedString())) : null,
                       StaffType != null ? string.Join(Configuration.FieldRepeatSeparator, StaffType.Select(x => x.ToDelimitedString())) : null,
                       AdministrativeSex?.ToDelimitedString(),
                       DateTimeOfBirth.HasValue ? DateTimeOfBirth.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ActiveInactiveFlag,
                       Department != null ? string.Join(Configuration.FieldRepeatSeparator, Department.Select(x => x.ToDelimitedString())) : null,
                       HospitalServiceStf != null ? string.Join(Configuration.FieldRepeatSeparator, HospitalServiceStf.Select(x => x.ToDelimitedString())) : null,
                       Phone != null ? string.Join(Configuration.FieldRepeatSeparator, Phone.Select(x => x.ToDelimitedString())) : null,
                       OfficeHomeAddressBirthplace != null ? string.Join(Configuration.FieldRepeatSeparator, OfficeHomeAddressBirthplace.Select(x => x.ToDelimitedString())) : null,
                       InstitutionActivationDate != null ? string.Join(Configuration.FieldRepeatSeparator, InstitutionActivationDate.Select(x => x.ToDelimitedString())) : null,
                       InstitutionInactivationDate != null ? string.Join(Configuration.FieldRepeatSeparator, InstitutionInactivationDate.Select(x => x.ToDelimitedString())) : null,
                       BackupPersonId != null ? string.Join(Configuration.FieldRepeatSeparator, BackupPersonId.Select(x => x.ToDelimitedString())) : null,
                       EmailAddress != null ? string.Join(Configuration.FieldRepeatSeparator, EmailAddress) : null,
                       PreferredMethodOfContact?.ToDelimitedString(),
                       MaritalStatus?.ToDelimitedString(),
                       JobTitle,
                       JobCodeClass?.ToDelimitedString(),
                       EmploymentStatusCode?.ToDelimitedString(),
                       AdditionalInsuredOnAuto,
                       DriversLicenseNumberStaff?.ToDelimitedString(),
                       CopyAutoIns,
                       AutoInsExpires.HasValue ? AutoInsExpires.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       DateLastDmvReview.HasValue ? DateLastDmvReview.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       DateNextDmvReview.HasValue ? DateNextDmvReview.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       Race?.ToDelimitedString(),
                       EthnicGroup?.ToDelimitedString(),
                       ReactivationApprovalIndicator,
                       Citizenship != null ? string.Join(Configuration.FieldRepeatSeparator, Citizenship.Select(x => x.ToDelimitedString())) : null,
                       DateTimeOfDeath.HasValue ? DateTimeOfDeath.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       DeathIndicator,
                       InstitutionRelationshipTypeCode?.ToDelimitedString(),
                       InstitutionRelationshipPeriod?.ToDelimitedString(),
                       ExpectedReturnDate.HasValue ? ExpectedReturnDate.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       CostCenterCode != null ? string.Join(Configuration.FieldRepeatSeparator, CostCenterCode.Select(x => x.ToDelimitedString())) : null,
                       GenericClassificationIndicator,
                       InactiveReasonCode?.ToDelimitedString(),
                       GenericResourceTypeOrCategory != null ? string.Join(Configuration.FieldRepeatSeparator, GenericResourceTypeOrCategory.Select(x => x.ToDelimitedString())) : null,
                       Religion?.ToDelimitedString(),
                       Signature?.ToDelimitedString()
                       ).TrimEnd(Configuration.FieldSeparator.ToCharArray()));
        }
Example #2
0
        /// <inheritdoc/>
        public string ToDelimitedString()
        {
            CultureInfo culture = CultureInfo.CurrentCulture;

            return(string.Format(
                       culture,
                       StringHelper.StringFormatSequence(0, 13, Configuration.FieldSeparator),
                       Id,
                       SetIdOrg.HasValue ? SetIdOrg.Value.ToString(culture) : null,
                       OrganizationUnitCode?.ToDelimitedString(),
                       OrganizationUnitTypeCode?.ToDelimitedString(),
                       PrimaryOrgUnitIndicator,
                       PractitionerOrgUnitIdentifier?.ToDelimitedString(),
                       HealthCareProviderTypeCode?.ToDelimitedString(),
                       HealthCareProviderClassificationCode?.ToDelimitedString(),
                       HealthCareProviderAreaOfSpecializationCode?.ToDelimitedString(),
                       EffectiveDateRange?.ToDelimitedString(),
                       EmploymentStatusCode?.ToDelimitedString(),
                       BoardApprovalIndicator,
                       PrimaryCarePhysicianIndicator
                       ).TrimEnd(Configuration.FieldSeparator.ToCharArray()));
        }