pub struct PvArray { /* private fields */ }Expand description
Handle to an array-backed record (waveform/aai/aao). Unlike Pv<T>
this is untyped over the element kind — values are ScalarArrayValue.
Cheap to clone; all clones share state.
Implementations§
Source§impl PvArray
impl PvArray
Sourcepub fn waveform(name: impl Into<String>, data: ScalarArrayValue) -> Self
pub fn waveform(name: impl Into<String>, data: ScalarArrayValue) -> Self
waveform — array record, writable over the wire.
Sourcepub fn aai(name: impl Into<String>, data: ScalarArrayValue) -> Self
pub fn aai(name: impl Into<String>, data: ScalarArrayValue) -> Self
aai — analog array input, read-only over the wire.
Sourcepub fn aao(name: impl Into<String>, data: ScalarArrayValue) -> Self
pub fn aao(name: impl Into<String>, data: ScalarArrayValue) -> Self
aao — analog array output, writable over the wire.
pub fn name(&self) -> &str
Sourcepub async fn set(&self, data: ScalarArrayValue) -> Result<(), PvError>
pub async fn set(&self, data: ScalarArrayValue) -> Result<(), PvError>
Write an array value through the full posting pipeline.
Sourcepub async fn set_alarm(
&self,
severity: i32,
status: i32,
message: &str,
) -> Result<(), PvError>
pub async fn set_alarm( &self, severity: i32, status: i32, message: &str, ) -> Result<(), PvError>
Explicitly set the record’s alarm severity/status/message, independent
of its value. Alarm transitions always post (no MDEL gating, no link
evaluation). A no-op re-set (unchanged alarm) is Ok(()).
Sourcepub async fn get(&self) -> Result<ScalarArrayValue, PvError>
pub async fn get(&self) -> Result<ScalarArrayValue, PvError>
Read the current array value.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PvArray
impl RefUnwindSafe for PvArray
impl Send for PvArray
impl Sync for PvArray
impl Unpin for PvArray
impl UnsafeUnpin for PvArray
impl UnwindSafe for PvArray
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