namespace

package
v0.0.0-...-792cabc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2017 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package namespace is a generated protocol buffer package.

Package namespace defines data model for Kubernetes Namespace.

It is generated from these files:

namespace.proto

It has these top-level messages:

Namespace

Index

Constants

View Source
const (
	// NamespacePrefix is a key prefix under which the current state of every
	// known K8s namespace is stored.
	NamespacePrefix = "k8s/namespace/"
)

Variables

This section is empty.

Functions

func Key

func Key(namespace string) string

Key returns the key under which a configuration for the given namespace should be stored in the data-store.

func KeyPrefix

func KeyPrefix() string

KeyPrefix returns the key prefix used in the data-store to save the current state of every known K8s namespace.

func ParseNamespaceFromKey

func ParseNamespaceFromKey(key string) (namespace string, err error)

ParseNamespaceFromKey parses namespace id from the associated data-store key.

Types

type ID

type ID string

ID used to uniquely represent a K8s Namespace.

func GetID

func GetID(ns *Namespace) ID

GetID returns ID of a namespace.

func (ID) String

func (id ID) String() string

String returns a string representation of a namespace ID.

type Namespace

type Namespace struct {
	// Name of the namespace.
	// Cannot be updated.
	Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
	// A list of labels attached to this namespace.
	// +optional
	Label []*Namespace_Label `protobuf:"bytes,3,rep,name=label" json:"label,omitempty"`
}

Namespace provides a scope for resource names.

func (*Namespace) GetLabel

func (m *Namespace) GetLabel() []*Namespace_Label

func (*Namespace) ProtoMessage

func (*Namespace) ProtoMessage()

func (*Namespace) Reset

func (m *Namespace) Reset()

func (*Namespace) String

func (m *Namespace) String() string

type Namespace_Label

type Namespace_Label struct {
	Key   string `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
}

Label is a key/value pair attached to an object (namespace in this case). Labels are used to organize and to select subsets of objects.

func (*Namespace_Label) ProtoMessage

func (*Namespace_Label) ProtoMessage()

func (*Namespace_Label) Reset

func (m *Namespace_Label) Reset()

func (*Namespace_Label) String

func (m *Namespace_Label) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL