Documentation ¶
Index ¶
- Constants
- Variables
- func AddFormValue(form *url.Values, key string, v string)
- func AddFormValues(form *url.Values, key string, values []string)
- func CreateSpringTreeSelect(message string, name string, tree *SpringTreeSelect, data *SpringBootForm) *survey.Question
- func CreateValueInput(message string, name string, value *SpringValue, data *SpringBootForm) *survey.Question
- func CreateValueSelect(message string, name string, options *SpringOptions, data *SpringBootForm) *survey.Question
- type SpringBootForm
- type SpringBootModel
- func (model *SpringBootModel) CreateSurvey(data *SpringBootForm, advanced bool, batchMode bool) error
- func (model *SpringBootModel) ValidateInput(name string, options *SpringOptions, value string) error
- func (model *SpringBootModel) ValidateTreeInput(name string, options *SpringTreeSelect, values []string) error
- type SpringOption
- type SpringOptions
- type SpringTreeGroup
- type SpringTreeSelect
- type SpringValue
Constants ¶
View Source
const ( OptionGroupId = "group" OptionArtifactId = "artifact" OptionLanguage = "language" OptionJavaVersion = "java-version" OptionBootVersion = "boot-version" OptionPackaging = "packaging" OptionDependency = "dep" OptionDependencyKind = "kind" OptionType = "type" )
Variables ¶
View Source
var (
DefaultDependencyKinds = []string{"Core", "Web", "Template Engines", "SQL", "I/O", "Ops", "Spring Cloud GCP", "Azure", "Cloud Contract", "Cloud AWS", "Cloud Messaging", "Cloud Tracing"}
)
Functions ¶
func CreateSpringTreeSelect ¶
func CreateSpringTreeSelect(message string, name string, tree *SpringTreeSelect, data *SpringBootForm) *survey.Question
func CreateValueInput ¶
func CreateValueInput(message string, name string, value *SpringValue, data *SpringBootForm) *survey.Question
func CreateValueSelect ¶
func CreateValueSelect(message string, name string, options *SpringOptions, data *SpringBootForm) *survey.Question
Types ¶
type SpringBootForm ¶
type SpringBootForm struct { Packaging string Language string JavaVersion string BootVersion string GroupId string ArtifactId string Version string Name string PackageName string Dependencies []string DependencyKinds []string Type string }
func (*SpringBootForm) AddFormValues ¶
func (data *SpringBootForm) AddFormValues(form *url.Values)
func (*SpringBootForm) CreateProject ¶
func (data *SpringBootForm) CreateProject(workDir string) (string, error)
type SpringBootModel ¶
type SpringBootModel struct { Packaging SpringOptions Language SpringOptions JavaVersion SpringOptions BootVersion SpringOptions Type SpringOptions GroupId SpringValue ArtifactId SpringValue Version SpringValue Name SpringValue Description SpringValue PackageName SpringValue Dependencies SpringTreeSelect }
func LoadSpringBoot ¶
func LoadSpringBoot(cacheDir string) (*SpringBootModel, error)
func (*SpringBootModel) CreateSurvey ¶
func (model *SpringBootModel) CreateSurvey(data *SpringBootForm, advanced bool, batchMode bool) error
func (*SpringBootModel) ValidateInput ¶
func (model *SpringBootModel) ValidateInput(name string, options *SpringOptions, value string) error
func (*SpringBootModel) ValidateTreeInput ¶
func (model *SpringBootModel) ValidateTreeInput(name string, options *SpringTreeSelect, values []string) error
type SpringOption ¶
type SpringOptions ¶
type SpringOptions struct { Type string Default string Values []SpringOption }
func (*SpringOptions) StringArray ¶
func (options *SpringOptions) StringArray() []string
type SpringTreeGroup ¶
type SpringTreeGroup struct { Name string Values []SpringOption }
type SpringTreeSelect ¶
type SpringTreeSelect struct { Type string Values []SpringTreeGroup }
func (*SpringTreeSelect) StringArray ¶
func (options *SpringTreeSelect) StringArray() []string
type SpringValue ¶
Click to show internal directories.
Click to hide internal directories.