pub enum FieldType {
Integer,
Real,
Text,
Blob,
Boolean,
Date,
DateTime,
Null,
}Expand description
Column type categories used in GeoPackage / SQLite schemas.
Variants§
Integer
Signed integer (SQLite INTEGER affinity).
Real
IEEE-754 double (SQLite REAL affinity).
Text
UTF-8 text (SQLite TEXT affinity).
Blob
Raw binary (SQLite BLOB affinity).
Boolean
Boolean stored as INTEGER 0/1.
Date
Calendar date stored as TEXT "YYYY-MM-DD".
DateTime
Date+time stored as TEXT "YYYY-MM-DDTHH:MM:SS.sssZ".
Null
SQL NULL / unknown type.
Implementations§
Source§impl FieldType
impl FieldType
Sourcepub fn from_sql_type(type_str: &str) -> Self
pub fn from_sql_type(type_str: &str) -> Self
Derive a FieldType from a SQLite type-name string (case-insensitive).
Unrecognised strings map to FieldType::Text following SQLite type
affinity rules.
Trait Implementations§
impl Copy for FieldType
impl Eq for FieldType
impl StructuralPartialEq for FieldType
Auto Trait Implementations§
impl Freeze for FieldType
impl RefUnwindSafe for FieldType
impl Send for FieldType
impl Sync for FieldType
impl Unpin for FieldType
impl UnsafeUnpin for FieldType
impl UnwindSafe for FieldType
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