Format implements the NodeFormatter interface.
(ctx *FmtCtx)
| 2655 | |
| 2656 | // Format implements the NodeFormatter interface. |
| 2657 | func (d *DInterval) Format(ctx *FmtCtx) { |
| 2658 | f := ctx.flags |
| 2659 | bareStrings := f.HasFlags(FmtFlags(lex.EncBareStrings)) |
| 2660 | if !bareStrings { |
| 2661 | ctx.WriteByte('\'') |
| 2662 | } |
| 2663 | d.Duration.Format(&ctx.Buffer) |
| 2664 | if !bareStrings { |
| 2665 | ctx.WriteByte('\'') |
| 2666 | } |
| 2667 | } |
| 2668 | |
| 2669 | // Size implements the Datum interface. |
| 2670 | func (d *DInterval) Size() uintptr { |