Esempio n. 1
0
        /// <summary>
        ///     Indicates whether the current <see cref="C4textRecord" /> instance is equal to another <see cref="C4textRecord" /> instance.
        /// </summary>
        /// <param name="that">
        ///     The <see cref="C4textRecord" /> instance to be compared against this instance.
        /// </param>
        /// <returns>
        ///     True if both instances are considered equal; otherwise, false.
        /// </returns>
        public Boolean Equals(C4textRecord that)
        {
            Boolean result = true;

            result = result && (this.Id.TrimOrNullify() == that.Id.TrimOrNullify());
            result = result && (this.Type.TrimOrNullify() == that.Type.TrimOrNullify());
            result = result && (this.OwnerId.TrimOrNullify() == that.OwnerId.TrimOrNullify());
            result = result && (this.Body.TrimOrNullify() == that.Body.TrimOrNullify());
            result = result && (this.Rtf.TrimOrNullify() == that.Rtf.TrimOrNullify());
            result = result && (this.Html.TrimOrNullify() == that.Html.TrimOrNullify());
            result = result && (this.OwnerUrl.TrimOrNullify() == that.OwnerUrl.TrimOrNullify());
            return(result);
        }
Esempio n. 2
0
        /// <summary>
        ///     Creates a new <see cref="C4textRecord" /> object instance that is a shallow-copy of the current object instance.
        /// </summary>
        /// <returns>
        ///     The shallow-copy of the current <see cref="C4textRecord" /> object instance.
        /// </returns>
        public C4textRecord Clone()
        {
            C4textRecord record = new C4textRecord();

            record.Id       = this.Id;
            record.AddDate  = this.AddDate;
            record.AddBy    = this.AddBy;
            record.ModDate  = this.ModDate;
            record.ModBy    = this.ModBy;
            record.RcvDate  = this.RcvDate;
            record.RcvFrom  = this.RcvFrom;
            record.Type     = this.Type;
            record.OwnerId  = this.OwnerId;
            record.Body     = this.Body;
            record.Rtf      = this.Rtf;
            record.Html     = this.Html;
            record.OwnerUrl = this.OwnerUrl;
            return(record);
        }