/// <summary> /// Initializes a new instance of the <see cref="RequestSetData"/> class. /// </summary> /// <param name="path">Path to the node</param> /// <param name="context">Context associated with the request</param> /// <param name="data">Data to set on the node</param> /// <param name="version">Expected version of data on the node</param> /// <param name="callback">Callback to invoke when the request is completed</param> /// <param name="dataCommand">Indicates whether the data is an encoded command</param> /// <param name="uid">Unique Id to assign to the request</param> public RequestSetData( string path, object context, byte[] data, int version, StatCallbackDelegate callback, bool dataCommand = false, ulong uid = 0) : this(new RequestDefinitions.RequestSetData(path, data, version, dataCommand, MakeUid(uid)), context, callback) { }
/// <summary> /// Initializes a new instance of the <see cref="RequestExists"/> class. /// </summary> /// <param name="request">Request to wrap</param> /// <param name="context">Context associated with the request</param> /// <param name="callback">Callback to invoke when the request is completed</param> public RequestExists(RequestDefinitions.RequestExists request, object context, StatCallbackDelegate callback) : base(request, context) { this.callback = callback; }
/// <summary> /// Initializes a new instance of the <see cref="RequestExists"/> class. /// </summary> /// <param name="path">Path to the node</param> /// <param name="context">Context associated with the request</param> /// <param name="watcher">Optional watcher to set on the node</param> /// <param name="callback">Callback to invoke when the request is completed</param> /// <param name="uid">Unique id to assign to the request</param> public RequestExists(string path, object context, IWatcher watcher, StatCallbackDelegate callback, ulong uid = 0) : this(new RequestDefinitions.RequestExists(path, watcher, MakeUid(uid)), context, callback) { }
/// <summary> /// Initializes a new instance of the <see cref="RequestSetAcl"/> class. /// </summary> /// <param name="path">Path to the node</param> /// <param name="context">Context associated with the request</param> /// <param name="acl">List of <see cref="Acl"/>s that must be set on the nodes</param> /// <param name="version">Expected value of the <c>Aversion</c> on the node</param> /// <param name="callback">Callback to invoke when the request is completed</param> /// <param name="uid">Unique id to assign to the request</param> public RequestSetAcl(string path, object context, IReadOnlyList <Acl> acl, int version, StatCallbackDelegate callback, ulong uid = 0) : this(new RequestDefinitions.RequestSetAcl(path, acl, version, MakeUid(uid)), context, callback) { }