コード例 #1
0
        /// <summary>
        /// Translates the specified clinical payor coverage.
        /// </summary>
        /// <param name="clinicalPayorCoverage">The clinical payor coverage.</param>
        /// <returns>A billing PayorCoverage.</returns>
        public PayorCoverage Translate(PayorCoverageCache clinicalPayorCoverage)
        {
            if (clinicalPayorCoverage == null)
            {
                return null;
            }

            var payor = _payorRepository.GetByKey ( clinicalPayorCoverage.PayorCache.Key );

            var clinicalPayorSubscriber = clinicalPayorCoverage.PayorSubscriberCache;
            var payorSubscriberRelationshipType =
                _lookupValueRepository.GetLookupByWellKnownName<PayorSubscriberRelationshipType> (
                    clinicalPayorSubscriber.PayorSubscriberRelationshipCacheType.WellKnownName );
            var payorSubscriber = new PayorSubscriber (
                clinicalPayorSubscriber.Address,
                clinicalPayorSubscriber.BirthDate,
                clinicalPayorSubscriber.AdministrativeGender,
                clinicalPayorSubscriber.Name,
                payorSubscriberRelationshipType );

            var payorCoverageType =
                _lookupValueRepository.GetLookupByWellKnownName<PayorCoverageType> ( clinicalPayorCoverage.PayorCoverageCacheType.WellKnownName );

            var billingPayorCoverage = new PayorCoverage (
                payor, payorSubscriber, clinicalPayorCoverage.MemberNumber, clinicalPayorCoverage.EffectiveDateRange, payorCoverageType);

            return billingPayorCoverage;
        }
コード例 #2
0
ファイル: PayorCoverage.cs プロジェクト: girish66/REM
 /// <summary>
 /// Equals the specified other.
 /// </summary>
 /// <param name="other">The other.</param>
 /// <returns><c>true</c> if the specified <see cref="System.Object"/> is equal to this instance; otherwise, <c>false</c>.</returns>
 public virtual bool Equals(PayorCoverage other)
 {
     if (ReferenceEquals(null, other))
     {
         return(false);
     }
     if (ReferenceEquals(this, other))
     {
         return(true);
     }
     return(base.Equals(other) && Equals(other.EffectiveCoverageDateRange, EffectiveCoverageDateRange) && Equals(other.MemberNumber, MemberNumber) && Equals(other.Payor, Payor) && Equals(other.PayorSubscriber, PayorSubscriber));
 }
コード例 #3
0
ファイル: PayorCoverage.cs プロジェクト: girish66/REM
        /// <summary>
        /// Determines if the values are equal.
        /// </summary>
        /// <param name="payorCoverage">
        /// The other object.
        /// </param>
        /// <returns>
        /// A boolean denoting equality of the values.
        /// </returns>
        public virtual bool ValuesEqual(PayorCoverage payorCoverage)
        {
            if (payorCoverage == null)
            {
                return(false);
            }

            var valuesEqual =
                Equals(Payor.Key, payorCoverage.Payor.Key) &&
                Equals(PayorSubscriber, payorCoverage.PayorSubscriber) &&
                Equals(MemberNumber, payorCoverage.MemberNumber) &&
                Equals(EffectiveCoverageDateRange, payorCoverage.EffectiveCoverageDateRange);

            return(valuesEqual);
        }
コード例 #4
0
ファイル: PayorCoverage.cs プロジェクト: divyang4481/REM
        /// <summary>
        /// Determines if the values are equal.
        /// </summary>
        /// <param name="payorCoverage">
        /// The other object.
        /// </param>
        /// <returns>
        /// A boolean denoting equality of the values.
        /// </returns>            
        public virtual bool ValuesEqual(PayorCoverage payorCoverage)
        {
            if (payorCoverage == null)
            {
                return false;
            }

            var valuesEqual =
                Equals(Payor.Key, payorCoverage.Payor.Key) &&
                Equals(PayorSubscriber, payorCoverage.PayorSubscriber) &&
                Equals(MemberNumber, payorCoverage.MemberNumber) &&
                Equals(EffectiveCoverageDateRange, payorCoverage.EffectiveCoverageDateRange);

            return valuesEqual;
        }
コード例 #5
0
ファイル: PayorCoverage.cs プロジェクト: divyang4481/REM
 /// <summary>
 /// Equals the specified other.
 /// </summary>
 /// <param name="other">The other.</param>
 /// <returns><c>true</c> if the specified <see cref="System.Object"/> is equal to this instance; otherwise, <c>false</c>.</returns>
 public virtual bool Equals(PayorCoverage other)
 {
     if (ReferenceEquals(null, other))
     {
         return false;
     }
     if (ReferenceEquals(this, other))
     {
         return true;
     }
     return base.Equals(other) && Equals(other.EffectiveCoverageDateRange, EffectiveCoverageDateRange) && Equals(other.MemberNumber, MemberNumber) && Equals(other.Payor, Payor) && Equals(other.PayorSubscriber, PayorSubscriber);
 }