MCPcopy Create free account
hub / github.com/SeaQL/sea-orm / unpack_table_ref

Function unpack_table_ref

sea-orm-codegen/src/util.rs:27–39  ·  view source on GitHub ↗
(table_ref: &TableRef)

Source from the content-addressed store, hash-verified

25pub(crate) const RUST_SPECIAL_KEYWORDS: [&str; 3] = ["crate", "Self", "self"];
26
27pub(crate) fn unpack_table_ref(table_ref: &TableRef) -> String {
28 match table_ref {
29 TableRef::Table(tbl)
30 | TableRef::SchemaTable(_, tbl)
31 | TableRef::DatabaseSchemaTable(_, _, tbl)
32 | TableRef::TableAlias(tbl, _)
33 | TableRef::SchemaTableAlias(_, tbl, _)
34 | TableRef::DatabaseSchemaTableAlias(_, _, tbl, _)
35 | TableRef::SubQuery(_, tbl)
36 | TableRef::ValuesList(_, tbl)
37 | TableRef::FunctionCall(_, tbl) => tbl.to_string(),
38 }
39}

Callers 2

fromMethod · 0.50
transformMethod · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected