示例#1
0
        /// <summary>
        /// Determine semantic equality between this and <paramref name="other"/>
        /// </summary>
        public override BL SemanticEquals(IAny other)
        {
            var baseEq = base.SemanticEquals(other);

            if (!(bool)baseEq)
            {
                return(baseEq);
            }

            // Null-flavored
            if (this.IsNull && other.IsNull)
            {
                return(true);
            }
            else if (this.IsNull ^ other.IsNull)
            {
                return(false);
            }

            PIVL <T> eivlOther = (PIVL <T>)other;

            if (eivlOther == null)
            {
                return(false);
            }
            else
            {
                return
                    ((eivlOther.Period == null ? this.Period == null : (bool)eivlOther.Period.SemanticEquals(this.Period))
                     &&
                     (eivlOther.Frequency == null ? this.Frequency == null : (bool)eivlOther.Frequency.SemanticEquals(this.Frequency))
                     &&
                     (eivlOther.Phase == null ? this.Phase == null : (bool)eivlOther.Phase.SemanticEquals(this.Phase)));
            }
        }
示例#2
0
        /// <summary>
        /// Determine if this PIVL of T equals another PIVL of T
        /// </summary>
        public bool Equals(PIVL <T> other)
        {
            bool result = false;

            if (other != null)
            {
                result = base.Equals((SXCM <T>)other) &&
                         (other.Phase != null ? other.Phase.Equals(this.Phase) : this.Phase == null) &&
                         (other.Period != null ? other.Period.Equals(this.Period) : this.Period == null) &&
                         (other.Count != null ? other.Count.Equals(this.Count) : this.Count == null) &&
                         other.Alignment == this.Alignment &&
                         other.InstitutionSpecified == this.InstitutionSpecified;
            }
            return(result);
        }
示例#3
0
 /// <summary>
 /// Create a new instance of the GTS class with the specified <paramref name="hull"/>
 /// </summary>
 /// <param name="hull">A PIVL&lt;TS> to set as the hull</param>
 public GTS(PIVL <TS> hull)
     : base()
 {
     this.Hull = hull;
 }