pub enum GrantObject {
Tables(Vec<String>),
Roles(Vec<String>),
Sequences(Vec<String>),
Schemas(Vec<String>),
Databases(Vec<String>),
Functions(Vec<(String, Option<Vec<String>>)>),
AllTablesInSchema,
Other(String),
}Expand description
v7.39 (read01 round 57) — the object a GRANT names. SPG enforces TABLE privileges; every other object class parses and is accepted as a no-op, so a pg_dump that grants on schemas / sequences / functions still restores.
Variants§
Tables(Vec<String>)
ON [TABLE] a, b — the enforced case.
Roles(Vec<String>)
v7.39 (read01 round 58) — GRANT devs TO alice / REVOKE devs FROM alice: role MEMBERSHIP, which has no ON clause at all. Carries the
granted roles; the grantees are the members.
Sequences(Vec<String>)
v7.39 (read01 round 60) — ON SEQUENCE a, b. A sequence’s meaningful
privileges are SELECT (currval), UPDATE (setval) and USAGE (nextval).
Schemas(Vec<String>)
v7.39 (read01 round 60) — ON SCHEMA public. USAGE / CREATE.
Databases(Vec<String>)
v7.39 (read01 round 60) — ON DATABASE app. CREATE / CONNECT / TEMP.
Functions(Vec<(String, Option<Vec<String>>)>)
v7.39 (read01 round 61) — ON FUNCTION f(int). The names are bare
(SPG keys functions by name); the argument list parses and is dropped.
AllTablesInSchema
v7.39 (read01 round 61) — ON ALL TABLES IN SCHEMA public: expands to
every table at GRANT time, exactly like PG.
Other(String)
ON TYPE / LANGUAGE / …. Carries the object-class word for the no-op
message.
Trait Implementations§
Source§impl Clone for GrantObject
impl Clone for GrantObject
Source§fn clone(&self) -> GrantObject
fn clone(&self) -> GrantObject
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more