kubernetes/vendor/sigs.k8s.io/kustomize/kyaml/kio/tree.go

type TreeStructure

const TreeStructurePackage

const TreeStructureGraph

var GraphStructures

type TreeWriter

type TreeWriterField

func (p TreeWriter) packageStructure(nodes []*yaml.RNode) error {}

// branchName takes the root directory and relative path to the directory
// and returns the branch name
func branchName(root, dirRelPath, openAPIFileName string) string {}

// Write writes the ascii tree to p.Writer
func (p TreeWriter) Write(nodes []*yaml.RNode) error {}

type node

func (a node) Len() int      {}

func (a node) Swap(i, j int) {}

func (a node) Less(i, j int) bool {}

// Tree adds this node to the root
func (a node) Tree(root treeprint.Tree) error {}

// graphStructure writes the tree using owners for structure
func (p TreeWriter) graphStructure(nodes []*yaml.RNode) error {}

// nodeToString generates a string to identify the node -- matches ownerToString format
func nodeToString(node *yaml.RNode) (string, error) {}

// ownerToString generate a string to identify the owner -- matches nodeToString format
func ownerToString(node *yaml.RNode) (string, error) {}

// index indexes the Resources by their package
func (p TreeWriter) index(nodes []*yaml.RNode) map[string][]*yaml.RNode {}

func compareNodes(i, j *yaml.RNode) bool {}

// sort sorts the Resources in the index in display order and returns the ordered
// keys for the index
//
// Packages are sorted by package name
// Resources within a package are sorted by: [filename, namespace, name, kind, apiVersion]
func (p TreeWriter) sort(indexByPackage map[string][]*yaml.RNode) []string {}

func (p TreeWriter) doResource(leaf *yaml.RNode, metaString string, branch treeprint.Tree) (treeprint.Tree, error) {}

// getFields looks up p.Fields from leaf and structures them into treeFields.
// TODO(pwittrock): simplify this function
func (p TreeWriter) getFields(leaf *yaml.RNode) (treeFields, error) {}

type treeField

type treeFields

func (nodes treeFields) Len() int {}

func (nodes treeFields) Less(i, j int) bool {}

func (nodes treeFields) Swap(i, j int) {}