pub struct DartFirstClassMap {
pub field_types: HashMap<String, HashMap<String, String>>,
pub root_type: Option<String>,
pub stringy_fields_by_type: HashMap<String, Vec<StringyField>>,
}Expand description
Dart opaque type classification + chain-resolution metadata, mirroring
Swift’s needs to track stringy field accessors on element types for
Vec<T> contains assertions. Unlike Swift, Dart doesn’t distinguish
first-class vs opaque; we just track stringy fields per type.
Fields§
§field_types: HashMap<String, HashMap<String, String>>§root_type: Option<String>§stringy_fields_by_type: HashMap<String, Vec<StringyField>>Per-type readable text accessors. Used by the dart e2e contains
assertion to aggregate every stringy field on a Vec<T> element type.
Implementations§
Source§impl DartFirstClassMap
impl DartFirstClassMap
Sourcepub fn advance(
&self,
owner_type: Option<&str>,
field_name: &str,
) -> Option<String>
pub fn advance( &self, owner_type: Option<&str>, field_name: &str, ) -> Option<String>
Returns the IR Named type that field_name traverses into for the
next chain segment, or None if the field is terminal/scalar/unknown.
Sourcepub fn stringy_fields(&self, type_name: &str) -> Option<&[StringyField]>
pub fn stringy_fields(&self, type_name: &str) -> Option<&[StringyField]>
Returns the list of stringy accessors recorded for type_name, or
None if the type has no recorded stringy fields.
Trait Implementations§
Source§impl Clone for DartFirstClassMap
impl Clone for DartFirstClassMap
Source§fn clone(&self) -> DartFirstClassMap
fn clone(&self) -> DartFirstClassMap
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 DartFirstClassMap
impl Debug for DartFirstClassMap
Source§impl Default for DartFirstClassMap
impl Default for DartFirstClassMap
Source§fn default() -> DartFirstClassMap
fn default() -> DartFirstClassMap
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for DartFirstClassMap
impl RefUnwindSafe for DartFirstClassMap
impl Send for DartFirstClassMap
impl Sync for DartFirstClassMap
impl Unpin for DartFirstClassMap
impl UnsafeUnpin for DartFirstClassMap
impl UnwindSafe for DartFirstClassMap
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