pub struct Node { /* private fields */ }Expand description
Proxy that represents a node that is connected to the server.
Implementations§
Source§impl Node
impl Node
Sourcepub fn add_listener(&self, events: NodeEvents) -> HookId
pub fn add_listener(&self, events: NodeEvents) -> HookId
Register for notifications of node events.
Sourcepub fn remove_listener(&self, hook_id: HookId)
pub fn remove_listener(&self, hook_id: HookId)
Remove a set of event listeners.
Sourcepub fn subscribe_params(&self, ids: &[ParamType]) -> Result<()>
pub fn subscribe_params(&self, ids: &[ParamType]) -> Result<()>
Register for notifications of the specified param types.
Sourcepub fn enum_params(
&self,
seq: u32,
id: Option<ParamType>,
start: u32,
num: u32,
filter: Option<ParamBuilder>,
) -> Result<()>
pub fn enum_params( &self, seq: u32, id: Option<ParamType>, start: u32, num: u32, filter: Option<ParamBuilder>, ) -> Result<()>
Enumerate params (via NodeEvents::param). Set id to None to query all param types.
Sourcepub fn set_param(
&self,
param_id: ParamType,
object_type: ObjectType,
flags: u32,
builder: Box<dyn FnOnce(ObjectBuilder<'_>) -> ObjectBuilder<'_>>,
) -> Result<()>
pub fn set_param( &self, param_id: ParamType, object_type: ObjectType, flags: u32, builder: Box<dyn FnOnce(ObjectBuilder<'_>) -> ObjectBuilder<'_>>, ) -> Result<()>
Set a parameter on the node.
Trait Implementations§
Source§impl Refcounted for Node
impl Refcounted for Node
Source§fn upgrade(this: &Self::WeakRef) -> Option<Self>
fn upgrade(this: &Self::WeakRef) -> Option<Self>
Try to convert a weak reference to a strong reference. If the underlying object isstill
alive, returns a
Some continaing the value. If the underlying object’s strong reference
count dropped to zero, and was thus freed, this returns None.Source§fn downgrade(&self) -> Self::WeakRef
fn downgrade(&self) -> Self::WeakRef
Create a weak reference to the object. This reference does not impact the object’s
lifecycle, and merely allows us the option to try to retrieve the object using
Self::upgrade().
impl Send for Node
impl Sync for Node
Auto Trait Implementations§
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more