// NameAndAliases returns a list of the command name and all aliases
970818
func (c *Command) NameAndAliases() string {
	return strings.Join(append([]string{c.Name()}, c.Aliases...), ", ")
}
181247
func NameHandler(name string, handler cfg.Handler) *HandlerName {
	return &HandlerName{
		Name:    name,
		Handler: handler,
	}
}
558629
func NameSystems() namer.NameSystems {
	return namer.NameSystems{
		"public":  namer.NewPublicNamer(0),
		"private": namer.NewPrivateNamer(0),
		"raw":     namer.NewRawNamer("", nil),
	}
}
875386
func Names() []string {
	out := []string{}
	for name := range Registry {
		out = append(out, name)
	}
	sort.Strings(out)
	return out
}
1308180
func (t *tree) parseAlias(token item) {
	var name = t.expect(itemIdent, "alias").val
	var lastSegment = name
	for {
		switch next := t.next(); next.typ {
		case itemDotIdent:
			name += next.val
			lastSegment = next.val[1:]
		case itemRightDelim:
			t.aliases[lastSegment] = name
			return
		default:
			t.unexpected(next, "alias. (expected '}')")
		}
	}
}
35004
func (f *FakeDockerClient) idsToNames(ids []string) ([]string, error) {
	names := []string{}
	for _, id := range ids {
		names = append(names, strings.TrimPrefix(f.ContainerMap[id].Name, dockerNamePrefix))
	}
	return names, nil
}
308911
func VisitAllNames(f func(string)) {
	for _, o := range opts {
		for _, n := range o.names {
			f(n)
		}
	}
}
1332889
func (p *PUPolicy) DNSNameACLs() DNSRuleList {
	p.Lock()
	defer p.Unlock()

	return p.DNSACLs.Copy()
}
245666
func (l paramsList) Names() []string {
	var names []string
	for _, item := range l {
		names = append(names, item.Name)
	}
	return names
}
207322
func (k *Kubernetes) filteredNamespaceExists(namespace string) bool {
	ns, err := k.APIConn.GetNamespaceByName(namespace)
	if err != nil {
		return false
	}
	return ns.ObjectMeta.Name == namespace
}
184956
func AllSortedNamedFactories() []ErrorFactory {
	sorter := newSorter(namedFactories)
	sort.Sort(sorter)
	return sorter.data
}
1035536
func (s *PresenceService) DeleteNamespace(namespace string) error {
	if namespace == "" {
		return trace.BadParameter("missing namespace name")
	}
	err := s.Delete(context.TODO(), backend.Key(namespacesPrefix, namespace, paramsPrefix))
	if err != nil {
		if trace.IsNotFound(err) {
			return trace.NotFound("namespace %q is not found", namespace)
		}
	}
	return trace.Wrap(err)
}
578903
func namespacesAreValid(namespace string, userNamespaces []string) bool {
	return len(userNamespaces) == 0 ||
		(len(userNamespaces) == 1 && userNamespaces[0] == namespace)
}
559710
func ListNamespaces() ([]HostComputeNamespace, error) {
	hcnQuery := defaultQuery()
	namespaces, err := ListNamespacesQuery(hcnQuery)
	if err != nil {
		return nil, err
	}
	return namespaces, nil
}
283974
func NameSystems() namer.NameSystems {
	pluralExceptions := map[string]string{
		"Endpoints": "Endpoints",
	}
	return namer.NameSystems{
		"public":             namer.NewPublicNamer(0),
		"private":            namer.NewPrivateNamer(0),
		"raw":                namer.NewRawNamer("", nil),
		"publicPlural":       namer.NewPublicPluralNamer(pluralExceptions),
		"allLowercasePlural": namer.NewAllLowercasePluralNamer(pluralExceptions),
		"lowercaseSingular":  &lowercaseSingularNamer{},
	}
}
630680
func ValidateNamespaceName(name string, prefix bool) (bool, string) {
	return NameIsDNSLabel(name, prefix)
}
532833
func (v *version) Namespaces() NamespaceInformer {
	return &namespaceInformer{factory: v.factory, tweakListOptions: v.tweakListOptions}
}