unmarshal_test.go 87 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218
  1. package query_test
  2. import (
  3. "bytes"
  4. "encoding/json"
  5. "encoding/xml"
  6. "fmt"
  7. "io"
  8. "io/ioutil"
  9. "net/http"
  10. "net/url"
  11. "testing"
  12. "time"
  13. "github.com/aws/aws-sdk-go/aws"
  14. "github.com/aws/aws-sdk-go/aws/client"
  15. "github.com/aws/aws-sdk-go/aws/client/metadata"
  16. "github.com/aws/aws-sdk-go/aws/request"
  17. "github.com/aws/aws-sdk-go/aws/signer/v4"
  18. "github.com/aws/aws-sdk-go/awstesting"
  19. "github.com/aws/aws-sdk-go/awstesting/unit"
  20. "github.com/aws/aws-sdk-go/private/protocol"
  21. "github.com/aws/aws-sdk-go/private/protocol/query"
  22. "github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil"
  23. "github.com/aws/aws-sdk-go/private/util"
  24. "github.com/stretchr/testify/assert"
  25. )
  26. var _ bytes.Buffer // always import bytes
  27. var _ http.Request
  28. var _ json.Marshaler
  29. var _ time.Time
  30. var _ xmlutil.XMLNode
  31. var _ xml.Attr
  32. var _ = ioutil.Discard
  33. var _ = util.Trim("")
  34. var _ = url.Values{}
  35. var _ = io.EOF
  36. var _ = aws.String
  37. var _ = fmt.Println
  38. func init() {
  39. protocol.RandReader = &awstesting.ZeroReader{}
  40. }
  41. //The service client's operations are safe to be used concurrently.
  42. // It is not safe to mutate any of the client's properties though.
  43. type OutputService1ProtocolTest struct {
  44. *client.Client
  45. }
  46. // New creates a new instance of the OutputService1ProtocolTest client with a session.
  47. // If additional configuration is needed for the client instance use the optional
  48. // aws.Config parameter to add your extra config.
  49. //
  50. // Example:
  51. // // Create a OutputService1ProtocolTest client from just a session.
  52. // svc := outputservice1protocoltest.New(mySession)
  53. //
  54. // // Create a OutputService1ProtocolTest client with additional configuration
  55. // svc := outputservice1protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  56. func NewOutputService1ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService1ProtocolTest {
  57. c := p.ClientConfig("outputservice1protocoltest", cfgs...)
  58. return newOutputService1ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  59. }
  60. // newClient creates, initializes and returns a new service client instance.
  61. func newOutputService1ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService1ProtocolTest {
  62. svc := &OutputService1ProtocolTest{
  63. Client: client.New(
  64. cfg,
  65. metadata.ClientInfo{
  66. ServiceName: "outputservice1protocoltest",
  67. SigningRegion: signingRegion,
  68. Endpoint: endpoint,
  69. APIVersion: "",
  70. },
  71. handlers,
  72. ),
  73. }
  74. // Handlers
  75. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  76. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  77. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  78. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  79. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  80. return svc
  81. }
  82. // newRequest creates a new request for a OutputService1ProtocolTest operation and runs any
  83. // custom request initialization.
  84. func (c *OutputService1ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  85. req := c.NewRequest(op, params, data)
  86. return req
  87. }
  88. const opOutputService1TestCaseOperation1 = "OperationName"
  89. // OutputService1TestCaseOperation1Request generates a "aws/request.Request" representing the
  90. // client's request for the OutputService1TestCaseOperation1 operation. The "output" return
  91. // value can be used to capture response data after the request's "Send" method
  92. // is called.
  93. //
  94. // See OutputService1TestCaseOperation1 for usage and error information.
  95. //
  96. // Creating a request object using this method should be used when you want to inject
  97. // custom logic into the request's lifecycle using a custom handler, or if you want to
  98. // access properties on the request object before or after sending the request. If
  99. // you just want the service response, call the OutputService1TestCaseOperation1 method directly
  100. // instead.
  101. //
  102. // Note: You must call the "Send" method on the returned request object in order
  103. // to execute the request.
  104. //
  105. // // Example sending a request using the OutputService1TestCaseOperation1Request method.
  106. // req, resp := client.OutputService1TestCaseOperation1Request(params)
  107. //
  108. // err := req.Send()
  109. // if err == nil { // resp is now filled
  110. // fmt.Println(resp)
  111. // }
  112. //
  113. func (c *OutputService1ProtocolTest) OutputService1TestCaseOperation1Request(input *OutputService1TestShapeOutputService1TestCaseOperation1Input) (req *request.Request, output *OutputService1TestShapeOutputService1TestCaseOperation1Output) {
  114. op := &request.Operation{
  115. Name: opOutputService1TestCaseOperation1,
  116. HTTPPath: "/",
  117. }
  118. if input == nil {
  119. input = &OutputService1TestShapeOutputService1TestCaseOperation1Input{}
  120. }
  121. req = c.newRequest(op, input, output)
  122. output = &OutputService1TestShapeOutputService1TestCaseOperation1Output{}
  123. req.Data = output
  124. return
  125. }
  126. // OutputService1TestCaseOperation1 API operation for .
  127. //
  128. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  129. // with awserr.Error's Code and Message methods to get detailed information about
  130. // the error.
  131. //
  132. // See the AWS API reference guide for 's
  133. // API operation OutputService1TestCaseOperation1 for usage and error information.
  134. func (c *OutputService1ProtocolTest) OutputService1TestCaseOperation1(input *OutputService1TestShapeOutputService1TestCaseOperation1Input) (*OutputService1TestShapeOutputService1TestCaseOperation1Output, error) {
  135. req, out := c.OutputService1TestCaseOperation1Request(input)
  136. err := req.Send()
  137. return out, err
  138. }
  139. type OutputService1TestShapeOutputService1TestCaseOperation1Input struct {
  140. _ struct{} `type:"structure"`
  141. }
  142. type OutputService1TestShapeOutputService1TestCaseOperation1Output struct {
  143. _ struct{} `type:"structure"`
  144. Char *string `type:"character"`
  145. Double *float64 `type:"double"`
  146. FalseBool *bool `type:"boolean"`
  147. Float *float64 `type:"float"`
  148. Long *int64 `type:"long"`
  149. Num *int64 `locationName:"FooNum" type:"integer"`
  150. Str *string `type:"string"`
  151. Timestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  152. TrueBool *bool `type:"boolean"`
  153. }
  154. //The service client's operations are safe to be used concurrently.
  155. // It is not safe to mutate any of the client's properties though.
  156. type OutputService2ProtocolTest struct {
  157. *client.Client
  158. }
  159. // New creates a new instance of the OutputService2ProtocolTest client with a session.
  160. // If additional configuration is needed for the client instance use the optional
  161. // aws.Config parameter to add your extra config.
  162. //
  163. // Example:
  164. // // Create a OutputService2ProtocolTest client from just a session.
  165. // svc := outputservice2protocoltest.New(mySession)
  166. //
  167. // // Create a OutputService2ProtocolTest client with additional configuration
  168. // svc := outputservice2protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  169. func NewOutputService2ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService2ProtocolTest {
  170. c := p.ClientConfig("outputservice2protocoltest", cfgs...)
  171. return newOutputService2ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  172. }
  173. // newClient creates, initializes and returns a new service client instance.
  174. func newOutputService2ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService2ProtocolTest {
  175. svc := &OutputService2ProtocolTest{
  176. Client: client.New(
  177. cfg,
  178. metadata.ClientInfo{
  179. ServiceName: "outputservice2protocoltest",
  180. SigningRegion: signingRegion,
  181. Endpoint: endpoint,
  182. APIVersion: "",
  183. },
  184. handlers,
  185. ),
  186. }
  187. // Handlers
  188. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  189. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  190. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  191. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  192. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  193. return svc
  194. }
  195. // newRequest creates a new request for a OutputService2ProtocolTest operation and runs any
  196. // custom request initialization.
  197. func (c *OutputService2ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  198. req := c.NewRequest(op, params, data)
  199. return req
  200. }
  201. const opOutputService2TestCaseOperation1 = "OperationName"
  202. // OutputService2TestCaseOperation1Request generates a "aws/request.Request" representing the
  203. // client's request for the OutputService2TestCaseOperation1 operation. The "output" return
  204. // value can be used to capture response data after the request's "Send" method
  205. // is called.
  206. //
  207. // See OutputService2TestCaseOperation1 for usage and error information.
  208. //
  209. // Creating a request object using this method should be used when you want to inject
  210. // custom logic into the request's lifecycle using a custom handler, or if you want to
  211. // access properties on the request object before or after sending the request. If
  212. // you just want the service response, call the OutputService2TestCaseOperation1 method directly
  213. // instead.
  214. //
  215. // Note: You must call the "Send" method on the returned request object in order
  216. // to execute the request.
  217. //
  218. // // Example sending a request using the OutputService2TestCaseOperation1Request method.
  219. // req, resp := client.OutputService2TestCaseOperation1Request(params)
  220. //
  221. // err := req.Send()
  222. // if err == nil { // resp is now filled
  223. // fmt.Println(resp)
  224. // }
  225. //
  226. func (c *OutputService2ProtocolTest) OutputService2TestCaseOperation1Request(input *OutputService2TestShapeOutputService2TestCaseOperation1Input) (req *request.Request, output *OutputService2TestShapeOutputService2TestCaseOperation1Output) {
  227. op := &request.Operation{
  228. Name: opOutputService2TestCaseOperation1,
  229. HTTPPath: "/",
  230. }
  231. if input == nil {
  232. input = &OutputService2TestShapeOutputService2TestCaseOperation1Input{}
  233. }
  234. req = c.newRequest(op, input, output)
  235. output = &OutputService2TestShapeOutputService2TestCaseOperation1Output{}
  236. req.Data = output
  237. return
  238. }
  239. // OutputService2TestCaseOperation1 API operation for .
  240. //
  241. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  242. // with awserr.Error's Code and Message methods to get detailed information about
  243. // the error.
  244. //
  245. // See the AWS API reference guide for 's
  246. // API operation OutputService2TestCaseOperation1 for usage and error information.
  247. func (c *OutputService2ProtocolTest) OutputService2TestCaseOperation1(input *OutputService2TestShapeOutputService2TestCaseOperation1Input) (*OutputService2TestShapeOutputService2TestCaseOperation1Output, error) {
  248. req, out := c.OutputService2TestCaseOperation1Request(input)
  249. err := req.Send()
  250. return out, err
  251. }
  252. type OutputService2TestShapeOutputService2TestCaseOperation1Input struct {
  253. _ struct{} `type:"structure"`
  254. }
  255. type OutputService2TestShapeOutputService2TestCaseOperation1Output struct {
  256. _ struct{} `type:"structure"`
  257. Num *int64 `type:"integer"`
  258. Str *string `type:"string"`
  259. }
  260. //The service client's operations are safe to be used concurrently.
  261. // It is not safe to mutate any of the client's properties though.
  262. type OutputService3ProtocolTest struct {
  263. *client.Client
  264. }
  265. // New creates a new instance of the OutputService3ProtocolTest client with a session.
  266. // If additional configuration is needed for the client instance use the optional
  267. // aws.Config parameter to add your extra config.
  268. //
  269. // Example:
  270. // // Create a OutputService3ProtocolTest client from just a session.
  271. // svc := outputservice3protocoltest.New(mySession)
  272. //
  273. // // Create a OutputService3ProtocolTest client with additional configuration
  274. // svc := outputservice3protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  275. func NewOutputService3ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService3ProtocolTest {
  276. c := p.ClientConfig("outputservice3protocoltest", cfgs...)
  277. return newOutputService3ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  278. }
  279. // newClient creates, initializes and returns a new service client instance.
  280. func newOutputService3ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService3ProtocolTest {
  281. svc := &OutputService3ProtocolTest{
  282. Client: client.New(
  283. cfg,
  284. metadata.ClientInfo{
  285. ServiceName: "outputservice3protocoltest",
  286. SigningRegion: signingRegion,
  287. Endpoint: endpoint,
  288. APIVersion: "",
  289. },
  290. handlers,
  291. ),
  292. }
  293. // Handlers
  294. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  295. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  296. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  297. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  298. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  299. return svc
  300. }
  301. // newRequest creates a new request for a OutputService3ProtocolTest operation and runs any
  302. // custom request initialization.
  303. func (c *OutputService3ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  304. req := c.NewRequest(op, params, data)
  305. return req
  306. }
  307. const opOutputService3TestCaseOperation1 = "OperationName"
  308. // OutputService3TestCaseOperation1Request generates a "aws/request.Request" representing the
  309. // client's request for the OutputService3TestCaseOperation1 operation. The "output" return
  310. // value can be used to capture response data after the request's "Send" method
  311. // is called.
  312. //
  313. // See OutputService3TestCaseOperation1 for usage and error information.
  314. //
  315. // Creating a request object using this method should be used when you want to inject
  316. // custom logic into the request's lifecycle using a custom handler, or if you want to
  317. // access properties on the request object before or after sending the request. If
  318. // you just want the service response, call the OutputService3TestCaseOperation1 method directly
  319. // instead.
  320. //
  321. // Note: You must call the "Send" method on the returned request object in order
  322. // to execute the request.
  323. //
  324. // // Example sending a request using the OutputService3TestCaseOperation1Request method.
  325. // req, resp := client.OutputService3TestCaseOperation1Request(params)
  326. //
  327. // err := req.Send()
  328. // if err == nil { // resp is now filled
  329. // fmt.Println(resp)
  330. // }
  331. //
  332. func (c *OutputService3ProtocolTest) OutputService3TestCaseOperation1Request(input *OutputService3TestShapeOutputService3TestCaseOperation1Input) (req *request.Request, output *OutputService3TestShapeOutputService3TestCaseOperation1Output) {
  333. op := &request.Operation{
  334. Name: opOutputService3TestCaseOperation1,
  335. HTTPPath: "/",
  336. }
  337. if input == nil {
  338. input = &OutputService3TestShapeOutputService3TestCaseOperation1Input{}
  339. }
  340. req = c.newRequest(op, input, output)
  341. output = &OutputService3TestShapeOutputService3TestCaseOperation1Output{}
  342. req.Data = output
  343. return
  344. }
  345. // OutputService3TestCaseOperation1 API operation for .
  346. //
  347. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  348. // with awserr.Error's Code and Message methods to get detailed information about
  349. // the error.
  350. //
  351. // See the AWS API reference guide for 's
  352. // API operation OutputService3TestCaseOperation1 for usage and error information.
  353. func (c *OutputService3ProtocolTest) OutputService3TestCaseOperation1(input *OutputService3TestShapeOutputService3TestCaseOperation1Input) (*OutputService3TestShapeOutputService3TestCaseOperation1Output, error) {
  354. req, out := c.OutputService3TestCaseOperation1Request(input)
  355. err := req.Send()
  356. return out, err
  357. }
  358. type OutputService3TestShapeOutputService3TestCaseOperation1Input struct {
  359. _ struct{} `type:"structure"`
  360. }
  361. type OutputService3TestShapeOutputService3TestCaseOperation1Output struct {
  362. _ struct{} `type:"structure"`
  363. // Blob is automatically base64 encoded/decoded by the SDK.
  364. Blob []byte `type:"blob"`
  365. }
  366. //The service client's operations are safe to be used concurrently.
  367. // It is not safe to mutate any of the client's properties though.
  368. type OutputService4ProtocolTest struct {
  369. *client.Client
  370. }
  371. // New creates a new instance of the OutputService4ProtocolTest client with a session.
  372. // If additional configuration is needed for the client instance use the optional
  373. // aws.Config parameter to add your extra config.
  374. //
  375. // Example:
  376. // // Create a OutputService4ProtocolTest client from just a session.
  377. // svc := outputservice4protocoltest.New(mySession)
  378. //
  379. // // Create a OutputService4ProtocolTest client with additional configuration
  380. // svc := outputservice4protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  381. func NewOutputService4ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService4ProtocolTest {
  382. c := p.ClientConfig("outputservice4protocoltest", cfgs...)
  383. return newOutputService4ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  384. }
  385. // newClient creates, initializes and returns a new service client instance.
  386. func newOutputService4ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService4ProtocolTest {
  387. svc := &OutputService4ProtocolTest{
  388. Client: client.New(
  389. cfg,
  390. metadata.ClientInfo{
  391. ServiceName: "outputservice4protocoltest",
  392. SigningRegion: signingRegion,
  393. Endpoint: endpoint,
  394. APIVersion: "",
  395. },
  396. handlers,
  397. ),
  398. }
  399. // Handlers
  400. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  401. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  402. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  403. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  404. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  405. return svc
  406. }
  407. // newRequest creates a new request for a OutputService4ProtocolTest operation and runs any
  408. // custom request initialization.
  409. func (c *OutputService4ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  410. req := c.NewRequest(op, params, data)
  411. return req
  412. }
  413. const opOutputService4TestCaseOperation1 = "OperationName"
  414. // OutputService4TestCaseOperation1Request generates a "aws/request.Request" representing the
  415. // client's request for the OutputService4TestCaseOperation1 operation. The "output" return
  416. // value can be used to capture response data after the request's "Send" method
  417. // is called.
  418. //
  419. // See OutputService4TestCaseOperation1 for usage and error information.
  420. //
  421. // Creating a request object using this method should be used when you want to inject
  422. // custom logic into the request's lifecycle using a custom handler, or if you want to
  423. // access properties on the request object before or after sending the request. If
  424. // you just want the service response, call the OutputService4TestCaseOperation1 method directly
  425. // instead.
  426. //
  427. // Note: You must call the "Send" method on the returned request object in order
  428. // to execute the request.
  429. //
  430. // // Example sending a request using the OutputService4TestCaseOperation1Request method.
  431. // req, resp := client.OutputService4TestCaseOperation1Request(params)
  432. //
  433. // err := req.Send()
  434. // if err == nil { // resp is now filled
  435. // fmt.Println(resp)
  436. // }
  437. //
  438. func (c *OutputService4ProtocolTest) OutputService4TestCaseOperation1Request(input *OutputService4TestShapeOutputService4TestCaseOperation1Input) (req *request.Request, output *OutputService4TestShapeOutputService4TestCaseOperation1Output) {
  439. op := &request.Operation{
  440. Name: opOutputService4TestCaseOperation1,
  441. HTTPPath: "/",
  442. }
  443. if input == nil {
  444. input = &OutputService4TestShapeOutputService4TestCaseOperation1Input{}
  445. }
  446. req = c.newRequest(op, input, output)
  447. output = &OutputService4TestShapeOutputService4TestCaseOperation1Output{}
  448. req.Data = output
  449. return
  450. }
  451. // OutputService4TestCaseOperation1 API operation for .
  452. //
  453. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  454. // with awserr.Error's Code and Message methods to get detailed information about
  455. // the error.
  456. //
  457. // See the AWS API reference guide for 's
  458. // API operation OutputService4TestCaseOperation1 for usage and error information.
  459. func (c *OutputService4ProtocolTest) OutputService4TestCaseOperation1(input *OutputService4TestShapeOutputService4TestCaseOperation1Input) (*OutputService4TestShapeOutputService4TestCaseOperation1Output, error) {
  460. req, out := c.OutputService4TestCaseOperation1Request(input)
  461. err := req.Send()
  462. return out, err
  463. }
  464. type OutputService4TestShapeOutputService4TestCaseOperation1Input struct {
  465. _ struct{} `type:"structure"`
  466. }
  467. type OutputService4TestShapeOutputService4TestCaseOperation1Output struct {
  468. _ struct{} `type:"structure"`
  469. ListMember []*string `type:"list"`
  470. }
  471. //The service client's operations are safe to be used concurrently.
  472. // It is not safe to mutate any of the client's properties though.
  473. type OutputService5ProtocolTest struct {
  474. *client.Client
  475. }
  476. // New creates a new instance of the OutputService5ProtocolTest client with a session.
  477. // If additional configuration is needed for the client instance use the optional
  478. // aws.Config parameter to add your extra config.
  479. //
  480. // Example:
  481. // // Create a OutputService5ProtocolTest client from just a session.
  482. // svc := outputservice5protocoltest.New(mySession)
  483. //
  484. // // Create a OutputService5ProtocolTest client with additional configuration
  485. // svc := outputservice5protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  486. func NewOutputService5ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService5ProtocolTest {
  487. c := p.ClientConfig("outputservice5protocoltest", cfgs...)
  488. return newOutputService5ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  489. }
  490. // newClient creates, initializes and returns a new service client instance.
  491. func newOutputService5ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService5ProtocolTest {
  492. svc := &OutputService5ProtocolTest{
  493. Client: client.New(
  494. cfg,
  495. metadata.ClientInfo{
  496. ServiceName: "outputservice5protocoltest",
  497. SigningRegion: signingRegion,
  498. Endpoint: endpoint,
  499. APIVersion: "",
  500. },
  501. handlers,
  502. ),
  503. }
  504. // Handlers
  505. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  506. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  507. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  508. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  509. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  510. return svc
  511. }
  512. // newRequest creates a new request for a OutputService5ProtocolTest operation and runs any
  513. // custom request initialization.
  514. func (c *OutputService5ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  515. req := c.NewRequest(op, params, data)
  516. return req
  517. }
  518. const opOutputService5TestCaseOperation1 = "OperationName"
  519. // OutputService5TestCaseOperation1Request generates a "aws/request.Request" representing the
  520. // client's request for the OutputService5TestCaseOperation1 operation. The "output" return
  521. // value can be used to capture response data after the request's "Send" method
  522. // is called.
  523. //
  524. // See OutputService5TestCaseOperation1 for usage and error information.
  525. //
  526. // Creating a request object using this method should be used when you want to inject
  527. // custom logic into the request's lifecycle using a custom handler, or if you want to
  528. // access properties on the request object before or after sending the request. If
  529. // you just want the service response, call the OutputService5TestCaseOperation1 method directly
  530. // instead.
  531. //
  532. // Note: You must call the "Send" method on the returned request object in order
  533. // to execute the request.
  534. //
  535. // // Example sending a request using the OutputService5TestCaseOperation1Request method.
  536. // req, resp := client.OutputService5TestCaseOperation1Request(params)
  537. //
  538. // err := req.Send()
  539. // if err == nil { // resp is now filled
  540. // fmt.Println(resp)
  541. // }
  542. //
  543. func (c *OutputService5ProtocolTest) OutputService5TestCaseOperation1Request(input *OutputService5TestShapeOutputService5TestCaseOperation1Input) (req *request.Request, output *OutputService5TestShapeOutputService5TestCaseOperation1Output) {
  544. op := &request.Operation{
  545. Name: opOutputService5TestCaseOperation1,
  546. HTTPPath: "/",
  547. }
  548. if input == nil {
  549. input = &OutputService5TestShapeOutputService5TestCaseOperation1Input{}
  550. }
  551. req = c.newRequest(op, input, output)
  552. output = &OutputService5TestShapeOutputService5TestCaseOperation1Output{}
  553. req.Data = output
  554. return
  555. }
  556. // OutputService5TestCaseOperation1 API operation for .
  557. //
  558. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  559. // with awserr.Error's Code and Message methods to get detailed information about
  560. // the error.
  561. //
  562. // See the AWS API reference guide for 's
  563. // API operation OutputService5TestCaseOperation1 for usage and error information.
  564. func (c *OutputService5ProtocolTest) OutputService5TestCaseOperation1(input *OutputService5TestShapeOutputService5TestCaseOperation1Input) (*OutputService5TestShapeOutputService5TestCaseOperation1Output, error) {
  565. req, out := c.OutputService5TestCaseOperation1Request(input)
  566. err := req.Send()
  567. return out, err
  568. }
  569. type OutputService5TestShapeOutputService5TestCaseOperation1Input struct {
  570. _ struct{} `type:"structure"`
  571. }
  572. type OutputService5TestShapeOutputService5TestCaseOperation1Output struct {
  573. _ struct{} `type:"structure"`
  574. ListMember []*string `locationNameList:"item" type:"list"`
  575. }
  576. //The service client's operations are safe to be used concurrently.
  577. // It is not safe to mutate any of the client's properties though.
  578. type OutputService6ProtocolTest struct {
  579. *client.Client
  580. }
  581. // New creates a new instance of the OutputService6ProtocolTest client with a session.
  582. // If additional configuration is needed for the client instance use the optional
  583. // aws.Config parameter to add your extra config.
  584. //
  585. // Example:
  586. // // Create a OutputService6ProtocolTest client from just a session.
  587. // svc := outputservice6protocoltest.New(mySession)
  588. //
  589. // // Create a OutputService6ProtocolTest client with additional configuration
  590. // svc := outputservice6protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  591. func NewOutputService6ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService6ProtocolTest {
  592. c := p.ClientConfig("outputservice6protocoltest", cfgs...)
  593. return newOutputService6ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  594. }
  595. // newClient creates, initializes and returns a new service client instance.
  596. func newOutputService6ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService6ProtocolTest {
  597. svc := &OutputService6ProtocolTest{
  598. Client: client.New(
  599. cfg,
  600. metadata.ClientInfo{
  601. ServiceName: "outputservice6protocoltest",
  602. SigningRegion: signingRegion,
  603. Endpoint: endpoint,
  604. APIVersion: "",
  605. },
  606. handlers,
  607. ),
  608. }
  609. // Handlers
  610. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  611. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  612. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  613. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  614. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  615. return svc
  616. }
  617. // newRequest creates a new request for a OutputService6ProtocolTest operation and runs any
  618. // custom request initialization.
  619. func (c *OutputService6ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  620. req := c.NewRequest(op, params, data)
  621. return req
  622. }
  623. const opOutputService6TestCaseOperation1 = "OperationName"
  624. // OutputService6TestCaseOperation1Request generates a "aws/request.Request" representing the
  625. // client's request for the OutputService6TestCaseOperation1 operation. The "output" return
  626. // value can be used to capture response data after the request's "Send" method
  627. // is called.
  628. //
  629. // See OutputService6TestCaseOperation1 for usage and error information.
  630. //
  631. // Creating a request object using this method should be used when you want to inject
  632. // custom logic into the request's lifecycle using a custom handler, or if you want to
  633. // access properties on the request object before or after sending the request. If
  634. // you just want the service response, call the OutputService6TestCaseOperation1 method directly
  635. // instead.
  636. //
  637. // Note: You must call the "Send" method on the returned request object in order
  638. // to execute the request.
  639. //
  640. // // Example sending a request using the OutputService6TestCaseOperation1Request method.
  641. // req, resp := client.OutputService6TestCaseOperation1Request(params)
  642. //
  643. // err := req.Send()
  644. // if err == nil { // resp is now filled
  645. // fmt.Println(resp)
  646. // }
  647. //
  648. func (c *OutputService6ProtocolTest) OutputService6TestCaseOperation1Request(input *OutputService6TestShapeOutputService6TestCaseOperation1Input) (req *request.Request, output *OutputService6TestShapeOutputService6TestCaseOperation1Output) {
  649. op := &request.Operation{
  650. Name: opOutputService6TestCaseOperation1,
  651. HTTPPath: "/",
  652. }
  653. if input == nil {
  654. input = &OutputService6TestShapeOutputService6TestCaseOperation1Input{}
  655. }
  656. req = c.newRequest(op, input, output)
  657. output = &OutputService6TestShapeOutputService6TestCaseOperation1Output{}
  658. req.Data = output
  659. return
  660. }
  661. // OutputService6TestCaseOperation1 API operation for .
  662. //
  663. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  664. // with awserr.Error's Code and Message methods to get detailed information about
  665. // the error.
  666. //
  667. // See the AWS API reference guide for 's
  668. // API operation OutputService6TestCaseOperation1 for usage and error information.
  669. func (c *OutputService6ProtocolTest) OutputService6TestCaseOperation1(input *OutputService6TestShapeOutputService6TestCaseOperation1Input) (*OutputService6TestShapeOutputService6TestCaseOperation1Output, error) {
  670. req, out := c.OutputService6TestCaseOperation1Request(input)
  671. err := req.Send()
  672. return out, err
  673. }
  674. type OutputService6TestShapeOutputService6TestCaseOperation1Input struct {
  675. _ struct{} `type:"structure"`
  676. }
  677. type OutputService6TestShapeOutputService6TestCaseOperation1Output struct {
  678. _ struct{} `type:"structure"`
  679. ListMember []*string `type:"list" flattened:"true"`
  680. }
  681. //The service client's operations are safe to be used concurrently.
  682. // It is not safe to mutate any of the client's properties though.
  683. type OutputService7ProtocolTest struct {
  684. *client.Client
  685. }
  686. // New creates a new instance of the OutputService7ProtocolTest client with a session.
  687. // If additional configuration is needed for the client instance use the optional
  688. // aws.Config parameter to add your extra config.
  689. //
  690. // Example:
  691. // // Create a OutputService7ProtocolTest client from just a session.
  692. // svc := outputservice7protocoltest.New(mySession)
  693. //
  694. // // Create a OutputService7ProtocolTest client with additional configuration
  695. // svc := outputservice7protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  696. func NewOutputService7ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService7ProtocolTest {
  697. c := p.ClientConfig("outputservice7protocoltest", cfgs...)
  698. return newOutputService7ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  699. }
  700. // newClient creates, initializes and returns a new service client instance.
  701. func newOutputService7ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService7ProtocolTest {
  702. svc := &OutputService7ProtocolTest{
  703. Client: client.New(
  704. cfg,
  705. metadata.ClientInfo{
  706. ServiceName: "outputservice7protocoltest",
  707. SigningRegion: signingRegion,
  708. Endpoint: endpoint,
  709. APIVersion: "",
  710. },
  711. handlers,
  712. ),
  713. }
  714. // Handlers
  715. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  716. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  717. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  718. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  719. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  720. return svc
  721. }
  722. // newRequest creates a new request for a OutputService7ProtocolTest operation and runs any
  723. // custom request initialization.
  724. func (c *OutputService7ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  725. req := c.NewRequest(op, params, data)
  726. return req
  727. }
  728. const opOutputService7TestCaseOperation1 = "OperationName"
  729. // OutputService7TestCaseOperation1Request generates a "aws/request.Request" representing the
  730. // client's request for the OutputService7TestCaseOperation1 operation. The "output" return
  731. // value can be used to capture response data after the request's "Send" method
  732. // is called.
  733. //
  734. // See OutputService7TestCaseOperation1 for usage and error information.
  735. //
  736. // Creating a request object using this method should be used when you want to inject
  737. // custom logic into the request's lifecycle using a custom handler, or if you want to
  738. // access properties on the request object before or after sending the request. If
  739. // you just want the service response, call the OutputService7TestCaseOperation1 method directly
  740. // instead.
  741. //
  742. // Note: You must call the "Send" method on the returned request object in order
  743. // to execute the request.
  744. //
  745. // // Example sending a request using the OutputService7TestCaseOperation1Request method.
  746. // req, resp := client.OutputService7TestCaseOperation1Request(params)
  747. //
  748. // err := req.Send()
  749. // if err == nil { // resp is now filled
  750. // fmt.Println(resp)
  751. // }
  752. //
  753. func (c *OutputService7ProtocolTest) OutputService7TestCaseOperation1Request(input *OutputService7TestShapeOutputService7TestCaseOperation1Input) (req *request.Request, output *OutputService7TestShapeOutputService7TestCaseOperation1Output) {
  754. op := &request.Operation{
  755. Name: opOutputService7TestCaseOperation1,
  756. HTTPPath: "/",
  757. }
  758. if input == nil {
  759. input = &OutputService7TestShapeOutputService7TestCaseOperation1Input{}
  760. }
  761. req = c.newRequest(op, input, output)
  762. output = &OutputService7TestShapeOutputService7TestCaseOperation1Output{}
  763. req.Data = output
  764. return
  765. }
  766. // OutputService7TestCaseOperation1 API operation for .
  767. //
  768. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  769. // with awserr.Error's Code and Message methods to get detailed information about
  770. // the error.
  771. //
  772. // See the AWS API reference guide for 's
  773. // API operation OutputService7TestCaseOperation1 for usage and error information.
  774. func (c *OutputService7ProtocolTest) OutputService7TestCaseOperation1(input *OutputService7TestShapeOutputService7TestCaseOperation1Input) (*OutputService7TestShapeOutputService7TestCaseOperation1Output, error) {
  775. req, out := c.OutputService7TestCaseOperation1Request(input)
  776. err := req.Send()
  777. return out, err
  778. }
  779. type OutputService7TestShapeOutputService7TestCaseOperation1Input struct {
  780. _ struct{} `type:"structure"`
  781. }
  782. type OutputService7TestShapeOutputService7TestCaseOperation1Output struct {
  783. _ struct{} `type:"structure"`
  784. ListMember []*string `type:"list" flattened:"true"`
  785. }
  786. //The service client's operations are safe to be used concurrently.
  787. // It is not safe to mutate any of the client's properties though.
  788. type OutputService8ProtocolTest struct {
  789. *client.Client
  790. }
  791. // New creates a new instance of the OutputService8ProtocolTest client with a session.
  792. // If additional configuration is needed for the client instance use the optional
  793. // aws.Config parameter to add your extra config.
  794. //
  795. // Example:
  796. // // Create a OutputService8ProtocolTest client from just a session.
  797. // svc := outputservice8protocoltest.New(mySession)
  798. //
  799. // // Create a OutputService8ProtocolTest client with additional configuration
  800. // svc := outputservice8protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  801. func NewOutputService8ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService8ProtocolTest {
  802. c := p.ClientConfig("outputservice8protocoltest", cfgs...)
  803. return newOutputService8ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  804. }
  805. // newClient creates, initializes and returns a new service client instance.
  806. func newOutputService8ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService8ProtocolTest {
  807. svc := &OutputService8ProtocolTest{
  808. Client: client.New(
  809. cfg,
  810. metadata.ClientInfo{
  811. ServiceName: "outputservice8protocoltest",
  812. SigningRegion: signingRegion,
  813. Endpoint: endpoint,
  814. APIVersion: "",
  815. },
  816. handlers,
  817. ),
  818. }
  819. // Handlers
  820. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  821. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  822. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  823. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  824. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  825. return svc
  826. }
  827. // newRequest creates a new request for a OutputService8ProtocolTest operation and runs any
  828. // custom request initialization.
  829. func (c *OutputService8ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  830. req := c.NewRequest(op, params, data)
  831. return req
  832. }
  833. const opOutputService8TestCaseOperation1 = "OperationName"
  834. // OutputService8TestCaseOperation1Request generates a "aws/request.Request" representing the
  835. // client's request for the OutputService8TestCaseOperation1 operation. The "output" return
  836. // value can be used to capture response data after the request's "Send" method
  837. // is called.
  838. //
  839. // See OutputService8TestCaseOperation1 for usage and error information.
  840. //
  841. // Creating a request object using this method should be used when you want to inject
  842. // custom logic into the request's lifecycle using a custom handler, or if you want to
  843. // access properties on the request object before or after sending the request. If
  844. // you just want the service response, call the OutputService8TestCaseOperation1 method directly
  845. // instead.
  846. //
  847. // Note: You must call the "Send" method on the returned request object in order
  848. // to execute the request.
  849. //
  850. // // Example sending a request using the OutputService8TestCaseOperation1Request method.
  851. // req, resp := client.OutputService8TestCaseOperation1Request(params)
  852. //
  853. // err := req.Send()
  854. // if err == nil { // resp is now filled
  855. // fmt.Println(resp)
  856. // }
  857. //
  858. func (c *OutputService8ProtocolTest) OutputService8TestCaseOperation1Request(input *OutputService8TestShapeOutputService8TestCaseOperation1Input) (req *request.Request, output *OutputService8TestShapeOutputService8TestCaseOperation1Output) {
  859. op := &request.Operation{
  860. Name: opOutputService8TestCaseOperation1,
  861. HTTPPath: "/",
  862. }
  863. if input == nil {
  864. input = &OutputService8TestShapeOutputService8TestCaseOperation1Input{}
  865. }
  866. req = c.newRequest(op, input, output)
  867. output = &OutputService8TestShapeOutputService8TestCaseOperation1Output{}
  868. req.Data = output
  869. return
  870. }
  871. // OutputService8TestCaseOperation1 API operation for .
  872. //
  873. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  874. // with awserr.Error's Code and Message methods to get detailed information about
  875. // the error.
  876. //
  877. // See the AWS API reference guide for 's
  878. // API operation OutputService8TestCaseOperation1 for usage and error information.
  879. func (c *OutputService8ProtocolTest) OutputService8TestCaseOperation1(input *OutputService8TestShapeOutputService8TestCaseOperation1Input) (*OutputService8TestShapeOutputService8TestCaseOperation1Output, error) {
  880. req, out := c.OutputService8TestCaseOperation1Request(input)
  881. err := req.Send()
  882. return out, err
  883. }
  884. type OutputService8TestShapeOutputService8TestCaseOperation1Input struct {
  885. _ struct{} `type:"structure"`
  886. }
  887. type OutputService8TestShapeOutputService8TestCaseOperation1Output struct {
  888. _ struct{} `type:"structure"`
  889. List []*OutputService8TestShapeStructureShape `type:"list"`
  890. }
  891. type OutputService8TestShapeStructureShape struct {
  892. _ struct{} `type:"structure"`
  893. Bar *string `type:"string"`
  894. Baz *string `type:"string"`
  895. Foo *string `type:"string"`
  896. }
  897. //The service client's operations are safe to be used concurrently.
  898. // It is not safe to mutate any of the client's properties though.
  899. type OutputService9ProtocolTest struct {
  900. *client.Client
  901. }
  902. // New creates a new instance of the OutputService9ProtocolTest client with a session.
  903. // If additional configuration is needed for the client instance use the optional
  904. // aws.Config parameter to add your extra config.
  905. //
  906. // Example:
  907. // // Create a OutputService9ProtocolTest client from just a session.
  908. // svc := outputservice9protocoltest.New(mySession)
  909. //
  910. // // Create a OutputService9ProtocolTest client with additional configuration
  911. // svc := outputservice9protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  912. func NewOutputService9ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService9ProtocolTest {
  913. c := p.ClientConfig("outputservice9protocoltest", cfgs...)
  914. return newOutputService9ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  915. }
  916. // newClient creates, initializes and returns a new service client instance.
  917. func newOutputService9ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService9ProtocolTest {
  918. svc := &OutputService9ProtocolTest{
  919. Client: client.New(
  920. cfg,
  921. metadata.ClientInfo{
  922. ServiceName: "outputservice9protocoltest",
  923. SigningRegion: signingRegion,
  924. Endpoint: endpoint,
  925. APIVersion: "",
  926. },
  927. handlers,
  928. ),
  929. }
  930. // Handlers
  931. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  932. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  933. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  934. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  935. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  936. return svc
  937. }
  938. // newRequest creates a new request for a OutputService9ProtocolTest operation and runs any
  939. // custom request initialization.
  940. func (c *OutputService9ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  941. req := c.NewRequest(op, params, data)
  942. return req
  943. }
  944. const opOutputService9TestCaseOperation1 = "OperationName"
  945. // OutputService9TestCaseOperation1Request generates a "aws/request.Request" representing the
  946. // client's request for the OutputService9TestCaseOperation1 operation. The "output" return
  947. // value can be used to capture response data after the request's "Send" method
  948. // is called.
  949. //
  950. // See OutputService9TestCaseOperation1 for usage and error information.
  951. //
  952. // Creating a request object using this method should be used when you want to inject
  953. // custom logic into the request's lifecycle using a custom handler, or if you want to
  954. // access properties on the request object before or after sending the request. If
  955. // you just want the service response, call the OutputService9TestCaseOperation1 method directly
  956. // instead.
  957. //
  958. // Note: You must call the "Send" method on the returned request object in order
  959. // to execute the request.
  960. //
  961. // // Example sending a request using the OutputService9TestCaseOperation1Request method.
  962. // req, resp := client.OutputService9TestCaseOperation1Request(params)
  963. //
  964. // err := req.Send()
  965. // if err == nil { // resp is now filled
  966. // fmt.Println(resp)
  967. // }
  968. //
  969. func (c *OutputService9ProtocolTest) OutputService9TestCaseOperation1Request(input *OutputService9TestShapeOutputService9TestCaseOperation1Input) (req *request.Request, output *OutputService9TestShapeOutputService9TestCaseOperation1Output) {
  970. op := &request.Operation{
  971. Name: opOutputService9TestCaseOperation1,
  972. HTTPPath: "/",
  973. }
  974. if input == nil {
  975. input = &OutputService9TestShapeOutputService9TestCaseOperation1Input{}
  976. }
  977. req = c.newRequest(op, input, output)
  978. output = &OutputService9TestShapeOutputService9TestCaseOperation1Output{}
  979. req.Data = output
  980. return
  981. }
  982. // OutputService9TestCaseOperation1 API operation for .
  983. //
  984. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  985. // with awserr.Error's Code and Message methods to get detailed information about
  986. // the error.
  987. //
  988. // See the AWS API reference guide for 's
  989. // API operation OutputService9TestCaseOperation1 for usage and error information.
  990. func (c *OutputService9ProtocolTest) OutputService9TestCaseOperation1(input *OutputService9TestShapeOutputService9TestCaseOperation1Input) (*OutputService9TestShapeOutputService9TestCaseOperation1Output, error) {
  991. req, out := c.OutputService9TestCaseOperation1Request(input)
  992. err := req.Send()
  993. return out, err
  994. }
  995. type OutputService9TestShapeOutputService9TestCaseOperation1Input struct {
  996. _ struct{} `type:"structure"`
  997. }
  998. type OutputService9TestShapeOutputService9TestCaseOperation1Output struct {
  999. _ struct{} `type:"structure"`
  1000. List []*OutputService9TestShapeStructureShape `type:"list" flattened:"true"`
  1001. }
  1002. type OutputService9TestShapeStructureShape struct {
  1003. _ struct{} `type:"structure"`
  1004. Bar *string `type:"string"`
  1005. Baz *string `type:"string"`
  1006. Foo *string `type:"string"`
  1007. }
  1008. //The service client's operations are safe to be used concurrently.
  1009. // It is not safe to mutate any of the client's properties though.
  1010. type OutputService10ProtocolTest struct {
  1011. *client.Client
  1012. }
  1013. // New creates a new instance of the OutputService10ProtocolTest client with a session.
  1014. // If additional configuration is needed for the client instance use the optional
  1015. // aws.Config parameter to add your extra config.
  1016. //
  1017. // Example:
  1018. // // Create a OutputService10ProtocolTest client from just a session.
  1019. // svc := outputservice10protocoltest.New(mySession)
  1020. //
  1021. // // Create a OutputService10ProtocolTest client with additional configuration
  1022. // svc := outputservice10protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1023. func NewOutputService10ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService10ProtocolTest {
  1024. c := p.ClientConfig("outputservice10protocoltest", cfgs...)
  1025. return newOutputService10ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1026. }
  1027. // newClient creates, initializes and returns a new service client instance.
  1028. func newOutputService10ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService10ProtocolTest {
  1029. svc := &OutputService10ProtocolTest{
  1030. Client: client.New(
  1031. cfg,
  1032. metadata.ClientInfo{
  1033. ServiceName: "outputservice10protocoltest",
  1034. SigningRegion: signingRegion,
  1035. Endpoint: endpoint,
  1036. APIVersion: "",
  1037. },
  1038. handlers,
  1039. ),
  1040. }
  1041. // Handlers
  1042. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1043. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1044. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1045. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1046. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1047. return svc
  1048. }
  1049. // newRequest creates a new request for a OutputService10ProtocolTest operation and runs any
  1050. // custom request initialization.
  1051. func (c *OutputService10ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1052. req := c.NewRequest(op, params, data)
  1053. return req
  1054. }
  1055. const opOutputService10TestCaseOperation1 = "OperationName"
  1056. // OutputService10TestCaseOperation1Request generates a "aws/request.Request" representing the
  1057. // client's request for the OutputService10TestCaseOperation1 operation. The "output" return
  1058. // value can be used to capture response data after the request's "Send" method
  1059. // is called.
  1060. //
  1061. // See OutputService10TestCaseOperation1 for usage and error information.
  1062. //
  1063. // Creating a request object using this method should be used when you want to inject
  1064. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1065. // access properties on the request object before or after sending the request. If
  1066. // you just want the service response, call the OutputService10TestCaseOperation1 method directly
  1067. // instead.
  1068. //
  1069. // Note: You must call the "Send" method on the returned request object in order
  1070. // to execute the request.
  1071. //
  1072. // // Example sending a request using the OutputService10TestCaseOperation1Request method.
  1073. // req, resp := client.OutputService10TestCaseOperation1Request(params)
  1074. //
  1075. // err := req.Send()
  1076. // if err == nil { // resp is now filled
  1077. // fmt.Println(resp)
  1078. // }
  1079. //
  1080. func (c *OutputService10ProtocolTest) OutputService10TestCaseOperation1Request(input *OutputService10TestShapeOutputService10TestCaseOperation1Input) (req *request.Request, output *OutputService10TestShapeOutputService10TestCaseOperation1Output) {
  1081. op := &request.Operation{
  1082. Name: opOutputService10TestCaseOperation1,
  1083. HTTPPath: "/",
  1084. }
  1085. if input == nil {
  1086. input = &OutputService10TestShapeOutputService10TestCaseOperation1Input{}
  1087. }
  1088. req = c.newRequest(op, input, output)
  1089. output = &OutputService10TestShapeOutputService10TestCaseOperation1Output{}
  1090. req.Data = output
  1091. return
  1092. }
  1093. // OutputService10TestCaseOperation1 API operation for .
  1094. //
  1095. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1096. // with awserr.Error's Code and Message methods to get detailed information about
  1097. // the error.
  1098. //
  1099. // See the AWS API reference guide for 's
  1100. // API operation OutputService10TestCaseOperation1 for usage and error information.
  1101. func (c *OutputService10ProtocolTest) OutputService10TestCaseOperation1(input *OutputService10TestShapeOutputService10TestCaseOperation1Input) (*OutputService10TestShapeOutputService10TestCaseOperation1Output, error) {
  1102. req, out := c.OutputService10TestCaseOperation1Request(input)
  1103. err := req.Send()
  1104. return out, err
  1105. }
  1106. type OutputService10TestShapeOutputService10TestCaseOperation1Input struct {
  1107. _ struct{} `type:"structure"`
  1108. }
  1109. type OutputService10TestShapeOutputService10TestCaseOperation1Output struct {
  1110. _ struct{} `type:"structure"`
  1111. List []*string `locationNameList:"NamedList" type:"list" flattened:"true"`
  1112. }
  1113. //The service client's operations are safe to be used concurrently.
  1114. // It is not safe to mutate any of the client's properties though.
  1115. type OutputService11ProtocolTest struct {
  1116. *client.Client
  1117. }
  1118. // New creates a new instance of the OutputService11ProtocolTest client with a session.
  1119. // If additional configuration is needed for the client instance use the optional
  1120. // aws.Config parameter to add your extra config.
  1121. //
  1122. // Example:
  1123. // // Create a OutputService11ProtocolTest client from just a session.
  1124. // svc := outputservice11protocoltest.New(mySession)
  1125. //
  1126. // // Create a OutputService11ProtocolTest client with additional configuration
  1127. // svc := outputservice11protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1128. func NewOutputService11ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService11ProtocolTest {
  1129. c := p.ClientConfig("outputservice11protocoltest", cfgs...)
  1130. return newOutputService11ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1131. }
  1132. // newClient creates, initializes and returns a new service client instance.
  1133. func newOutputService11ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService11ProtocolTest {
  1134. svc := &OutputService11ProtocolTest{
  1135. Client: client.New(
  1136. cfg,
  1137. metadata.ClientInfo{
  1138. ServiceName: "outputservice11protocoltest",
  1139. SigningRegion: signingRegion,
  1140. Endpoint: endpoint,
  1141. APIVersion: "",
  1142. },
  1143. handlers,
  1144. ),
  1145. }
  1146. // Handlers
  1147. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1148. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1149. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1150. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1151. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1152. return svc
  1153. }
  1154. // newRequest creates a new request for a OutputService11ProtocolTest operation and runs any
  1155. // custom request initialization.
  1156. func (c *OutputService11ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1157. req := c.NewRequest(op, params, data)
  1158. return req
  1159. }
  1160. const opOutputService11TestCaseOperation1 = "OperationName"
  1161. // OutputService11TestCaseOperation1Request generates a "aws/request.Request" representing the
  1162. // client's request for the OutputService11TestCaseOperation1 operation. The "output" return
  1163. // value can be used to capture response data after the request's "Send" method
  1164. // is called.
  1165. //
  1166. // See OutputService11TestCaseOperation1 for usage and error information.
  1167. //
  1168. // Creating a request object using this method should be used when you want to inject
  1169. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1170. // access properties on the request object before or after sending the request. If
  1171. // you just want the service response, call the OutputService11TestCaseOperation1 method directly
  1172. // instead.
  1173. //
  1174. // Note: You must call the "Send" method on the returned request object in order
  1175. // to execute the request.
  1176. //
  1177. // // Example sending a request using the OutputService11TestCaseOperation1Request method.
  1178. // req, resp := client.OutputService11TestCaseOperation1Request(params)
  1179. //
  1180. // err := req.Send()
  1181. // if err == nil { // resp is now filled
  1182. // fmt.Println(resp)
  1183. // }
  1184. //
  1185. func (c *OutputService11ProtocolTest) OutputService11TestCaseOperation1Request(input *OutputService11TestShapeOutputService11TestCaseOperation1Input) (req *request.Request, output *OutputService11TestShapeOutputService11TestCaseOperation1Output) {
  1186. op := &request.Operation{
  1187. Name: opOutputService11TestCaseOperation1,
  1188. HTTPPath: "/",
  1189. }
  1190. if input == nil {
  1191. input = &OutputService11TestShapeOutputService11TestCaseOperation1Input{}
  1192. }
  1193. req = c.newRequest(op, input, output)
  1194. output = &OutputService11TestShapeOutputService11TestCaseOperation1Output{}
  1195. req.Data = output
  1196. return
  1197. }
  1198. // OutputService11TestCaseOperation1 API operation for .
  1199. //
  1200. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1201. // with awserr.Error's Code and Message methods to get detailed information about
  1202. // the error.
  1203. //
  1204. // See the AWS API reference guide for 's
  1205. // API operation OutputService11TestCaseOperation1 for usage and error information.
  1206. func (c *OutputService11ProtocolTest) OutputService11TestCaseOperation1(input *OutputService11TestShapeOutputService11TestCaseOperation1Input) (*OutputService11TestShapeOutputService11TestCaseOperation1Output, error) {
  1207. req, out := c.OutputService11TestCaseOperation1Request(input)
  1208. err := req.Send()
  1209. return out, err
  1210. }
  1211. type OutputService11TestShapeOutputService11TestCaseOperation1Input struct {
  1212. _ struct{} `type:"structure"`
  1213. }
  1214. type OutputService11TestShapeOutputService11TestCaseOperation1Output struct {
  1215. _ struct{} `type:"structure"`
  1216. Map map[string]*OutputService11TestShapeStructType `type:"map"`
  1217. }
  1218. type OutputService11TestShapeStructType struct {
  1219. _ struct{} `type:"structure"`
  1220. Foo *string `locationName:"foo" type:"string"`
  1221. }
  1222. //The service client's operations are safe to be used concurrently.
  1223. // It is not safe to mutate any of the client's properties though.
  1224. type OutputService12ProtocolTest struct {
  1225. *client.Client
  1226. }
  1227. // New creates a new instance of the OutputService12ProtocolTest client with a session.
  1228. // If additional configuration is needed for the client instance use the optional
  1229. // aws.Config parameter to add your extra config.
  1230. //
  1231. // Example:
  1232. // // Create a OutputService12ProtocolTest client from just a session.
  1233. // svc := outputservice12protocoltest.New(mySession)
  1234. //
  1235. // // Create a OutputService12ProtocolTest client with additional configuration
  1236. // svc := outputservice12protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1237. func NewOutputService12ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService12ProtocolTest {
  1238. c := p.ClientConfig("outputservice12protocoltest", cfgs...)
  1239. return newOutputService12ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1240. }
  1241. // newClient creates, initializes and returns a new service client instance.
  1242. func newOutputService12ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService12ProtocolTest {
  1243. svc := &OutputService12ProtocolTest{
  1244. Client: client.New(
  1245. cfg,
  1246. metadata.ClientInfo{
  1247. ServiceName: "outputservice12protocoltest",
  1248. SigningRegion: signingRegion,
  1249. Endpoint: endpoint,
  1250. APIVersion: "",
  1251. },
  1252. handlers,
  1253. ),
  1254. }
  1255. // Handlers
  1256. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1257. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1258. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1259. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1260. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1261. return svc
  1262. }
  1263. // newRequest creates a new request for a OutputService12ProtocolTest operation and runs any
  1264. // custom request initialization.
  1265. func (c *OutputService12ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1266. req := c.NewRequest(op, params, data)
  1267. return req
  1268. }
  1269. const opOutputService12TestCaseOperation1 = "OperationName"
  1270. // OutputService12TestCaseOperation1Request generates a "aws/request.Request" representing the
  1271. // client's request for the OutputService12TestCaseOperation1 operation. The "output" return
  1272. // value can be used to capture response data after the request's "Send" method
  1273. // is called.
  1274. //
  1275. // See OutputService12TestCaseOperation1 for usage and error information.
  1276. //
  1277. // Creating a request object using this method should be used when you want to inject
  1278. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1279. // access properties on the request object before or after sending the request. If
  1280. // you just want the service response, call the OutputService12TestCaseOperation1 method directly
  1281. // instead.
  1282. //
  1283. // Note: You must call the "Send" method on the returned request object in order
  1284. // to execute the request.
  1285. //
  1286. // // Example sending a request using the OutputService12TestCaseOperation1Request method.
  1287. // req, resp := client.OutputService12TestCaseOperation1Request(params)
  1288. //
  1289. // err := req.Send()
  1290. // if err == nil { // resp is now filled
  1291. // fmt.Println(resp)
  1292. // }
  1293. //
  1294. func (c *OutputService12ProtocolTest) OutputService12TestCaseOperation1Request(input *OutputService12TestShapeOutputService12TestCaseOperation1Input) (req *request.Request, output *OutputService12TestShapeOutputService12TestCaseOperation1Output) {
  1295. op := &request.Operation{
  1296. Name: opOutputService12TestCaseOperation1,
  1297. HTTPPath: "/",
  1298. }
  1299. if input == nil {
  1300. input = &OutputService12TestShapeOutputService12TestCaseOperation1Input{}
  1301. }
  1302. req = c.newRequest(op, input, output)
  1303. output = &OutputService12TestShapeOutputService12TestCaseOperation1Output{}
  1304. req.Data = output
  1305. return
  1306. }
  1307. // OutputService12TestCaseOperation1 API operation for .
  1308. //
  1309. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1310. // with awserr.Error's Code and Message methods to get detailed information about
  1311. // the error.
  1312. //
  1313. // See the AWS API reference guide for 's
  1314. // API operation OutputService12TestCaseOperation1 for usage and error information.
  1315. func (c *OutputService12ProtocolTest) OutputService12TestCaseOperation1(input *OutputService12TestShapeOutputService12TestCaseOperation1Input) (*OutputService12TestShapeOutputService12TestCaseOperation1Output, error) {
  1316. req, out := c.OutputService12TestCaseOperation1Request(input)
  1317. err := req.Send()
  1318. return out, err
  1319. }
  1320. type OutputService12TestShapeOutputService12TestCaseOperation1Input struct {
  1321. _ struct{} `type:"structure"`
  1322. }
  1323. type OutputService12TestShapeOutputService12TestCaseOperation1Output struct {
  1324. _ struct{} `type:"structure"`
  1325. Map map[string]*string `type:"map" flattened:"true"`
  1326. }
  1327. //The service client's operations are safe to be used concurrently.
  1328. // It is not safe to mutate any of the client's properties though.
  1329. type OutputService13ProtocolTest struct {
  1330. *client.Client
  1331. }
  1332. // New creates a new instance of the OutputService13ProtocolTest client with a session.
  1333. // If additional configuration is needed for the client instance use the optional
  1334. // aws.Config parameter to add your extra config.
  1335. //
  1336. // Example:
  1337. // // Create a OutputService13ProtocolTest client from just a session.
  1338. // svc := outputservice13protocoltest.New(mySession)
  1339. //
  1340. // // Create a OutputService13ProtocolTest client with additional configuration
  1341. // svc := outputservice13protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1342. func NewOutputService13ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService13ProtocolTest {
  1343. c := p.ClientConfig("outputservice13protocoltest", cfgs...)
  1344. return newOutputService13ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1345. }
  1346. // newClient creates, initializes and returns a new service client instance.
  1347. func newOutputService13ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService13ProtocolTest {
  1348. svc := &OutputService13ProtocolTest{
  1349. Client: client.New(
  1350. cfg,
  1351. metadata.ClientInfo{
  1352. ServiceName: "outputservice13protocoltest",
  1353. SigningRegion: signingRegion,
  1354. Endpoint: endpoint,
  1355. APIVersion: "",
  1356. },
  1357. handlers,
  1358. ),
  1359. }
  1360. // Handlers
  1361. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1362. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1363. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1364. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1365. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1366. return svc
  1367. }
  1368. // newRequest creates a new request for a OutputService13ProtocolTest operation and runs any
  1369. // custom request initialization.
  1370. func (c *OutputService13ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1371. req := c.NewRequest(op, params, data)
  1372. return req
  1373. }
  1374. const opOutputService13TestCaseOperation1 = "OperationName"
  1375. // OutputService13TestCaseOperation1Request generates a "aws/request.Request" representing the
  1376. // client's request for the OutputService13TestCaseOperation1 operation. The "output" return
  1377. // value can be used to capture response data after the request's "Send" method
  1378. // is called.
  1379. //
  1380. // See OutputService13TestCaseOperation1 for usage and error information.
  1381. //
  1382. // Creating a request object using this method should be used when you want to inject
  1383. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1384. // access properties on the request object before or after sending the request. If
  1385. // you just want the service response, call the OutputService13TestCaseOperation1 method directly
  1386. // instead.
  1387. //
  1388. // Note: You must call the "Send" method on the returned request object in order
  1389. // to execute the request.
  1390. //
  1391. // // Example sending a request using the OutputService13TestCaseOperation1Request method.
  1392. // req, resp := client.OutputService13TestCaseOperation1Request(params)
  1393. //
  1394. // err := req.Send()
  1395. // if err == nil { // resp is now filled
  1396. // fmt.Println(resp)
  1397. // }
  1398. //
  1399. func (c *OutputService13ProtocolTest) OutputService13TestCaseOperation1Request(input *OutputService13TestShapeOutputService13TestCaseOperation1Input) (req *request.Request, output *OutputService13TestShapeOutputService13TestCaseOperation1Output) {
  1400. op := &request.Operation{
  1401. Name: opOutputService13TestCaseOperation1,
  1402. HTTPPath: "/",
  1403. }
  1404. if input == nil {
  1405. input = &OutputService13TestShapeOutputService13TestCaseOperation1Input{}
  1406. }
  1407. req = c.newRequest(op, input, output)
  1408. output = &OutputService13TestShapeOutputService13TestCaseOperation1Output{}
  1409. req.Data = output
  1410. return
  1411. }
  1412. // OutputService13TestCaseOperation1 API operation for .
  1413. //
  1414. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1415. // with awserr.Error's Code and Message methods to get detailed information about
  1416. // the error.
  1417. //
  1418. // See the AWS API reference guide for 's
  1419. // API operation OutputService13TestCaseOperation1 for usage and error information.
  1420. func (c *OutputService13ProtocolTest) OutputService13TestCaseOperation1(input *OutputService13TestShapeOutputService13TestCaseOperation1Input) (*OutputService13TestShapeOutputService13TestCaseOperation1Output, error) {
  1421. req, out := c.OutputService13TestCaseOperation1Request(input)
  1422. err := req.Send()
  1423. return out, err
  1424. }
  1425. type OutputService13TestShapeOutputService13TestCaseOperation1Input struct {
  1426. _ struct{} `type:"structure"`
  1427. }
  1428. type OutputService13TestShapeOutputService13TestCaseOperation1Output struct {
  1429. _ struct{} `type:"structure"`
  1430. Map map[string]*string `locationName:"Attribute" locationNameKey:"Name" locationNameValue:"Value" type:"map" flattened:"true"`
  1431. }
  1432. //The service client's operations are safe to be used concurrently.
  1433. // It is not safe to mutate any of the client's properties though.
  1434. type OutputService14ProtocolTest struct {
  1435. *client.Client
  1436. }
  1437. // New creates a new instance of the OutputService14ProtocolTest client with a session.
  1438. // If additional configuration is needed for the client instance use the optional
  1439. // aws.Config parameter to add your extra config.
  1440. //
  1441. // Example:
  1442. // // Create a OutputService14ProtocolTest client from just a session.
  1443. // svc := outputservice14protocoltest.New(mySession)
  1444. //
  1445. // // Create a OutputService14ProtocolTest client with additional configuration
  1446. // svc := outputservice14protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1447. func NewOutputService14ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService14ProtocolTest {
  1448. c := p.ClientConfig("outputservice14protocoltest", cfgs...)
  1449. return newOutputService14ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1450. }
  1451. // newClient creates, initializes and returns a new service client instance.
  1452. func newOutputService14ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService14ProtocolTest {
  1453. svc := &OutputService14ProtocolTest{
  1454. Client: client.New(
  1455. cfg,
  1456. metadata.ClientInfo{
  1457. ServiceName: "outputservice14protocoltest",
  1458. SigningRegion: signingRegion,
  1459. Endpoint: endpoint,
  1460. APIVersion: "",
  1461. },
  1462. handlers,
  1463. ),
  1464. }
  1465. // Handlers
  1466. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1467. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1468. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1469. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1470. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1471. return svc
  1472. }
  1473. // newRequest creates a new request for a OutputService14ProtocolTest operation and runs any
  1474. // custom request initialization.
  1475. func (c *OutputService14ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1476. req := c.NewRequest(op, params, data)
  1477. return req
  1478. }
  1479. const opOutputService14TestCaseOperation1 = "OperationName"
  1480. // OutputService14TestCaseOperation1Request generates a "aws/request.Request" representing the
  1481. // client's request for the OutputService14TestCaseOperation1 operation. The "output" return
  1482. // value can be used to capture response data after the request's "Send" method
  1483. // is called.
  1484. //
  1485. // See OutputService14TestCaseOperation1 for usage and error information.
  1486. //
  1487. // Creating a request object using this method should be used when you want to inject
  1488. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1489. // access properties on the request object before or after sending the request. If
  1490. // you just want the service response, call the OutputService14TestCaseOperation1 method directly
  1491. // instead.
  1492. //
  1493. // Note: You must call the "Send" method on the returned request object in order
  1494. // to execute the request.
  1495. //
  1496. // // Example sending a request using the OutputService14TestCaseOperation1Request method.
  1497. // req, resp := client.OutputService14TestCaseOperation1Request(params)
  1498. //
  1499. // err := req.Send()
  1500. // if err == nil { // resp is now filled
  1501. // fmt.Println(resp)
  1502. // }
  1503. //
  1504. func (c *OutputService14ProtocolTest) OutputService14TestCaseOperation1Request(input *OutputService14TestShapeOutputService14TestCaseOperation1Input) (req *request.Request, output *OutputService14TestShapeOutputService14TestCaseOperation1Output) {
  1505. op := &request.Operation{
  1506. Name: opOutputService14TestCaseOperation1,
  1507. HTTPPath: "/",
  1508. }
  1509. if input == nil {
  1510. input = &OutputService14TestShapeOutputService14TestCaseOperation1Input{}
  1511. }
  1512. req = c.newRequest(op, input, output)
  1513. output = &OutputService14TestShapeOutputService14TestCaseOperation1Output{}
  1514. req.Data = output
  1515. return
  1516. }
  1517. // OutputService14TestCaseOperation1 API operation for .
  1518. //
  1519. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1520. // with awserr.Error's Code and Message methods to get detailed information about
  1521. // the error.
  1522. //
  1523. // See the AWS API reference guide for 's
  1524. // API operation OutputService14TestCaseOperation1 for usage and error information.
  1525. func (c *OutputService14ProtocolTest) OutputService14TestCaseOperation1(input *OutputService14TestShapeOutputService14TestCaseOperation1Input) (*OutputService14TestShapeOutputService14TestCaseOperation1Output, error) {
  1526. req, out := c.OutputService14TestCaseOperation1Request(input)
  1527. err := req.Send()
  1528. return out, err
  1529. }
  1530. type OutputService14TestShapeOutputService14TestCaseOperation1Input struct {
  1531. _ struct{} `type:"structure"`
  1532. }
  1533. type OutputService14TestShapeOutputService14TestCaseOperation1Output struct {
  1534. _ struct{} `type:"structure"`
  1535. Map map[string]*string `locationNameKey:"foo" locationNameValue:"bar" type:"map" flattened:"true"`
  1536. }
  1537. //The service client's operations are safe to be used concurrently.
  1538. // It is not safe to mutate any of the client's properties though.
  1539. type OutputService15ProtocolTest struct {
  1540. *client.Client
  1541. }
  1542. // New creates a new instance of the OutputService15ProtocolTest client with a session.
  1543. // If additional configuration is needed for the client instance use the optional
  1544. // aws.Config parameter to add your extra config.
  1545. //
  1546. // Example:
  1547. // // Create a OutputService15ProtocolTest client from just a session.
  1548. // svc := outputservice15protocoltest.New(mySession)
  1549. //
  1550. // // Create a OutputService15ProtocolTest client with additional configuration
  1551. // svc := outputservice15protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1552. func NewOutputService15ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService15ProtocolTest {
  1553. c := p.ClientConfig("outputservice15protocoltest", cfgs...)
  1554. return newOutputService15ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1555. }
  1556. // newClient creates, initializes and returns a new service client instance.
  1557. func newOutputService15ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService15ProtocolTest {
  1558. svc := &OutputService15ProtocolTest{
  1559. Client: client.New(
  1560. cfg,
  1561. metadata.ClientInfo{
  1562. ServiceName: "outputservice15protocoltest",
  1563. SigningRegion: signingRegion,
  1564. Endpoint: endpoint,
  1565. APIVersion: "",
  1566. },
  1567. handlers,
  1568. ),
  1569. }
  1570. // Handlers
  1571. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1572. svc.Handlers.Build.PushBackNamed(query.BuildHandler)
  1573. svc.Handlers.Unmarshal.PushBackNamed(query.UnmarshalHandler)
  1574. svc.Handlers.UnmarshalMeta.PushBackNamed(query.UnmarshalMetaHandler)
  1575. svc.Handlers.UnmarshalError.PushBackNamed(query.UnmarshalErrorHandler)
  1576. return svc
  1577. }
  1578. // newRequest creates a new request for a OutputService15ProtocolTest operation and runs any
  1579. // custom request initialization.
  1580. func (c *OutputService15ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1581. req := c.NewRequest(op, params, data)
  1582. return req
  1583. }
  1584. const opOutputService15TestCaseOperation1 = "OperationName"
  1585. // OutputService15TestCaseOperation1Request generates a "aws/request.Request" representing the
  1586. // client's request for the OutputService15TestCaseOperation1 operation. The "output" return
  1587. // value can be used to capture response data after the request's "Send" method
  1588. // is called.
  1589. //
  1590. // See OutputService15TestCaseOperation1 for usage and error information.
  1591. //
  1592. // Creating a request object using this method should be used when you want to inject
  1593. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1594. // access properties on the request object before or after sending the request. If
  1595. // you just want the service response, call the OutputService15TestCaseOperation1 method directly
  1596. // instead.
  1597. //
  1598. // Note: You must call the "Send" method on the returned request object in order
  1599. // to execute the request.
  1600. //
  1601. // // Example sending a request using the OutputService15TestCaseOperation1Request method.
  1602. // req, resp := client.OutputService15TestCaseOperation1Request(params)
  1603. //
  1604. // err := req.Send()
  1605. // if err == nil { // resp is now filled
  1606. // fmt.Println(resp)
  1607. // }
  1608. //
  1609. func (c *OutputService15ProtocolTest) OutputService15TestCaseOperation1Request(input *OutputService15TestShapeOutputService15TestCaseOperation1Input) (req *request.Request, output *OutputService15TestShapeOutputService15TestCaseOperation1Output) {
  1610. op := &request.Operation{
  1611. Name: opOutputService15TestCaseOperation1,
  1612. HTTPPath: "/",
  1613. }
  1614. if input == nil {
  1615. input = &OutputService15TestShapeOutputService15TestCaseOperation1Input{}
  1616. }
  1617. req = c.newRequest(op, input, output)
  1618. output = &OutputService15TestShapeOutputService15TestCaseOperation1Output{}
  1619. req.Data = output
  1620. return
  1621. }
  1622. // OutputService15TestCaseOperation1 API operation for .
  1623. //
  1624. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1625. // with awserr.Error's Code and Message methods to get detailed information about
  1626. // the error.
  1627. //
  1628. // See the AWS API reference guide for 's
  1629. // API operation OutputService15TestCaseOperation1 for usage and error information.
  1630. func (c *OutputService15ProtocolTest) OutputService15TestCaseOperation1(input *OutputService15TestShapeOutputService15TestCaseOperation1Input) (*OutputService15TestShapeOutputService15TestCaseOperation1Output, error) {
  1631. req, out := c.OutputService15TestCaseOperation1Request(input)
  1632. err := req.Send()
  1633. return out, err
  1634. }
  1635. type OutputService15TestShapeOutputService15TestCaseOperation1Input struct {
  1636. _ struct{} `type:"structure"`
  1637. }
  1638. type OutputService15TestShapeOutputService15TestCaseOperation1Output struct {
  1639. _ struct{} `type:"structure"`
  1640. Foo *string `type:"string"`
  1641. }
  1642. //
  1643. // Tests begin here
  1644. //
  1645. func TestOutputService1ProtocolTestScalarMembersCase1(t *testing.T) {
  1646. svc := NewOutputService1ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1647. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Str>myname</Str><FooNum>123</FooNum><FalseBool>false</FalseBool><TrueBool>true</TrueBool><Float>1.2</Float><Double>1.3</Double><Long>200</Long><Char>a</Char><Timestamp>2015-01-25T08:00:00Z</Timestamp></OperationNameResult><ResponseMetadata><RequestId>request-id</RequestId></ResponseMetadata></OperationNameResponse>"))
  1648. req, out := svc.OutputService1TestCaseOperation1Request(nil)
  1649. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1650. // set headers
  1651. // unmarshal response
  1652. query.UnmarshalMeta(req)
  1653. query.Unmarshal(req)
  1654. assert.NoError(t, req.Error)
  1655. // assert response
  1656. assert.NotNil(t, out) // ensure out variable is used
  1657. assert.Equal(t, "a", *out.Char)
  1658. assert.Equal(t, 1.3, *out.Double)
  1659. assert.Equal(t, false, *out.FalseBool)
  1660. assert.Equal(t, 1.2, *out.Float)
  1661. assert.Equal(t, int64(200), *out.Long)
  1662. assert.Equal(t, int64(123), *out.Num)
  1663. assert.Equal(t, "myname", *out.Str)
  1664. assert.Equal(t, time.Unix(1.4221728e+09, 0).UTC().String(), out.Timestamp.String())
  1665. assert.Equal(t, true, *out.TrueBool)
  1666. }
  1667. func TestOutputService2ProtocolTestNotAllMembersInResponseCase1(t *testing.T) {
  1668. svc := NewOutputService2ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1669. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Str>myname</Str></OperationNameResult><ResponseMetadata><RequestId>request-id</RequestId></ResponseMetadata></OperationNameResponse>"))
  1670. req, out := svc.OutputService2TestCaseOperation1Request(nil)
  1671. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1672. // set headers
  1673. // unmarshal response
  1674. query.UnmarshalMeta(req)
  1675. query.Unmarshal(req)
  1676. assert.NoError(t, req.Error)
  1677. // assert response
  1678. assert.NotNil(t, out) // ensure out variable is used
  1679. assert.Equal(t, "myname", *out.Str)
  1680. }
  1681. func TestOutputService3ProtocolTestBlobCase1(t *testing.T) {
  1682. svc := NewOutputService3ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1683. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Blob>dmFsdWU=</Blob></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1684. req, out := svc.OutputService3TestCaseOperation1Request(nil)
  1685. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1686. // set headers
  1687. // unmarshal response
  1688. query.UnmarshalMeta(req)
  1689. query.Unmarshal(req)
  1690. assert.NoError(t, req.Error)
  1691. // assert response
  1692. assert.NotNil(t, out) // ensure out variable is used
  1693. assert.Equal(t, "value", string(out.Blob))
  1694. }
  1695. func TestOutputService4ProtocolTestListsCase1(t *testing.T) {
  1696. svc := NewOutputService4ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1697. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><ListMember><member>abc</member><member>123</member></ListMember></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1698. req, out := svc.OutputService4TestCaseOperation1Request(nil)
  1699. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1700. // set headers
  1701. // unmarshal response
  1702. query.UnmarshalMeta(req)
  1703. query.Unmarshal(req)
  1704. assert.NoError(t, req.Error)
  1705. // assert response
  1706. assert.NotNil(t, out) // ensure out variable is used
  1707. assert.Equal(t, "abc", *out.ListMember[0])
  1708. assert.Equal(t, "123", *out.ListMember[1])
  1709. }
  1710. func TestOutputService5ProtocolTestListWithCustomMemberNameCase1(t *testing.T) {
  1711. svc := NewOutputService5ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1712. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><ListMember><item>abc</item><item>123</item></ListMember></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1713. req, out := svc.OutputService5TestCaseOperation1Request(nil)
  1714. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1715. // set headers
  1716. // unmarshal response
  1717. query.UnmarshalMeta(req)
  1718. query.Unmarshal(req)
  1719. assert.NoError(t, req.Error)
  1720. // assert response
  1721. assert.NotNil(t, out) // ensure out variable is used
  1722. assert.Equal(t, "abc", *out.ListMember[0])
  1723. assert.Equal(t, "123", *out.ListMember[1])
  1724. }
  1725. func TestOutputService6ProtocolTestFlattenedListCase1(t *testing.T) {
  1726. svc := NewOutputService6ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1727. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><ListMember>abc</ListMember><ListMember>123</ListMember></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1728. req, out := svc.OutputService6TestCaseOperation1Request(nil)
  1729. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1730. // set headers
  1731. // unmarshal response
  1732. query.UnmarshalMeta(req)
  1733. query.Unmarshal(req)
  1734. assert.NoError(t, req.Error)
  1735. // assert response
  1736. assert.NotNil(t, out) // ensure out variable is used
  1737. assert.Equal(t, "abc", *out.ListMember[0])
  1738. assert.Equal(t, "123", *out.ListMember[1])
  1739. }
  1740. func TestOutputService7ProtocolTestFlattenedSingleElementListCase1(t *testing.T) {
  1741. svc := NewOutputService7ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1742. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><ListMember>abc</ListMember></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1743. req, out := svc.OutputService7TestCaseOperation1Request(nil)
  1744. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1745. // set headers
  1746. // unmarshal response
  1747. query.UnmarshalMeta(req)
  1748. query.Unmarshal(req)
  1749. assert.NoError(t, req.Error)
  1750. // assert response
  1751. assert.NotNil(t, out) // ensure out variable is used
  1752. assert.Equal(t, "abc", *out.ListMember[0])
  1753. }
  1754. func TestOutputService8ProtocolTestListOfStructuresCase1(t *testing.T) {
  1755. svc := NewOutputService8ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1756. buf := bytes.NewReader([]byte("<OperationNameResponse xmlns=\"https://service.amazonaws.com/doc/2010-05-08/\"><OperationNameResult><List><member><Foo>firstfoo</Foo><Bar>firstbar</Bar><Baz>firstbaz</Baz></member><member><Foo>secondfoo</Foo><Bar>secondbar</Bar><Baz>secondbaz</Baz></member></List></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1757. req, out := svc.OutputService8TestCaseOperation1Request(nil)
  1758. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1759. // set headers
  1760. // unmarshal response
  1761. query.UnmarshalMeta(req)
  1762. query.Unmarshal(req)
  1763. assert.NoError(t, req.Error)
  1764. // assert response
  1765. assert.NotNil(t, out) // ensure out variable is used
  1766. assert.Equal(t, "firstbar", *out.List[0].Bar)
  1767. assert.Equal(t, "firstbaz", *out.List[0].Baz)
  1768. assert.Equal(t, "firstfoo", *out.List[0].Foo)
  1769. assert.Equal(t, "secondbar", *out.List[1].Bar)
  1770. assert.Equal(t, "secondbaz", *out.List[1].Baz)
  1771. assert.Equal(t, "secondfoo", *out.List[1].Foo)
  1772. }
  1773. func TestOutputService9ProtocolTestFlattenedListOfStructuresCase1(t *testing.T) {
  1774. svc := NewOutputService9ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1775. buf := bytes.NewReader([]byte("<OperationNameResponse xmlns=\"https://service.amazonaws.com/doc/2010-05-08/\"><OperationNameResult><List><Foo>firstfoo</Foo><Bar>firstbar</Bar><Baz>firstbaz</Baz></List><List><Foo>secondfoo</Foo><Bar>secondbar</Bar><Baz>secondbaz</Baz></List></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1776. req, out := svc.OutputService9TestCaseOperation1Request(nil)
  1777. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1778. // set headers
  1779. // unmarshal response
  1780. query.UnmarshalMeta(req)
  1781. query.Unmarshal(req)
  1782. assert.NoError(t, req.Error)
  1783. // assert response
  1784. assert.NotNil(t, out) // ensure out variable is used
  1785. assert.Equal(t, "firstbar", *out.List[0].Bar)
  1786. assert.Equal(t, "firstbaz", *out.List[0].Baz)
  1787. assert.Equal(t, "firstfoo", *out.List[0].Foo)
  1788. assert.Equal(t, "secondbar", *out.List[1].Bar)
  1789. assert.Equal(t, "secondbaz", *out.List[1].Baz)
  1790. assert.Equal(t, "secondfoo", *out.List[1].Foo)
  1791. }
  1792. func TestOutputService10ProtocolTestFlattenedListWithLocationNameCase1(t *testing.T) {
  1793. svc := NewOutputService10ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1794. buf := bytes.NewReader([]byte("<OperationNameResponse xmlns=\"https://service.amazonaws.com/doc/2010-05-08/\"><OperationNameResult><NamedList>a</NamedList><NamedList>b</NamedList></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1795. req, out := svc.OutputService10TestCaseOperation1Request(nil)
  1796. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1797. // set headers
  1798. // unmarshal response
  1799. query.UnmarshalMeta(req)
  1800. query.Unmarshal(req)
  1801. assert.NoError(t, req.Error)
  1802. // assert response
  1803. assert.NotNil(t, out) // ensure out variable is used
  1804. assert.Equal(t, "a", *out.List[0])
  1805. assert.Equal(t, "b", *out.List[1])
  1806. }
  1807. func TestOutputService11ProtocolTestNormalMapCase1(t *testing.T) {
  1808. svc := NewOutputService11ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1809. buf := bytes.NewReader([]byte("<OperationNameResponse xmlns=\"https://service.amazonaws.com/doc/2010-05-08\"><OperationNameResult><Map><entry><key>qux</key><value><foo>bar</foo></value></entry><entry><key>baz</key><value><foo>bam</foo></value></entry></Map></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1810. req, out := svc.OutputService11TestCaseOperation1Request(nil)
  1811. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1812. // set headers
  1813. // unmarshal response
  1814. query.UnmarshalMeta(req)
  1815. query.Unmarshal(req)
  1816. assert.NoError(t, req.Error)
  1817. // assert response
  1818. assert.NotNil(t, out) // ensure out variable is used
  1819. assert.Equal(t, "bam", *out.Map["baz"].Foo)
  1820. assert.Equal(t, "bar", *out.Map["qux"].Foo)
  1821. }
  1822. func TestOutputService12ProtocolTestFlattenedMapCase1(t *testing.T) {
  1823. svc := NewOutputService12ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1824. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Map><key>qux</key><value>bar</value></Map><Map><key>baz</key><value>bam</value></Map></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1825. req, out := svc.OutputService12TestCaseOperation1Request(nil)
  1826. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1827. // set headers
  1828. // unmarshal response
  1829. query.UnmarshalMeta(req)
  1830. query.Unmarshal(req)
  1831. assert.NoError(t, req.Error)
  1832. // assert response
  1833. assert.NotNil(t, out) // ensure out variable is used
  1834. assert.Equal(t, "bam", *out.Map["baz"])
  1835. assert.Equal(t, "bar", *out.Map["qux"])
  1836. }
  1837. func TestOutputService13ProtocolTestFlattenedMapInShapeDefinitionCase1(t *testing.T) {
  1838. svc := NewOutputService13ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1839. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Attribute><Name>qux</Name><Value>bar</Value></Attribute></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1840. req, out := svc.OutputService13TestCaseOperation1Request(nil)
  1841. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1842. // set headers
  1843. // unmarshal response
  1844. query.UnmarshalMeta(req)
  1845. query.Unmarshal(req)
  1846. assert.NoError(t, req.Error)
  1847. // assert response
  1848. assert.NotNil(t, out) // ensure out variable is used
  1849. assert.Equal(t, "bar", *out.Map["qux"])
  1850. }
  1851. func TestOutputService14ProtocolTestNamedMapCase1(t *testing.T) {
  1852. svc := NewOutputService14ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1853. buf := bytes.NewReader([]byte("<OperationNameResponse><OperationNameResult><Map><foo>qux</foo><bar>bar</bar></Map><Map><foo>baz</foo><bar>bam</bar></Map></OperationNameResult><ResponseMetadata><RequestId>requestid</RequestId></ResponseMetadata></OperationNameResponse>"))
  1854. req, out := svc.OutputService14TestCaseOperation1Request(nil)
  1855. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1856. // set headers
  1857. // unmarshal response
  1858. query.UnmarshalMeta(req)
  1859. query.Unmarshal(req)
  1860. assert.NoError(t, req.Error)
  1861. // assert response
  1862. assert.NotNil(t, out) // ensure out variable is used
  1863. assert.Equal(t, "bam", *out.Map["baz"])
  1864. assert.Equal(t, "bar", *out.Map["qux"])
  1865. }
  1866. func TestOutputService15ProtocolTestEmptyStringCase1(t *testing.T) {
  1867. svc := NewOutputService15ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1868. buf := bytes.NewReader([]byte("<OperationNameResponse><Foo/><RequestId>requestid</RequestId></OperationNameResponse>"))
  1869. req, out := svc.OutputService15TestCaseOperation1Request(nil)
  1870. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1871. // set headers
  1872. // unmarshal response
  1873. query.UnmarshalMeta(req)
  1874. query.Unmarshal(req)
  1875. assert.NoError(t, req.Error)
  1876. // assert response
  1877. assert.NotNil(t, out) // ensure out variable is used
  1878. assert.Equal(t, "", *out.Foo)
  1879. }