Exemple #1
0
        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);
        }
Exemple #2
0
 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);
 }
Exemple #3
0
 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);
     }
 }