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

Function serverStreamingWithViewsDSL

http/codegen/websocket_golden_test.go:213–239  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

211}
212
213func serverStreamingWithViewsDSL() {
214 var UserType = ResultType("User", func() {
215 Attributes(func() {
216 Attribute("id", String)
217 Attribute("name", String)
218 Attribute("email", String)
219 })
220 Required("id", "name")
221 View("default", func() {
222 Attribute("id")
223 Attribute("name")
224 Attribute("email")
225 })
226 View("tiny", func() {
227 Attribute("id")
228 })
229 })
230
231 Service("TestService", func() {
232 Method("StreamUserWithViews", func() {
233 StreamingResult(UserType)
234 HTTP(func() {
235 GET("/stream/user/views")
236 })
237 })
238 })
239}
240
241func clientStreamingPrimitiveDSL() {
242 Service("TestService", func() {

Callers

nothing calls this directly

Calls 10

ResultTypeFunction · 0.85
AttributesFunction · 0.85
AttributeFunction · 0.85
RequiredFunction · 0.85
ViewFunction · 0.85
MethodFunction · 0.85
StreamingResultFunction · 0.85
GETFunction · 0.85
ServiceFunction · 0.50
HTTPFunction · 0.50

Tested by

no test coverage detected