pub struct Word {
pub value: String,
pub quote_style: Option<char>,
pub keyword: Keyword,
}
Expand description
A keyword (like SELECT) or an optionally quoted SQL identifier
Fields§
§value: String
The value of the token, without the enclosing quotes, and with the escape sequences (if any) processed (TODO: escapes are not handled)
quote_style: Option<char>
An identifier can be “quoted” (<delimited identifier> in ANSI parlance). The standard and most implementations allow using double quotes for this, but some implementations support other quoting styles as well (e.g. [MS SQL])
keyword: Keyword
If the word was not quoted and it matched one of the known keywords, this will have one of the values from dialect::keywords, otherwise empty
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Word
impl<'de> Deserialize<'de> for Word
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Ord for Word
impl Ord for Word
Source§impl PartialOrd for Word
impl PartialOrd for Word
Source§impl VisitMut for Word
impl VisitMut for Word
fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
impl Eq for Word
impl StructuralPartialEq for Word
Auto Trait Implementations§
impl Freeze for Word
impl RefUnwindSafe for Word
impl Send for Word
impl Sync for Word
impl Unpin for Word
impl UnwindSafe for Word
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)