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

            result = result && (this.Id == that.Id);
            result = result && (this.ProdId.TrimOrNullify() == that.ProdId.TrimOrNullify());
            result = result && (this.PackId.TrimOrNullify() == that.PackId.TrimOrNullify());
            result = result && (this.Type.TrimOrNullify() == that.Type.TrimOrNullify());
            result = result && (this.Suppress == that.Suppress);
            return(result);
        }
Beispiel #2
0
        /// <summary>
        ///     Creates a new <see cref="ProductPackRecord" /> object instance that is a shallow-copy of the current object instance.
        /// </summary>
        /// <returns>
        ///     The shallow-copy of the current <see cref="ProductPackRecord" /> object instance.
        /// </returns>
        public ProductPackRecord Clone()
        {
            ProductPackRecord record = new ProductPackRecord();

            record.Id       = this.Id;
            record.AddDate  = this.AddDate;
            record.AddBy    = this.AddBy;
            record.ModDate  = this.ModDate;
            record.ModBy    = this.ModBy;
            record.ProdId   = this.ProdId;
            record.PackId   = this.PackId;
            record.Type     = this.Type;
            record.Suppress = this.Suppress;
            return(record);
        }