func (ref ostreeReference) PolicyConfigurationNamespaces() []string {
	s := strings.SplitN(ref.image, ":", 2)
	if len(s) != 2 { // Coverage: Should never happen, NewReference above ensures ref.image has a :tag.
		panic(fmt.Sprintf("Internal inconsistency: ref.image value %q does not have a :tag", ref.image))
	}
	name := s[0]
	res := []string{}
	for {
		res = append(res, fmt.Sprintf("%s:%s", ref.repo, name))

		lastSlash := strings.LastIndex(name, "/")
		if lastSlash == -1 {
			break
		}
		name = name[:lastSlash]
	}
	return res
}
func (ref ostreeReference) PolicyConfigurationNamespaces() []string {
	s := strings.SplitN(ref.image, ":", 2)
	if len(s) != 2 { 
		panic(fmt.Sprintf("Internal inconsistency: ref.image value %q does not have a :tag", ref.image))
	}
	name := s[0]
	res := []string{}
	for {
		res = append(res, fmt.Sprintf("%s:%s", ref.repo, name))

		lastSlash := strings.LastIndex(name, "/")
		if lastSlash == -1 {
			break
		}
		name = name[:lastSlash]
	}
	return res
}
func ( ref ostreeReference ) PolicyConfigurationNamespaces ( ) [ ] string { s := strings . SplitN ( ref . image , " " , 2 ) if len ( s ) != 2 { // Coverage: Should never happen, NewReference above ensures ref.image has a :tag. panic ( fmt . Sprintf ( " " , ref . image ) ) } name := s [ 0 ] res := [ ] string { } for { res = append ( res , fmt . Sprintf ( " " , ref . repo , name ) ) lastSlash := strings . LastIndex ( name , " " ) if lastSlash == - 1 { break } name = name [ : lastSlash ] } return res }
// PolicyConfigurationNamespaces returns a list of other policy configuration namespaces to search
// for if explicit configuration for PolicyConfigurationIdentity() is not set.  The list will be processed
// in order, terminating on first match, and an implicit "" is always checked at the end.
// It is STRONGLY recommended for the first element, if any, to be a prefix of PolicyConfigurationIdentity(),
// and each following element to be a prefix of the element preceding it.
PolicyConfigurationNamespaces returns a list of other policy configuration namespaces to search for if explicit configuration for PolicyConfigurationIdentity () is not set . The list will be processed in order terminating on first match and an implicit is always checked at the end . It is STRONGLY recommended for the first element if any to be a prefix of PolicyConfigurationIdentity () and each following element to be a prefix of the element preceding it .