pub trait NodeManager: IntoAnyArc + Any {
Show 30 methods
// Required methods
fn owns_node(&self, id: &NodeId) -> bool;
fn name(&self) -> &str;
fn namespaces_for_user(
&self,
context: &RequestContext,
) -> Vec<NamespaceMetadata>;
fn init<'life0, 'life1, 'async_trait>(
&'life0 self,
type_tree: &'life1 mut DefaultTypeTree,
context: ServerContext,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
// Provided methods
fn owns_server_events(&self) -> bool { ... }
fn handle_new_node(&self, parent_id: &ExpandedNodeId) -> bool { ... }
fn resolve_external_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut ExternalReferenceRequest],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn read<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
max_age: f64,
timestamps_to_return: TimestampsToReturn,
nodes_to_read: &'life2 mut [&'life3 mut ReadNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_read_raw_modified<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadRawModifiedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_read_processed<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadProcessedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_read_at_time<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAtTimeDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_read_events<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadEventDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_read_annotations<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAnnotationDataDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait { ... }
fn write<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_write: &'life2 mut [&'life3 mut WriteNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn history_update<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut HistoryUpdateNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn browse<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_browse: &'life2 mut [BrowseNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait { ... }
fn translate_browse_paths_to_node_ids<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut BrowsePathItem<'_>],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn register_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut RegisterNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn unregister_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
_nodes: &'life2 [&'life3 NodeId],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn create_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut CreateMonitoredItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn modify_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemUpdateRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn set_monitoring_mode<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
mode: MonitoringMode,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn delete_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn query<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
request: &'life2 mut QueryRequest,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait { ... }
fn call<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
methods_to_call: &'life2 mut [&'life3 mut MethodCall],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn add_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_add: &'life2 mut [&'life3 mut AddNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn add_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_add: &'life2 mut [&'life3 mut AddReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn delete_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_delete: &'life2 mut [&'life3 mut DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn delete_node_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
to_delete: &'life2 [&'life3 DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
fn delete_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_delete: &'life2 mut [&'life3 mut DeleteReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
}Expand description
Trait for a type that implements logic for responding to requests. Implementations of this trait may make external calls for node information, or do other complex tasks.
Note that each request is passed to every node manager concurrently. It is up to each node manager to avoid responding to requests for nodes managed by a different node manager.
Requests are spawned on the tokio thread pool. Avoid making blocking calls in
methods on this trait. If you need to do blocking work use tokio::spawn_blocking,
though you should use async IO as much as possible.
For a simpler interface see InMemoryNodeManager, use this trait directly if you need to control how all node information is stored.
Required Methods§
Sourcefn owns_node(&self, id: &NodeId) -> bool
fn owns_node(&self, id: &NodeId) -> bool
Return whether this node manager owns the given node, this is used for propagating service-level errors.
If a service returns an error, all nodes it owns will get that error, even if this is a cross node-manager request like Browse.
Sourcefn namespaces_for_user(
&self,
context: &RequestContext,
) -> Vec<NamespaceMetadata>
fn namespaces_for_user( &self, context: &RequestContext, ) -> Vec<NamespaceMetadata>
Namespaces for a given user, used to populate the namespace array. This being a method allows different users to see different namespaces.
Sourcefn init<'life0, 'life1, 'async_trait>(
&'life0 self,
type_tree: &'life1 mut DefaultTypeTree,
context: ServerContext,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn init<'life0, 'life1, 'async_trait>(
&'life0 self,
type_tree: &'life1 mut DefaultTypeTree,
context: ServerContext,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Perform any necessary loading of nodes, should populate the type tree if needed.
Provided Methods§
Sourcefn owns_server_events(&self) -> bool
fn owns_server_events(&self) -> bool
Return whether this node manager owns events on the server. The first node manager that returns true here will be called when reading or updating historical server events.
Sourcefn handle_new_node(&self, parent_id: &ExpandedNodeId) -> bool
fn handle_new_node(&self, parent_id: &ExpandedNodeId) -> bool
Return whether this node should handle requests to create a node for the given parent ID. This is only called if no new node ID is requested, otherwise owns_node is called on the requested node ID.
Returning true here doesn’t mean that creating the new node must succeed, only that if the parent node exists, this node manager would be the one to create the requested node.
Sourcefn resolve_external_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut ExternalReferenceRequest],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn resolve_external_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut ExternalReferenceRequest],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Resolve a list of references given by a different node manager.
Sourcefn read<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
max_age: f64,
timestamps_to_return: TimestampsToReturn,
nodes_to_read: &'life2 mut [&'life3 mut ReadNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn read<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
max_age: f64,
timestamps_to_return: TimestampsToReturn,
nodes_to_read: &'life2 mut [&'life3 mut ReadNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Execute the Read service. This should set results on the given nodes_to_read as needed.
Sourcefn history_read_raw_modified<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadRawModifiedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
fn history_read_raw_modified<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadRawModifiedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
Perform the history read raw modified service. This should write results
to the nodes list of type either HistoryData or HistoryModifiedData
Sourcefn history_read_processed<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadProcessedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
fn history_read_processed<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadProcessedDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
Perform the history read processed service. This should write results
to the nodes list of type HistoryData.
Sourcefn history_read_at_time<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAtTimeDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
fn history_read_at_time<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAtTimeDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
Perform the history read processed service. This should write results
to the nodes list of type HistoryData.
Sourcefn history_read_events<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadEventDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
fn history_read_events<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadEventDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
Perform the history read events service. This should write results
to the nodes list of type HistoryEvent.
Sourcefn history_read_annotations<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAnnotationDataDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
fn history_read_annotations<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
details: &'life2 ReadAnnotationDataDetails,
nodes: &'life3 mut [&'life4 mut HistoryNode],
timestamps_to_return: TimestampsToReturn,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Self: Sync + 'async_trait,
Perform the history read annotations data service. This should write
results to the nodes list of type Annotation.
Sourcefn write<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_write: &'life2 mut [&'life3 mut WriteNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn write<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_write: &'life2 mut [&'life3 mut WriteNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Perform the write service. This should write results
to the nodes_to_write list. The default result is BadNodeIdUnknown
Sourcefn history_update<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut HistoryUpdateNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn history_update<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut HistoryUpdateNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Perform the HistoryUpdate service. This should write result
status codes to the nodes list as appropriate.
Sourcefn browse<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_browse: &'life2 mut [BrowseNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait,
fn browse<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_browse: &'life2 mut [BrowseNode],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait,
Perform the Browse or BrowseNext service.
Sourcefn translate_browse_paths_to_node_ids<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut BrowsePathItem<'_>],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn translate_browse_paths_to_node_ids<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut BrowsePathItem<'_>],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Perform the translate browse paths to node IDs service.
Sourcefn register_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut RegisterNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn register_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes: &'life2 mut [&'life3 mut RegisterNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Perform the register nodes service. The default behavior for this service is to do nothing and pretend the nodes were registered.
Sourcefn unregister_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
_nodes: &'life2 [&'life3 NodeId],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn unregister_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
_nodes: &'life2 [&'life3 NodeId],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Perform the unregister nodes service. The default behavior for this service is to do nothing.
Sourcefn create_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut CreateMonitoredItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn create_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 mut [&'life3 mut CreateMonitoredItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Prepare for monitored item creation, the node manager must take action to sample data for each produced monitored item, according to the parameters. Monitored item parameters have already been revised according to server limits, but the node manager is allowed to further revise sampling interval.
The node manager should also read the initial value of each monitored item, and set the status code if monitored item creation failed.
The node manager is responsible for tracking the subscription no matter what the value of monitoring_mode is, but should only sample if monitoring_mode is not Disabled.
Sourcefn modify_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemUpdateRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn modify_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemUpdateRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Modify monitored items. This method is purely informative for the node manager, to let it modify sampling intervals, apply a new filter, or similar.
Node managers are not required to take any action here, and this method is not allowed to fail.
Sourcefn set_monitoring_mode<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
mode: MonitoringMode,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn set_monitoring_mode<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
mode: MonitoringMode,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Modify monitored items. This method is purely informative for the node manager,
to let it pause or resume sampling. Note that this should not delete context
stored from create_monitored_items, since it may be called again to resume sampling.
The node manager should sample so long as monitoring mode is not Disabled, the difference
between Reporting and Sampling is handled by the server.
Node managers are not required to take any action here, and this method is not allowed to fail.
Sourcefn delete_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn delete_monitored_items<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
items: &'life2 [&'life3 MonitoredItemRef],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Delete monitored items. This method is purely informative for the node manager, to let it stop sampling, or similar.
Node managers are not required to take any action here, and this method is not allowed to fail. Most node managers that implement subscriptions will want to do something with this.
This method may be given monitored items that were never created, or were created for a different node manager. Attempting to delete a monitored item that does not exist is handled elsewhere and should be a no-op here.
Sourcefn query<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
request: &'life2 mut QueryRequest,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait,
fn query<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
request: &'life2 mut QueryRequest,
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: Sync + 'async_trait,
Perform a query on the address space.
All node managers must be able to query in order for the server to support querying.
The node manager should set a continuation point if it reaches limits, but is responsible for not exceeding max_data_sets_to_return and max_references_to_return.
Sourcefn call<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
methods_to_call: &'life2 mut [&'life3 mut MethodCall],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn call<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
methods_to_call: &'life2 mut [&'life3 mut MethodCall],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Call a list of methods.
The node manager should validate the method arguments and set an output error if the arguments are invalid.
The node manager must ensure that argument output lists and method output lists are of the correct length according to the method definition.
Sourcefn add_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_add: &'life2 mut [&'life3 mut AddNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn add_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_add: &'life2 mut [&'life3 mut AddNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Add a list of nodes.
This should create the nodes, or set a failed status as appropriate. If a node was created, the status should be set to Good.
Sourcefn add_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_add: &'life2 mut [&'life3 mut AddReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn add_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_add: &'life2 mut [&'life3 mut AddReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Add a list of references.
This will be given all references where the source or target belongs to this node manager. A reference is considered successfully added if either source_status or target_status are Good.
If you want to explicitly set the reference to failed, set both source and target status. Note that it may already have been added in a different node manager, you are responsible for any cleanup if you do this.
Sourcefn delete_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_delete: &'life2 mut [&'life3 mut DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn delete_nodes<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
nodes_to_delete: &'life2 mut [&'life3 mut DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Delete a list of nodes.
This will be given all nodes that belong to this node manager.
Typically, you also want to implement delete_node_references if
there are other node managers that support deletes.
Sourcefn delete_node_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
to_delete: &'life2 [&'life3 DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn delete_node_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
to_delete: &'life2 [&'life3 DeleteNodeItem],
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Delete references for the given list of nodes.
The node manager should respect delete_target_references.
This is not allowed to fail, you should make it impossible to delete nodes with immutable references.
Sourcefn delete_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_delete: &'life2 mut [&'life3 mut DeleteReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn delete_references<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
context: &'life1 RequestContext,
references_to_delete: &'life2 mut [&'life3 mut DeleteReferenceItem],
) -> Pin<Box<dyn Future<Output = Result<(), StatusCode>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Delete a list of references.
This will be given all references where the source or target belongs to this node manager. A reference is considered successfully added if either source_status or target_status are Good.
If you want to explicitly set the reference to failed, set both source and target status. Note that it may already have been deleted in a different node manager, you are responsible for any cleanup if you do this.