pub enum OwnedObjectId {
Qualified(QualifiedName),
Schema(Identifier),
Cluster(Identifier),
}Expand description
Identifies the object being re-owned by name shape.
Replaces the older convention of stuffing every kind into a
QualifiedName (which forced workarounds like
QualifiedName::new(name, name) for schemas and
QualifiedName::new("__cluster__", name) for publications /
subscriptions). The renderer dispatches on this enum directly.
Variants§
Qualified(QualifiedName)
A schema-qualified object: table, view, MV, sequence, function, procedure, user-type, statistic.
Schema(Identifier)
A schema itself. Rendered as the bare schema name.
Cluster(Identifier)
A cluster-level object — publication or subscription. Rendered as the bare name (no schema qualifier; PG does not schema-qualify these).
Implementations§
Source§impl OwnedObjectId
impl OwnedObjectId
Sourcepub fn render_sql(&self) -> String
pub fn render_sql(&self) -> String
Render the object’s target name for use in
ALTER <kind> <here>{signature} OWNER TO <role>;.
Trait Implementations§
Source§impl Clone for OwnedObjectId
impl Clone for OwnedObjectId
Source§fn clone(&self) -> OwnedObjectId
fn clone(&self) -> OwnedObjectId
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 moreSource§impl Debug for OwnedObjectId
impl Debug for OwnedObjectId
Source§impl<'de> Deserialize<'de> for OwnedObjectId
impl<'de> Deserialize<'de> for OwnedObjectId
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 Display for OwnedObjectId
impl Display for OwnedObjectId
impl Eq for OwnedObjectId
Source§impl PartialEq for OwnedObjectId
impl PartialEq for OwnedObjectId
Source§fn eq(&self, other: &OwnedObjectId) -> bool
fn eq(&self, other: &OwnedObjectId) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for OwnedObjectId
impl Serialize for OwnedObjectId
impl StructuralPartialEq for OwnedObjectId
Auto Trait Implementations§
impl Freeze for OwnedObjectId
impl RefUnwindSafe for OwnedObjectId
impl Send for OwnedObjectId
impl Sync for OwnedObjectId
impl Unpin for OwnedObjectId
impl UnsafeUnpin for OwnedObjectId
impl UnwindSafe for OwnedObjectId
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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