MCPcopy
hub / github.com/carvel-dev/ytt / PrintStr

Method PrintStr

pkg/yamlmeta/printer.go:36–40  ·  view source on GitHub ↗
(val interface{})

Source from the content-addressed store, hash-verified

34}
35
36func (p Printer) PrintStr(val interface{}) string {
37 buf := new(bytes.Buffer)
38 p.print(val, "", buf)
39 return buf.String()
40}
41
42func (p Printer) print(val interface{}, indent string, writer io.Writer) {
43 const indentLvl = " "

Callers 15

PrintMethod · 0.95
TestParserDocSetEmptyFunction · 0.45
TestParserDocSetNewlineFunction · 0.45
TestParserOnlyCommentFunction · 0.45
TestParserDocFunction · 0.45
TestParserMapArrayFunction · 0.45
TestParserMapCommentsFunction · 0.45
TestParserArrayCommentsFunction · 0.45
TestParserDocSetCommentsFunction · 0.45

Calls 2

printMethod · 0.95
StringMethod · 0.65

Tested by 15

TestParserDocSetEmptyFunction · 0.36
TestParserDocSetNewlineFunction · 0.36
TestParserOnlyCommentFunction · 0.36
TestParserDocFunction · 0.36
TestParserMapArrayFunction · 0.36
TestParserMapCommentsFunction · 0.36
TestParserArrayCommentsFunction · 0.36
TestParserDocSetCommentsFunction · 0.36