pub struct CreateResourceWatchParams {
pub channel: Uri,
pub uri: Uri,
pub recursive: Option<bool>,
pub excludes: Option<AnyValue>,
pub includes: Option<AnyValue>,
}Expand description
Creates a resource watcher on the receiver’s filesystem.
The receiver allocates an ahp-resource-watch:/<id> channel URI and
returns it on {@link CreateResourceWatchResult.channel}. The caller then
subscribes to that channel to receive
resourceWatch/changed actions over the standard action envelope.
The watch lifecycle is tied to subscription: when every subscriber has
unsubscribed (or the underlying connection drops), the receiver MUST
release the watcher. There is no explicit dispose command — unsubscribe
is the only handle the caller needs.
Like the rest of the resource* family, createResourceWatch is
symmetrical and MAY be sent in either direction. Access is gated through
the same permission flow as resourceRead/resourceWrite.
Fields§
§channel: UriChannel URI this command targets.
uri: UriURI to watch.
recursive: Option<bool>If true, the receiver MUST report changes for descendants of uri.
If false (default), only changes to uri itself — and, when uri
is a directory, its direct children — are reported.
excludes: Option<AnyValue>Glob patterns or paths relative to uri to exclude from reporting.
Wrapped in { items } for forward compatibility.
includes: Option<AnyValue>Glob patterns or paths relative to uri to restrict reporting to.
Omit to report every change under uri subject to excludes.
Wrapped in { items } for forward compatibility.
Trait Implementations§
Source§impl Clone for CreateResourceWatchParams
impl Clone for CreateResourceWatchParams
Source§fn clone(&self) -> CreateResourceWatchParams
fn clone(&self) -> CreateResourceWatchParams
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CreateResourceWatchParams
impl Debug for CreateResourceWatchParams
Source§impl<'de> Deserialize<'de> for CreateResourceWatchParams
impl<'de> Deserialize<'de> for CreateResourceWatchParams
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for CreateResourceWatchParams
impl PartialEq for CreateResourceWatchParams
Source§fn eq(&self, other: &CreateResourceWatchParams) -> bool
fn eq(&self, other: &CreateResourceWatchParams) -> bool
self and other values to be equal, and is used by ==.