[][src]Struct opcua_server::prelude::ByteString

pub struct ByteString {
    pub value: Option<Vec<u8>>,
}

A sequence of octets.

Fields

value: Option<Vec<u8>>

Implementations

impl ByteString[src]

pub fn null() -> ByteString[src]

Create a null string (not the same as an empty string)

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

Test if the string is null

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

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

Test if the string is null or empty

pub fn from_base64(data: &str) -> Option<ByteString>[src]

Creates a byte string from a Base64 encoded string

pub fn as_base64(&self) -> String[src]

Encodes the bytestring as a Base64 encoded string

pub fn substring(&self, min: usize, max: usize) -> Result<ByteString, ()>[src]

This function is meant for use with NumericRange. It creates a substring from this string from min up to and inclusive of max. Note that min must have an index within the string but max is allowed to be beyond the end in which case the remainder of the string is returned (see docs for NumericRange).

Trait Implementations

impl AsRef<[u8]> for ByteString[src]

impl BinaryEncoder<ByteString> for ByteString[src]

impl Clone for ByteString[src]

impl Debug for ByteString[src]

impl Default for ByteString[src]

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

impl Eq for ByteString[src]

impl<'a, T> From<&'a T> for ByteString where
    T: AsRef<[u8]> + ?Sized
[src]

impl From<ByteString> for DataValue[src]

impl From<ByteString> for Identifier[src]

impl From<ByteString> for Variant[src]

impl From<Guid> for ByteString[src]

impl From<Vec<u8>> for ByteString[src]

impl Hash for ByteString[src]

impl Into<ByteString> for Thumbprint[src]

impl Into<String> for ByteString[src]

impl PartialEq<ByteString> for ByteString[src]

impl Serialize for ByteString[src]

impl StructuralEq for ByteString[src]

impl StructuralPartialEq for ByteString[src]

impl<'_> TryFrom<&'_ ByteString> for Guid[src]

type Error = ()

The type returned in the event of a conversion error.

Auto Trait Implementations

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>,