ui

package
v0.0.18 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2019 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnterServiceNameInteractively

func EnterServiceNameInteractively(defaultValue, promptText string, validateName Validator) (serviceName string)

EnterServiceNameInteractively lets the user enter the name of the service instance to create, defaulting to the provided default value and specifying both the prompt text and validation function for the name

func EnterServicePropertiesInteractively

func EnterServicePropertiesInteractively(svcPlan scv1beta1.ClusterServicePlan) (values map[string]string)

EnterServicePropertiesInteractively lets the user enter the properties specified by the provided plan if not already specified by the passed values

func GetServicePlanNames

func GetServicePlanNames(stringMap map[string]scv1beta1.ClusterServicePlan) (keys []string)

GetServicePlanNames returns the service plan names included in the specified map

func SelectClassInteractively

func SelectClassInteractively(classesByCategory map[string][]scv1beta1.ClusterServiceClass) (class scv1beta1.ClusterServiceClass, serviceType string)

SelectClassInteractively lets the user select target service class from possible options, first filtering by categories then by class name

func SelectPlanNameInteractively

func SelectPlanNameInteractively(plans map[string]scv1beta1.ClusterServicePlan, promptText string) (plan string)

SelectPlanNameInteractively lets the user to select the plan name from possible options, specifying which text should appear in the prompt

Types

type Validator

type Validator func(interface{}) error

Validator is a function that validates that the provided interface is conform to expectations or return an error

Jump to

Keyboard shortcuts

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