MCPcopy Create free account
hub / github.com/goadesign/goa / NewAPIExpr

Function NewAPIExpr

expr/api.go:117–126  ·  view source on GitHub ↗

NewAPIExpr initializes an API expression.

(name string, dsl func())

Source from the content-addressed store, hash-verified

115
116// NewAPIExpr initializes an API expression.
117func NewAPIExpr(name string, dsl func()) *APIExpr {
118 return &APIExpr{
119 Name: name,
120 HTTP: new(HTTPExpr),
121 GRPC: new(GRPCExpr),
122 JSONRPC: new(JSONRPCExpr),
123 DSLFunc: dsl,
124 ExampleGenerator: NewRandom(name),
125 }
126}
127
128// Schemes returns the list of transport schemes used by all the API servers.
129// The possible values for the elements of the returned slice are "http",

Callers 6

APIFunction · 0.92
runDSLFunction · 0.92
RunDSLFunction · 0.92
initDSLFunction · 0.92
WalkSetsMethod · 0.85
ResetDSLFunction · 0.85

Calls 1

NewRandomFunction · 0.85

Tested by 1

runDSLFunction · 0.74