MCPcopy Create free account
hub / github.com/dolthub/doltgresql / Format

Method Format

postgres/parser/sem/tree/drop.go:468–483  ·  view source on GitHub ↗

Format implements the NodeFormatter interface.

(ctx *FmtCtx)

Source from the content-addressed store, hash-verified

466
467// Format implements the NodeFormatter interface.
468func (node *DropSchema) Format(ctx *FmtCtx) {
469 ctx.WriteString("DROP SCHEMA ")
470 if node.IfExists {
471 ctx.WriteString("IF EXISTS ")
472 }
473 for i := range node.Names {
474 if i > 0 {
475 ctx.WriteString(", ")
476 }
477 ctx.FormatNameP(&node.Names[i])
478 }
479 if node.DropBehavior != DropDefault {
480 ctx.WriteString(" ")
481 ctx.WriteString(node.DropBehavior.String())
482 }
483}

Callers

nothing calls this directly

Calls 3

WriteStringMethod · 0.80
FormatNamePMethod · 0.80
StringMethod · 0.65

Tested by

no test coverage detected