pub struct TypeBridgeConfigSpec { /* private fields */ }Expand description
A strict parsed workspace spec retaining exact source, comments, and spans.
The semantic wire is private and this trusted type implements no deserialization contract.
Implementations§
Source§impl TypeBridgeConfigSpec
impl TypeBridgeConfigSpec
Sourcepub fn parse_yaml(
source: impl Into<String>,
origin: ConfigOrigin,
) -> Result<LocatedConfigSpec, WorkspaceConfigError>
pub fn parse_yaml( source: impl Into<String>, origin: ConfigOrigin, ) -> Result<LocatedConfigSpec, WorkspaceConfigError>
Parse UTF-8 workspace text and permanently attach its origin.
Sourcepub fn from_yaml_bytes(
bytes: &[u8],
origin: ConfigOrigin,
) -> Result<LocatedConfigSpec, WorkspaceConfigError>
pub fn from_yaml_bytes( bytes: &[u8], origin: ConfigOrigin, ) -> Result<LocatedConfigSpec, WorkspaceConfigError>
Parse exact file bytes as UTF-8 and permanently attach their origin.
Sourcepub fn comments(&self) -> &[SchemaComment]
pub fn comments(&self) -> &[SchemaComment]
Return retained source comments in parser order.
Sourcepub const fn fingerprint(&self) -> &DocumentFingerprint
pub const fn fingerprint(&self) -> &DocumentFingerprint
Return the exact authored-source fingerprint.
Sourcepub const fn root(&self) -> &YamlMapping
pub const fn root(&self) -> &YamlMapping
Return the lossless root mapping and its exact spans.
Trait Implementations§
Source§impl Clone for TypeBridgeConfigSpec
impl Clone for TypeBridgeConfigSpec
Source§fn clone(&self) -> TypeBridgeConfigSpec
fn clone(&self) -> TypeBridgeConfigSpec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TypeBridgeConfigSpec
impl Debug for TypeBridgeConfigSpec
impl Eq for TypeBridgeConfigSpec
Source§impl PartialEq for TypeBridgeConfigSpec
impl PartialEq for TypeBridgeConfigSpec
impl StructuralPartialEq for TypeBridgeConfigSpec
Auto Trait Implementations§
impl Freeze for TypeBridgeConfigSpec
impl RefUnwindSafe for TypeBridgeConfigSpec
impl Send for TypeBridgeConfigSpec
impl Sync for TypeBridgeConfigSpec
impl Unpin for TypeBridgeConfigSpec
impl UnsafeUnpin for TypeBridgeConfigSpec
impl UnwindSafe for TypeBridgeConfigSpec
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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