Get a reference to the logical plan's schema
(&self)
| 65 | impl DdlStatement { |
| 66 | /// Get a reference to the logical plan's schema |
| 67 | pub fn schema(&self) -> &DFSchemaRef { |
| 68 | match self { |
| 69 | DdlStatement::CreateExternalTable(CreateExternalTable { schema, .. }) => { |
| 70 | schema |
| 71 | } |
| 72 | DdlStatement::CreateMemoryTable(CreateMemoryTable { input, .. }) |
| 73 | | DdlStatement::CreateView(CreateView { input, .. }) => input.schema(), |
| 74 | DdlStatement::CreateCatalogSchema(CreateCatalogSchema { schema, .. }) => { |
| 75 | schema |
| 76 | } |
| 77 | DdlStatement::CreateCatalog(CreateCatalog { schema, .. }) => schema, |
| 78 | DdlStatement::CreateIndex(CreateIndex { schema, .. }) => schema, |
| 79 | DdlStatement::DropTable(DropTable { schema, .. }) => schema, |
| 80 | DdlStatement::DropView(DropView { schema, .. }) => schema, |
| 81 | DdlStatement::DropCatalogSchema(DropCatalogSchema { schema, .. }) => schema, |
| 82 | DdlStatement::CreateFunction(CreateFunction { schema, .. }) => schema, |
| 83 | DdlStatement::DropFunction(DropFunction { schema, .. }) => schema, |
| 84 | } |
| 85 | } |
| 86 | |
| 87 | /// Return a descriptive string describing the type of this |
| 88 | /// [`DdlStatement`] |
no outgoing calls
no test coverage detected