public override void InternalToBinary(IBinaryRawWriter writer) { VersionSerializationHelper.EmitVersionByte(writer, VERSION_NUMBER); writer.WriteLong(InsertUTC.ToBinary()); writer.WriteByteArray(Content); writer.WriteGuid(ProjectUID); writer.WriteGuid(MachineUid); writer.WriteInt((int)Operation); writer.WriteInt((int)Origin); }
public bool Equals(SiteModelChangeBufferQueueItem other) { if (ReferenceEquals(null, other)) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(InsertUTC.Equals(other.InsertUTC) && Equals(Content, other.Content) && ProjectUID.Equals(other.ProjectUID) && MachineUid.Equals(other.MachineUid) && Operation == other.Operation && Origin == other.Origin); }
public override int GetHashCode() { unchecked { var hashCode = InsertUTC.GetHashCode(); hashCode = (hashCode * 397) ^ (Content != null ? Content.GetHashCode() : 0); hashCode = (hashCode * 397) ^ ProjectUID.GetHashCode(); hashCode = (hashCode * 397) ^ MachineUid.GetHashCode(); hashCode = (hashCode * 397) ^ (int)Operation; hashCode = (hashCode * 397) ^ (int)Origin; return(hashCode); } }