[][src]Struct opcua_server::prelude::array::Array

pub struct Array {
    pub values: Vec<Variant>,
    pub dimensions: Vec<u32>,
}

An array is a vector of values with an optional number of dimensions. It is expected that the multi-dimensional array is valid, or it might not be encoded or decoded properly. The dimensions should match the number of values, or the array is invalid.

Fields

values: Vec<Variant>

Values are stored sequentially

dimensions: Vec<u32>

Multi dimension array which can contain any scalar type, all the same type. Nested arrays are rejected. Higher rank dimensions are serialized first. For example an array with dimensions [2,2,2] is written in this order - [0,0,0], [0,0,1], [0,1,0], [0,1,1], [1,0,0], [1,0,1], [1,1,0], [1,1,1].

Implementations

impl Array[src]

pub fn new_single<V>(values: V) -> Array where
    V: Into<Vec<Variant>>, 
[src]

pub fn new_multi<V, D>(values: V, dimensions: D) -> Array where
    D: Into<Vec<u32>>,
    V: Into<Vec<Variant>>, 
[src]

pub fn is_valid(&self) -> bool[src]

pub fn has_dimensions(&self) -> bool[src]

pub fn encoding_mask(&self) -> u8[src]

Trait Implementations

impl Clone for Array[src]

impl Debug for Array[src]

impl<'de> Deserialize<'de> for Array[src]

impl From<Array> for Variant[src]

impl PartialEq<Array> for Array[src]

impl Serialize for Array[src]

impl StructuralPartialEq for Array[src]

Auto Trait Implementations

impl RefUnwindSafe for Array

impl Send for Array

impl Sync for Array

impl Unpin for Array

impl UnwindSafe for Array

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,