pub struct ParsedField {
pub rust_name: String,
pub column_name: String,
pub rust_type: String,
pub is_nullable: bool,
pub inner_type: String,
pub is_primary_key: bool,
}Expand description
Represents a field parsed from a generated entity struct.
Fields§
§rust_name: StringRust field name (e.g. “connector_type”)
column_name: StringOriginal DB column name. From #[sqlx(rename = "...")] if present, otherwise same as rust_name.
rust_type: StringFull Rust type as a string (e.g. “Option
is_nullable: boolWhether the type is wrapped in Option
inner_type: StringThe inner type if nullable, or the full type if not
is_primary_key: boolWhether this field is a primary key (#[sqlx_gen(primary_key)])
Trait Implementations§
Source§impl Clone for ParsedField
impl Clone for ParsedField
Source§fn clone(&self) -> ParsedField
fn clone(&self) -> ParsedField
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 ParsedField
impl RefUnwindSafe for ParsedField
impl Send for ParsedField
impl Sync for ParsedField
impl Unpin for ParsedField
impl UnsafeUnpin for ParsedField
impl UnwindSafe for ParsedField
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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