pub struct ResolvedField {
pub name: String,
pub id: u16,
pub type_name: String,
pub offset: usize,
pub encoded_length: usize,
pub rust_type: String,
pub getter_name: String,
pub setter_name: String,
pub is_optional: bool,
pub is_array: bool,
pub array_length: Option<usize>,
pub primitive_type: Option<PrimitiveType>,
}Expand description
Resolved field information.
Fields§
§name: StringField name.
id: u16Field ID.
type_name: StringType name.
offset: usizeOffset in bytes.
encoded_length: usizeEncoded length in bytes.
rust_type: StringRust type.
getter_name: StringGetter method name.
setter_name: StringSetter method name.
is_optional: boolWhether the field is optional.
is_array: boolWhether the field is an array.
array_length: Option<usize>Array length (if array).
primitive_type: Option<PrimitiveType>Primitive type (if applicable).
Implementations§
Source§impl ResolvedField
impl ResolvedField
Sourcepub fn from_field_def(
field: &FieldDef,
types: &HashMap<String, ResolvedType>,
) -> Self
pub fn from_field_def( field: &FieldDef, types: &HashMap<String, ResolvedType>, ) -> Self
Creates a resolved field from a field definition.
Trait Implementations§
Source§impl Clone for ResolvedField
impl Clone for ResolvedField
Source§fn clone(&self) -> ResolvedField
fn clone(&self) -> ResolvedField
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ResolvedField
impl RefUnwindSafe for ResolvedField
impl Send for ResolvedField
impl Sync for ResolvedField
impl Unpin for ResolvedField
impl UnwindSafe for ResolvedField
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