예제 #1
0
        /// <summary>
        /// Initialize class
        /// </summary>
        internal IpmiMessage()
        {
            IpmiMessageAttribute[] attributes =
                (IpmiMessageAttribute[])this.GetType().GetCustomAttributes(typeof(IpmiMessageAttribute), true);
            if (attributes.Length != 1)
            {
                throw new InvalidOperationException();
            }

            this.ipmiMessageAttribute = attributes[0];
        }
        /// <summary>
        /// Initialize class
        /// </summary>
        internal IpmiMessage()
        {
            IpmiMessageAttribute[] attributes =
                (IpmiMessageAttribute[])this.GetType().GetCustomAttributes(typeof(IpmiMessageAttribute), true);
            if (attributes.Length != 1)
            {
                throw new InvalidOperationException();
            }

            this.ipmiMessageAttribute = attributes[0];
        }