conjureplugin

package
v6.74.0 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Publish

func Publish(params ConjureProjectParams, projectDir string, flagVals map[distgo.PublisherFlagName]interface{}, dryRun bool, stdout io.Writer) error

func PublisherFlags

func PublisherFlags() ([]distgo.PublisherFlag, error)

func Run

func Run(params ConjureProjectParams, verify bool, projectDir string, stdout io.Writer) error

Types

type ConjureProjectParam

type ConjureProjectParam struct {
	OutputDir    string
	IRProvider   IRProvider
	IROutputPath string
	// Server will optionally generate server code in addition to client code for services specified in this project.
	Server bool
	// CLI will optionally generate cobra CLI bindings in addition to client code for services specified in this project.
	CLI bool
	// AcceptFuncs will optionally generate lambda based visitor code for unions specified in this project.
	AcceptFuncs bool
	// Publish specifies whether or not this Conjure project should be included in the "publish" operation.
	Publish bool
}

type ConjureProjectParams

type ConjureProjectParams struct {
	SortedKeys []string
	Params     map[string]ConjureProjectParam
}

func (*ConjureProjectParams) OrderedParams

func (p *ConjureProjectParams) OrderedParams() []ConjureProjectParam

type IRProvider

type IRProvider interface {
	IRBytes() ([]byte, error)
	// Generated returns true if the IR provided by this provider is generated from YAML, false otherwise.
	GeneratedFromYAML() bool
}

func NewHTTPIRProvider

func NewHTTPIRProvider(irURL string) IRProvider

NewHTTPIRProvider returns an IRProvider that that provides IR downloaded from the provided URL over HTTP.

func NewLocalFileIRProvider

func NewLocalFileIRProvider(path string) IRProvider

NewLocalFileIRProvider returns an IRProvider that that provides IR from the local file at the specified path.

func NewLocalYAMLIRProvider

func NewLocalYAMLIRProvider(path string, params ...conjureircli.Param) IRProvider

NewLocalYAMLIRProvider returns an IRProvider that provides IR generated from local YAML. The provided path must be a path to a Conjure YAML file or a directory that contains Conjure YAML files.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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