public void AddShiftedByWords(LongArray other, int words) { int otherUsedLen = other.GetUsedLength(); if (otherUsedLen == 0) { return; } int minLen = otherUsedLen + words; if (minLen > m_ints.Length) { m_ints = ResizedInts(minLen); } Add(m_ints, words, other.m_ints, 0, otherUsedLen); }
public virtual bool Equals(LongArray other) { if (this == other) return true; if (null == other) return false; int usedLen = GetUsedLength(); if (other.GetUsedLength() != usedLen) { return false; } for (int i = 0; i < usedLen; i++) { if (m_ints[i] != other.m_ints[i]) { return false; } } return true; }