pub struct Subscription { /* private fields */ }Implementations§
Source§impl Subscription
impl Subscription
pub fn new( diagnostics: Arc<RwLock<ServerDiagnostics>>, subscription_id: u32, publishing_enabled: bool, publishing_interval: Duration, lifetime_counter: u32, keep_alive_counter: u32, priority: u8, ) -> Subscription
pub fn monitored_items_len(&self) -> usize
Sourcepub fn create_monitored_items(
&mut self,
server_state: &ServerState,
address_space: &AddressSpace,
now: &DateTimeUtc,
timestamps_to_return: TimestampsToReturn,
items_to_create: &[MonitoredItemCreateRequest],
) -> Vec<MonitoredItemCreateResult>
pub fn create_monitored_items( &mut self, server_state: &ServerState, address_space: &AddressSpace, now: &DateTimeUtc, timestamps_to_return: TimestampsToReturn, items_to_create: &[MonitoredItemCreateRequest], ) -> Vec<MonitoredItemCreateResult>
Creates monitored items on the specified subscription, returning the creation results
Sourcepub fn modify_monitored_items(
&mut self,
server_state: &ServerState,
address_space: &AddressSpace,
timestamps_to_return: TimestampsToReturn,
items_to_modify: &[MonitoredItemModifyRequest],
) -> Vec<MonitoredItemModifyResult>
pub fn modify_monitored_items( &mut self, server_state: &ServerState, address_space: &AddressSpace, timestamps_to_return: TimestampsToReturn, items_to_modify: &[MonitoredItemModifyRequest], ) -> Vec<MonitoredItemModifyResult>
Modify the specified monitored items, returning a result for each
Sourcepub fn set_monitoring_mode(
&mut self,
monitored_item_id: u32,
monitoring_mode: MonitoringMode,
) -> StatusCode
pub fn set_monitoring_mode( &mut self, monitored_item_id: u32, monitoring_mode: MonitoringMode, ) -> StatusCode
Sets the monitoring mode on one monitored item
Sourcepub fn delete_monitored_items(
&mut self,
items_to_delete: &[u32],
) -> Vec<StatusCode>
pub fn delete_monitored_items( &mut self, items_to_delete: &[u32], ) -> Vec<StatusCode>
Delete the specified monitored items (by item id), returning a status code for each
pub fn get_handles(&self) -> (Vec<u32>, Vec<u32>)
Sourcepub fn set_resend_data(&mut self)
pub fn set_resend_data(&mut self)
Sets the resend data flag which means the next publish request will receive the latest value of every monitored item whether it has changed in this cycle or not.
Sourcepub fn reset_keep_alive_counter(&mut self)
pub fn reset_keep_alive_counter(&mut self)
Reset the keep-alive counter to the maximum keep-alive count of the Subscription. The maximum keep-alive count is set by the Client when the Subscription is created and may be modified using the ModifySubscription Service
Sourcepub fn reset_lifetime_counter(&mut self)
pub fn reset_lifetime_counter(&mut self)
Reset the lifetime counter to the value specified for the life time of the subscription in the create subscription service
Sourcepub fn start_publishing_timer(&mut self)
pub fn start_publishing_timer(&mut self)
Start or restart the publishing timer and decrement the LifetimeCounter Variable.
pub fn subscription_id(&self) -> u32
pub fn lifetime_counter(&self) -> u32
pub fn keep_alive_counter(&self) -> u32
pub fn message_sent(&self) -> bool
pub fn publishing_interval(&self) -> Duration
pub fn max_keep_alive_count(&self) -> u32
pub fn max_lifetime_count(&self) -> u32
pub fn priority(&self) -> u8
Trait Implementations§
Source§impl Clone for Subscription
impl Clone for Subscription
Source§fn clone(&self) -> Subscription
fn clone(&self) -> Subscription
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more