manifest

package
v0.0.0-...-8a61130 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2020 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Marshal

func Marshal(app Application) ([]byte, error)

Types

type Application

type Application struct {
	Name      string `yaml:"name"`
	Version   string `yaml:"version"`
	Endpoints []Endpoint
}

func Unmarshal

func Unmarshal(content []byte) (Application, error)

type Endpoint

type Endpoint struct {
	Path        string   `yaml:"path"`
	Description string   `yaml:"description"`
	Methods     []Method `json:"methods"`
}

type Method

type Method struct {
	Name        string  `yaml:"name"`
	Description string  `yaml:"description"`
	Program     Program `yaml:"program"`
}

type Program

type Program struct {
	Name   string   `yaml:"name"`
	Args   []string `yaml:"args"`
	Stdin  string   `yaml:"stdin"`
	Stdout string   `yaml:"stdout"`
	Stderr string   `yaml:"stderr"`
}

Jump to

Keyboard shortcuts

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