public static void TestGetHashCode() { UInt32 i1 = 123; UInt32 i2 = 654; Assert.NotEqual(0, i1.GetHashCode()); Assert.NotEqual(i1.GetHashCode(), i2.GetHashCode()); }
public override int GetHashCode() { UInt32 tmp = (uint)(VendorId << 16); tmp |= DeviceId; return(tmp.GetHashCode()); }
public override int GetHashCode() { return(mName.GetHashCode() ^ mMaterialIndex.GetHashCode() ^ mVertexFormatIndex.GetHashCode() ^ mVertexBufferIndex.GetHashCode() ^ mIndexBufferIndex.GetHashCode() ^ mPrimitiveType.GetHashCode() ^ mFlags.GetHashCode() ^ mStreamOffset.GetHashCode() ^ mStartVertex.GetHashCode() ^ mStartIndex.GetHashCode() ^ mMinVertexIndex.GetHashCode() ^ mVertexCount.GetHashCode() ^ mPrimitiveCount.GetHashCode() ^ mSkinControllerIndex.GetHashCode() ^ mScaleOffsetIndex.GetHashCode() ^ mJointReferences.GetHashCode() ^ mBounds.GetHashCode() ^ mGeometryStates.GetHashCode() ^ mParentName.GetHashCode() ^ mMirrorPlane.GetHashCode() ^ mOwner.GetHashCode() ); }
public TxOutputKey(UInt256 txHash, UInt32 txOutputIndex) { this._txHash = txHash; this._txOutputIndex = txOutputIndex; this.hashCode = txHash.GetHashCode() ^ txOutputIndex.GetHashCode(); }
public TxKey(UInt256 blockHash, UInt32 txIndex, UInt256 txHash) { this._blockHash = blockHash; this._txIndex = txIndex; this._txHash = txHash; this.hashCode = blockHash.GetHashCode() ^ txIndex.GetHashCode() ^ txHash.GetHashCode(); }
public override int GetHashCode() { return (mVertexSize.GetHashCode() ^ mVertexCount.GetHashCode() ^ mByteOffset.GetHashCode() ^ mSwizzles.GetHashCode() ); }
public UnspentTx(UInt256 blockHash, UInt32 txIndex, UInt256 txHash, ImmutableBitArray unspentOutputs) { this._blockHash = blockHash; this._txIndex = txIndex; this._txHash = txHash; this._unspentOutputs = unspentOutputs; this.notDefault = true; this.hashCode = blockHash.GetHashCode() ^ txIndex.GetHashCode() ^ txHash.GetHashCode() ^ unspentOutputs.GetHashCode(); }
public override int GetHashCode() { return (mName.GetHashCode() ^ mStartIndex.GetHashCode() ^ mMinVertexIndex.GetHashCode() ^ mVertexCount.GetHashCode() ^ mPrimitiveCount.GetHashCode() ); }
public override int GetHashCode() { var hash = 17; hash = hash * 23 + format.GetHashCode(); hash = hash * 23 + w.GetHashCode(); hash = hash * 23 + h.GetHashCode(); hash = hash * 23 + refresh_rate.GetHashCode(); return(hash); }
public override int GetHashCode() { int hash = specialFormat.GetHashCode() * 17; hash = hash * 17 + compCount.GetHashCode(); hash = hash * 17 + compByteWidth.GetHashCode(); hash = hash * 17 + compType.GetHashCode(); hash = hash * 17 + srgbCorrected.GetHashCode(); return(hash); }
public void TestGetHashCode() { try { MyUInt32_1.GetHashCode(); MyUInt32_2.GetHashCode(); MyUInt32_3.GetHashCode(); } catch { Assert.Fail("GetHashCode should not raise an exception here"); } }
public override int GetHashCode() { int hashCode = -855528038; hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Name); hashCode = hashCode * -1521134295 + Format.GetHashCode(); hashCode = hashCode * -1521134295 + NbTuples.GetHashCode(); hashCode = hashCode * -1521134295 + NbValuesPerTuple.GetHashCode(); return(hashCode); }
public override int GetHashCode() { unchecked { int hashCode = Persistent.GetHashCode(); hashCode = (hashCode * 397) ^ Random.GetHashCode(); hashCode = (hashCode * 397) ^ ToSource.GetHashCode(); hashCode = (hashCode * 397) ^ ToDestination.GetHashCode(); hashCode = (hashCode * 397) ^ CtMask.GetHashCode(); hashCode = (hashCode * 397) ^ CtMark.GetHashCode(); return(hashCode); } }
/// <summary> Gets the hash code for the current format. </summary> /// <returns> The hash code. </returns> public override Int32 GetHashCode() { Int32 Hash = FConnectionId.GetHashCode(); Hash = (Hash * 397) ^ FDeviceType.GetHashCode(); Hash = (Hash * 397) ^ FInterval.GetHashCode(); Hash = (Hash * 397) ^ FMode.GetHashCode(); Hash = (Hash * 397) ^ FNotificationsEnabled.GetHashCode(); Hash = (Hash * 397) ^ FNumberOfBytes.GetHashCode(); Hash = (Hash * 397) ^ FRevision.GetHashCode(); Hash = (Hash * 397) ^ FUnit.GetHashCode(); return(Hash); }
public override Int32 GetHashCode() { var hashCode = instructionPointer.GetHashCode() ^ registers.GetHashCode() ^ zeroFlag.GetHashCode(); foreach (var key in dataSegment.Keys) { hashCode ^= dataSegment[key].GetHashCode(); } return(hashCode); }
public override int GetHashCode() { unchecked { int hash = 17; hash = hash * 29 + PrimaryNameServer.GetHashCode(); hash = hash * 29 + Hostmaster.GetHashCode(); hash = hash * 29 + Serial.GetHashCode(); hash = hash * 29 + RefreshSeconds.GetHashCode(); hash = hash * 29 + RetrySeconds.GetHashCode(); hash = hash * 29 + ExpireSeconds.GetHashCode(); hash = hash * 29 + MinimumTTL.GetHashCode(); return(hash); } }
private void RandomSyncedDelivery(Stimulus stim, UInt32 begin, UInt32 end) { Random syncRandom = new Random(randomSeed + begin.GetHashCode() + end.GetHashCode()); List <Interval> bufferIntervals = new List <Interval>(); for (int i = 0; i < stim.stims_per_sound; i++) { StimulusInterval interval; Interval bufferInterval; do { uint duration = (uint)syncRandom.Next((int)(stim.dur_min), (int)(stim.dur_max)); uint buffer = stim.dur_max + stim.interval_min; uint randomStim = ((uint)syncRandom.Next((int)(begin), (int)(end - buffer))); bufferInterval = new Interval(randomStim, randomStim + buffer); interval = new StimulusInterval(stim, randomStim, randomStim + duration); } while (bufferIntervals.Exists(a => a.Overlap(bufferInterval))); stim.stimIntervals.Add(interval); bufferIntervals.Add(bufferInterval); } }
public bool PosTest3() { bool retVal = true; TestLibrary.TestFramework.BeginScenario("PosTest3: the UInt32 instance is the Int32 MaxValue"); try { UInt32 uintA = (UInt32)Int32.MaxValue; Int32 uintB = uintA.GetHashCode(); if (uintB != Int32.MaxValue) { TestLibrary.TestFramework.LogError("005", "the ActualResult is not the ExpectResult"); retVal = false; } } catch (Exception e) { TestLibrary.TestFramework.LogError("006", "Unexpected exception: " + e); retVal = false; } return(retVal); }
public override int GetHashCode() { int hash = 0; hash ^= baseColor.GetHashCode(); hash ^= baseMaskType.GetHashCode(); hash ^= baseMaskParameters.GetHashCode(); hash ^= baseMaskAxis.GetHashCode(); hash ^= sampleMode.GetHashCode(); hash ^= alphaMaskTextureID.GetHashCode(); hash ^= alphaMaskScaleOffset.GetHashCode(); hash ^= normalMapTextureID.GetHashCode(); hash ^= normalMapScaleOffset.GetHashCode(); hash ^= parallaxMapTextureID.GetHashCode(); hash ^= parallaxMapScaleOffset.GetHashCode(); hash ^= roughnessMapTextureID.GetHashCode(); hash ^= roughnessMapScaleOffset.GetHashCode(); hash ^= layerCount.GetHashCode(); for (int i = 0; i < layerCount; ++i) { hash ^= layers[i].GetHashCode(); } return(hash); }
public bool PosTest5() { bool retVal = true; TestLibrary.TestFramework.BeginScenario("PosTest5: the UInt32 instance is less than the Int32 MaxValue"); try { int intA = this.GetInt32(1, Int32.MaxValue); UInt32 uintA = (UInt32)intA; Int32 uintB = uintA.GetHashCode(); if (uintB != intA) { TestLibrary.TestFramework.LogError("009", "the ActualResult is not the ExpectResult"); retVal = false; } } catch (Exception e) { TestLibrary.TestFramework.LogError("010", "Unexpected exception: " + e); retVal = false; } return(retVal); }
public override int GetHashCode() => value.GetHashCode();
public override int GetHashCode() { return(m_Handle.GetHashCode() ^ m_Version.GetHashCode()); }
public override int GetHashCode() { return(Value.GetHashCode()); }
public override int GetHashCode() { return(mNameHash.GetHashCode() ^ mInverseBindPose.GetHashCode()); }
public override int GetHashCode() { return(Id.GetHashCode()); }
public override Int32 GetHashCode() { return(InstructionPointer.GetHashCode() ^ IsTainted.GetHashCode()); }
public override int GetHashCode() { // ReSharper disable NonReadonlyMemberInGetHashCode return(CombineHashCodes(hasValue.GetHashCode(), value.GetHashCode())); // ReSharper restore NonReadonlyMemberInGetHashCode }
public override int GetHashCode() { return(rawType.GetHashCode()); }
override public int GetHashCode() { return(ID.GetHashCode()); }
public override int GetHashCode() { return(m_data.GetHashCode()); }