Integer value element class.
Inheritance: IBaseObject
 public void SumTest()
 {
     int x = new ValueInt(1) + new ValueInt(3);
     Assert.AreEqual(4, x);
     ValueInt y = new ValueInt(1) + new ValueInt(3);
     Assert.AreEqual(4, (int)y);
     Assert.IsTrue(4.Equals(y));
 }
 public void IndependentNumberTest()
 {
     firstAlphabet.Add(new ValueInt(2));
     firstAlphabet.Add(new ValueInt(1));
     firstAlphabet.Add(new ValueInt(3));
     firstAlphabet.Add(new ValueInt(4));
     firstAlphabet[0] = new ValueInt(3);
     Assert.AreEqual(new ValueInt(2), firstAlphabet[0]);
     Assert.AreEqual(new ValueInt(1), firstAlphabet[1]);
     Assert.AreEqual(new ValueInt(3), firstAlphabet[2]);
     Assert.AreEqual(new ValueInt(4), firstAlphabet[3]);
 }
        /// <summary>
        /// The make new chain.
        /// </summary>
        /// <returns>
        /// The <see cref="Chain"/>.
        /// </returns>
        public Chain MakeNewChain()
        {
            var newChain = new Chain(range.Length);

            for (int i = 0; i < range.Length; i++)
            {
                newChain[i] = new ValueInt(range.Data[i].Id);
            }

            chain = (Chain)newChain.Clone();
            return newChain;
        }
        /// <summary>
        /// The equals.
        /// </summary>
        /// <param name="other">
        /// The other element.
        /// </param>
        /// <returns>
        /// The <see cref="bool"/>.
        /// </returns>
        public bool Equals(ValueInt other)
        {
            if (other == null)
            {
                return false;
            }

            return value == other.value;
        }