MCPcopy
hub / github.com/operator-framework/operator-sdk / String

Method String

internal/olm/client/status.go:146–166  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

144}
145
146func (s Status) String() string {
147 out := &bytes.Buffer{}
148 tw := tabwriter.NewWriter(out, 8, 4, 4, ' ', 0)
149 fmt.Fprintf(tw, "NAME\tNAMESPACE\tKIND\tSTATUS\n")
150 for _, r := range s.Resources {
151 nn := r.NamespacedName
152 kind := r.GVK.Kind
153 var status string
154 if r.Error != nil {
155 status = r.Error.Error()
156 } else if r.Resource != nil {
157 status = "Installed"
158 } else {
159 status = "Unknown"
160 }
161 fmt.Fprintf(tw, "%s\t%s\t%s\t%s\n", nn.Name, nn.Namespace, kind, status)
162 }
163 tw.Flush()
164
165 return out.String()
166}

Callers 15

NewPrometheusRuleFunction · 0.45
mainFunction · 0.45
NewWatchedSecretsFunction · 0.45
CleanupReleaseMethod · 0.45
AddFunction · 0.45
expandOverrideValuesFunction · 0.45
GenerateFunction · 0.45
prefixLinesFunction · 0.45
GetCodeFragmentsMethod · 0.45
fetchChartDependenciesFunction · 0.45
getPodDefinitionFunction · 0.45

Calls 1

ErrorMethod · 0.45

Tested by 2

cmpTarFilesHelperFunction · 0.36
makeMockMarkedFieldsFunction · 0.36