/**
         * Compares for reference equality and value equality.
         */
        public bool equals(EnvironmentalProcessPdu rhs)
        {
            bool ivarsEqual = true;

            if (rhs.GetType() != this.GetType())
            {
                return(false);
            }

            ivarsEqual = base.Equals(rhs);

            if (!(_environementalProcessID.Equals(rhs._environementalProcessID)))
            {
                ivarsEqual = false;
            }
            if (!(_environmentType.Equals(rhs._environmentType)))
            {
                ivarsEqual = false;
            }
            if (!(_modelType == rhs._modelType))
            {
                ivarsEqual = false;
            }
            if (!(_environmentStatus == rhs._environmentStatus))
            {
                ivarsEqual = false;
            }
            if (!(_numberOfEnvironmentRecords == rhs._numberOfEnvironmentRecords))
            {
                ivarsEqual = false;
            }
            if (!(_sequenceNumber == rhs._sequenceNumber))
            {
                ivarsEqual = false;
            }

            if (!(_environmentRecords.Count == rhs._environmentRecords.Count))
            {
                ivarsEqual = false;
            }
            if (ivarsEqual)
            {
                for (int idx = 0; idx < _environmentRecords.Count; idx++)
                {
                    if (!(_environmentRecords[idx].Equals(rhs._environmentRecords[idx])))
                    {
                        ivarsEqual = false;
                    }
                }
            }


            return(ivarsEqual);
        }
        /**
         * Compares for reference equality and value equality.
         */
        public bool equals(EnvironmentalProcessPdu rhs)
        {
            bool ivarsEqual = true;

            if(rhs.GetType() != this.GetType())
                return false;

            ivarsEqual = base.Equals(rhs);

            if( ! (_environementalProcessID.Equals( rhs._environementalProcessID) )) ivarsEqual = false;
            if( ! (_environmentType.Equals( rhs._environmentType) )) ivarsEqual = false;
            if( ! (_modelType == rhs._modelType)) ivarsEqual = false;
            if( ! (_environmentStatus == rhs._environmentStatus)) ivarsEqual = false;
            if( ! (_numberOfEnvironmentRecords == rhs._numberOfEnvironmentRecords)) ivarsEqual = false;
            if( ! (_sequenceNumber == rhs._sequenceNumber)) ivarsEqual = false;

            if( ! (_environmentRecords.Count == rhs._environmentRecords.Count)) ivarsEqual = false;
            if(ivarsEqual)
            {
                for(int idx = 0; idx < _environmentRecords.Count; idx++)
                {
                    if( ! ( _environmentRecords[idx].Equals(rhs._environmentRecords[idx]))) ivarsEqual = false;
                }
            }

            return ivarsEqual;
        }