codeprinter

package
v0.0.0-...-94ba18c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 2, 2019 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Option

type Option func(p *Printer)

func WithIndentString

func WithIndentString(str string) Option

type Printer

type Printer struct {
	bytes.Buffer
	Pass *analysis.Pass

	Indent      int
	CurrentNode ast.Node
	// contains filtered or unexported fields
}

func NewPrinter

func NewPrinter(pass *analysis.Pass, srcFile []byte, opts ...Option) (p *Printer)

func (*Printer) Print

func (this *Printer) Print(a ...interface{})

func (*Printer) Printf

func (this *Printer) Printf(format string, a ...interface{})

func (*Printer) Println

func (this *Printer) Println(a ...interface{})

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL