pub struct PortEncoding {
pub kind: Option<String>,
pub signed: Option<bool>,
pub frame: Option<String>,
pub positioning: Option<String>,
pub source: PortEncodingSource,
}Expand description
One designated port’s encoding. A None field is unknown (null on the wire).
Fields§
§kind: Option<String>§signed: Option<bool>§frame: Option<String>§positioning: Option<String>§source: PortEncodingSourceImplementations§
Source§impl PortEncoding
impl PortEncoding
Sourcepub fn from_stored_value(value: &Value) -> Result<Self, FeagiDataError>
pub fn from_stored_value(value: &Value) -> Result<Self, FeagiDataError>
Parse a stored entry; source is required and must be "wiring" or "author".
Parse an entry an author sends through the API. The server assigns source = "author",
so a source key in the input is rejected.
Sourcepub fn from_flag_fields(fields: &PortEncodingFields) -> Self
pub fn from_flag_fields(fields: &PortEncodingFields) -> Self
Wiring entry holding exactly what one IO flag defines.
Sourcepub fn from_peer_fields(peers: &[PortEncodingFields]) -> Option<Self>
pub fn from_peer_fields(peers: &[PortEncodingFields]) -> Option<Self>
Wiring entry for several IO peers: a field the peers disagree on is None, an agreed
field is kept. None when there are no peers.
Trait Implementations§
Source§impl Clone for PortEncoding
impl Clone for PortEncoding
Source§impl Debug for PortEncoding
impl Debug for PortEncoding
impl Eq for PortEncoding
Source§impl PartialEq for PortEncoding
impl PartialEq for PortEncoding
impl StructuralPartialEq for PortEncoding
Auto Trait Implementations§
impl Forget for PortEncoding
impl Freeze for PortEncoding
impl Move for PortEncoding
impl RefUnwindSafe for PortEncoding
impl Send for PortEncoding
impl Sync for PortEncoding
impl Unpin for PortEncoding
impl UnsafeUnpin for PortEncoding
impl UnwindSafe for PortEncoding
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more