unmarshal_test.go 73 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908
  1. package restxml_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/restxml"
  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(restxml.BuildHandler)
  77. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  78. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  79. svc.Handlers.UnmarshalError.PushBackNamed(restxml.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 *OutputService1TestShapeOutputShape) {
  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 = &OutputService1TestShapeOutputShape{}
  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) (*OutputService1TestShapeOutputShape, error) {
  135. req, out := c.OutputService1TestCaseOperation1Request(input)
  136. err := req.Send()
  137. return out, err
  138. }
  139. const opOutputService1TestCaseOperation2 = "OperationName"
  140. // OutputService1TestCaseOperation2Request generates a "aws/request.Request" representing the
  141. // client's request for the OutputService1TestCaseOperation2 operation. The "output" return
  142. // value can be used to capture response data after the request's "Send" method
  143. // is called.
  144. //
  145. // See OutputService1TestCaseOperation2 for usage and error information.
  146. //
  147. // Creating a request object using this method should be used when you want to inject
  148. // custom logic into the request's lifecycle using a custom handler, or if you want to
  149. // access properties on the request object before or after sending the request. If
  150. // you just want the service response, call the OutputService1TestCaseOperation2 method directly
  151. // instead.
  152. //
  153. // Note: You must call the "Send" method on the returned request object in order
  154. // to execute the request.
  155. //
  156. // // Example sending a request using the OutputService1TestCaseOperation2Request method.
  157. // req, resp := client.OutputService1TestCaseOperation2Request(params)
  158. //
  159. // err := req.Send()
  160. // if err == nil { // resp is now filled
  161. // fmt.Println(resp)
  162. // }
  163. //
  164. func (c *OutputService1ProtocolTest) OutputService1TestCaseOperation2Request(input *OutputService1TestShapeOutputService1TestCaseOperation2Input) (req *request.Request, output *OutputService1TestShapeOutputShape) {
  165. op := &request.Operation{
  166. Name: opOutputService1TestCaseOperation2,
  167. HTTPPath: "/",
  168. }
  169. if input == nil {
  170. input = &OutputService1TestShapeOutputService1TestCaseOperation2Input{}
  171. }
  172. req = c.newRequest(op, input, output)
  173. output = &OutputService1TestShapeOutputShape{}
  174. req.Data = output
  175. return
  176. }
  177. // OutputService1TestCaseOperation2 API operation for .
  178. //
  179. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  180. // with awserr.Error's Code and Message methods to get detailed information about
  181. // the error.
  182. //
  183. // See the AWS API reference guide for 's
  184. // API operation OutputService1TestCaseOperation2 for usage and error information.
  185. func (c *OutputService1ProtocolTest) OutputService1TestCaseOperation2(input *OutputService1TestShapeOutputService1TestCaseOperation2Input) (*OutputService1TestShapeOutputShape, error) {
  186. req, out := c.OutputService1TestCaseOperation2Request(input)
  187. err := req.Send()
  188. return out, err
  189. }
  190. type OutputService1TestShapeOutputService1TestCaseOperation1Input struct {
  191. _ struct{} `type:"structure"`
  192. }
  193. type OutputService1TestShapeOutputService1TestCaseOperation2Input struct {
  194. _ struct{} `type:"structure"`
  195. }
  196. type OutputService1TestShapeOutputShape struct {
  197. _ struct{} `type:"structure"`
  198. Char *string `type:"character"`
  199. Double *float64 `type:"double"`
  200. FalseBool *bool `type:"boolean"`
  201. Float *float64 `type:"float"`
  202. ImaHeader *string `location:"header" type:"string"`
  203. ImaHeaderLocation *string `location:"header" locationName:"X-Foo" type:"string"`
  204. Long *int64 `type:"long"`
  205. Num *int64 `locationName:"FooNum" type:"integer"`
  206. Str *string `type:"string"`
  207. Timestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  208. TrueBool *bool `type:"boolean"`
  209. }
  210. //The service client's operations are safe to be used concurrently.
  211. // It is not safe to mutate any of the client's properties though.
  212. type OutputService2ProtocolTest struct {
  213. *client.Client
  214. }
  215. // New creates a new instance of the OutputService2ProtocolTest client with a session.
  216. // If additional configuration is needed for the client instance use the optional
  217. // aws.Config parameter to add your extra config.
  218. //
  219. // Example:
  220. // // Create a OutputService2ProtocolTest client from just a session.
  221. // svc := outputservice2protocoltest.New(mySession)
  222. //
  223. // // Create a OutputService2ProtocolTest client with additional configuration
  224. // svc := outputservice2protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  225. func NewOutputService2ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService2ProtocolTest {
  226. c := p.ClientConfig("outputservice2protocoltest", cfgs...)
  227. return newOutputService2ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  228. }
  229. // newClient creates, initializes and returns a new service client instance.
  230. func newOutputService2ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService2ProtocolTest {
  231. svc := &OutputService2ProtocolTest{
  232. Client: client.New(
  233. cfg,
  234. metadata.ClientInfo{
  235. ServiceName: "outputservice2protocoltest",
  236. SigningRegion: signingRegion,
  237. Endpoint: endpoint,
  238. APIVersion: "",
  239. },
  240. handlers,
  241. ),
  242. }
  243. // Handlers
  244. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  245. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  246. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  247. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  248. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  249. return svc
  250. }
  251. // newRequest creates a new request for a OutputService2ProtocolTest operation and runs any
  252. // custom request initialization.
  253. func (c *OutputService2ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  254. req := c.NewRequest(op, params, data)
  255. return req
  256. }
  257. const opOutputService2TestCaseOperation1 = "OperationName"
  258. // OutputService2TestCaseOperation1Request generates a "aws/request.Request" representing the
  259. // client's request for the OutputService2TestCaseOperation1 operation. The "output" return
  260. // value can be used to capture response data after the request's "Send" method
  261. // is called.
  262. //
  263. // See OutputService2TestCaseOperation1 for usage and error information.
  264. //
  265. // Creating a request object using this method should be used when you want to inject
  266. // custom logic into the request's lifecycle using a custom handler, or if you want to
  267. // access properties on the request object before or after sending the request. If
  268. // you just want the service response, call the OutputService2TestCaseOperation1 method directly
  269. // instead.
  270. //
  271. // Note: You must call the "Send" method on the returned request object in order
  272. // to execute the request.
  273. //
  274. // // Example sending a request using the OutputService2TestCaseOperation1Request method.
  275. // req, resp := client.OutputService2TestCaseOperation1Request(params)
  276. //
  277. // err := req.Send()
  278. // if err == nil { // resp is now filled
  279. // fmt.Println(resp)
  280. // }
  281. //
  282. func (c *OutputService2ProtocolTest) OutputService2TestCaseOperation1Request(input *OutputService2TestShapeOutputService2TestCaseOperation1Input) (req *request.Request, output *OutputService2TestShapeOutputService2TestCaseOperation1Output) {
  283. op := &request.Operation{
  284. Name: opOutputService2TestCaseOperation1,
  285. HTTPPath: "/",
  286. }
  287. if input == nil {
  288. input = &OutputService2TestShapeOutputService2TestCaseOperation1Input{}
  289. }
  290. req = c.newRequest(op, input, output)
  291. output = &OutputService2TestShapeOutputService2TestCaseOperation1Output{}
  292. req.Data = output
  293. return
  294. }
  295. // OutputService2TestCaseOperation1 API operation for .
  296. //
  297. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  298. // with awserr.Error's Code and Message methods to get detailed information about
  299. // the error.
  300. //
  301. // See the AWS API reference guide for 's
  302. // API operation OutputService2TestCaseOperation1 for usage and error information.
  303. func (c *OutputService2ProtocolTest) OutputService2TestCaseOperation1(input *OutputService2TestShapeOutputService2TestCaseOperation1Input) (*OutputService2TestShapeOutputService2TestCaseOperation1Output, error) {
  304. req, out := c.OutputService2TestCaseOperation1Request(input)
  305. err := req.Send()
  306. return out, err
  307. }
  308. type OutputService2TestShapeOutputService2TestCaseOperation1Input struct {
  309. _ struct{} `type:"structure"`
  310. }
  311. type OutputService2TestShapeOutputService2TestCaseOperation1Output struct {
  312. _ struct{} `type:"structure"`
  313. // Blob is automatically base64 encoded/decoded by the SDK.
  314. Blob []byte `type:"blob"`
  315. }
  316. //The service client's operations are safe to be used concurrently.
  317. // It is not safe to mutate any of the client's properties though.
  318. type OutputService3ProtocolTest struct {
  319. *client.Client
  320. }
  321. // New creates a new instance of the OutputService3ProtocolTest client with a session.
  322. // If additional configuration is needed for the client instance use the optional
  323. // aws.Config parameter to add your extra config.
  324. //
  325. // Example:
  326. // // Create a OutputService3ProtocolTest client from just a session.
  327. // svc := outputservice3protocoltest.New(mySession)
  328. //
  329. // // Create a OutputService3ProtocolTest client with additional configuration
  330. // svc := outputservice3protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  331. func NewOutputService3ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService3ProtocolTest {
  332. c := p.ClientConfig("outputservice3protocoltest", cfgs...)
  333. return newOutputService3ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  334. }
  335. // newClient creates, initializes and returns a new service client instance.
  336. func newOutputService3ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService3ProtocolTest {
  337. svc := &OutputService3ProtocolTest{
  338. Client: client.New(
  339. cfg,
  340. metadata.ClientInfo{
  341. ServiceName: "outputservice3protocoltest",
  342. SigningRegion: signingRegion,
  343. Endpoint: endpoint,
  344. APIVersion: "",
  345. },
  346. handlers,
  347. ),
  348. }
  349. // Handlers
  350. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  351. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  352. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  353. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  354. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  355. return svc
  356. }
  357. // newRequest creates a new request for a OutputService3ProtocolTest operation and runs any
  358. // custom request initialization.
  359. func (c *OutputService3ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  360. req := c.NewRequest(op, params, data)
  361. return req
  362. }
  363. const opOutputService3TestCaseOperation1 = "OperationName"
  364. // OutputService3TestCaseOperation1Request generates a "aws/request.Request" representing the
  365. // client's request for the OutputService3TestCaseOperation1 operation. The "output" return
  366. // value can be used to capture response data after the request's "Send" method
  367. // is called.
  368. //
  369. // See OutputService3TestCaseOperation1 for usage and error information.
  370. //
  371. // Creating a request object using this method should be used when you want to inject
  372. // custom logic into the request's lifecycle using a custom handler, or if you want to
  373. // access properties on the request object before or after sending the request. If
  374. // you just want the service response, call the OutputService3TestCaseOperation1 method directly
  375. // instead.
  376. //
  377. // Note: You must call the "Send" method on the returned request object in order
  378. // to execute the request.
  379. //
  380. // // Example sending a request using the OutputService3TestCaseOperation1Request method.
  381. // req, resp := client.OutputService3TestCaseOperation1Request(params)
  382. //
  383. // err := req.Send()
  384. // if err == nil { // resp is now filled
  385. // fmt.Println(resp)
  386. // }
  387. //
  388. func (c *OutputService3ProtocolTest) OutputService3TestCaseOperation1Request(input *OutputService3TestShapeOutputService3TestCaseOperation1Input) (req *request.Request, output *OutputService3TestShapeOutputService3TestCaseOperation1Output) {
  389. op := &request.Operation{
  390. Name: opOutputService3TestCaseOperation1,
  391. HTTPPath: "/",
  392. }
  393. if input == nil {
  394. input = &OutputService3TestShapeOutputService3TestCaseOperation1Input{}
  395. }
  396. req = c.newRequest(op, input, output)
  397. output = &OutputService3TestShapeOutputService3TestCaseOperation1Output{}
  398. req.Data = output
  399. return
  400. }
  401. // OutputService3TestCaseOperation1 API operation for .
  402. //
  403. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  404. // with awserr.Error's Code and Message methods to get detailed information about
  405. // the error.
  406. //
  407. // See the AWS API reference guide for 's
  408. // API operation OutputService3TestCaseOperation1 for usage and error information.
  409. func (c *OutputService3ProtocolTest) OutputService3TestCaseOperation1(input *OutputService3TestShapeOutputService3TestCaseOperation1Input) (*OutputService3TestShapeOutputService3TestCaseOperation1Output, error) {
  410. req, out := c.OutputService3TestCaseOperation1Request(input)
  411. err := req.Send()
  412. return out, err
  413. }
  414. type OutputService3TestShapeOutputService3TestCaseOperation1Input struct {
  415. _ struct{} `type:"structure"`
  416. }
  417. type OutputService3TestShapeOutputService3TestCaseOperation1Output struct {
  418. _ struct{} `type:"structure"`
  419. ListMember []*string `type:"list"`
  420. }
  421. //The service client's operations are safe to be used concurrently.
  422. // It is not safe to mutate any of the client's properties though.
  423. type OutputService4ProtocolTest struct {
  424. *client.Client
  425. }
  426. // New creates a new instance of the OutputService4ProtocolTest client with a session.
  427. // If additional configuration is needed for the client instance use the optional
  428. // aws.Config parameter to add your extra config.
  429. //
  430. // Example:
  431. // // Create a OutputService4ProtocolTest client from just a session.
  432. // svc := outputservice4protocoltest.New(mySession)
  433. //
  434. // // Create a OutputService4ProtocolTest client with additional configuration
  435. // svc := outputservice4protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  436. func NewOutputService4ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService4ProtocolTest {
  437. c := p.ClientConfig("outputservice4protocoltest", cfgs...)
  438. return newOutputService4ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  439. }
  440. // newClient creates, initializes and returns a new service client instance.
  441. func newOutputService4ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService4ProtocolTest {
  442. svc := &OutputService4ProtocolTest{
  443. Client: client.New(
  444. cfg,
  445. metadata.ClientInfo{
  446. ServiceName: "outputservice4protocoltest",
  447. SigningRegion: signingRegion,
  448. Endpoint: endpoint,
  449. APIVersion: "",
  450. },
  451. handlers,
  452. ),
  453. }
  454. // Handlers
  455. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  456. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  457. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  458. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  459. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  460. return svc
  461. }
  462. // newRequest creates a new request for a OutputService4ProtocolTest operation and runs any
  463. // custom request initialization.
  464. func (c *OutputService4ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  465. req := c.NewRequest(op, params, data)
  466. return req
  467. }
  468. const opOutputService4TestCaseOperation1 = "OperationName"
  469. // OutputService4TestCaseOperation1Request generates a "aws/request.Request" representing the
  470. // client's request for the OutputService4TestCaseOperation1 operation. The "output" return
  471. // value can be used to capture response data after the request's "Send" method
  472. // is called.
  473. //
  474. // See OutputService4TestCaseOperation1 for usage and error information.
  475. //
  476. // Creating a request object using this method should be used when you want to inject
  477. // custom logic into the request's lifecycle using a custom handler, or if you want to
  478. // access properties on the request object before or after sending the request. If
  479. // you just want the service response, call the OutputService4TestCaseOperation1 method directly
  480. // instead.
  481. //
  482. // Note: You must call the "Send" method on the returned request object in order
  483. // to execute the request.
  484. //
  485. // // Example sending a request using the OutputService4TestCaseOperation1Request method.
  486. // req, resp := client.OutputService4TestCaseOperation1Request(params)
  487. //
  488. // err := req.Send()
  489. // if err == nil { // resp is now filled
  490. // fmt.Println(resp)
  491. // }
  492. //
  493. func (c *OutputService4ProtocolTest) OutputService4TestCaseOperation1Request(input *OutputService4TestShapeOutputService4TestCaseOperation1Input) (req *request.Request, output *OutputService4TestShapeOutputService4TestCaseOperation1Output) {
  494. op := &request.Operation{
  495. Name: opOutputService4TestCaseOperation1,
  496. HTTPPath: "/",
  497. }
  498. if input == nil {
  499. input = &OutputService4TestShapeOutputService4TestCaseOperation1Input{}
  500. }
  501. req = c.newRequest(op, input, output)
  502. output = &OutputService4TestShapeOutputService4TestCaseOperation1Output{}
  503. req.Data = output
  504. return
  505. }
  506. // OutputService4TestCaseOperation1 API operation for .
  507. //
  508. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  509. // with awserr.Error's Code and Message methods to get detailed information about
  510. // the error.
  511. //
  512. // See the AWS API reference guide for 's
  513. // API operation OutputService4TestCaseOperation1 for usage and error information.
  514. func (c *OutputService4ProtocolTest) OutputService4TestCaseOperation1(input *OutputService4TestShapeOutputService4TestCaseOperation1Input) (*OutputService4TestShapeOutputService4TestCaseOperation1Output, error) {
  515. req, out := c.OutputService4TestCaseOperation1Request(input)
  516. err := req.Send()
  517. return out, err
  518. }
  519. type OutputService4TestShapeOutputService4TestCaseOperation1Input struct {
  520. _ struct{} `type:"structure"`
  521. }
  522. type OutputService4TestShapeOutputService4TestCaseOperation1Output struct {
  523. _ struct{} `type:"structure"`
  524. ListMember []*string `locationNameList:"item" type:"list"`
  525. }
  526. //The service client's operations are safe to be used concurrently.
  527. // It is not safe to mutate any of the client's properties though.
  528. type OutputService5ProtocolTest struct {
  529. *client.Client
  530. }
  531. // New creates a new instance of the OutputService5ProtocolTest client with a session.
  532. // If additional configuration is needed for the client instance use the optional
  533. // aws.Config parameter to add your extra config.
  534. //
  535. // Example:
  536. // // Create a OutputService5ProtocolTest client from just a session.
  537. // svc := outputservice5protocoltest.New(mySession)
  538. //
  539. // // Create a OutputService5ProtocolTest client with additional configuration
  540. // svc := outputservice5protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  541. func NewOutputService5ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService5ProtocolTest {
  542. c := p.ClientConfig("outputservice5protocoltest", cfgs...)
  543. return newOutputService5ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  544. }
  545. // newClient creates, initializes and returns a new service client instance.
  546. func newOutputService5ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService5ProtocolTest {
  547. svc := &OutputService5ProtocolTest{
  548. Client: client.New(
  549. cfg,
  550. metadata.ClientInfo{
  551. ServiceName: "outputservice5protocoltest",
  552. SigningRegion: signingRegion,
  553. Endpoint: endpoint,
  554. APIVersion: "",
  555. },
  556. handlers,
  557. ),
  558. }
  559. // Handlers
  560. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  561. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  562. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  563. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  564. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  565. return svc
  566. }
  567. // newRequest creates a new request for a OutputService5ProtocolTest operation and runs any
  568. // custom request initialization.
  569. func (c *OutputService5ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  570. req := c.NewRequest(op, params, data)
  571. return req
  572. }
  573. const opOutputService5TestCaseOperation1 = "OperationName"
  574. // OutputService5TestCaseOperation1Request generates a "aws/request.Request" representing the
  575. // client's request for the OutputService5TestCaseOperation1 operation. The "output" return
  576. // value can be used to capture response data after the request's "Send" method
  577. // is called.
  578. //
  579. // See OutputService5TestCaseOperation1 for usage and error information.
  580. //
  581. // Creating a request object using this method should be used when you want to inject
  582. // custom logic into the request's lifecycle using a custom handler, or if you want to
  583. // access properties on the request object before or after sending the request. If
  584. // you just want the service response, call the OutputService5TestCaseOperation1 method directly
  585. // instead.
  586. //
  587. // Note: You must call the "Send" method on the returned request object in order
  588. // to execute the request.
  589. //
  590. // // Example sending a request using the OutputService5TestCaseOperation1Request method.
  591. // req, resp := client.OutputService5TestCaseOperation1Request(params)
  592. //
  593. // err := req.Send()
  594. // if err == nil { // resp is now filled
  595. // fmt.Println(resp)
  596. // }
  597. //
  598. func (c *OutputService5ProtocolTest) OutputService5TestCaseOperation1Request(input *OutputService5TestShapeOutputService5TestCaseOperation1Input) (req *request.Request, output *OutputService5TestShapeOutputService5TestCaseOperation1Output) {
  599. op := &request.Operation{
  600. Name: opOutputService5TestCaseOperation1,
  601. HTTPPath: "/",
  602. }
  603. if input == nil {
  604. input = &OutputService5TestShapeOutputService5TestCaseOperation1Input{}
  605. }
  606. req = c.newRequest(op, input, output)
  607. output = &OutputService5TestShapeOutputService5TestCaseOperation1Output{}
  608. req.Data = output
  609. return
  610. }
  611. // OutputService5TestCaseOperation1 API operation for .
  612. //
  613. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  614. // with awserr.Error's Code and Message methods to get detailed information about
  615. // the error.
  616. //
  617. // See the AWS API reference guide for 's
  618. // API operation OutputService5TestCaseOperation1 for usage and error information.
  619. func (c *OutputService5ProtocolTest) OutputService5TestCaseOperation1(input *OutputService5TestShapeOutputService5TestCaseOperation1Input) (*OutputService5TestShapeOutputService5TestCaseOperation1Output, error) {
  620. req, out := c.OutputService5TestCaseOperation1Request(input)
  621. err := req.Send()
  622. return out, err
  623. }
  624. type OutputService5TestShapeOutputService5TestCaseOperation1Input struct {
  625. _ struct{} `type:"structure"`
  626. }
  627. type OutputService5TestShapeOutputService5TestCaseOperation1Output struct {
  628. _ struct{} `type:"structure"`
  629. ListMember []*string `type:"list" flattened:"true"`
  630. }
  631. //The service client's operations are safe to be used concurrently.
  632. // It is not safe to mutate any of the client's properties though.
  633. type OutputService6ProtocolTest struct {
  634. *client.Client
  635. }
  636. // New creates a new instance of the OutputService6ProtocolTest client with a session.
  637. // If additional configuration is needed for the client instance use the optional
  638. // aws.Config parameter to add your extra config.
  639. //
  640. // Example:
  641. // // Create a OutputService6ProtocolTest client from just a session.
  642. // svc := outputservice6protocoltest.New(mySession)
  643. //
  644. // // Create a OutputService6ProtocolTest client with additional configuration
  645. // svc := outputservice6protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  646. func NewOutputService6ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService6ProtocolTest {
  647. c := p.ClientConfig("outputservice6protocoltest", cfgs...)
  648. return newOutputService6ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  649. }
  650. // newClient creates, initializes and returns a new service client instance.
  651. func newOutputService6ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService6ProtocolTest {
  652. svc := &OutputService6ProtocolTest{
  653. Client: client.New(
  654. cfg,
  655. metadata.ClientInfo{
  656. ServiceName: "outputservice6protocoltest",
  657. SigningRegion: signingRegion,
  658. Endpoint: endpoint,
  659. APIVersion: "",
  660. },
  661. handlers,
  662. ),
  663. }
  664. // Handlers
  665. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  666. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  667. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  668. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  669. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  670. return svc
  671. }
  672. // newRequest creates a new request for a OutputService6ProtocolTest operation and runs any
  673. // custom request initialization.
  674. func (c *OutputService6ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  675. req := c.NewRequest(op, params, data)
  676. return req
  677. }
  678. const opOutputService6TestCaseOperation1 = "OperationName"
  679. // OutputService6TestCaseOperation1Request generates a "aws/request.Request" representing the
  680. // client's request for the OutputService6TestCaseOperation1 operation. The "output" return
  681. // value can be used to capture response data after the request's "Send" method
  682. // is called.
  683. //
  684. // See OutputService6TestCaseOperation1 for usage and error information.
  685. //
  686. // Creating a request object using this method should be used when you want to inject
  687. // custom logic into the request's lifecycle using a custom handler, or if you want to
  688. // access properties on the request object before or after sending the request. If
  689. // you just want the service response, call the OutputService6TestCaseOperation1 method directly
  690. // instead.
  691. //
  692. // Note: You must call the "Send" method on the returned request object in order
  693. // to execute the request.
  694. //
  695. // // Example sending a request using the OutputService6TestCaseOperation1Request method.
  696. // req, resp := client.OutputService6TestCaseOperation1Request(params)
  697. //
  698. // err := req.Send()
  699. // if err == nil { // resp is now filled
  700. // fmt.Println(resp)
  701. // }
  702. //
  703. func (c *OutputService6ProtocolTest) OutputService6TestCaseOperation1Request(input *OutputService6TestShapeOutputService6TestCaseOperation1Input) (req *request.Request, output *OutputService6TestShapeOutputService6TestCaseOperation1Output) {
  704. op := &request.Operation{
  705. Name: opOutputService6TestCaseOperation1,
  706. HTTPPath: "/",
  707. }
  708. if input == nil {
  709. input = &OutputService6TestShapeOutputService6TestCaseOperation1Input{}
  710. }
  711. req = c.newRequest(op, input, output)
  712. output = &OutputService6TestShapeOutputService6TestCaseOperation1Output{}
  713. req.Data = output
  714. return
  715. }
  716. // OutputService6TestCaseOperation1 API operation for .
  717. //
  718. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  719. // with awserr.Error's Code and Message methods to get detailed information about
  720. // the error.
  721. //
  722. // See the AWS API reference guide for 's
  723. // API operation OutputService6TestCaseOperation1 for usage and error information.
  724. func (c *OutputService6ProtocolTest) OutputService6TestCaseOperation1(input *OutputService6TestShapeOutputService6TestCaseOperation1Input) (*OutputService6TestShapeOutputService6TestCaseOperation1Output, error) {
  725. req, out := c.OutputService6TestCaseOperation1Request(input)
  726. err := req.Send()
  727. return out, err
  728. }
  729. type OutputService6TestShapeOutputService6TestCaseOperation1Input struct {
  730. _ struct{} `type:"structure"`
  731. }
  732. type OutputService6TestShapeOutputService6TestCaseOperation1Output struct {
  733. _ struct{} `type:"structure"`
  734. Map map[string]*OutputService6TestShapeSingleStructure `type:"map"`
  735. }
  736. type OutputService6TestShapeSingleStructure struct {
  737. _ struct{} `type:"structure"`
  738. Foo *string `locationName:"foo" type:"string"`
  739. }
  740. //The service client's operations are safe to be used concurrently.
  741. // It is not safe to mutate any of the client's properties though.
  742. type OutputService7ProtocolTest struct {
  743. *client.Client
  744. }
  745. // New creates a new instance of the OutputService7ProtocolTest client with a session.
  746. // If additional configuration is needed for the client instance use the optional
  747. // aws.Config parameter to add your extra config.
  748. //
  749. // Example:
  750. // // Create a OutputService7ProtocolTest client from just a session.
  751. // svc := outputservice7protocoltest.New(mySession)
  752. //
  753. // // Create a OutputService7ProtocolTest client with additional configuration
  754. // svc := outputservice7protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  755. func NewOutputService7ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService7ProtocolTest {
  756. c := p.ClientConfig("outputservice7protocoltest", cfgs...)
  757. return newOutputService7ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  758. }
  759. // newClient creates, initializes and returns a new service client instance.
  760. func newOutputService7ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService7ProtocolTest {
  761. svc := &OutputService7ProtocolTest{
  762. Client: client.New(
  763. cfg,
  764. metadata.ClientInfo{
  765. ServiceName: "outputservice7protocoltest",
  766. SigningRegion: signingRegion,
  767. Endpoint: endpoint,
  768. APIVersion: "",
  769. },
  770. handlers,
  771. ),
  772. }
  773. // Handlers
  774. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  775. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  776. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  777. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  778. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  779. return svc
  780. }
  781. // newRequest creates a new request for a OutputService7ProtocolTest operation and runs any
  782. // custom request initialization.
  783. func (c *OutputService7ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  784. req := c.NewRequest(op, params, data)
  785. return req
  786. }
  787. const opOutputService7TestCaseOperation1 = "OperationName"
  788. // OutputService7TestCaseOperation1Request generates a "aws/request.Request" representing the
  789. // client's request for the OutputService7TestCaseOperation1 operation. The "output" return
  790. // value can be used to capture response data after the request's "Send" method
  791. // is called.
  792. //
  793. // See OutputService7TestCaseOperation1 for usage and error information.
  794. //
  795. // Creating a request object using this method should be used when you want to inject
  796. // custom logic into the request's lifecycle using a custom handler, or if you want to
  797. // access properties on the request object before or after sending the request. If
  798. // you just want the service response, call the OutputService7TestCaseOperation1 method directly
  799. // instead.
  800. //
  801. // Note: You must call the "Send" method on the returned request object in order
  802. // to execute the request.
  803. //
  804. // // Example sending a request using the OutputService7TestCaseOperation1Request method.
  805. // req, resp := client.OutputService7TestCaseOperation1Request(params)
  806. //
  807. // err := req.Send()
  808. // if err == nil { // resp is now filled
  809. // fmt.Println(resp)
  810. // }
  811. //
  812. func (c *OutputService7ProtocolTest) OutputService7TestCaseOperation1Request(input *OutputService7TestShapeOutputService7TestCaseOperation1Input) (req *request.Request, output *OutputService7TestShapeOutputService7TestCaseOperation1Output) {
  813. op := &request.Operation{
  814. Name: opOutputService7TestCaseOperation1,
  815. HTTPPath: "/",
  816. }
  817. if input == nil {
  818. input = &OutputService7TestShapeOutputService7TestCaseOperation1Input{}
  819. }
  820. req = c.newRequest(op, input, output)
  821. output = &OutputService7TestShapeOutputService7TestCaseOperation1Output{}
  822. req.Data = output
  823. return
  824. }
  825. // OutputService7TestCaseOperation1 API operation for .
  826. //
  827. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  828. // with awserr.Error's Code and Message methods to get detailed information about
  829. // the error.
  830. //
  831. // See the AWS API reference guide for 's
  832. // API operation OutputService7TestCaseOperation1 for usage and error information.
  833. func (c *OutputService7ProtocolTest) OutputService7TestCaseOperation1(input *OutputService7TestShapeOutputService7TestCaseOperation1Input) (*OutputService7TestShapeOutputService7TestCaseOperation1Output, error) {
  834. req, out := c.OutputService7TestCaseOperation1Request(input)
  835. err := req.Send()
  836. return out, err
  837. }
  838. type OutputService7TestShapeOutputService7TestCaseOperation1Input struct {
  839. _ struct{} `type:"structure"`
  840. }
  841. type OutputService7TestShapeOutputService7TestCaseOperation1Output struct {
  842. _ struct{} `type:"structure"`
  843. Map map[string]*string `type:"map" flattened:"true"`
  844. }
  845. //The service client's operations are safe to be used concurrently.
  846. // It is not safe to mutate any of the client's properties though.
  847. type OutputService8ProtocolTest struct {
  848. *client.Client
  849. }
  850. // New creates a new instance of the OutputService8ProtocolTest client with a session.
  851. // If additional configuration is needed for the client instance use the optional
  852. // aws.Config parameter to add your extra config.
  853. //
  854. // Example:
  855. // // Create a OutputService8ProtocolTest client from just a session.
  856. // svc := outputservice8protocoltest.New(mySession)
  857. //
  858. // // Create a OutputService8ProtocolTest client with additional configuration
  859. // svc := outputservice8protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  860. func NewOutputService8ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService8ProtocolTest {
  861. c := p.ClientConfig("outputservice8protocoltest", cfgs...)
  862. return newOutputService8ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  863. }
  864. // newClient creates, initializes and returns a new service client instance.
  865. func newOutputService8ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService8ProtocolTest {
  866. svc := &OutputService8ProtocolTest{
  867. Client: client.New(
  868. cfg,
  869. metadata.ClientInfo{
  870. ServiceName: "outputservice8protocoltest",
  871. SigningRegion: signingRegion,
  872. Endpoint: endpoint,
  873. APIVersion: "",
  874. },
  875. handlers,
  876. ),
  877. }
  878. // Handlers
  879. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  880. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  881. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  882. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  883. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  884. return svc
  885. }
  886. // newRequest creates a new request for a OutputService8ProtocolTest operation and runs any
  887. // custom request initialization.
  888. func (c *OutputService8ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  889. req := c.NewRequest(op, params, data)
  890. return req
  891. }
  892. const opOutputService8TestCaseOperation1 = "OperationName"
  893. // OutputService8TestCaseOperation1Request generates a "aws/request.Request" representing the
  894. // client's request for the OutputService8TestCaseOperation1 operation. The "output" return
  895. // value can be used to capture response data after the request's "Send" method
  896. // is called.
  897. //
  898. // See OutputService8TestCaseOperation1 for usage and error information.
  899. //
  900. // Creating a request object using this method should be used when you want to inject
  901. // custom logic into the request's lifecycle using a custom handler, or if you want to
  902. // access properties on the request object before or after sending the request. If
  903. // you just want the service response, call the OutputService8TestCaseOperation1 method directly
  904. // instead.
  905. //
  906. // Note: You must call the "Send" method on the returned request object in order
  907. // to execute the request.
  908. //
  909. // // Example sending a request using the OutputService8TestCaseOperation1Request method.
  910. // req, resp := client.OutputService8TestCaseOperation1Request(params)
  911. //
  912. // err := req.Send()
  913. // if err == nil { // resp is now filled
  914. // fmt.Println(resp)
  915. // }
  916. //
  917. func (c *OutputService8ProtocolTest) OutputService8TestCaseOperation1Request(input *OutputService8TestShapeOutputService8TestCaseOperation1Input) (req *request.Request, output *OutputService8TestShapeOutputService8TestCaseOperation1Output) {
  918. op := &request.Operation{
  919. Name: opOutputService8TestCaseOperation1,
  920. HTTPPath: "/",
  921. }
  922. if input == nil {
  923. input = &OutputService8TestShapeOutputService8TestCaseOperation1Input{}
  924. }
  925. req = c.newRequest(op, input, output)
  926. output = &OutputService8TestShapeOutputService8TestCaseOperation1Output{}
  927. req.Data = output
  928. return
  929. }
  930. // OutputService8TestCaseOperation1 API operation for .
  931. //
  932. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  933. // with awserr.Error's Code and Message methods to get detailed information about
  934. // the error.
  935. //
  936. // See the AWS API reference guide for 's
  937. // API operation OutputService8TestCaseOperation1 for usage and error information.
  938. func (c *OutputService8ProtocolTest) OutputService8TestCaseOperation1(input *OutputService8TestShapeOutputService8TestCaseOperation1Input) (*OutputService8TestShapeOutputService8TestCaseOperation1Output, error) {
  939. req, out := c.OutputService8TestCaseOperation1Request(input)
  940. err := req.Send()
  941. return out, err
  942. }
  943. type OutputService8TestShapeOutputService8TestCaseOperation1Input struct {
  944. _ struct{} `type:"structure"`
  945. }
  946. type OutputService8TestShapeOutputService8TestCaseOperation1Output struct {
  947. _ struct{} `type:"structure"`
  948. Map map[string]*string `locationNameKey:"foo" locationNameValue:"bar" type:"map"`
  949. }
  950. //The service client's operations are safe to be used concurrently.
  951. // It is not safe to mutate any of the client's properties though.
  952. type OutputService9ProtocolTest struct {
  953. *client.Client
  954. }
  955. // New creates a new instance of the OutputService9ProtocolTest client with a session.
  956. // If additional configuration is needed for the client instance use the optional
  957. // aws.Config parameter to add your extra config.
  958. //
  959. // Example:
  960. // // Create a OutputService9ProtocolTest client from just a session.
  961. // svc := outputservice9protocoltest.New(mySession)
  962. //
  963. // // Create a OutputService9ProtocolTest client with additional configuration
  964. // svc := outputservice9protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  965. func NewOutputService9ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService9ProtocolTest {
  966. c := p.ClientConfig("outputservice9protocoltest", cfgs...)
  967. return newOutputService9ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  968. }
  969. // newClient creates, initializes and returns a new service client instance.
  970. func newOutputService9ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService9ProtocolTest {
  971. svc := &OutputService9ProtocolTest{
  972. Client: client.New(
  973. cfg,
  974. metadata.ClientInfo{
  975. ServiceName: "outputservice9protocoltest",
  976. SigningRegion: signingRegion,
  977. Endpoint: endpoint,
  978. APIVersion: "",
  979. },
  980. handlers,
  981. ),
  982. }
  983. // Handlers
  984. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  985. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  986. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  987. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  988. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  989. return svc
  990. }
  991. // newRequest creates a new request for a OutputService9ProtocolTest operation and runs any
  992. // custom request initialization.
  993. func (c *OutputService9ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  994. req := c.NewRequest(op, params, data)
  995. return req
  996. }
  997. const opOutputService9TestCaseOperation1 = "OperationName"
  998. // OutputService9TestCaseOperation1Request generates a "aws/request.Request" representing the
  999. // client's request for the OutputService9TestCaseOperation1 operation. The "output" return
  1000. // value can be used to capture response data after the request's "Send" method
  1001. // is called.
  1002. //
  1003. // See OutputService9TestCaseOperation1 for usage and error information.
  1004. //
  1005. // Creating a request object using this method should be used when you want to inject
  1006. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1007. // access properties on the request object before or after sending the request. If
  1008. // you just want the service response, call the OutputService9TestCaseOperation1 method directly
  1009. // instead.
  1010. //
  1011. // Note: You must call the "Send" method on the returned request object in order
  1012. // to execute the request.
  1013. //
  1014. // // Example sending a request using the OutputService9TestCaseOperation1Request method.
  1015. // req, resp := client.OutputService9TestCaseOperation1Request(params)
  1016. //
  1017. // err := req.Send()
  1018. // if err == nil { // resp is now filled
  1019. // fmt.Println(resp)
  1020. // }
  1021. //
  1022. func (c *OutputService9ProtocolTest) OutputService9TestCaseOperation1Request(input *OutputService9TestShapeOutputService9TestCaseOperation1Input) (req *request.Request, output *OutputService9TestShapeOutputService9TestCaseOperation1Output) {
  1023. op := &request.Operation{
  1024. Name: opOutputService9TestCaseOperation1,
  1025. HTTPPath: "/",
  1026. }
  1027. if input == nil {
  1028. input = &OutputService9TestShapeOutputService9TestCaseOperation1Input{}
  1029. }
  1030. req = c.newRequest(op, input, output)
  1031. output = &OutputService9TestShapeOutputService9TestCaseOperation1Output{}
  1032. req.Data = output
  1033. return
  1034. }
  1035. // OutputService9TestCaseOperation1 API operation for .
  1036. //
  1037. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1038. // with awserr.Error's Code and Message methods to get detailed information about
  1039. // the error.
  1040. //
  1041. // See the AWS API reference guide for 's
  1042. // API operation OutputService9TestCaseOperation1 for usage and error information.
  1043. func (c *OutputService9ProtocolTest) OutputService9TestCaseOperation1(input *OutputService9TestShapeOutputService9TestCaseOperation1Input) (*OutputService9TestShapeOutputService9TestCaseOperation1Output, error) {
  1044. req, out := c.OutputService9TestCaseOperation1Request(input)
  1045. err := req.Send()
  1046. return out, err
  1047. }
  1048. type OutputService9TestShapeOutputService9TestCaseOperation1Input struct {
  1049. _ struct{} `type:"structure"`
  1050. }
  1051. type OutputService9TestShapeOutputService9TestCaseOperation1Output struct {
  1052. _ struct{} `type:"structure" payload:"Data"`
  1053. Data *OutputService9TestShapeSingleStructure `type:"structure"`
  1054. Header *string `location:"header" locationName:"X-Foo" type:"string"`
  1055. }
  1056. type OutputService9TestShapeSingleStructure struct {
  1057. _ struct{} `type:"structure"`
  1058. Foo *string `type:"string"`
  1059. }
  1060. //The service client's operations are safe to be used concurrently.
  1061. // It is not safe to mutate any of the client's properties though.
  1062. type OutputService10ProtocolTest struct {
  1063. *client.Client
  1064. }
  1065. // New creates a new instance of the OutputService10ProtocolTest client with a session.
  1066. // If additional configuration is needed for the client instance use the optional
  1067. // aws.Config parameter to add your extra config.
  1068. //
  1069. // Example:
  1070. // // Create a OutputService10ProtocolTest client from just a session.
  1071. // svc := outputservice10protocoltest.New(mySession)
  1072. //
  1073. // // Create a OutputService10ProtocolTest client with additional configuration
  1074. // svc := outputservice10protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1075. func NewOutputService10ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService10ProtocolTest {
  1076. c := p.ClientConfig("outputservice10protocoltest", cfgs...)
  1077. return newOutputService10ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1078. }
  1079. // newClient creates, initializes and returns a new service client instance.
  1080. func newOutputService10ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService10ProtocolTest {
  1081. svc := &OutputService10ProtocolTest{
  1082. Client: client.New(
  1083. cfg,
  1084. metadata.ClientInfo{
  1085. ServiceName: "outputservice10protocoltest",
  1086. SigningRegion: signingRegion,
  1087. Endpoint: endpoint,
  1088. APIVersion: "",
  1089. },
  1090. handlers,
  1091. ),
  1092. }
  1093. // Handlers
  1094. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1095. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  1096. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  1097. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  1098. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  1099. return svc
  1100. }
  1101. // newRequest creates a new request for a OutputService10ProtocolTest operation and runs any
  1102. // custom request initialization.
  1103. func (c *OutputService10ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1104. req := c.NewRequest(op, params, data)
  1105. return req
  1106. }
  1107. const opOutputService10TestCaseOperation1 = "OperationName"
  1108. // OutputService10TestCaseOperation1Request generates a "aws/request.Request" representing the
  1109. // client's request for the OutputService10TestCaseOperation1 operation. The "output" return
  1110. // value can be used to capture response data after the request's "Send" method
  1111. // is called.
  1112. //
  1113. // See OutputService10TestCaseOperation1 for usage and error information.
  1114. //
  1115. // Creating a request object using this method should be used when you want to inject
  1116. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1117. // access properties on the request object before or after sending the request. If
  1118. // you just want the service response, call the OutputService10TestCaseOperation1 method directly
  1119. // instead.
  1120. //
  1121. // Note: You must call the "Send" method on the returned request object in order
  1122. // to execute the request.
  1123. //
  1124. // // Example sending a request using the OutputService10TestCaseOperation1Request method.
  1125. // req, resp := client.OutputService10TestCaseOperation1Request(params)
  1126. //
  1127. // err := req.Send()
  1128. // if err == nil { // resp is now filled
  1129. // fmt.Println(resp)
  1130. // }
  1131. //
  1132. func (c *OutputService10ProtocolTest) OutputService10TestCaseOperation1Request(input *OutputService10TestShapeOutputService10TestCaseOperation1Input) (req *request.Request, output *OutputService10TestShapeOutputService10TestCaseOperation1Output) {
  1133. op := &request.Operation{
  1134. Name: opOutputService10TestCaseOperation1,
  1135. HTTPPath: "/",
  1136. }
  1137. if input == nil {
  1138. input = &OutputService10TestShapeOutputService10TestCaseOperation1Input{}
  1139. }
  1140. req = c.newRequest(op, input, output)
  1141. output = &OutputService10TestShapeOutputService10TestCaseOperation1Output{}
  1142. req.Data = output
  1143. return
  1144. }
  1145. // OutputService10TestCaseOperation1 API operation for .
  1146. //
  1147. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1148. // with awserr.Error's Code and Message methods to get detailed information about
  1149. // the error.
  1150. //
  1151. // See the AWS API reference guide for 's
  1152. // API operation OutputService10TestCaseOperation1 for usage and error information.
  1153. func (c *OutputService10ProtocolTest) OutputService10TestCaseOperation1(input *OutputService10TestShapeOutputService10TestCaseOperation1Input) (*OutputService10TestShapeOutputService10TestCaseOperation1Output, error) {
  1154. req, out := c.OutputService10TestCaseOperation1Request(input)
  1155. err := req.Send()
  1156. return out, err
  1157. }
  1158. type OutputService10TestShapeOutputService10TestCaseOperation1Input struct {
  1159. _ struct{} `type:"structure"`
  1160. }
  1161. type OutputService10TestShapeOutputService10TestCaseOperation1Output struct {
  1162. _ struct{} `type:"structure" payload:"Stream"`
  1163. Stream []byte `type:"blob"`
  1164. }
  1165. //The service client's operations are safe to be used concurrently.
  1166. // It is not safe to mutate any of the client's properties though.
  1167. type OutputService11ProtocolTest struct {
  1168. *client.Client
  1169. }
  1170. // New creates a new instance of the OutputService11ProtocolTest client with a session.
  1171. // If additional configuration is needed for the client instance use the optional
  1172. // aws.Config parameter to add your extra config.
  1173. //
  1174. // Example:
  1175. // // Create a OutputService11ProtocolTest client from just a session.
  1176. // svc := outputservice11protocoltest.New(mySession)
  1177. //
  1178. // // Create a OutputService11ProtocolTest client with additional configuration
  1179. // svc := outputservice11protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1180. func NewOutputService11ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService11ProtocolTest {
  1181. c := p.ClientConfig("outputservice11protocoltest", cfgs...)
  1182. return newOutputService11ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1183. }
  1184. // newClient creates, initializes and returns a new service client instance.
  1185. func newOutputService11ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService11ProtocolTest {
  1186. svc := &OutputService11ProtocolTest{
  1187. Client: client.New(
  1188. cfg,
  1189. metadata.ClientInfo{
  1190. ServiceName: "outputservice11protocoltest",
  1191. SigningRegion: signingRegion,
  1192. Endpoint: endpoint,
  1193. APIVersion: "",
  1194. },
  1195. handlers,
  1196. ),
  1197. }
  1198. // Handlers
  1199. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1200. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  1201. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  1202. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  1203. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  1204. return svc
  1205. }
  1206. // newRequest creates a new request for a OutputService11ProtocolTest operation and runs any
  1207. // custom request initialization.
  1208. func (c *OutputService11ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1209. req := c.NewRequest(op, params, data)
  1210. return req
  1211. }
  1212. const opOutputService11TestCaseOperation1 = "OperationName"
  1213. // OutputService11TestCaseOperation1Request generates a "aws/request.Request" representing the
  1214. // client's request for the OutputService11TestCaseOperation1 operation. The "output" return
  1215. // value can be used to capture response data after the request's "Send" method
  1216. // is called.
  1217. //
  1218. // See OutputService11TestCaseOperation1 for usage and error information.
  1219. //
  1220. // Creating a request object using this method should be used when you want to inject
  1221. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1222. // access properties on the request object before or after sending the request. If
  1223. // you just want the service response, call the OutputService11TestCaseOperation1 method directly
  1224. // instead.
  1225. //
  1226. // Note: You must call the "Send" method on the returned request object in order
  1227. // to execute the request.
  1228. //
  1229. // // Example sending a request using the OutputService11TestCaseOperation1Request method.
  1230. // req, resp := client.OutputService11TestCaseOperation1Request(params)
  1231. //
  1232. // err := req.Send()
  1233. // if err == nil { // resp is now filled
  1234. // fmt.Println(resp)
  1235. // }
  1236. //
  1237. func (c *OutputService11ProtocolTest) OutputService11TestCaseOperation1Request(input *OutputService11TestShapeOutputService11TestCaseOperation1Input) (req *request.Request, output *OutputService11TestShapeOutputService11TestCaseOperation1Output) {
  1238. op := &request.Operation{
  1239. Name: opOutputService11TestCaseOperation1,
  1240. HTTPPath: "/",
  1241. }
  1242. if input == nil {
  1243. input = &OutputService11TestShapeOutputService11TestCaseOperation1Input{}
  1244. }
  1245. req = c.newRequest(op, input, output)
  1246. output = &OutputService11TestShapeOutputService11TestCaseOperation1Output{}
  1247. req.Data = output
  1248. return
  1249. }
  1250. // OutputService11TestCaseOperation1 API operation for .
  1251. //
  1252. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1253. // with awserr.Error's Code and Message methods to get detailed information about
  1254. // the error.
  1255. //
  1256. // See the AWS API reference guide for 's
  1257. // API operation OutputService11TestCaseOperation1 for usage and error information.
  1258. func (c *OutputService11ProtocolTest) OutputService11TestCaseOperation1(input *OutputService11TestShapeOutputService11TestCaseOperation1Input) (*OutputService11TestShapeOutputService11TestCaseOperation1Output, error) {
  1259. req, out := c.OutputService11TestCaseOperation1Request(input)
  1260. err := req.Send()
  1261. return out, err
  1262. }
  1263. type OutputService11TestShapeOutputService11TestCaseOperation1Input struct {
  1264. _ struct{} `type:"structure"`
  1265. }
  1266. type OutputService11TestShapeOutputService11TestCaseOperation1Output struct {
  1267. _ struct{} `type:"structure"`
  1268. Char *string `location:"header" locationName:"x-char" type:"character"`
  1269. Double *float64 `location:"header" locationName:"x-double" type:"double"`
  1270. FalseBool *bool `location:"header" locationName:"x-false-bool" type:"boolean"`
  1271. Float *float64 `location:"header" locationName:"x-float" type:"float"`
  1272. Integer *int64 `location:"header" locationName:"x-int" type:"integer"`
  1273. Long *int64 `location:"header" locationName:"x-long" type:"long"`
  1274. Str *string `location:"header" locationName:"x-str" type:"string"`
  1275. Timestamp *time.Time `location:"header" locationName:"x-timestamp" type:"timestamp" timestampFormat:"iso8601"`
  1276. TrueBool *bool `location:"header" locationName:"x-true-bool" type:"boolean"`
  1277. }
  1278. //The service client's operations are safe to be used concurrently.
  1279. // It is not safe to mutate any of the client's properties though.
  1280. type OutputService12ProtocolTest struct {
  1281. *client.Client
  1282. }
  1283. // New creates a new instance of the OutputService12ProtocolTest client with a session.
  1284. // If additional configuration is needed for the client instance use the optional
  1285. // aws.Config parameter to add your extra config.
  1286. //
  1287. // Example:
  1288. // // Create a OutputService12ProtocolTest client from just a session.
  1289. // svc := outputservice12protocoltest.New(mySession)
  1290. //
  1291. // // Create a OutputService12ProtocolTest client with additional configuration
  1292. // svc := outputservice12protocoltest.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
  1293. func NewOutputService12ProtocolTest(p client.ConfigProvider, cfgs ...*aws.Config) *OutputService12ProtocolTest {
  1294. c := p.ClientConfig("outputservice12protocoltest", cfgs...)
  1295. return newOutputService12ProtocolTestClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion)
  1296. }
  1297. // newClient creates, initializes and returns a new service client instance.
  1298. func newOutputService12ProtocolTestClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion string) *OutputService12ProtocolTest {
  1299. svc := &OutputService12ProtocolTest{
  1300. Client: client.New(
  1301. cfg,
  1302. metadata.ClientInfo{
  1303. ServiceName: "outputservice12protocoltest",
  1304. SigningRegion: signingRegion,
  1305. Endpoint: endpoint,
  1306. APIVersion: "",
  1307. },
  1308. handlers,
  1309. ),
  1310. }
  1311. // Handlers
  1312. svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
  1313. svc.Handlers.Build.PushBackNamed(restxml.BuildHandler)
  1314. svc.Handlers.Unmarshal.PushBackNamed(restxml.UnmarshalHandler)
  1315. svc.Handlers.UnmarshalMeta.PushBackNamed(restxml.UnmarshalMetaHandler)
  1316. svc.Handlers.UnmarshalError.PushBackNamed(restxml.UnmarshalErrorHandler)
  1317. return svc
  1318. }
  1319. // newRequest creates a new request for a OutputService12ProtocolTest operation and runs any
  1320. // custom request initialization.
  1321. func (c *OutputService12ProtocolTest) newRequest(op *request.Operation, params, data interface{}) *request.Request {
  1322. req := c.NewRequest(op, params, data)
  1323. return req
  1324. }
  1325. const opOutputService12TestCaseOperation1 = "OperationName"
  1326. // OutputService12TestCaseOperation1Request generates a "aws/request.Request" representing the
  1327. // client's request for the OutputService12TestCaseOperation1 operation. The "output" return
  1328. // value can be used to capture response data after the request's "Send" method
  1329. // is called.
  1330. //
  1331. // See OutputService12TestCaseOperation1 for usage and error information.
  1332. //
  1333. // Creating a request object using this method should be used when you want to inject
  1334. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1335. // access properties on the request object before or after sending the request. If
  1336. // you just want the service response, call the OutputService12TestCaseOperation1 method directly
  1337. // instead.
  1338. //
  1339. // Note: You must call the "Send" method on the returned request object in order
  1340. // to execute the request.
  1341. //
  1342. // // Example sending a request using the OutputService12TestCaseOperation1Request method.
  1343. // req, resp := client.OutputService12TestCaseOperation1Request(params)
  1344. //
  1345. // err := req.Send()
  1346. // if err == nil { // resp is now filled
  1347. // fmt.Println(resp)
  1348. // }
  1349. //
  1350. func (c *OutputService12ProtocolTest) OutputService12TestCaseOperation1Request(input *OutputService12TestShapeOutputService12TestCaseOperation1Input) (req *request.Request, output *OutputService12TestShapeOutputService12TestCaseOperation1Output) {
  1351. op := &request.Operation{
  1352. Name: opOutputService12TestCaseOperation1,
  1353. HTTPPath: "/",
  1354. }
  1355. if input == nil {
  1356. input = &OutputService12TestShapeOutputService12TestCaseOperation1Input{}
  1357. }
  1358. req = c.newRequest(op, input, output)
  1359. output = &OutputService12TestShapeOutputService12TestCaseOperation1Output{}
  1360. req.Data = output
  1361. return
  1362. }
  1363. // OutputService12TestCaseOperation1 API operation for .
  1364. //
  1365. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1366. // with awserr.Error's Code and Message methods to get detailed information about
  1367. // the error.
  1368. //
  1369. // See the AWS API reference guide for 's
  1370. // API operation OutputService12TestCaseOperation1 for usage and error information.
  1371. func (c *OutputService12ProtocolTest) OutputService12TestCaseOperation1(input *OutputService12TestShapeOutputService12TestCaseOperation1Input) (*OutputService12TestShapeOutputService12TestCaseOperation1Output, error) {
  1372. req, out := c.OutputService12TestCaseOperation1Request(input)
  1373. err := req.Send()
  1374. return out, err
  1375. }
  1376. type OutputService12TestShapeOutputService12TestCaseOperation1Input struct {
  1377. _ struct{} `type:"structure"`
  1378. }
  1379. type OutputService12TestShapeOutputService12TestCaseOperation1Output struct {
  1380. _ struct{} `type:"structure"`
  1381. Foo *string `type:"string"`
  1382. }
  1383. //
  1384. // Tests begin here
  1385. //
  1386. func TestOutputService1ProtocolTestScalarMembersCase1(t *testing.T) {
  1387. svc := NewOutputService1ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1388. buf := bytes.NewReader([]byte("<OperationNameResponse><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></OperationNameResponse>"))
  1389. req, out := svc.OutputService1TestCaseOperation1Request(nil)
  1390. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1391. // set headers
  1392. req.HTTPResponse.Header.Set("ImaHeader", "test")
  1393. req.HTTPResponse.Header.Set("X-Foo", "abc")
  1394. // unmarshal response
  1395. restxml.UnmarshalMeta(req)
  1396. restxml.Unmarshal(req)
  1397. assert.NoError(t, req.Error)
  1398. // assert response
  1399. assert.NotNil(t, out) // ensure out variable is used
  1400. assert.Equal(t, "a", *out.Char)
  1401. assert.Equal(t, 1.3, *out.Double)
  1402. assert.Equal(t, false, *out.FalseBool)
  1403. assert.Equal(t, 1.2, *out.Float)
  1404. assert.Equal(t, "test", *out.ImaHeader)
  1405. assert.Equal(t, "abc", *out.ImaHeaderLocation)
  1406. assert.Equal(t, int64(200), *out.Long)
  1407. assert.Equal(t, int64(123), *out.Num)
  1408. assert.Equal(t, "myname", *out.Str)
  1409. assert.Equal(t, time.Unix(1.4221728e+09, 0).UTC().String(), out.Timestamp.String())
  1410. assert.Equal(t, true, *out.TrueBool)
  1411. }
  1412. func TestOutputService1ProtocolTestScalarMembersCase2(t *testing.T) {
  1413. svc := NewOutputService1ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1414. buf := bytes.NewReader([]byte("<OperationNameResponse><Str></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></OperationNameResponse>"))
  1415. req, out := svc.OutputService1TestCaseOperation2Request(nil)
  1416. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1417. // set headers
  1418. req.HTTPResponse.Header.Set("ImaHeader", "test")
  1419. req.HTTPResponse.Header.Set("X-Foo", "abc")
  1420. // unmarshal response
  1421. restxml.UnmarshalMeta(req)
  1422. restxml.Unmarshal(req)
  1423. assert.NoError(t, req.Error)
  1424. // assert response
  1425. assert.NotNil(t, out) // ensure out variable is used
  1426. assert.Equal(t, "a", *out.Char)
  1427. assert.Equal(t, 1.3, *out.Double)
  1428. assert.Equal(t, false, *out.FalseBool)
  1429. assert.Equal(t, 1.2, *out.Float)
  1430. assert.Equal(t, "test", *out.ImaHeader)
  1431. assert.Equal(t, "abc", *out.ImaHeaderLocation)
  1432. assert.Equal(t, int64(200), *out.Long)
  1433. assert.Equal(t, int64(123), *out.Num)
  1434. assert.Equal(t, "", *out.Str)
  1435. assert.Equal(t, time.Unix(1.4221728e+09, 0).UTC().String(), out.Timestamp.String())
  1436. assert.Equal(t, true, *out.TrueBool)
  1437. }
  1438. func TestOutputService2ProtocolTestBlobCase1(t *testing.T) {
  1439. svc := NewOutputService2ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1440. buf := bytes.NewReader([]byte("<OperationNameResult><Blob>dmFsdWU=</Blob></OperationNameResult>"))
  1441. req, out := svc.OutputService2TestCaseOperation1Request(nil)
  1442. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1443. // set headers
  1444. // unmarshal response
  1445. restxml.UnmarshalMeta(req)
  1446. restxml.Unmarshal(req)
  1447. assert.NoError(t, req.Error)
  1448. // assert response
  1449. assert.NotNil(t, out) // ensure out variable is used
  1450. assert.Equal(t, "value", string(out.Blob))
  1451. }
  1452. func TestOutputService3ProtocolTestListsCase1(t *testing.T) {
  1453. svc := NewOutputService3ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1454. buf := bytes.NewReader([]byte("<OperationNameResult><ListMember><member>abc</member><member>123</member></ListMember></OperationNameResult>"))
  1455. req, out := svc.OutputService3TestCaseOperation1Request(nil)
  1456. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1457. // set headers
  1458. // unmarshal response
  1459. restxml.UnmarshalMeta(req)
  1460. restxml.Unmarshal(req)
  1461. assert.NoError(t, req.Error)
  1462. // assert response
  1463. assert.NotNil(t, out) // ensure out variable is used
  1464. assert.Equal(t, "abc", *out.ListMember[0])
  1465. assert.Equal(t, "123", *out.ListMember[1])
  1466. }
  1467. func TestOutputService4ProtocolTestListWithCustomMemberNameCase1(t *testing.T) {
  1468. svc := NewOutputService4ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1469. buf := bytes.NewReader([]byte("<OperationNameResult><ListMember><item>abc</item><item>123</item></ListMember></OperationNameResult>"))
  1470. req, out := svc.OutputService4TestCaseOperation1Request(nil)
  1471. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1472. // set headers
  1473. // unmarshal response
  1474. restxml.UnmarshalMeta(req)
  1475. restxml.Unmarshal(req)
  1476. assert.NoError(t, req.Error)
  1477. // assert response
  1478. assert.NotNil(t, out) // ensure out variable is used
  1479. assert.Equal(t, "abc", *out.ListMember[0])
  1480. assert.Equal(t, "123", *out.ListMember[1])
  1481. }
  1482. func TestOutputService5ProtocolTestFlattenedListCase1(t *testing.T) {
  1483. svc := NewOutputService5ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1484. buf := bytes.NewReader([]byte("<OperationNameResult><ListMember>abc</ListMember><ListMember>123</ListMember></OperationNameResult>"))
  1485. req, out := svc.OutputService5TestCaseOperation1Request(nil)
  1486. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1487. // set headers
  1488. // unmarshal response
  1489. restxml.UnmarshalMeta(req)
  1490. restxml.Unmarshal(req)
  1491. assert.NoError(t, req.Error)
  1492. // assert response
  1493. assert.NotNil(t, out) // ensure out variable is used
  1494. assert.Equal(t, "abc", *out.ListMember[0])
  1495. assert.Equal(t, "123", *out.ListMember[1])
  1496. }
  1497. func TestOutputService6ProtocolTestNormalMapCase1(t *testing.T) {
  1498. svc := NewOutputService6ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1499. buf := bytes.NewReader([]byte("<OperationNameResult><Map><entry><key>qux</key><value><foo>bar</foo></value></entry><entry><key>baz</key><value><foo>bam</foo></value></entry></Map></OperationNameResult>"))
  1500. req, out := svc.OutputService6TestCaseOperation1Request(nil)
  1501. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1502. // set headers
  1503. // unmarshal response
  1504. restxml.UnmarshalMeta(req)
  1505. restxml.Unmarshal(req)
  1506. assert.NoError(t, req.Error)
  1507. // assert response
  1508. assert.NotNil(t, out) // ensure out variable is used
  1509. assert.Equal(t, "bam", *out.Map["baz"].Foo)
  1510. assert.Equal(t, "bar", *out.Map["qux"].Foo)
  1511. }
  1512. func TestOutputService7ProtocolTestFlattenedMapCase1(t *testing.T) {
  1513. svc := NewOutputService7ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1514. buf := bytes.NewReader([]byte("<OperationNameResult><Map><key>qux</key><value>bar</value></Map><Map><key>baz</key><value>bam</value></Map></OperationNameResult>"))
  1515. req, out := svc.OutputService7TestCaseOperation1Request(nil)
  1516. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1517. // set headers
  1518. // unmarshal response
  1519. restxml.UnmarshalMeta(req)
  1520. restxml.Unmarshal(req)
  1521. assert.NoError(t, req.Error)
  1522. // assert response
  1523. assert.NotNil(t, out) // ensure out variable is used
  1524. assert.Equal(t, "bam", *out.Map["baz"])
  1525. assert.Equal(t, "bar", *out.Map["qux"])
  1526. }
  1527. func TestOutputService8ProtocolTestNamedMapCase1(t *testing.T) {
  1528. svc := NewOutputService8ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1529. buf := bytes.NewReader([]byte("<OperationNameResult><Map><entry><foo>qux</foo><bar>bar</bar></entry><entry><foo>baz</foo><bar>bam</bar></entry></Map></OperationNameResult>"))
  1530. req, out := svc.OutputService8TestCaseOperation1Request(nil)
  1531. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1532. // set headers
  1533. // unmarshal response
  1534. restxml.UnmarshalMeta(req)
  1535. restxml.Unmarshal(req)
  1536. assert.NoError(t, req.Error)
  1537. // assert response
  1538. assert.NotNil(t, out) // ensure out variable is used
  1539. assert.Equal(t, "bam", *out.Map["baz"])
  1540. assert.Equal(t, "bar", *out.Map["qux"])
  1541. }
  1542. func TestOutputService9ProtocolTestXMLPayloadCase1(t *testing.T) {
  1543. svc := NewOutputService9ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1544. buf := bytes.NewReader([]byte("<OperationNameResponse><Foo>abc</Foo></OperationNameResponse>"))
  1545. req, out := svc.OutputService9TestCaseOperation1Request(nil)
  1546. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1547. // set headers
  1548. req.HTTPResponse.Header.Set("X-Foo", "baz")
  1549. // unmarshal response
  1550. restxml.UnmarshalMeta(req)
  1551. restxml.Unmarshal(req)
  1552. assert.NoError(t, req.Error)
  1553. // assert response
  1554. assert.NotNil(t, out) // ensure out variable is used
  1555. assert.Equal(t, "abc", *out.Data.Foo)
  1556. assert.Equal(t, "baz", *out.Header)
  1557. }
  1558. func TestOutputService10ProtocolTestStreamingPayloadCase1(t *testing.T) {
  1559. svc := NewOutputService10ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1560. buf := bytes.NewReader([]byte("abc"))
  1561. req, out := svc.OutputService10TestCaseOperation1Request(nil)
  1562. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1563. // set headers
  1564. // unmarshal response
  1565. restxml.UnmarshalMeta(req)
  1566. restxml.Unmarshal(req)
  1567. assert.NoError(t, req.Error)
  1568. // assert response
  1569. assert.NotNil(t, out) // ensure out variable is used
  1570. assert.Equal(t, "abc", string(out.Stream))
  1571. }
  1572. func TestOutputService11ProtocolTestScalarMembersInHeadersCase1(t *testing.T) {
  1573. svc := NewOutputService11ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1574. buf := bytes.NewReader([]byte(""))
  1575. req, out := svc.OutputService11TestCaseOperation1Request(nil)
  1576. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1577. // set headers
  1578. req.HTTPResponse.Header.Set("x-char", "a")
  1579. req.HTTPResponse.Header.Set("x-double", "1.5")
  1580. req.HTTPResponse.Header.Set("x-false-bool", "false")
  1581. req.HTTPResponse.Header.Set("x-float", "1.5")
  1582. req.HTTPResponse.Header.Set("x-int", "1")
  1583. req.HTTPResponse.Header.Set("x-long", "100")
  1584. req.HTTPResponse.Header.Set("x-str", "string")
  1585. req.HTTPResponse.Header.Set("x-timestamp", "Sun, 25 Jan 2015 08:00:00 GMT")
  1586. req.HTTPResponse.Header.Set("x-true-bool", "true")
  1587. // unmarshal response
  1588. restxml.UnmarshalMeta(req)
  1589. restxml.Unmarshal(req)
  1590. assert.NoError(t, req.Error)
  1591. // assert response
  1592. assert.NotNil(t, out) // ensure out variable is used
  1593. assert.Equal(t, "a", *out.Char)
  1594. assert.Equal(t, 1.5, *out.Double)
  1595. assert.Equal(t, false, *out.FalseBool)
  1596. assert.Equal(t, 1.5, *out.Float)
  1597. assert.Equal(t, int64(1), *out.Integer)
  1598. assert.Equal(t, int64(100), *out.Long)
  1599. assert.Equal(t, "string", *out.Str)
  1600. assert.Equal(t, time.Unix(1.4221728e+09, 0).UTC().String(), out.Timestamp.String())
  1601. assert.Equal(t, true, *out.TrueBool)
  1602. }
  1603. func TestOutputService12ProtocolTestEmptyStringCase1(t *testing.T) {
  1604. svc := NewOutputService12ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
  1605. buf := bytes.NewReader([]byte("<OperationNameResponse><Foo/><RequestId>requestid</RequestId></OperationNameResponse>"))
  1606. req, out := svc.OutputService12TestCaseOperation1Request(nil)
  1607. req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
  1608. // set headers
  1609. // unmarshal response
  1610. restxml.UnmarshalMeta(req)
  1611. restxml.Unmarshal(req)
  1612. assert.NoError(t, req.Error)
  1613. // assert response
  1614. assert.NotNil(t, out) // ensure out variable is used
  1615. assert.Equal(t, "", *out.Foo)
  1616. }