pub struct JsonFormat {
pub encoding: Option<JsonEncoding>,
}Expand description
The SQL/JSON FORMAT JSON [ENCODING <enc>] specifier (SQL:2016).
The only spellable format is JSON (PostgreSQL rejects FORMAT JSONB at raw
parse), so the struct’s mere presence records “FORMAT JSON was written”; the
optional encoding is the ENCODING tail. PostgreSQL validates the encoding
name against UTF8/UTF16/UTF32 at raw parse (“unrecognized JSON encoding”),
so it is a closed JsonEncoding rather than a free identifier.
Fields§
§encoding: Option<JsonEncoding>Optional encoding for this syntax.
Trait Implementations§
Source§impl Clone for JsonFormat
impl Clone for JsonFormat
Source§fn clone(&self) -> JsonFormat
fn clone(&self) -> JsonFormat
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 moreimpl Copy for JsonFormat
Source§impl Debug for JsonFormat
impl Debug for JsonFormat
Source§impl<'de> Deserialize<'de> for JsonFormat
impl<'de> Deserialize<'de> for JsonFormat
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
impl Eq for JsonFormat
Source§impl Hash for JsonFormat
impl Hash for JsonFormat
Source§impl PartialEq for JsonFormat
impl PartialEq for JsonFormat
Source§impl Render for JsonFormat
impl Render for JsonFormat
Source§fn render(&self, ctx: &RenderCtx<'_>, f: &mut Formatter<'_>) -> Result
fn render(&self, ctx: &RenderCtx<'_>, f: &mut Formatter<'_>) -> Result
Renders FORMAT JSON [ENCODING <enc>]; callers write the leading space.
Source§fn operand_binding_power(&self) -> Option<BindingPower>
fn operand_binding_power(&self) -> Option<BindingPower>
The binding power this node contributes when it appears as an operand, or
None (the default) for a self-delimiting node — an atom, call, or
constructor — that never needs parentheses. Read moreSource§impl Serialize for JsonFormat
impl Serialize for JsonFormat
impl StructuralPartialEq for JsonFormat
Auto Trait Implementations§
impl Freeze for JsonFormat
impl RefUnwindSafe for JsonFormat
impl Send for JsonFormat
impl Sync for JsonFormat
impl Unpin for JsonFormat
impl UnsafeUnpin for JsonFormat
impl UnwindSafe for JsonFormat
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