DSInternals/Src/DSInternals.Replication.Model/ReplicationCookie.cs

69 lines
1.7 KiB
C#
Raw Normal View History

2016-02-21 09:05:09 +00:00
using System;
2015-12-26 22:44:43 +00:00
namespace DSInternals.Replication.Model
{
/// <summary>
/// USN Vector
/// </summary>
2016-02-21 09:05:09 +00:00
[Serializable]
2015-12-26 22:44:43 +00:00
public sealed class ReplicationCookie
{
public ReplicationCookie(string namingContext)
{
this.NamingContext = namingContext;
}
public ReplicationCookie(string namingContext, Guid invocationId, Int64 highObjectUpdate, Int64 highPropUpdate, Int64 reserved)
{
this.NamingContext = namingContext;
this.InvocationId = invocationId;
this.HighObjUpdate = highObjectUpdate;
this.HighPropUpdate = highPropUpdate;
this.Reserved = reserved;
}
2016-02-21 09:05:09 +00:00
private ReplicationCookie()
{
}
/// <summary>
/// Performs memberwise assignment.
/// </summary>
/// <param name="cookie">The cookie to assign.</param>
public void Assign(ReplicationCookie cookie)
{
this.NamingContext = cookie.NamingContext;
this.InvocationId = cookie.InvocationId;
this.HighObjUpdate = cookie.HighObjUpdate;
this.Reserved = cookie.Reserved;
this.HighPropUpdate = cookie.HighPropUpdate;
}
2015-12-26 22:44:43 +00:00
public string NamingContext
{
get;
2016-02-21 09:05:09 +00:00
set;
2015-12-26 22:44:43 +00:00
}
public Guid InvocationId
{
get;
2016-02-21 09:05:09 +00:00
set;
2015-12-26 22:44:43 +00:00
}
public Int64 HighObjUpdate
{
get;
2016-02-21 09:05:09 +00:00
set;
2015-12-26 22:44:43 +00:00
}
public Int64 Reserved
{
get;
2016-02-21 09:05:09 +00:00
set;
2015-12-26 22:44:43 +00:00
}
public Int64 HighPropUpdate
{
get;
2016-02-21 09:05:09 +00:00
set;
2015-12-26 22:44:43 +00:00
}
}
}