api.go 714 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966119671196811969119701197111972119731197411975119761197711978119791198011981119821198311984119851198611987119881198911990119911199211993119941199511996119971199811999120001200112002120031200412005120061200712008120091201012011120121201312014120151201612017120181201912020120211202212023120241202512026120271202812029120301203112032120331203412035120361203712038120391204012041120421204312044120451204612047120481204912050120511205212053120541205512056120571205812059120601206112062120631206412065120661206712068120691207012071120721207312074120751207612077120781207912080120811208212083120841208512086120871208812089120901209112092120931209412095120961209712098120991210012101121021210312104121051210612107121081210912110121111211212113121141211512116121171211812119121201212112122121231212412125121261212712128121291213012131121321213312134121351213612137121381213912140121411214212143121441214512146121471214812149121501215112152121531215412155121561215712158121591216012161121621216312164121651216612167121681216912170121711217212173121741217512176121771217812179121801218112182121831218412185121861218712188121891219012191121921219312194121951219612197121981219912200122011220212203122041220512206122071220812209122101221112212122131221412215122161221712218122191222012221122221222312224122251222612227122281222912230122311223212233122341223512236122371223812239122401224112242122431224412245122461224712248122491225012251122521225312254122551225612257122581225912260122611226212263122641226512266122671226812269122701227112272122731227412275122761227712278122791228012281122821228312284122851228612287122881228912290122911229212293122941229512296122971229812299123001230112302123031230412305123061230712308123091231012311123121231312314123151231612317123181231912320123211232212323123241232512326123271232812329123301233112332123331233412335123361233712338123391234012341123421234312344123451234612347123481234912350123511235212353123541235512356123571235812359123601236112362123631236412365123661236712368123691237012371123721237312374123751237612377123781237912380123811238212383123841238512386123871238812389123901239112392123931239412395123961239712398123991240012401124021240312404124051240612407124081240912410124111241212413124141241512416124171241812419124201242112422124231242412425124261242712428124291243012431124321243312434124351243612437124381243912440124411244212443124441244512446124471244812449124501245112452124531245412455124561245712458124591246012461124621246312464124651246612467124681246912470124711247212473124741247512476124771247812479124801248112482124831248412485124861248712488124891249012491124921249312494124951249612497124981249912500125011250212503125041250512506125071250812509125101251112512125131251412515125161251712518125191252012521125221252312524125251252612527125281252912530125311253212533125341253512536125371253812539125401254112542125431254412545125461254712548125491255012551125521255312554125551255612557125581255912560125611256212563125641256512566125671256812569125701257112572125731257412575125761257712578125791258012581125821258312584125851258612587125881258912590125911259212593125941259512596125971259812599126001260112602126031260412605126061260712608126091261012611126121261312614126151261612617126181261912620126211262212623126241262512626126271262812629126301263112632126331263412635126361263712638126391264012641126421264312644126451264612647126481264912650126511265212653126541265512656126571265812659126601266112662126631266412665126661266712668126691267012671126721267312674126751267612677126781267912680126811268212683126841268512686126871268812689126901269112692126931269412695126961269712698126991270012701127021270312704127051270612707127081270912710127111271212713127141271512716127171271812719127201272112722127231272412725127261272712728127291273012731127321273312734127351273612737127381273912740127411274212743127441274512746127471274812749127501275112752127531275412755127561275712758127591276012761127621276312764127651276612767127681276912770127711277212773127741277512776127771277812779127801278112782127831278412785127861278712788127891279012791127921279312794127951279612797127981279912800128011280212803128041280512806128071280812809128101281112812128131281412815128161281712818128191282012821128221282312824128251282612827128281282912830128311283212833128341283512836128371283812839128401284112842128431284412845128461284712848128491285012851128521285312854128551285612857128581285912860128611286212863128641286512866128671286812869128701287112872128731287412875128761287712878128791288012881128821288312884128851288612887128881288912890128911289212893128941289512896128971289812899129001290112902129031290412905129061290712908129091291012911129121291312914129151291612917129181291912920129211292212923129241292512926129271292812929129301293112932129331293412935129361293712938129391294012941129421294312944129451294612947129481294912950129511295212953129541295512956129571295812959129601296112962129631296412965129661296712968129691297012971129721297312974129751297612977129781297912980129811298212983129841298512986129871298812989129901299112992129931299412995129961299712998129991300013001130021300313004130051300613007130081300913010130111301213013130141301513016130171301813019130201302113022130231302413025130261302713028130291303013031130321303313034130351303613037130381303913040130411304213043130441304513046130471304813049130501305113052130531305413055130561305713058130591306013061130621306313064130651306613067130681306913070130711307213073130741307513076130771307813079130801308113082130831308413085130861308713088130891309013091130921309313094130951309613097130981309913100131011310213103131041310513106131071310813109131101311113112131131311413115131161311713118131191312013121131221312313124131251312613127131281312913130131311313213133131341313513136131371313813139131401314113142131431314413145131461314713148131491315013151131521315313154131551315613157131581315913160131611316213163131641316513166131671316813169131701317113172131731317413175131761317713178131791318013181131821318313184131851318613187131881318913190131911319213193131941319513196131971319813199132001320113202132031320413205132061320713208132091321013211132121321313214132151321613217132181321913220132211322213223132241322513226132271322813229132301323113232132331323413235132361323713238132391324013241132421324313244132451324613247132481324913250132511325213253132541325513256132571325813259132601326113262132631326413265132661326713268132691327013271132721327313274132751327613277132781327913280132811328213283132841328513286132871328813289132901329113292132931329413295132961329713298132991330013301133021330313304133051330613307133081330913310133111331213313133141331513316133171331813319133201332113322133231332413325133261332713328133291333013331133321333313334133351333613337133381333913340133411334213343133441334513346133471334813349133501335113352133531335413355133561335713358133591336013361133621336313364133651336613367133681336913370133711337213373133741337513376133771337813379133801338113382133831338413385133861338713388133891339013391133921339313394133951339613397133981339913400134011340213403134041340513406134071340813409134101341113412134131341413415134161341713418134191342013421134221342313424134251342613427134281342913430134311343213433134341343513436134371343813439134401344113442134431344413445134461344713448134491345013451134521345313454134551345613457134581345913460134611346213463134641346513466134671346813469134701347113472134731347413475134761347713478134791348013481134821348313484134851348613487134881348913490134911349213493134941349513496134971349813499135001350113502135031350413505135061350713508135091351013511135121351313514135151351613517135181351913520135211352213523135241352513526135271352813529135301353113532135331353413535135361353713538135391354013541135421354313544135451354613547135481354913550135511355213553135541355513556135571355813559135601356113562135631356413565135661356713568135691357013571135721357313574135751357613577135781357913580135811358213583135841358513586135871358813589135901359113592135931359413595135961359713598135991360013601136021360313604136051360613607136081360913610136111361213613136141361513616136171361813619136201362113622136231362413625136261362713628136291363013631136321363313634136351363613637136381363913640136411364213643136441364513646136471364813649136501365113652136531365413655136561365713658136591366013661136621366313664136651366613667136681366913670136711367213673136741367513676136771367813679136801368113682136831368413685136861368713688136891369013691136921369313694136951369613697136981369913700137011370213703137041370513706137071370813709137101371113712137131371413715137161371713718137191372013721137221372313724137251372613727137281372913730137311373213733137341373513736137371373813739137401374113742137431374413745137461374713748137491375013751137521375313754137551375613757137581375913760137611376213763137641376513766137671376813769137701377113772137731377413775137761377713778137791378013781137821378313784137851378613787137881378913790137911379213793137941379513796137971379813799138001380113802138031380413805138061380713808138091381013811138121381313814138151381613817138181381913820138211382213823138241382513826138271382813829138301383113832138331383413835138361383713838138391384013841138421384313844138451384613847138481384913850138511385213853138541385513856138571385813859138601386113862138631386413865138661386713868138691387013871138721387313874138751387613877138781387913880138811388213883138841388513886138871388813889138901389113892138931389413895138961389713898138991390013901139021390313904139051390613907139081390913910139111391213913139141391513916139171391813919139201392113922139231392413925139261392713928139291393013931139321393313934139351393613937139381393913940139411394213943139441394513946139471394813949139501395113952139531395413955139561395713958139591396013961139621396313964139651396613967139681396913970139711397213973139741397513976139771397813979139801398113982139831398413985139861398713988139891399013991139921399313994139951399613997139981399914000140011400214003140041400514006140071400814009140101401114012140131401414015140161401714018140191402014021140221402314024140251402614027140281402914030140311403214033140341403514036140371403814039140401404114042140431404414045140461404714048140491405014051140521405314054140551405614057140581405914060140611406214063140641406514066140671406814069140701407114072140731407414075140761407714078140791408014081140821408314084140851408614087140881408914090140911409214093140941409514096140971409814099141001410114102141031410414105141061410714108141091411014111141121411314114141151411614117141181411914120141211412214123141241412514126141271412814129141301413114132141331413414135141361413714138141391414014141141421414314144141451414614147141481414914150141511415214153141541415514156141571415814159141601416114162141631416414165141661416714168141691417014171141721417314174141751417614177141781417914180141811418214183141841418514186141871418814189141901419114192141931419414195141961419714198141991420014201142021420314204142051420614207142081420914210142111421214213142141421514216142171421814219142201422114222142231422414225142261422714228142291423014231142321423314234142351423614237142381423914240142411424214243142441424514246142471424814249142501425114252142531425414255142561425714258142591426014261142621426314264142651426614267142681426914270142711427214273142741427514276142771427814279142801428114282142831428414285142861428714288142891429014291142921429314294142951429614297142981429914300143011430214303143041430514306143071430814309143101431114312143131431414315143161431714318143191432014321143221432314324143251432614327143281432914330143311433214333143341433514336143371433814339143401434114342143431434414345143461434714348143491435014351143521435314354143551435614357143581435914360143611436214363143641436514366143671436814369143701437114372143731437414375143761437714378143791438014381143821438314384143851438614387143881438914390143911439214393143941439514396143971439814399144001440114402144031440414405144061440714408144091441014411144121441314414144151441614417144181441914420144211442214423144241442514426144271442814429144301443114432144331443414435144361443714438144391444014441144421444314444144451444614447144481444914450144511445214453144541445514456144571445814459144601446114462144631446414465144661446714468144691447014471144721447314474144751447614477144781447914480144811448214483144841448514486144871448814489144901449114492144931449414495144961449714498144991450014501145021450314504145051450614507145081450914510145111451214513145141451514516145171451814519145201452114522145231452414525145261452714528145291453014531145321453314534145351453614537145381453914540145411454214543145441454514546145471454814549145501455114552145531455414555145561455714558145591456014561145621456314564145651456614567145681456914570145711457214573145741457514576145771457814579145801458114582145831458414585145861458714588145891459014591145921459314594145951459614597145981459914600146011460214603146041460514606146071460814609146101461114612146131461414615146161461714618146191462014621146221462314624146251462614627146281462914630146311463214633146341463514636146371463814639146401464114642146431464414645146461464714648146491465014651146521465314654146551465614657146581465914660146611466214663146641466514666146671466814669146701467114672146731467414675146761467714678146791468014681146821468314684146851468614687146881468914690146911469214693146941469514696146971469814699147001470114702147031470414705147061470714708147091471014711147121471314714147151471614717147181471914720147211472214723147241472514726147271472814729147301473114732147331473414735147361473714738147391474014741147421474314744147451474614747147481474914750147511475214753147541475514756147571475814759147601476114762147631476414765147661476714768147691477014771147721477314774147751477614777147781477914780147811478214783147841478514786147871478814789147901479114792147931479414795147961479714798147991480014801148021480314804148051480614807148081480914810148111481214813148141481514816148171481814819148201482114822148231482414825148261482714828148291483014831148321483314834148351483614837148381483914840148411484214843148441484514846148471484814849148501485114852148531485414855148561485714858148591486014861148621486314864148651486614867148681486914870148711487214873148741487514876148771487814879148801488114882148831488414885148861488714888148891489014891148921489314894148951489614897148981489914900149011490214903149041490514906149071490814909149101491114912149131491414915149161491714918149191492014921149221492314924149251492614927149281492914930149311493214933149341493514936149371493814939149401494114942149431494414945149461494714948149491495014951149521495314954149551495614957149581495914960149611496214963149641496514966149671496814969149701497114972149731497414975149761497714978149791498014981149821498314984149851498614987149881498914990149911499214993149941499514996149971499814999150001500115002150031500415005150061500715008150091501015011150121501315014150151501615017150181501915020150211502215023150241502515026150271502815029150301503115032150331503415035150361503715038150391504015041150421504315044150451504615047150481504915050150511505215053150541505515056150571505815059150601506115062150631506415065150661506715068150691507015071150721507315074150751507615077150781507915080150811508215083150841508515086150871508815089150901509115092150931509415095150961509715098150991510015101151021510315104151051510615107151081510915110151111511215113151141511515116151171511815119151201512115122151231512415125151261512715128151291513015131151321513315134151351513615137151381513915140151411514215143151441514515146151471514815149151501515115152151531515415155151561515715158151591516015161151621516315164151651516615167151681516915170151711517215173151741517515176151771517815179151801518115182151831518415185151861518715188151891519015191151921519315194151951519615197151981519915200152011520215203152041520515206152071520815209152101521115212152131521415215152161521715218152191522015221152221522315224152251522615227152281522915230152311523215233152341523515236152371523815239152401524115242152431524415245152461524715248152491525015251152521525315254152551525615257152581525915260152611526215263152641526515266152671526815269152701527115272152731527415275152761527715278152791528015281152821528315284152851528615287152881528915290152911529215293152941529515296152971529815299153001530115302153031530415305153061530715308153091531015311153121531315314153151531615317153181531915320153211532215323153241532515326153271532815329153301533115332153331533415335153361533715338153391534015341153421534315344153451534615347153481534915350153511535215353153541535515356153571535815359153601536115362153631536415365153661536715368153691537015371153721537315374153751537615377153781537915380153811538215383153841538515386153871538815389153901539115392153931539415395153961539715398153991540015401154021540315404154051540615407154081540915410154111541215413154141541515416154171541815419154201542115422154231542415425154261542715428154291543015431154321543315434154351543615437154381543915440154411544215443154441544515446154471544815449154501545115452154531545415455154561545715458154591546015461154621546315464154651546615467154681546915470154711547215473154741547515476154771547815479154801548115482154831548415485154861548715488154891549015491154921549315494154951549615497154981549915500155011550215503155041550515506155071550815509155101551115512155131551415515155161551715518155191552015521155221552315524155251552615527155281552915530155311553215533155341553515536155371553815539155401554115542155431554415545155461554715548155491555015551155521555315554155551555615557155581555915560155611556215563155641556515566155671556815569155701557115572155731557415575155761557715578155791558015581155821558315584155851558615587155881558915590155911559215593155941559515596155971559815599156001560115602156031560415605156061560715608156091561015611156121561315614156151561615617156181561915620156211562215623156241562515626156271562815629156301563115632156331563415635156361563715638156391564015641156421564315644156451564615647156481564915650156511565215653156541565515656156571565815659156601566115662156631566415665156661566715668156691567015671156721567315674156751567615677156781567915680156811568215683156841568515686156871568815689156901569115692156931569415695156961569715698156991570015701157021570315704157051570615707157081570915710157111571215713157141571515716157171571815719157201572115722157231572415725157261572715728157291573015731157321573315734157351573615737157381573915740157411574215743157441574515746157471574815749157501575115752157531575415755157561575715758157591576015761157621576315764157651576615767157681576915770157711577215773157741577515776157771577815779157801578115782157831578415785157861578715788157891579015791157921579315794157951579615797157981579915800158011580215803158041580515806158071580815809158101581115812158131581415815158161581715818158191582015821158221582315824158251582615827158281582915830158311583215833158341583515836158371583815839158401584115842158431584415845158461584715848158491585015851158521585315854158551585615857158581585915860158611586215863158641586515866158671586815869158701587115872158731587415875158761587715878158791588015881158821588315884158851588615887158881588915890158911589215893158941589515896158971589815899159001590115902159031590415905159061590715908159091591015911159121591315914159151591615917159181591915920159211592215923159241592515926159271592815929159301593115932159331593415935159361593715938159391594015941159421594315944159451594615947159481594915950159511595215953159541595515956159571595815959159601596115962159631596415965159661596715968159691597015971159721597315974159751597615977159781597915980159811598215983159841598515986159871598815989159901599115992159931599415995159961599715998159991600016001160021600316004160051600616007160081600916010160111601216013160141601516016160171601816019160201602116022160231602416025160261602716028160291603016031160321603316034160351603616037160381603916040160411604216043160441604516046160471604816049160501605116052160531605416055160561605716058160591606016061160621606316064160651606616067160681606916070160711607216073160741607516076160771607816079160801608116082160831608416085160861608716088160891609016091160921609316094160951609616097160981609916100161011610216103161041610516106161071610816109161101611116112161131611416115161161611716118161191612016121161221612316124161251612616127161281612916130161311613216133161341613516136161371613816139161401614116142161431614416145161461614716148161491615016151161521615316154161551615616157161581615916160161611616216163161641616516166161671616816169161701617116172161731617416175161761617716178161791618016181161821618316184161851618616187161881618916190161911619216193161941619516196161971619816199162001620116202162031620416205162061620716208162091621016211162121621316214162151621616217162181621916220162211622216223162241622516226162271622816229162301623116232162331623416235162361623716238162391624016241162421624316244162451624616247162481624916250162511625216253162541625516256162571625816259162601626116262162631626416265162661626716268162691627016271162721627316274162751627616277162781627916280162811628216283162841628516286162871628816289162901629116292162931629416295162961629716298162991630016301163021630316304163051630616307163081630916310163111631216313163141631516316163171631816319163201632116322163231632416325163261632716328163291633016331163321633316334163351633616337163381633916340163411634216343163441634516346163471634816349163501635116352163531635416355163561635716358163591636016361163621636316364163651636616367163681636916370163711637216373163741637516376163771637816379163801638116382163831638416385163861638716388163891639016391163921639316394163951639616397163981639916400164011640216403164041640516406164071640816409164101641116412164131641416415164161641716418164191642016421164221642316424164251642616427164281642916430164311643216433164341643516436164371643816439164401644116442164431644416445164461644716448164491645016451164521645316454164551645616457164581645916460164611646216463164641646516466164671646816469164701647116472164731647416475164761647716478164791648016481164821648316484164851648616487164881648916490164911649216493164941649516496164971649816499165001650116502165031650416505165061650716508165091651016511165121651316514165151651616517165181651916520165211652216523165241652516526165271652816529165301653116532165331653416535165361653716538165391654016541165421654316544165451654616547165481654916550165511655216553165541655516556165571655816559165601656116562165631656416565165661656716568165691657016571165721657316574165751657616577165781657916580165811658216583165841658516586165871658816589165901659116592165931659416595165961659716598165991660016601166021660316604166051660616607166081660916610166111661216613166141661516616166171661816619166201662116622166231662416625166261662716628166291663016631166321663316634166351663616637166381663916640166411664216643166441664516646166471664816649166501665116652166531665416655166561665716658166591666016661166621666316664166651666616667166681666916670166711667216673166741667516676166771667816679166801668116682166831668416685166861668716688166891669016691166921669316694166951669616697166981669916700167011670216703167041670516706167071670816709167101671116712167131671416715167161671716718167191672016721167221672316724167251672616727167281672916730167311673216733167341673516736167371673816739167401674116742167431674416745167461674716748167491675016751167521675316754167551675616757167581675916760167611676216763167641676516766167671676816769167701677116772167731677416775167761677716778167791678016781167821678316784167851678616787167881678916790167911679216793167941679516796167971679816799168001680116802168031680416805168061680716808168091681016811168121681316814168151681616817168181681916820168211682216823168241682516826168271682816829168301683116832168331683416835168361683716838168391684016841168421684316844168451684616847168481684916850168511685216853168541685516856168571685816859168601686116862168631686416865168661686716868168691687016871168721687316874168751687616877168781687916880168811688216883168841688516886168871688816889168901689116892168931689416895168961689716898168991690016901169021690316904169051690616907169081690916910169111691216913169141691516916169171691816919169201692116922169231692416925169261692716928169291693016931169321693316934169351693616937169381693916940169411694216943169441694516946169471694816949169501695116952169531695416955169561695716958169591696016961169621696316964169651696616967169681696916970169711697216973169741697516976169771697816979169801698116982169831698416985169861698716988169891699016991169921699316994169951699616997169981699917000170011700217003170041700517006170071700817009170101701117012170131701417015170161701717018170191702017021170221702317024170251702617027170281702917030170311703217033170341703517036170371703817039170401704117042170431704417045170461704717048170491705017051170521705317054170551705617057170581705917060170611706217063170641706517066170671706817069170701707117072170731707417075170761707717078170791708017081170821708317084170851708617087170881708917090170911709217093170941709517096170971709817099171001710117102171031710417105171061710717108171091711017111171121711317114171151711617117171181711917120171211712217123171241712517126171271712817129171301713117132171331713417135171361713717138171391714017141171421714317144171451714617147171481714917150171511715217153171541715517156171571715817159171601716117162171631716417165171661716717168171691717017171171721717317174171751717617177171781717917180171811718217183171841718517186171871718817189171901719117192171931719417195171961719717198171991720017201172021720317204172051720617207172081720917210172111721217213172141721517216172171721817219172201722117222172231722417225172261722717228172291723017231172321723317234172351723617237172381723917240172411724217243172441724517246172471724817249172501725117252172531725417255172561725717258172591726017261172621726317264172651726617267172681726917270172711727217273172741727517276172771727817279172801728117282172831728417285172861728717288172891729017291172921729317294172951729617297172981729917300173011730217303173041730517306173071730817309173101731117312173131731417315173161731717318173191732017321173221732317324173251732617327173281732917330173311733217333173341733517336173371733817339173401734117342173431734417345173461734717348173491735017351173521735317354173551735617357173581735917360173611736217363173641736517366173671736817369173701737117372173731737417375173761737717378173791738017381173821738317384173851738617387173881738917390173911739217393173941739517396173971739817399174001740117402174031740417405174061740717408174091741017411174121741317414174151741617417174181741917420174211742217423174241742517426174271742817429174301743117432174331743417435174361743717438174391744017441174421744317444174451744617447174481744917450174511745217453174541745517456174571745817459174601746117462174631746417465174661746717468174691747017471174721747317474174751747617477174781747917480174811748217483174841748517486174871748817489174901749117492174931749417495174961749717498174991750017501175021750317504175051750617507175081750917510175111751217513175141751517516175171751817519175201752117522175231752417525175261752717528175291753017531175321753317534175351753617537175381753917540175411754217543175441754517546175471754817549175501755117552175531755417555175561755717558175591756017561175621756317564175651756617567175681756917570175711757217573175741757517576175771757817579175801758117582175831758417585175861758717588175891759017591175921759317594175951759617597175981759917600176011760217603176041760517606176071760817609176101761117612176131761417615176161761717618176191762017621176221762317624176251762617627176281762917630176311763217633176341763517636176371763817639176401764117642176431764417645176461764717648176491765017651176521765317654176551765617657176581765917660176611766217663176641766517666176671766817669176701767117672176731767417675176761767717678176791768017681176821768317684176851768617687176881768917690176911769217693176941769517696176971769817699177001770117702177031770417705177061770717708177091771017711177121771317714177151771617717177181771917720177211772217723177241772517726177271772817729177301773117732177331773417735177361773717738177391774017741177421774317744177451774617747177481774917750177511775217753177541775517756177571775817759177601776117762177631776417765177661776717768177691777017771177721777317774177751777617777177781777917780177811778217783177841778517786177871778817789177901779117792177931779417795177961779717798177991780017801178021780317804178051780617807178081780917810178111781217813178141781517816178171781817819178201782117822178231782417825178261782717828178291783017831178321783317834178351783617837178381783917840178411784217843178441784517846178471784817849178501785117852178531785417855178561785717858178591786017861178621786317864178651786617867178681786917870178711787217873178741787517876178771787817879178801788117882178831788417885178861788717888178891789017891178921789317894178951789617897178981789917900179011790217903179041790517906179071790817909179101791117912179131791417915179161791717918179191792017921179221792317924179251792617927179281792917930179311793217933179341793517936179371793817939179401794117942179431794417945179461794717948179491795017951179521795317954179551795617957179581795917960179611796217963179641796517966179671796817969179701797117972179731797417975179761797717978179791798017981179821798317984179851798617987179881798917990179911799217993179941799517996179971799817999180001800118002180031800418005180061800718008180091801018011180121801318014180151801618017180181801918020180211802218023180241802518026180271802818029180301803118032180331803418035180361803718038180391804018041180421804318044180451804618047180481804918050180511805218053180541805518056180571805818059180601806118062180631806418065180661806718068180691807018071180721807318074180751807618077180781807918080180811808218083180841808518086180871808818089180901809118092180931809418095180961809718098180991810018101181021810318104181051810618107181081810918110181111811218113181141811518116181171811818119181201812118122181231812418125181261812718128181291813018131181321813318134181351813618137181381813918140181411814218143181441814518146181471814818149181501815118152181531815418155181561815718158181591816018161181621816318164181651816618167181681816918170181711817218173181741817518176181771817818179181801818118182181831818418185181861818718188181891819018191181921819318194181951819618197181981819918200182011820218203182041820518206182071820818209182101821118212182131821418215182161821718218182191822018221182221822318224182251822618227182281822918230182311823218233182341823518236182371823818239182401824118242182431824418245182461824718248182491825018251182521825318254182551825618257182581825918260182611826218263182641826518266182671826818269182701827118272182731827418275182761827718278182791828018281182821828318284182851828618287182881828918290182911829218293182941829518296182971829818299183001830118302183031830418305183061830718308183091831018311183121831318314183151831618317183181831918320183211832218323183241832518326183271832818329183301833118332183331833418335183361833718338183391834018341183421834318344183451834618347183481834918350183511835218353183541835518356183571835818359183601836118362183631836418365183661836718368183691837018371183721837318374183751837618377183781837918380183811838218383183841838518386183871838818389183901839118392183931839418395183961839718398183991840018401184021840318404184051840618407184081840918410184111841218413184141841518416184171841818419184201842118422184231842418425184261842718428184291843018431184321843318434184351843618437184381843918440184411844218443184441844518446184471844818449184501845118452184531845418455184561845718458184591846018461184621846318464184651846618467184681846918470184711847218473184741847518476184771847818479184801848118482184831848418485184861848718488184891849018491184921849318494184951849618497184981849918500185011850218503185041850518506185071850818509185101851118512185131851418515185161851718518185191852018521185221852318524185251852618527185281852918530185311853218533185341853518536185371853818539185401854118542185431854418545185461854718548185491855018551185521855318554185551855618557185581855918560185611856218563185641856518566185671856818569185701857118572185731857418575185761857718578185791858018581185821858318584185851858618587185881858918590185911859218593185941859518596185971859818599186001860118602186031860418605186061860718608186091861018611186121861318614186151861618617186181861918620186211862218623186241862518626186271862818629186301863118632186331863418635186361863718638186391864018641186421864318644186451864618647186481864918650186511865218653186541865518656186571865818659186601866118662186631866418665186661866718668186691867018671186721867318674186751867618677186781867918680186811868218683186841868518686186871868818689186901869118692186931869418695186961869718698186991870018701187021870318704187051870618707187081870918710187111871218713187141871518716187171871818719187201872118722187231872418725187261872718728187291873018731187321873318734187351873618737187381873918740187411874218743187441874518746187471874818749187501875118752187531875418755187561875718758187591876018761187621876318764187651876618767187681876918770187711877218773187741877518776187771877818779187801878118782187831878418785187861878718788187891879018791187921879318794187951879618797187981879918800188011880218803188041880518806188071880818809188101881118812188131881418815188161881718818188191882018821188221882318824188251882618827188281882918830188311883218833188341883518836188371883818839188401884118842188431884418845188461884718848188491885018851188521885318854188551885618857188581885918860188611886218863188641886518866188671886818869188701887118872188731887418875188761887718878188791888018881188821888318884188851888618887188881888918890188911889218893188941889518896188971889818899189001890118902189031890418905189061890718908189091891018911189121891318914189151891618917189181891918920189211892218923189241892518926189271892818929189301893118932189331893418935189361893718938189391894018941189421894318944189451894618947189481894918950189511895218953189541895518956189571895818959189601896118962189631896418965189661896718968189691897018971189721897318974189751897618977189781897918980189811898218983189841898518986189871898818989189901899118992189931899418995189961899718998189991900019001190021900319004190051900619007190081900919010190111901219013190141901519016190171901819019190201902119022190231902419025190261902719028190291903019031190321903319034190351903619037190381903919040190411904219043190441904519046190471904819049190501905119052190531905419055190561905719058190591906019061190621906319064190651906619067190681906919070190711907219073190741907519076190771907819079190801908119082190831908419085190861908719088190891909019091190921909319094190951909619097190981909919100191011910219103191041910519106191071910819109191101911119112191131911419115191161911719118191191912019121191221912319124191251912619127191281912919130191311913219133191341913519136191371913819139191401914119142191431914419145191461914719148191491915019151191521915319154191551915619157191581915919160191611916219163191641916519166191671916819169191701917119172191731917419175191761917719178191791918019181191821918319184191851918619187191881918919190191911919219193191941919519196191971919819199192001920119202192031920419205192061920719208192091921019211192121921319214192151921619217192181921919220192211922219223192241922519226192271922819229192301923119232192331923419235192361923719238192391924019241192421924319244192451924619247192481924919250192511925219253192541925519256192571925819259192601926119262192631926419265192661926719268192691927019271192721927319274192751927619277192781927919280192811928219283192841928519286192871928819289192901929119292192931929419295192961929719298192991930019301193021930319304193051930619307193081930919310193111931219313193141931519316193171931819319193201932119322193231932419325193261932719328193291933019331193321933319334193351933619337193381933919340193411934219343193441934519346193471934819349193501935119352193531935419355193561935719358193591936019361193621936319364193651936619367193681936919370193711937219373193741937519376193771937819379193801938119382193831938419385193861938719388193891939019391193921939319394193951939619397193981939919400194011940219403194041940519406194071940819409194101941119412194131941419415194161941719418194191942019421194221942319424194251942619427194281942919430194311943219433194341943519436194371943819439194401944119442194431944419445194461944719448194491945019451194521945319454194551945619457194581945919460194611946219463194641946519466194671946819469194701947119472194731947419475194761947719478194791948019481194821948319484194851948619487194881948919490194911949219493194941949519496194971949819499195001950119502195031950419505195061950719508195091951019511195121951319514195151951619517195181951919520195211952219523195241952519526195271952819529195301953119532195331953419535195361953719538195391954019541195421954319544195451954619547195481954919550195511955219553195541955519556195571955819559195601956119562195631956419565195661956719568195691957019571195721957319574195751957619577195781957919580195811958219583195841958519586195871958819589195901959119592195931959419595195961959719598195991960019601196021960319604196051960619607196081960919610196111961219613196141961519616196171961819619196201962119622196231962419625196261962719628196291963019631196321963319634196351963619637196381963919640196411964219643196441964519646196471964819649196501965119652196531965419655196561965719658196591966019661196621966319664196651966619667196681966919670196711967219673196741967519676196771967819679196801968119682196831968419685196861968719688196891969019691196921969319694196951969619697196981969919700197011970219703197041970519706197071970819709197101971119712197131971419715197161971719718197191972019721197221972319724197251972619727197281972919730197311973219733197341973519736197371973819739197401974119742197431974419745197461974719748197491975019751197521975319754197551975619757197581975919760197611976219763197641976519766197671976819769197701977119772197731977419775197761977719778197791978019781197821978319784197851978619787197881978919790197911979219793197941979519796197971979819799198001980119802198031980419805198061980719808198091981019811198121981319814198151981619817198181981919820198211982219823198241982519826198271982819829198301983119832198331983419835198361983719838198391984019841198421984319844198451984619847198481984919850198511985219853198541985519856198571985819859198601986119862198631986419865198661986719868198691987019871198721987319874198751987619877198781987919880198811988219883198841988519886198871988819889198901989119892198931989419895198961989719898198991990019901199021990319904199051990619907199081990919910199111991219913199141991519916199171991819919199201992119922199231992419925199261992719928199291993019931199321993319934199351993619937199381993919940199411994219943199441994519946199471994819949199501995119952199531995419955199561995719958199591996019961199621996319964199651996619967199681996919970199711997219973199741997519976199771997819979199801998119982199831998419985199861998719988199891999019991199921999319994199951999619997199981999920000200012000220003200042000520006200072000820009200102001120012200132001420015200162001720018200192002020021200222002320024200252002620027200282002920030200312003220033200342003520036200372003820039200402004120042200432004420045200462004720048200492005020051200522005320054200552005620057200582005920060200612006220063200642006520066200672006820069200702007120072200732007420075200762007720078200792008020081200822008320084200852008620087200882008920090200912009220093200942009520096200972009820099201002010120102201032010420105201062010720108201092011020111201122011320114201152011620117201182011920120201212012220123201242012520126201272012820129201302013120132201332013420135201362013720138201392014020141201422014320144201452014620147201482014920150201512015220153201542015520156201572015820159201602016120162201632016420165201662016720168201692017020171201722017320174201752017620177201782017920180201812018220183201842018520186201872018820189201902019120192201932019420195201962019720198201992020020201202022020320204202052020620207202082020920210202112021220213202142021520216202172021820219202202022120222202232022420225202262022720228202292023020231202322023320234202352023620237202382023920240202412024220243202442024520246202472024820249202502025120252202532025420255202562025720258202592026020261202622026320264202652026620267202682026920270202712027220273202742027520276202772027820279202802028120282202832028420285202862028720288202892029020291202922029320294202952029620297202982029920300203012030220303203042030520306203072030820309203102031120312203132031420315203162031720318203192032020321203222032320324203252032620327203282032920330203312033220333203342033520336203372033820339203402034120342203432034420345203462034720348203492035020351203522035320354203552035620357203582035920360203612036220363203642036520366203672036820369203702037120372203732037420375203762037720378203792038020381203822038320384203852038620387203882038920390203912039220393203942039520396203972039820399204002040120402204032040420405204062040720408204092041020411204122041320414204152041620417204182041920420204212042220423204242042520426204272042820429204302043120432204332043420435204362043720438204392044020441204422044320444204452044620447204482044920450204512045220453204542045520456204572045820459204602046120462204632046420465204662046720468204692047020471204722047320474204752047620477204782047920480204812048220483204842048520486204872048820489204902049120492204932049420495204962049720498204992050020501205022050320504205052050620507205082050920510205112051220513205142051520516205172051820519205202052120522205232052420525205262052720528205292053020531205322053320534205352053620537205382053920540205412054220543205442054520546205472054820549205502055120552205532055420555205562055720558205592056020561205622056320564205652056620567205682056920570205712057220573205742057520576205772057820579205802058120582205832058420585205862058720588205892059020591205922059320594205952059620597205982059920600206012060220603206042060520606206072060820609206102061120612206132061420615206162061720618206192062020621206222062320624206252062620627206282062920630206312063220633206342063520636206372063820639206402064120642206432064420645206462064720648206492065020651206522065320654206552065620657206582065920660206612066220663206642066520666206672066820669206702067120672206732067420675206762067720678206792068020681206822068320684206852068620687206882068920690206912069220693206942069520696206972069820699207002070120702207032070420705207062070720708207092071020711207122071320714207152071620717207182071920720207212072220723207242072520726207272072820729207302073120732207332073420735207362073720738207392074020741207422074320744207452074620747207482074920750207512075220753207542075520756207572075820759207602076120762207632076420765207662076720768207692077020771207722077320774207752077620777207782077920780207812078220783207842078520786207872078820789207902079120792207932079420795207962079720798207992080020801208022080320804208052080620807208082080920810208112081220813208142081520816208172081820819208202082120822208232082420825208262082720828208292083020831208322083320834208352083620837208382083920840208412084220843208442084520846208472084820849208502085120852208532085420855208562085720858208592086020861208622086320864208652086620867208682086920870208712087220873208742087520876208772087820879208802088120882208832088420885208862088720888208892089020891208922089320894208952089620897208982089920900209012090220903209042090520906209072090820909209102091120912209132091420915209162091720918209192092020921209222092320924209252092620927209282092920930209312093220933209342093520936209372093820939209402094120942209432094420945209462094720948209492095020951209522095320954209552095620957209582095920960209612096220963209642096520966209672096820969209702097120972209732097420975209762097720978209792098020981209822098320984209852098620987209882098920990209912099220993209942099520996209972099820999210002100121002210032100421005210062100721008210092101021011210122101321014210152101621017210182101921020210212102221023210242102521026210272102821029210302103121032210332103421035210362103721038210392104021041210422104321044210452104621047210482104921050210512105221053210542105521056210572105821059210602106121062210632106421065210662106721068210692107021071210722107321074210752107621077210782107921080210812108221083210842108521086210872108821089210902109121092210932109421095210962109721098210992110021101211022110321104211052110621107211082110921110211112111221113211142111521116211172111821119211202112121122211232112421125211262112721128211292113021131211322113321134211352113621137211382113921140211412114221143211442114521146211472114821149211502115121152211532115421155211562115721158211592116021161211622116321164211652116621167211682116921170211712117221173211742117521176211772117821179211802118121182211832118421185211862118721188211892119021191211922119321194211952119621197211982119921200212012120221203212042120521206212072120821209212102121121212212132121421215212162121721218212192122021221212222122321224212252122621227212282122921230212312123221233212342123521236212372123821239212402124121242212432124421245212462124721248212492125021251212522125321254212552125621257212582125921260212612126221263212642126521266212672126821269212702127121272212732127421275212762127721278212792128021281212822128321284212852128621287212882128921290212912129221293212942129521296212972129821299213002130121302213032130421305213062130721308213092131021311213122131321314213152131621317213182131921320213212132221323213242132521326213272132821329213302133121332213332133421335213362133721338213392134021341213422134321344213452134621347213482134921350213512135221353213542135521356213572135821359213602136121362213632136421365213662136721368213692137021371213722137321374
  1. // Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
  2. package s3
  3. import (
  4. "fmt"
  5. "io"
  6. "time"
  7. "github.com/aws/aws-sdk-go/aws"
  8. "github.com/aws/aws-sdk-go/aws/awsutil"
  9. "github.com/aws/aws-sdk-go/aws/request"
  10. "github.com/aws/aws-sdk-go/private/protocol"
  11. "github.com/aws/aws-sdk-go/private/protocol/restxml"
  12. )
  13. const opAbortMultipartUpload = "AbortMultipartUpload"
  14. // AbortMultipartUploadRequest generates a "aws/request.Request" representing the
  15. // client's request for the AbortMultipartUpload operation. The "output" return
  16. // value will be populated with the request's response once the request complets
  17. // successfuly.
  18. //
  19. // Use "Send" method on the returned Request to send the API call to the service.
  20. // the "output" return value is not valid until after Send returns without error.
  21. //
  22. // See AbortMultipartUpload for more information on using the AbortMultipartUpload
  23. // API call, and error handling.
  24. //
  25. // This method is useful when you want to inject custom logic or configuration
  26. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  27. //
  28. //
  29. // // Example sending a request using the AbortMultipartUploadRequest method.
  30. // req, resp := client.AbortMultipartUploadRequest(params)
  31. //
  32. // err := req.Send()
  33. // if err == nil { // resp is now filled
  34. // fmt.Println(resp)
  35. // }
  36. //
  37. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUpload
  38. func (c *S3) AbortMultipartUploadRequest(input *AbortMultipartUploadInput) (req *request.Request, output *AbortMultipartUploadOutput) {
  39. op := &request.Operation{
  40. Name: opAbortMultipartUpload,
  41. HTTPMethod: "DELETE",
  42. HTTPPath: "/{Bucket}/{Key+}",
  43. }
  44. if input == nil {
  45. input = &AbortMultipartUploadInput{}
  46. }
  47. output = &AbortMultipartUploadOutput{}
  48. req = c.newRequest(op, input, output)
  49. return
  50. }
  51. // AbortMultipartUpload API operation for Amazon Simple Storage Service.
  52. //
  53. // Aborts a multipart upload.
  54. //
  55. // To verify that all parts have been removed, so you don't get charged for
  56. // the part storage, you should call the List Parts operation and ensure the
  57. // parts list is empty.
  58. //
  59. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  60. // with awserr.Error's Code and Message methods to get detailed information about
  61. // the error.
  62. //
  63. // See the AWS API reference guide for Amazon Simple Storage Service's
  64. // API operation AbortMultipartUpload for usage and error information.
  65. //
  66. // Returned Error Codes:
  67. // * ErrCodeNoSuchUpload "NoSuchUpload"
  68. // The specified multipart upload does not exist.
  69. //
  70. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUpload
  71. func (c *S3) AbortMultipartUpload(input *AbortMultipartUploadInput) (*AbortMultipartUploadOutput, error) {
  72. req, out := c.AbortMultipartUploadRequest(input)
  73. return out, req.Send()
  74. }
  75. // AbortMultipartUploadWithContext is the same as AbortMultipartUpload with the addition of
  76. // the ability to pass a context and additional request options.
  77. //
  78. // See AbortMultipartUpload for details on how to use this API operation.
  79. //
  80. // The context must be non-nil and will be used for request cancellation. If
  81. // the context is nil a panic will occur. In the future the SDK may create
  82. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  83. // for more information on using Contexts.
  84. func (c *S3) AbortMultipartUploadWithContext(ctx aws.Context, input *AbortMultipartUploadInput, opts ...request.Option) (*AbortMultipartUploadOutput, error) {
  85. req, out := c.AbortMultipartUploadRequest(input)
  86. req.SetContext(ctx)
  87. req.ApplyOptions(opts...)
  88. return out, req.Send()
  89. }
  90. const opCompleteMultipartUpload = "CompleteMultipartUpload"
  91. // CompleteMultipartUploadRequest generates a "aws/request.Request" representing the
  92. // client's request for the CompleteMultipartUpload operation. The "output" return
  93. // value will be populated with the request's response once the request complets
  94. // successfuly.
  95. //
  96. // Use "Send" method on the returned Request to send the API call to the service.
  97. // the "output" return value is not valid until after Send returns without error.
  98. //
  99. // See CompleteMultipartUpload for more information on using the CompleteMultipartUpload
  100. // API call, and error handling.
  101. //
  102. // This method is useful when you want to inject custom logic or configuration
  103. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  104. //
  105. //
  106. // // Example sending a request using the CompleteMultipartUploadRequest method.
  107. // req, resp := client.CompleteMultipartUploadRequest(params)
  108. //
  109. // err := req.Send()
  110. // if err == nil { // resp is now filled
  111. // fmt.Println(resp)
  112. // }
  113. //
  114. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUpload
  115. func (c *S3) CompleteMultipartUploadRequest(input *CompleteMultipartUploadInput) (req *request.Request, output *CompleteMultipartUploadOutput) {
  116. op := &request.Operation{
  117. Name: opCompleteMultipartUpload,
  118. HTTPMethod: "POST",
  119. HTTPPath: "/{Bucket}/{Key+}",
  120. }
  121. if input == nil {
  122. input = &CompleteMultipartUploadInput{}
  123. }
  124. output = &CompleteMultipartUploadOutput{}
  125. req = c.newRequest(op, input, output)
  126. return
  127. }
  128. // CompleteMultipartUpload API operation for Amazon Simple Storage Service.
  129. //
  130. // Completes a multipart upload by assembling previously uploaded parts.
  131. //
  132. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  133. // with awserr.Error's Code and Message methods to get detailed information about
  134. // the error.
  135. //
  136. // See the AWS API reference guide for Amazon Simple Storage Service's
  137. // API operation CompleteMultipartUpload for usage and error information.
  138. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUpload
  139. func (c *S3) CompleteMultipartUpload(input *CompleteMultipartUploadInput) (*CompleteMultipartUploadOutput, error) {
  140. req, out := c.CompleteMultipartUploadRequest(input)
  141. return out, req.Send()
  142. }
  143. // CompleteMultipartUploadWithContext is the same as CompleteMultipartUpload with the addition of
  144. // the ability to pass a context and additional request options.
  145. //
  146. // See CompleteMultipartUpload for details on how to use this API operation.
  147. //
  148. // The context must be non-nil and will be used for request cancellation. If
  149. // the context is nil a panic will occur. In the future the SDK may create
  150. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  151. // for more information on using Contexts.
  152. func (c *S3) CompleteMultipartUploadWithContext(ctx aws.Context, input *CompleteMultipartUploadInput, opts ...request.Option) (*CompleteMultipartUploadOutput, error) {
  153. req, out := c.CompleteMultipartUploadRequest(input)
  154. req.SetContext(ctx)
  155. req.ApplyOptions(opts...)
  156. return out, req.Send()
  157. }
  158. const opCopyObject = "CopyObject"
  159. // CopyObjectRequest generates a "aws/request.Request" representing the
  160. // client's request for the CopyObject operation. The "output" return
  161. // value will be populated with the request's response once the request complets
  162. // successfuly.
  163. //
  164. // Use "Send" method on the returned Request to send the API call to the service.
  165. // the "output" return value is not valid until after Send returns without error.
  166. //
  167. // See CopyObject for more information on using the CopyObject
  168. // API call, and error handling.
  169. //
  170. // This method is useful when you want to inject custom logic or configuration
  171. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  172. //
  173. //
  174. // // Example sending a request using the CopyObjectRequest method.
  175. // req, resp := client.CopyObjectRequest(params)
  176. //
  177. // err := req.Send()
  178. // if err == nil { // resp is now filled
  179. // fmt.Println(resp)
  180. // }
  181. //
  182. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObject
  183. func (c *S3) CopyObjectRequest(input *CopyObjectInput) (req *request.Request, output *CopyObjectOutput) {
  184. op := &request.Operation{
  185. Name: opCopyObject,
  186. HTTPMethod: "PUT",
  187. HTTPPath: "/{Bucket}/{Key+}",
  188. }
  189. if input == nil {
  190. input = &CopyObjectInput{}
  191. }
  192. output = &CopyObjectOutput{}
  193. req = c.newRequest(op, input, output)
  194. return
  195. }
  196. // CopyObject API operation for Amazon Simple Storage Service.
  197. //
  198. // Creates a copy of an object that is already stored in Amazon S3.
  199. //
  200. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  201. // with awserr.Error's Code and Message methods to get detailed information about
  202. // the error.
  203. //
  204. // See the AWS API reference guide for Amazon Simple Storage Service's
  205. // API operation CopyObject for usage and error information.
  206. //
  207. // Returned Error Codes:
  208. // * ErrCodeObjectNotInActiveTierError "ObjectNotInActiveTierError"
  209. // The source object of the COPY operation is not in the active tier and is
  210. // only stored in Amazon Glacier.
  211. //
  212. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObject
  213. func (c *S3) CopyObject(input *CopyObjectInput) (*CopyObjectOutput, error) {
  214. req, out := c.CopyObjectRequest(input)
  215. return out, req.Send()
  216. }
  217. // CopyObjectWithContext is the same as CopyObject with the addition of
  218. // the ability to pass a context and additional request options.
  219. //
  220. // See CopyObject for details on how to use this API operation.
  221. //
  222. // The context must be non-nil and will be used for request cancellation. If
  223. // the context is nil a panic will occur. In the future the SDK may create
  224. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  225. // for more information on using Contexts.
  226. func (c *S3) CopyObjectWithContext(ctx aws.Context, input *CopyObjectInput, opts ...request.Option) (*CopyObjectOutput, error) {
  227. req, out := c.CopyObjectRequest(input)
  228. req.SetContext(ctx)
  229. req.ApplyOptions(opts...)
  230. return out, req.Send()
  231. }
  232. const opCreateBucket = "CreateBucket"
  233. // CreateBucketRequest generates a "aws/request.Request" representing the
  234. // client's request for the CreateBucket operation. The "output" return
  235. // value will be populated with the request's response once the request complets
  236. // successfuly.
  237. //
  238. // Use "Send" method on the returned Request to send the API call to the service.
  239. // the "output" return value is not valid until after Send returns without error.
  240. //
  241. // See CreateBucket for more information on using the CreateBucket
  242. // API call, and error handling.
  243. //
  244. // This method is useful when you want to inject custom logic or configuration
  245. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  246. //
  247. //
  248. // // Example sending a request using the CreateBucketRequest method.
  249. // req, resp := client.CreateBucketRequest(params)
  250. //
  251. // err := req.Send()
  252. // if err == nil { // resp is now filled
  253. // fmt.Println(resp)
  254. // }
  255. //
  256. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucket
  257. func (c *S3) CreateBucketRequest(input *CreateBucketInput) (req *request.Request, output *CreateBucketOutput) {
  258. op := &request.Operation{
  259. Name: opCreateBucket,
  260. HTTPMethod: "PUT",
  261. HTTPPath: "/{Bucket}",
  262. }
  263. if input == nil {
  264. input = &CreateBucketInput{}
  265. }
  266. output = &CreateBucketOutput{}
  267. req = c.newRequest(op, input, output)
  268. return
  269. }
  270. // CreateBucket API operation for Amazon Simple Storage Service.
  271. //
  272. // Creates a new bucket.
  273. //
  274. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  275. // with awserr.Error's Code and Message methods to get detailed information about
  276. // the error.
  277. //
  278. // See the AWS API reference guide for Amazon Simple Storage Service's
  279. // API operation CreateBucket for usage and error information.
  280. //
  281. // Returned Error Codes:
  282. // * ErrCodeBucketAlreadyExists "BucketAlreadyExists"
  283. // The requested bucket name is not available. The bucket namespace is shared
  284. // by all users of the system. Please select a different name and try again.
  285. //
  286. // * ErrCodeBucketAlreadyOwnedByYou "BucketAlreadyOwnedByYou"
  287. //
  288. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucket
  289. func (c *S3) CreateBucket(input *CreateBucketInput) (*CreateBucketOutput, error) {
  290. req, out := c.CreateBucketRequest(input)
  291. return out, req.Send()
  292. }
  293. // CreateBucketWithContext is the same as CreateBucket with the addition of
  294. // the ability to pass a context and additional request options.
  295. //
  296. // See CreateBucket for details on how to use this API operation.
  297. //
  298. // The context must be non-nil and will be used for request cancellation. If
  299. // the context is nil a panic will occur. In the future the SDK may create
  300. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  301. // for more information on using Contexts.
  302. func (c *S3) CreateBucketWithContext(ctx aws.Context, input *CreateBucketInput, opts ...request.Option) (*CreateBucketOutput, error) {
  303. req, out := c.CreateBucketRequest(input)
  304. req.SetContext(ctx)
  305. req.ApplyOptions(opts...)
  306. return out, req.Send()
  307. }
  308. const opCreateMultipartUpload = "CreateMultipartUpload"
  309. // CreateMultipartUploadRequest generates a "aws/request.Request" representing the
  310. // client's request for the CreateMultipartUpload operation. The "output" return
  311. // value will be populated with the request's response once the request complets
  312. // successfuly.
  313. //
  314. // Use "Send" method on the returned Request to send the API call to the service.
  315. // the "output" return value is not valid until after Send returns without error.
  316. //
  317. // See CreateMultipartUpload for more information on using the CreateMultipartUpload
  318. // API call, and error handling.
  319. //
  320. // This method is useful when you want to inject custom logic or configuration
  321. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  322. //
  323. //
  324. // // Example sending a request using the CreateMultipartUploadRequest method.
  325. // req, resp := client.CreateMultipartUploadRequest(params)
  326. //
  327. // err := req.Send()
  328. // if err == nil { // resp is now filled
  329. // fmt.Println(resp)
  330. // }
  331. //
  332. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUpload
  333. func (c *S3) CreateMultipartUploadRequest(input *CreateMultipartUploadInput) (req *request.Request, output *CreateMultipartUploadOutput) {
  334. op := &request.Operation{
  335. Name: opCreateMultipartUpload,
  336. HTTPMethod: "POST",
  337. HTTPPath: "/{Bucket}/{Key+}?uploads",
  338. }
  339. if input == nil {
  340. input = &CreateMultipartUploadInput{}
  341. }
  342. output = &CreateMultipartUploadOutput{}
  343. req = c.newRequest(op, input, output)
  344. return
  345. }
  346. // CreateMultipartUpload API operation for Amazon Simple Storage Service.
  347. //
  348. // Initiates a multipart upload and returns an upload ID.
  349. //
  350. // Note: After you initiate multipart upload and upload one or more parts, you
  351. // must either complete or abort multipart upload in order to stop getting charged
  352. // for storage of the uploaded parts. Only after you either complete or abort
  353. // multipart upload, Amazon S3 frees up the parts storage and stops charging
  354. // you for the parts storage.
  355. //
  356. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  357. // with awserr.Error's Code and Message methods to get detailed information about
  358. // the error.
  359. //
  360. // See the AWS API reference guide for Amazon Simple Storage Service's
  361. // API operation CreateMultipartUpload for usage and error information.
  362. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUpload
  363. func (c *S3) CreateMultipartUpload(input *CreateMultipartUploadInput) (*CreateMultipartUploadOutput, error) {
  364. req, out := c.CreateMultipartUploadRequest(input)
  365. return out, req.Send()
  366. }
  367. // CreateMultipartUploadWithContext is the same as CreateMultipartUpload with the addition of
  368. // the ability to pass a context and additional request options.
  369. //
  370. // See CreateMultipartUpload for details on how to use this API operation.
  371. //
  372. // The context must be non-nil and will be used for request cancellation. If
  373. // the context is nil a panic will occur. In the future the SDK may create
  374. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  375. // for more information on using Contexts.
  376. func (c *S3) CreateMultipartUploadWithContext(ctx aws.Context, input *CreateMultipartUploadInput, opts ...request.Option) (*CreateMultipartUploadOutput, error) {
  377. req, out := c.CreateMultipartUploadRequest(input)
  378. req.SetContext(ctx)
  379. req.ApplyOptions(opts...)
  380. return out, req.Send()
  381. }
  382. const opDeleteBucket = "DeleteBucket"
  383. // DeleteBucketRequest generates a "aws/request.Request" representing the
  384. // client's request for the DeleteBucket operation. The "output" return
  385. // value will be populated with the request's response once the request complets
  386. // successfuly.
  387. //
  388. // Use "Send" method on the returned Request to send the API call to the service.
  389. // the "output" return value is not valid until after Send returns without error.
  390. //
  391. // See DeleteBucket for more information on using the DeleteBucket
  392. // API call, and error handling.
  393. //
  394. // This method is useful when you want to inject custom logic or configuration
  395. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  396. //
  397. //
  398. // // Example sending a request using the DeleteBucketRequest method.
  399. // req, resp := client.DeleteBucketRequest(params)
  400. //
  401. // err := req.Send()
  402. // if err == nil { // resp is now filled
  403. // fmt.Println(resp)
  404. // }
  405. //
  406. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucket
  407. func (c *S3) DeleteBucketRequest(input *DeleteBucketInput) (req *request.Request, output *DeleteBucketOutput) {
  408. op := &request.Operation{
  409. Name: opDeleteBucket,
  410. HTTPMethod: "DELETE",
  411. HTTPPath: "/{Bucket}",
  412. }
  413. if input == nil {
  414. input = &DeleteBucketInput{}
  415. }
  416. output = &DeleteBucketOutput{}
  417. req = c.newRequest(op, input, output)
  418. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  419. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  420. return
  421. }
  422. // DeleteBucket API operation for Amazon Simple Storage Service.
  423. //
  424. // Deletes the bucket. All objects (including all object versions and Delete
  425. // Markers) in the bucket must be deleted before the bucket itself can be deleted.
  426. //
  427. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  428. // with awserr.Error's Code and Message methods to get detailed information about
  429. // the error.
  430. //
  431. // See the AWS API reference guide for Amazon Simple Storage Service's
  432. // API operation DeleteBucket for usage and error information.
  433. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucket
  434. func (c *S3) DeleteBucket(input *DeleteBucketInput) (*DeleteBucketOutput, error) {
  435. req, out := c.DeleteBucketRequest(input)
  436. return out, req.Send()
  437. }
  438. // DeleteBucketWithContext is the same as DeleteBucket with the addition of
  439. // the ability to pass a context and additional request options.
  440. //
  441. // See DeleteBucket for details on how to use this API operation.
  442. //
  443. // The context must be non-nil and will be used for request cancellation. If
  444. // the context is nil a panic will occur. In the future the SDK may create
  445. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  446. // for more information on using Contexts.
  447. func (c *S3) DeleteBucketWithContext(ctx aws.Context, input *DeleteBucketInput, opts ...request.Option) (*DeleteBucketOutput, error) {
  448. req, out := c.DeleteBucketRequest(input)
  449. req.SetContext(ctx)
  450. req.ApplyOptions(opts...)
  451. return out, req.Send()
  452. }
  453. const opDeleteBucketAnalyticsConfiguration = "DeleteBucketAnalyticsConfiguration"
  454. // DeleteBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the
  455. // client's request for the DeleteBucketAnalyticsConfiguration operation. The "output" return
  456. // value will be populated with the request's response once the request complets
  457. // successfuly.
  458. //
  459. // Use "Send" method on the returned Request to send the API call to the service.
  460. // the "output" return value is not valid until after Send returns without error.
  461. //
  462. // See DeleteBucketAnalyticsConfiguration for more information on using the DeleteBucketAnalyticsConfiguration
  463. // API call, and error handling.
  464. //
  465. // This method is useful when you want to inject custom logic or configuration
  466. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  467. //
  468. //
  469. // // Example sending a request using the DeleteBucketAnalyticsConfigurationRequest method.
  470. // req, resp := client.DeleteBucketAnalyticsConfigurationRequest(params)
  471. //
  472. // err := req.Send()
  473. // if err == nil { // resp is now filled
  474. // fmt.Println(resp)
  475. // }
  476. //
  477. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfiguration
  478. func (c *S3) DeleteBucketAnalyticsConfigurationRequest(input *DeleteBucketAnalyticsConfigurationInput) (req *request.Request, output *DeleteBucketAnalyticsConfigurationOutput) {
  479. op := &request.Operation{
  480. Name: opDeleteBucketAnalyticsConfiguration,
  481. HTTPMethod: "DELETE",
  482. HTTPPath: "/{Bucket}?analytics",
  483. }
  484. if input == nil {
  485. input = &DeleteBucketAnalyticsConfigurationInput{}
  486. }
  487. output = &DeleteBucketAnalyticsConfigurationOutput{}
  488. req = c.newRequest(op, input, output)
  489. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  490. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  491. return
  492. }
  493. // DeleteBucketAnalyticsConfiguration API operation for Amazon Simple Storage Service.
  494. //
  495. // Deletes an analytics configuration for the bucket (specified by the analytics
  496. // configuration ID).
  497. //
  498. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  499. // with awserr.Error's Code and Message methods to get detailed information about
  500. // the error.
  501. //
  502. // See the AWS API reference guide for Amazon Simple Storage Service's
  503. // API operation DeleteBucketAnalyticsConfiguration for usage and error information.
  504. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfiguration
  505. func (c *S3) DeleteBucketAnalyticsConfiguration(input *DeleteBucketAnalyticsConfigurationInput) (*DeleteBucketAnalyticsConfigurationOutput, error) {
  506. req, out := c.DeleteBucketAnalyticsConfigurationRequest(input)
  507. return out, req.Send()
  508. }
  509. // DeleteBucketAnalyticsConfigurationWithContext is the same as DeleteBucketAnalyticsConfiguration with the addition of
  510. // the ability to pass a context and additional request options.
  511. //
  512. // See DeleteBucketAnalyticsConfiguration for details on how to use this API operation.
  513. //
  514. // The context must be non-nil and will be used for request cancellation. If
  515. // the context is nil a panic will occur. In the future the SDK may create
  516. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  517. // for more information on using Contexts.
  518. func (c *S3) DeleteBucketAnalyticsConfigurationWithContext(ctx aws.Context, input *DeleteBucketAnalyticsConfigurationInput, opts ...request.Option) (*DeleteBucketAnalyticsConfigurationOutput, error) {
  519. req, out := c.DeleteBucketAnalyticsConfigurationRequest(input)
  520. req.SetContext(ctx)
  521. req.ApplyOptions(opts...)
  522. return out, req.Send()
  523. }
  524. const opDeleteBucketCors = "DeleteBucketCors"
  525. // DeleteBucketCorsRequest generates a "aws/request.Request" representing the
  526. // client's request for the DeleteBucketCors operation. The "output" return
  527. // value will be populated with the request's response once the request complets
  528. // successfuly.
  529. //
  530. // Use "Send" method on the returned Request to send the API call to the service.
  531. // the "output" return value is not valid until after Send returns without error.
  532. //
  533. // See DeleteBucketCors for more information on using the DeleteBucketCors
  534. // API call, and error handling.
  535. //
  536. // This method is useful when you want to inject custom logic or configuration
  537. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  538. //
  539. //
  540. // // Example sending a request using the DeleteBucketCorsRequest method.
  541. // req, resp := client.DeleteBucketCorsRequest(params)
  542. //
  543. // err := req.Send()
  544. // if err == nil { // resp is now filled
  545. // fmt.Println(resp)
  546. // }
  547. //
  548. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCors
  549. func (c *S3) DeleteBucketCorsRequest(input *DeleteBucketCorsInput) (req *request.Request, output *DeleteBucketCorsOutput) {
  550. op := &request.Operation{
  551. Name: opDeleteBucketCors,
  552. HTTPMethod: "DELETE",
  553. HTTPPath: "/{Bucket}?cors",
  554. }
  555. if input == nil {
  556. input = &DeleteBucketCorsInput{}
  557. }
  558. output = &DeleteBucketCorsOutput{}
  559. req = c.newRequest(op, input, output)
  560. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  561. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  562. return
  563. }
  564. // DeleteBucketCors API operation for Amazon Simple Storage Service.
  565. //
  566. // Deletes the cors configuration information set for the bucket.
  567. //
  568. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  569. // with awserr.Error's Code and Message methods to get detailed information about
  570. // the error.
  571. //
  572. // See the AWS API reference guide for Amazon Simple Storage Service's
  573. // API operation DeleteBucketCors for usage and error information.
  574. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCors
  575. func (c *S3) DeleteBucketCors(input *DeleteBucketCorsInput) (*DeleteBucketCorsOutput, error) {
  576. req, out := c.DeleteBucketCorsRequest(input)
  577. return out, req.Send()
  578. }
  579. // DeleteBucketCorsWithContext is the same as DeleteBucketCors with the addition of
  580. // the ability to pass a context and additional request options.
  581. //
  582. // See DeleteBucketCors for details on how to use this API operation.
  583. //
  584. // The context must be non-nil and will be used for request cancellation. If
  585. // the context is nil a panic will occur. In the future the SDK may create
  586. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  587. // for more information on using Contexts.
  588. func (c *S3) DeleteBucketCorsWithContext(ctx aws.Context, input *DeleteBucketCorsInput, opts ...request.Option) (*DeleteBucketCorsOutput, error) {
  589. req, out := c.DeleteBucketCorsRequest(input)
  590. req.SetContext(ctx)
  591. req.ApplyOptions(opts...)
  592. return out, req.Send()
  593. }
  594. const opDeleteBucketEncryption = "DeleteBucketEncryption"
  595. // DeleteBucketEncryptionRequest generates a "aws/request.Request" representing the
  596. // client's request for the DeleteBucketEncryption operation. The "output" return
  597. // value will be populated with the request's response once the request complets
  598. // successfuly.
  599. //
  600. // Use "Send" method on the returned Request to send the API call to the service.
  601. // the "output" return value is not valid until after Send returns without error.
  602. //
  603. // See DeleteBucketEncryption for more information on using the DeleteBucketEncryption
  604. // API call, and error handling.
  605. //
  606. // This method is useful when you want to inject custom logic or configuration
  607. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  608. //
  609. //
  610. // // Example sending a request using the DeleteBucketEncryptionRequest method.
  611. // req, resp := client.DeleteBucketEncryptionRequest(params)
  612. //
  613. // err := req.Send()
  614. // if err == nil { // resp is now filled
  615. // fmt.Println(resp)
  616. // }
  617. //
  618. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryption
  619. func (c *S3) DeleteBucketEncryptionRequest(input *DeleteBucketEncryptionInput) (req *request.Request, output *DeleteBucketEncryptionOutput) {
  620. op := &request.Operation{
  621. Name: opDeleteBucketEncryption,
  622. HTTPMethod: "DELETE",
  623. HTTPPath: "/{Bucket}?encryption",
  624. }
  625. if input == nil {
  626. input = &DeleteBucketEncryptionInput{}
  627. }
  628. output = &DeleteBucketEncryptionOutput{}
  629. req = c.newRequest(op, input, output)
  630. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  631. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  632. return
  633. }
  634. // DeleteBucketEncryption API operation for Amazon Simple Storage Service.
  635. //
  636. // Deletes the server-side encryption configuration from the bucket.
  637. //
  638. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  639. // with awserr.Error's Code and Message methods to get detailed information about
  640. // the error.
  641. //
  642. // See the AWS API reference guide for Amazon Simple Storage Service's
  643. // API operation DeleteBucketEncryption for usage and error information.
  644. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryption
  645. func (c *S3) DeleteBucketEncryption(input *DeleteBucketEncryptionInput) (*DeleteBucketEncryptionOutput, error) {
  646. req, out := c.DeleteBucketEncryptionRequest(input)
  647. return out, req.Send()
  648. }
  649. // DeleteBucketEncryptionWithContext is the same as DeleteBucketEncryption with the addition of
  650. // the ability to pass a context and additional request options.
  651. //
  652. // See DeleteBucketEncryption for details on how to use this API operation.
  653. //
  654. // The context must be non-nil and will be used for request cancellation. If
  655. // the context is nil a panic will occur. In the future the SDK may create
  656. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  657. // for more information on using Contexts.
  658. func (c *S3) DeleteBucketEncryptionWithContext(ctx aws.Context, input *DeleteBucketEncryptionInput, opts ...request.Option) (*DeleteBucketEncryptionOutput, error) {
  659. req, out := c.DeleteBucketEncryptionRequest(input)
  660. req.SetContext(ctx)
  661. req.ApplyOptions(opts...)
  662. return out, req.Send()
  663. }
  664. const opDeleteBucketInventoryConfiguration = "DeleteBucketInventoryConfiguration"
  665. // DeleteBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the
  666. // client's request for the DeleteBucketInventoryConfiguration operation. The "output" return
  667. // value will be populated with the request's response once the request complets
  668. // successfuly.
  669. //
  670. // Use "Send" method on the returned Request to send the API call to the service.
  671. // the "output" return value is not valid until after Send returns without error.
  672. //
  673. // See DeleteBucketInventoryConfiguration for more information on using the DeleteBucketInventoryConfiguration
  674. // API call, and error handling.
  675. //
  676. // This method is useful when you want to inject custom logic or configuration
  677. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  678. //
  679. //
  680. // // Example sending a request using the DeleteBucketInventoryConfigurationRequest method.
  681. // req, resp := client.DeleteBucketInventoryConfigurationRequest(params)
  682. //
  683. // err := req.Send()
  684. // if err == nil { // resp is now filled
  685. // fmt.Println(resp)
  686. // }
  687. //
  688. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfiguration
  689. func (c *S3) DeleteBucketInventoryConfigurationRequest(input *DeleteBucketInventoryConfigurationInput) (req *request.Request, output *DeleteBucketInventoryConfigurationOutput) {
  690. op := &request.Operation{
  691. Name: opDeleteBucketInventoryConfiguration,
  692. HTTPMethod: "DELETE",
  693. HTTPPath: "/{Bucket}?inventory",
  694. }
  695. if input == nil {
  696. input = &DeleteBucketInventoryConfigurationInput{}
  697. }
  698. output = &DeleteBucketInventoryConfigurationOutput{}
  699. req = c.newRequest(op, input, output)
  700. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  701. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  702. return
  703. }
  704. // DeleteBucketInventoryConfiguration API operation for Amazon Simple Storage Service.
  705. //
  706. // Deletes an inventory configuration (identified by the inventory ID) from
  707. // the bucket.
  708. //
  709. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  710. // with awserr.Error's Code and Message methods to get detailed information about
  711. // the error.
  712. //
  713. // See the AWS API reference guide for Amazon Simple Storage Service's
  714. // API operation DeleteBucketInventoryConfiguration for usage and error information.
  715. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfiguration
  716. func (c *S3) DeleteBucketInventoryConfiguration(input *DeleteBucketInventoryConfigurationInput) (*DeleteBucketInventoryConfigurationOutput, error) {
  717. req, out := c.DeleteBucketInventoryConfigurationRequest(input)
  718. return out, req.Send()
  719. }
  720. // DeleteBucketInventoryConfigurationWithContext is the same as DeleteBucketInventoryConfiguration with the addition of
  721. // the ability to pass a context and additional request options.
  722. //
  723. // See DeleteBucketInventoryConfiguration for details on how to use this API operation.
  724. //
  725. // The context must be non-nil and will be used for request cancellation. If
  726. // the context is nil a panic will occur. In the future the SDK may create
  727. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  728. // for more information on using Contexts.
  729. func (c *S3) DeleteBucketInventoryConfigurationWithContext(ctx aws.Context, input *DeleteBucketInventoryConfigurationInput, opts ...request.Option) (*DeleteBucketInventoryConfigurationOutput, error) {
  730. req, out := c.DeleteBucketInventoryConfigurationRequest(input)
  731. req.SetContext(ctx)
  732. req.ApplyOptions(opts...)
  733. return out, req.Send()
  734. }
  735. const opDeleteBucketLifecycle = "DeleteBucketLifecycle"
  736. // DeleteBucketLifecycleRequest generates a "aws/request.Request" representing the
  737. // client's request for the DeleteBucketLifecycle operation. The "output" return
  738. // value will be populated with the request's response once the request complets
  739. // successfuly.
  740. //
  741. // Use "Send" method on the returned Request to send the API call to the service.
  742. // the "output" return value is not valid until after Send returns without error.
  743. //
  744. // See DeleteBucketLifecycle for more information on using the DeleteBucketLifecycle
  745. // API call, and error handling.
  746. //
  747. // This method is useful when you want to inject custom logic or configuration
  748. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  749. //
  750. //
  751. // // Example sending a request using the DeleteBucketLifecycleRequest method.
  752. // req, resp := client.DeleteBucketLifecycleRequest(params)
  753. //
  754. // err := req.Send()
  755. // if err == nil { // resp is now filled
  756. // fmt.Println(resp)
  757. // }
  758. //
  759. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycle
  760. func (c *S3) DeleteBucketLifecycleRequest(input *DeleteBucketLifecycleInput) (req *request.Request, output *DeleteBucketLifecycleOutput) {
  761. op := &request.Operation{
  762. Name: opDeleteBucketLifecycle,
  763. HTTPMethod: "DELETE",
  764. HTTPPath: "/{Bucket}?lifecycle",
  765. }
  766. if input == nil {
  767. input = &DeleteBucketLifecycleInput{}
  768. }
  769. output = &DeleteBucketLifecycleOutput{}
  770. req = c.newRequest(op, input, output)
  771. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  772. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  773. return
  774. }
  775. // DeleteBucketLifecycle API operation for Amazon Simple Storage Service.
  776. //
  777. // Deletes the lifecycle configuration from the bucket.
  778. //
  779. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  780. // with awserr.Error's Code and Message methods to get detailed information about
  781. // the error.
  782. //
  783. // See the AWS API reference guide for Amazon Simple Storage Service's
  784. // API operation DeleteBucketLifecycle for usage and error information.
  785. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycle
  786. func (c *S3) DeleteBucketLifecycle(input *DeleteBucketLifecycleInput) (*DeleteBucketLifecycleOutput, error) {
  787. req, out := c.DeleteBucketLifecycleRequest(input)
  788. return out, req.Send()
  789. }
  790. // DeleteBucketLifecycleWithContext is the same as DeleteBucketLifecycle with the addition of
  791. // the ability to pass a context and additional request options.
  792. //
  793. // See DeleteBucketLifecycle for details on how to use this API operation.
  794. //
  795. // The context must be non-nil and will be used for request cancellation. If
  796. // the context is nil a panic will occur. In the future the SDK may create
  797. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  798. // for more information on using Contexts.
  799. func (c *S3) DeleteBucketLifecycleWithContext(ctx aws.Context, input *DeleteBucketLifecycleInput, opts ...request.Option) (*DeleteBucketLifecycleOutput, error) {
  800. req, out := c.DeleteBucketLifecycleRequest(input)
  801. req.SetContext(ctx)
  802. req.ApplyOptions(opts...)
  803. return out, req.Send()
  804. }
  805. const opDeleteBucketMetricsConfiguration = "DeleteBucketMetricsConfiguration"
  806. // DeleteBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the
  807. // client's request for the DeleteBucketMetricsConfiguration operation. The "output" return
  808. // value will be populated with the request's response once the request complets
  809. // successfuly.
  810. //
  811. // Use "Send" method on the returned Request to send the API call to the service.
  812. // the "output" return value is not valid until after Send returns without error.
  813. //
  814. // See DeleteBucketMetricsConfiguration for more information on using the DeleteBucketMetricsConfiguration
  815. // API call, and error handling.
  816. //
  817. // This method is useful when you want to inject custom logic or configuration
  818. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  819. //
  820. //
  821. // // Example sending a request using the DeleteBucketMetricsConfigurationRequest method.
  822. // req, resp := client.DeleteBucketMetricsConfigurationRequest(params)
  823. //
  824. // err := req.Send()
  825. // if err == nil { // resp is now filled
  826. // fmt.Println(resp)
  827. // }
  828. //
  829. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfiguration
  830. func (c *S3) DeleteBucketMetricsConfigurationRequest(input *DeleteBucketMetricsConfigurationInput) (req *request.Request, output *DeleteBucketMetricsConfigurationOutput) {
  831. op := &request.Operation{
  832. Name: opDeleteBucketMetricsConfiguration,
  833. HTTPMethod: "DELETE",
  834. HTTPPath: "/{Bucket}?metrics",
  835. }
  836. if input == nil {
  837. input = &DeleteBucketMetricsConfigurationInput{}
  838. }
  839. output = &DeleteBucketMetricsConfigurationOutput{}
  840. req = c.newRequest(op, input, output)
  841. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  842. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  843. return
  844. }
  845. // DeleteBucketMetricsConfiguration API operation for Amazon Simple Storage Service.
  846. //
  847. // Deletes a metrics configuration (specified by the metrics configuration ID)
  848. // from the bucket.
  849. //
  850. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  851. // with awserr.Error's Code and Message methods to get detailed information about
  852. // the error.
  853. //
  854. // See the AWS API reference guide for Amazon Simple Storage Service's
  855. // API operation DeleteBucketMetricsConfiguration for usage and error information.
  856. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfiguration
  857. func (c *S3) DeleteBucketMetricsConfiguration(input *DeleteBucketMetricsConfigurationInput) (*DeleteBucketMetricsConfigurationOutput, error) {
  858. req, out := c.DeleteBucketMetricsConfigurationRequest(input)
  859. return out, req.Send()
  860. }
  861. // DeleteBucketMetricsConfigurationWithContext is the same as DeleteBucketMetricsConfiguration with the addition of
  862. // the ability to pass a context and additional request options.
  863. //
  864. // See DeleteBucketMetricsConfiguration for details on how to use this API operation.
  865. //
  866. // The context must be non-nil and will be used for request cancellation. If
  867. // the context is nil a panic will occur. In the future the SDK may create
  868. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  869. // for more information on using Contexts.
  870. func (c *S3) DeleteBucketMetricsConfigurationWithContext(ctx aws.Context, input *DeleteBucketMetricsConfigurationInput, opts ...request.Option) (*DeleteBucketMetricsConfigurationOutput, error) {
  871. req, out := c.DeleteBucketMetricsConfigurationRequest(input)
  872. req.SetContext(ctx)
  873. req.ApplyOptions(opts...)
  874. return out, req.Send()
  875. }
  876. const opDeleteBucketPolicy = "DeleteBucketPolicy"
  877. // DeleteBucketPolicyRequest generates a "aws/request.Request" representing the
  878. // client's request for the DeleteBucketPolicy operation. The "output" return
  879. // value will be populated with the request's response once the request complets
  880. // successfuly.
  881. //
  882. // Use "Send" method on the returned Request to send the API call to the service.
  883. // the "output" return value is not valid until after Send returns without error.
  884. //
  885. // See DeleteBucketPolicy for more information on using the DeleteBucketPolicy
  886. // API call, and error handling.
  887. //
  888. // This method is useful when you want to inject custom logic or configuration
  889. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  890. //
  891. //
  892. // // Example sending a request using the DeleteBucketPolicyRequest method.
  893. // req, resp := client.DeleteBucketPolicyRequest(params)
  894. //
  895. // err := req.Send()
  896. // if err == nil { // resp is now filled
  897. // fmt.Println(resp)
  898. // }
  899. //
  900. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicy
  901. func (c *S3) DeleteBucketPolicyRequest(input *DeleteBucketPolicyInput) (req *request.Request, output *DeleteBucketPolicyOutput) {
  902. op := &request.Operation{
  903. Name: opDeleteBucketPolicy,
  904. HTTPMethod: "DELETE",
  905. HTTPPath: "/{Bucket}?policy",
  906. }
  907. if input == nil {
  908. input = &DeleteBucketPolicyInput{}
  909. }
  910. output = &DeleteBucketPolicyOutput{}
  911. req = c.newRequest(op, input, output)
  912. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  913. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  914. return
  915. }
  916. // DeleteBucketPolicy API operation for Amazon Simple Storage Service.
  917. //
  918. // Deletes the policy from the bucket.
  919. //
  920. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  921. // with awserr.Error's Code and Message methods to get detailed information about
  922. // the error.
  923. //
  924. // See the AWS API reference guide for Amazon Simple Storage Service's
  925. // API operation DeleteBucketPolicy for usage and error information.
  926. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicy
  927. func (c *S3) DeleteBucketPolicy(input *DeleteBucketPolicyInput) (*DeleteBucketPolicyOutput, error) {
  928. req, out := c.DeleteBucketPolicyRequest(input)
  929. return out, req.Send()
  930. }
  931. // DeleteBucketPolicyWithContext is the same as DeleteBucketPolicy with the addition of
  932. // the ability to pass a context and additional request options.
  933. //
  934. // See DeleteBucketPolicy for details on how to use this API operation.
  935. //
  936. // The context must be non-nil and will be used for request cancellation. If
  937. // the context is nil a panic will occur. In the future the SDK may create
  938. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  939. // for more information on using Contexts.
  940. func (c *S3) DeleteBucketPolicyWithContext(ctx aws.Context, input *DeleteBucketPolicyInput, opts ...request.Option) (*DeleteBucketPolicyOutput, error) {
  941. req, out := c.DeleteBucketPolicyRequest(input)
  942. req.SetContext(ctx)
  943. req.ApplyOptions(opts...)
  944. return out, req.Send()
  945. }
  946. const opDeleteBucketReplication = "DeleteBucketReplication"
  947. // DeleteBucketReplicationRequest generates a "aws/request.Request" representing the
  948. // client's request for the DeleteBucketReplication operation. The "output" return
  949. // value will be populated with the request's response once the request complets
  950. // successfuly.
  951. //
  952. // Use "Send" method on the returned Request to send the API call to the service.
  953. // the "output" return value is not valid until after Send returns without error.
  954. //
  955. // See DeleteBucketReplication for more information on using the DeleteBucketReplication
  956. // API call, and error handling.
  957. //
  958. // This method is useful when you want to inject custom logic or configuration
  959. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  960. //
  961. //
  962. // // Example sending a request using the DeleteBucketReplicationRequest method.
  963. // req, resp := client.DeleteBucketReplicationRequest(params)
  964. //
  965. // err := req.Send()
  966. // if err == nil { // resp is now filled
  967. // fmt.Println(resp)
  968. // }
  969. //
  970. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplication
  971. func (c *S3) DeleteBucketReplicationRequest(input *DeleteBucketReplicationInput) (req *request.Request, output *DeleteBucketReplicationOutput) {
  972. op := &request.Operation{
  973. Name: opDeleteBucketReplication,
  974. HTTPMethod: "DELETE",
  975. HTTPPath: "/{Bucket}?replication",
  976. }
  977. if input == nil {
  978. input = &DeleteBucketReplicationInput{}
  979. }
  980. output = &DeleteBucketReplicationOutput{}
  981. req = c.newRequest(op, input, output)
  982. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  983. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  984. return
  985. }
  986. // DeleteBucketReplication API operation for Amazon Simple Storage Service.
  987. //
  988. // Deletes the replication configuration from the bucket.
  989. //
  990. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  991. // with awserr.Error's Code and Message methods to get detailed information about
  992. // the error.
  993. //
  994. // See the AWS API reference guide for Amazon Simple Storage Service's
  995. // API operation DeleteBucketReplication for usage and error information.
  996. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplication
  997. func (c *S3) DeleteBucketReplication(input *DeleteBucketReplicationInput) (*DeleteBucketReplicationOutput, error) {
  998. req, out := c.DeleteBucketReplicationRequest(input)
  999. return out, req.Send()
  1000. }
  1001. // DeleteBucketReplicationWithContext is the same as DeleteBucketReplication with the addition of
  1002. // the ability to pass a context and additional request options.
  1003. //
  1004. // See DeleteBucketReplication for details on how to use this API operation.
  1005. //
  1006. // The context must be non-nil and will be used for request cancellation. If
  1007. // the context is nil a panic will occur. In the future the SDK may create
  1008. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1009. // for more information on using Contexts.
  1010. func (c *S3) DeleteBucketReplicationWithContext(ctx aws.Context, input *DeleteBucketReplicationInput, opts ...request.Option) (*DeleteBucketReplicationOutput, error) {
  1011. req, out := c.DeleteBucketReplicationRequest(input)
  1012. req.SetContext(ctx)
  1013. req.ApplyOptions(opts...)
  1014. return out, req.Send()
  1015. }
  1016. const opDeleteBucketTagging = "DeleteBucketTagging"
  1017. // DeleteBucketTaggingRequest generates a "aws/request.Request" representing the
  1018. // client's request for the DeleteBucketTagging operation. The "output" return
  1019. // value will be populated with the request's response once the request complets
  1020. // successfuly.
  1021. //
  1022. // Use "Send" method on the returned Request to send the API call to the service.
  1023. // the "output" return value is not valid until after Send returns without error.
  1024. //
  1025. // See DeleteBucketTagging for more information on using the DeleteBucketTagging
  1026. // API call, and error handling.
  1027. //
  1028. // This method is useful when you want to inject custom logic or configuration
  1029. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1030. //
  1031. //
  1032. // // Example sending a request using the DeleteBucketTaggingRequest method.
  1033. // req, resp := client.DeleteBucketTaggingRequest(params)
  1034. //
  1035. // err := req.Send()
  1036. // if err == nil { // resp is now filled
  1037. // fmt.Println(resp)
  1038. // }
  1039. //
  1040. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTagging
  1041. func (c *S3) DeleteBucketTaggingRequest(input *DeleteBucketTaggingInput) (req *request.Request, output *DeleteBucketTaggingOutput) {
  1042. op := &request.Operation{
  1043. Name: opDeleteBucketTagging,
  1044. HTTPMethod: "DELETE",
  1045. HTTPPath: "/{Bucket}?tagging",
  1046. }
  1047. if input == nil {
  1048. input = &DeleteBucketTaggingInput{}
  1049. }
  1050. output = &DeleteBucketTaggingOutput{}
  1051. req = c.newRequest(op, input, output)
  1052. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  1053. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  1054. return
  1055. }
  1056. // DeleteBucketTagging API operation for Amazon Simple Storage Service.
  1057. //
  1058. // Deletes the tags from the bucket.
  1059. //
  1060. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1061. // with awserr.Error's Code and Message methods to get detailed information about
  1062. // the error.
  1063. //
  1064. // See the AWS API reference guide for Amazon Simple Storage Service's
  1065. // API operation DeleteBucketTagging for usage and error information.
  1066. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTagging
  1067. func (c *S3) DeleteBucketTagging(input *DeleteBucketTaggingInput) (*DeleteBucketTaggingOutput, error) {
  1068. req, out := c.DeleteBucketTaggingRequest(input)
  1069. return out, req.Send()
  1070. }
  1071. // DeleteBucketTaggingWithContext is the same as DeleteBucketTagging with the addition of
  1072. // the ability to pass a context and additional request options.
  1073. //
  1074. // See DeleteBucketTagging for details on how to use this API operation.
  1075. //
  1076. // The context must be non-nil and will be used for request cancellation. If
  1077. // the context is nil a panic will occur. In the future the SDK may create
  1078. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1079. // for more information on using Contexts.
  1080. func (c *S3) DeleteBucketTaggingWithContext(ctx aws.Context, input *DeleteBucketTaggingInput, opts ...request.Option) (*DeleteBucketTaggingOutput, error) {
  1081. req, out := c.DeleteBucketTaggingRequest(input)
  1082. req.SetContext(ctx)
  1083. req.ApplyOptions(opts...)
  1084. return out, req.Send()
  1085. }
  1086. const opDeleteBucketWebsite = "DeleteBucketWebsite"
  1087. // DeleteBucketWebsiteRequest generates a "aws/request.Request" representing the
  1088. // client's request for the DeleteBucketWebsite operation. The "output" return
  1089. // value will be populated with the request's response once the request complets
  1090. // successfuly.
  1091. //
  1092. // Use "Send" method on the returned Request to send the API call to the service.
  1093. // the "output" return value is not valid until after Send returns without error.
  1094. //
  1095. // See DeleteBucketWebsite for more information on using the DeleteBucketWebsite
  1096. // API call, and error handling.
  1097. //
  1098. // This method is useful when you want to inject custom logic or configuration
  1099. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1100. //
  1101. //
  1102. // // Example sending a request using the DeleteBucketWebsiteRequest method.
  1103. // req, resp := client.DeleteBucketWebsiteRequest(params)
  1104. //
  1105. // err := req.Send()
  1106. // if err == nil { // resp is now filled
  1107. // fmt.Println(resp)
  1108. // }
  1109. //
  1110. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsite
  1111. func (c *S3) DeleteBucketWebsiteRequest(input *DeleteBucketWebsiteInput) (req *request.Request, output *DeleteBucketWebsiteOutput) {
  1112. op := &request.Operation{
  1113. Name: opDeleteBucketWebsite,
  1114. HTTPMethod: "DELETE",
  1115. HTTPPath: "/{Bucket}?website",
  1116. }
  1117. if input == nil {
  1118. input = &DeleteBucketWebsiteInput{}
  1119. }
  1120. output = &DeleteBucketWebsiteOutput{}
  1121. req = c.newRequest(op, input, output)
  1122. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  1123. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  1124. return
  1125. }
  1126. // DeleteBucketWebsite API operation for Amazon Simple Storage Service.
  1127. //
  1128. // This operation removes the website configuration from the bucket.
  1129. //
  1130. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1131. // with awserr.Error's Code and Message methods to get detailed information about
  1132. // the error.
  1133. //
  1134. // See the AWS API reference guide for Amazon Simple Storage Service's
  1135. // API operation DeleteBucketWebsite for usage and error information.
  1136. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsite
  1137. func (c *S3) DeleteBucketWebsite(input *DeleteBucketWebsiteInput) (*DeleteBucketWebsiteOutput, error) {
  1138. req, out := c.DeleteBucketWebsiteRequest(input)
  1139. return out, req.Send()
  1140. }
  1141. // DeleteBucketWebsiteWithContext is the same as DeleteBucketWebsite with the addition of
  1142. // the ability to pass a context and additional request options.
  1143. //
  1144. // See DeleteBucketWebsite for details on how to use this API operation.
  1145. //
  1146. // The context must be non-nil and will be used for request cancellation. If
  1147. // the context is nil a panic will occur. In the future the SDK may create
  1148. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1149. // for more information on using Contexts.
  1150. func (c *S3) DeleteBucketWebsiteWithContext(ctx aws.Context, input *DeleteBucketWebsiteInput, opts ...request.Option) (*DeleteBucketWebsiteOutput, error) {
  1151. req, out := c.DeleteBucketWebsiteRequest(input)
  1152. req.SetContext(ctx)
  1153. req.ApplyOptions(opts...)
  1154. return out, req.Send()
  1155. }
  1156. const opDeleteObject = "DeleteObject"
  1157. // DeleteObjectRequest generates a "aws/request.Request" representing the
  1158. // client's request for the DeleteObject operation. The "output" return
  1159. // value will be populated with the request's response once the request complets
  1160. // successfuly.
  1161. //
  1162. // Use "Send" method on the returned Request to send the API call to the service.
  1163. // the "output" return value is not valid until after Send returns without error.
  1164. //
  1165. // See DeleteObject for more information on using the DeleteObject
  1166. // API call, and error handling.
  1167. //
  1168. // This method is useful when you want to inject custom logic or configuration
  1169. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1170. //
  1171. //
  1172. // // Example sending a request using the DeleteObjectRequest method.
  1173. // req, resp := client.DeleteObjectRequest(params)
  1174. //
  1175. // err := req.Send()
  1176. // if err == nil { // resp is now filled
  1177. // fmt.Println(resp)
  1178. // }
  1179. //
  1180. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObject
  1181. func (c *S3) DeleteObjectRequest(input *DeleteObjectInput) (req *request.Request, output *DeleteObjectOutput) {
  1182. op := &request.Operation{
  1183. Name: opDeleteObject,
  1184. HTTPMethod: "DELETE",
  1185. HTTPPath: "/{Bucket}/{Key+}",
  1186. }
  1187. if input == nil {
  1188. input = &DeleteObjectInput{}
  1189. }
  1190. output = &DeleteObjectOutput{}
  1191. req = c.newRequest(op, input, output)
  1192. return
  1193. }
  1194. // DeleteObject API operation for Amazon Simple Storage Service.
  1195. //
  1196. // Removes the null version (if there is one) of an object and inserts a delete
  1197. // marker, which becomes the latest version of the object. If there isn't a
  1198. // null version, Amazon S3 does not remove any objects.
  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 Amazon Simple Storage Service's
  1205. // API operation DeleteObject for usage and error information.
  1206. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObject
  1207. func (c *S3) DeleteObject(input *DeleteObjectInput) (*DeleteObjectOutput, error) {
  1208. req, out := c.DeleteObjectRequest(input)
  1209. return out, req.Send()
  1210. }
  1211. // DeleteObjectWithContext is the same as DeleteObject with the addition of
  1212. // the ability to pass a context and additional request options.
  1213. //
  1214. // See DeleteObject for details on how to use this API operation.
  1215. //
  1216. // The context must be non-nil and will be used for request cancellation. If
  1217. // the context is nil a panic will occur. In the future the SDK may create
  1218. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1219. // for more information on using Contexts.
  1220. func (c *S3) DeleteObjectWithContext(ctx aws.Context, input *DeleteObjectInput, opts ...request.Option) (*DeleteObjectOutput, error) {
  1221. req, out := c.DeleteObjectRequest(input)
  1222. req.SetContext(ctx)
  1223. req.ApplyOptions(opts...)
  1224. return out, req.Send()
  1225. }
  1226. const opDeleteObjectTagging = "DeleteObjectTagging"
  1227. // DeleteObjectTaggingRequest generates a "aws/request.Request" representing the
  1228. // client's request for the DeleteObjectTagging operation. The "output" return
  1229. // value will be populated with the request's response once the request complets
  1230. // successfuly.
  1231. //
  1232. // Use "Send" method on the returned Request to send the API call to the service.
  1233. // the "output" return value is not valid until after Send returns without error.
  1234. //
  1235. // See DeleteObjectTagging for more information on using the DeleteObjectTagging
  1236. // API call, and error handling.
  1237. //
  1238. // This method is useful when you want to inject custom logic or configuration
  1239. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1240. //
  1241. //
  1242. // // Example sending a request using the DeleteObjectTaggingRequest method.
  1243. // req, resp := client.DeleteObjectTaggingRequest(params)
  1244. //
  1245. // err := req.Send()
  1246. // if err == nil { // resp is now filled
  1247. // fmt.Println(resp)
  1248. // }
  1249. //
  1250. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTagging
  1251. func (c *S3) DeleteObjectTaggingRequest(input *DeleteObjectTaggingInput) (req *request.Request, output *DeleteObjectTaggingOutput) {
  1252. op := &request.Operation{
  1253. Name: opDeleteObjectTagging,
  1254. HTTPMethod: "DELETE",
  1255. HTTPPath: "/{Bucket}/{Key+}?tagging",
  1256. }
  1257. if input == nil {
  1258. input = &DeleteObjectTaggingInput{}
  1259. }
  1260. output = &DeleteObjectTaggingOutput{}
  1261. req = c.newRequest(op, input, output)
  1262. return
  1263. }
  1264. // DeleteObjectTagging API operation for Amazon Simple Storage Service.
  1265. //
  1266. // Removes the tag-set from an existing object.
  1267. //
  1268. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1269. // with awserr.Error's Code and Message methods to get detailed information about
  1270. // the error.
  1271. //
  1272. // See the AWS API reference guide for Amazon Simple Storage Service's
  1273. // API operation DeleteObjectTagging for usage and error information.
  1274. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTagging
  1275. func (c *S3) DeleteObjectTagging(input *DeleteObjectTaggingInput) (*DeleteObjectTaggingOutput, error) {
  1276. req, out := c.DeleteObjectTaggingRequest(input)
  1277. return out, req.Send()
  1278. }
  1279. // DeleteObjectTaggingWithContext is the same as DeleteObjectTagging with the addition of
  1280. // the ability to pass a context and additional request options.
  1281. //
  1282. // See DeleteObjectTagging for details on how to use this API operation.
  1283. //
  1284. // The context must be non-nil and will be used for request cancellation. If
  1285. // the context is nil a panic will occur. In the future the SDK may create
  1286. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1287. // for more information on using Contexts.
  1288. func (c *S3) DeleteObjectTaggingWithContext(ctx aws.Context, input *DeleteObjectTaggingInput, opts ...request.Option) (*DeleteObjectTaggingOutput, error) {
  1289. req, out := c.DeleteObjectTaggingRequest(input)
  1290. req.SetContext(ctx)
  1291. req.ApplyOptions(opts...)
  1292. return out, req.Send()
  1293. }
  1294. const opDeleteObjects = "DeleteObjects"
  1295. // DeleteObjectsRequest generates a "aws/request.Request" representing the
  1296. // client's request for the DeleteObjects operation. The "output" return
  1297. // value will be populated with the request's response once the request complets
  1298. // successfuly.
  1299. //
  1300. // Use "Send" method on the returned Request to send the API call to the service.
  1301. // the "output" return value is not valid until after Send returns without error.
  1302. //
  1303. // See DeleteObjects for more information on using the DeleteObjects
  1304. // API call, and error handling.
  1305. //
  1306. // This method is useful when you want to inject custom logic or configuration
  1307. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1308. //
  1309. //
  1310. // // Example sending a request using the DeleteObjectsRequest method.
  1311. // req, resp := client.DeleteObjectsRequest(params)
  1312. //
  1313. // err := req.Send()
  1314. // if err == nil { // resp is now filled
  1315. // fmt.Println(resp)
  1316. // }
  1317. //
  1318. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjects
  1319. func (c *S3) DeleteObjectsRequest(input *DeleteObjectsInput) (req *request.Request, output *DeleteObjectsOutput) {
  1320. op := &request.Operation{
  1321. Name: opDeleteObjects,
  1322. HTTPMethod: "POST",
  1323. HTTPPath: "/{Bucket}?delete",
  1324. }
  1325. if input == nil {
  1326. input = &DeleteObjectsInput{}
  1327. }
  1328. output = &DeleteObjectsOutput{}
  1329. req = c.newRequest(op, input, output)
  1330. return
  1331. }
  1332. // DeleteObjects API operation for Amazon Simple Storage Service.
  1333. //
  1334. // This operation enables you to delete multiple objects from a bucket using
  1335. // a single HTTP request. You may specify up to 1000 keys.
  1336. //
  1337. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1338. // with awserr.Error's Code and Message methods to get detailed information about
  1339. // the error.
  1340. //
  1341. // See the AWS API reference guide for Amazon Simple Storage Service's
  1342. // API operation DeleteObjects for usage and error information.
  1343. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjects
  1344. func (c *S3) DeleteObjects(input *DeleteObjectsInput) (*DeleteObjectsOutput, error) {
  1345. req, out := c.DeleteObjectsRequest(input)
  1346. return out, req.Send()
  1347. }
  1348. // DeleteObjectsWithContext is the same as DeleteObjects with the addition of
  1349. // the ability to pass a context and additional request options.
  1350. //
  1351. // See DeleteObjects for details on how to use this API operation.
  1352. //
  1353. // The context must be non-nil and will be used for request cancellation. If
  1354. // the context is nil a panic will occur. In the future the SDK may create
  1355. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1356. // for more information on using Contexts.
  1357. func (c *S3) DeleteObjectsWithContext(ctx aws.Context, input *DeleteObjectsInput, opts ...request.Option) (*DeleteObjectsOutput, error) {
  1358. req, out := c.DeleteObjectsRequest(input)
  1359. req.SetContext(ctx)
  1360. req.ApplyOptions(opts...)
  1361. return out, req.Send()
  1362. }
  1363. const opGetBucketAccelerateConfiguration = "GetBucketAccelerateConfiguration"
  1364. // GetBucketAccelerateConfigurationRequest generates a "aws/request.Request" representing the
  1365. // client's request for the GetBucketAccelerateConfiguration operation. The "output" return
  1366. // value will be populated with the request's response once the request complets
  1367. // successfuly.
  1368. //
  1369. // Use "Send" method on the returned Request to send the API call to the service.
  1370. // the "output" return value is not valid until after Send returns without error.
  1371. //
  1372. // See GetBucketAccelerateConfiguration for more information on using the GetBucketAccelerateConfiguration
  1373. // API call, and error handling.
  1374. //
  1375. // This method is useful when you want to inject custom logic or configuration
  1376. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1377. //
  1378. //
  1379. // // Example sending a request using the GetBucketAccelerateConfigurationRequest method.
  1380. // req, resp := client.GetBucketAccelerateConfigurationRequest(params)
  1381. //
  1382. // err := req.Send()
  1383. // if err == nil { // resp is now filled
  1384. // fmt.Println(resp)
  1385. // }
  1386. //
  1387. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfiguration
  1388. func (c *S3) GetBucketAccelerateConfigurationRequest(input *GetBucketAccelerateConfigurationInput) (req *request.Request, output *GetBucketAccelerateConfigurationOutput) {
  1389. op := &request.Operation{
  1390. Name: opGetBucketAccelerateConfiguration,
  1391. HTTPMethod: "GET",
  1392. HTTPPath: "/{Bucket}?accelerate",
  1393. }
  1394. if input == nil {
  1395. input = &GetBucketAccelerateConfigurationInput{}
  1396. }
  1397. output = &GetBucketAccelerateConfigurationOutput{}
  1398. req = c.newRequest(op, input, output)
  1399. return
  1400. }
  1401. // GetBucketAccelerateConfiguration API operation for Amazon Simple Storage Service.
  1402. //
  1403. // Returns the accelerate configuration of a bucket.
  1404. //
  1405. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1406. // with awserr.Error's Code and Message methods to get detailed information about
  1407. // the error.
  1408. //
  1409. // See the AWS API reference guide for Amazon Simple Storage Service's
  1410. // API operation GetBucketAccelerateConfiguration for usage and error information.
  1411. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfiguration
  1412. func (c *S3) GetBucketAccelerateConfiguration(input *GetBucketAccelerateConfigurationInput) (*GetBucketAccelerateConfigurationOutput, error) {
  1413. req, out := c.GetBucketAccelerateConfigurationRequest(input)
  1414. return out, req.Send()
  1415. }
  1416. // GetBucketAccelerateConfigurationWithContext is the same as GetBucketAccelerateConfiguration with the addition of
  1417. // the ability to pass a context and additional request options.
  1418. //
  1419. // See GetBucketAccelerateConfiguration for details on how to use this API operation.
  1420. //
  1421. // The context must be non-nil and will be used for request cancellation. If
  1422. // the context is nil a panic will occur. In the future the SDK may create
  1423. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1424. // for more information on using Contexts.
  1425. func (c *S3) GetBucketAccelerateConfigurationWithContext(ctx aws.Context, input *GetBucketAccelerateConfigurationInput, opts ...request.Option) (*GetBucketAccelerateConfigurationOutput, error) {
  1426. req, out := c.GetBucketAccelerateConfigurationRequest(input)
  1427. req.SetContext(ctx)
  1428. req.ApplyOptions(opts...)
  1429. return out, req.Send()
  1430. }
  1431. const opGetBucketAcl = "GetBucketAcl"
  1432. // GetBucketAclRequest generates a "aws/request.Request" representing the
  1433. // client's request for the GetBucketAcl operation. The "output" return
  1434. // value will be populated with the request's response once the request complets
  1435. // successfuly.
  1436. //
  1437. // Use "Send" method on the returned Request to send the API call to the service.
  1438. // the "output" return value is not valid until after Send returns without error.
  1439. //
  1440. // See GetBucketAcl for more information on using the GetBucketAcl
  1441. // API call, and error handling.
  1442. //
  1443. // This method is useful when you want to inject custom logic or configuration
  1444. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1445. //
  1446. //
  1447. // // Example sending a request using the GetBucketAclRequest method.
  1448. // req, resp := client.GetBucketAclRequest(params)
  1449. //
  1450. // err := req.Send()
  1451. // if err == nil { // resp is now filled
  1452. // fmt.Println(resp)
  1453. // }
  1454. //
  1455. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAcl
  1456. func (c *S3) GetBucketAclRequest(input *GetBucketAclInput) (req *request.Request, output *GetBucketAclOutput) {
  1457. op := &request.Operation{
  1458. Name: opGetBucketAcl,
  1459. HTTPMethod: "GET",
  1460. HTTPPath: "/{Bucket}?acl",
  1461. }
  1462. if input == nil {
  1463. input = &GetBucketAclInput{}
  1464. }
  1465. output = &GetBucketAclOutput{}
  1466. req = c.newRequest(op, input, output)
  1467. return
  1468. }
  1469. // GetBucketAcl API operation for Amazon Simple Storage Service.
  1470. //
  1471. // Gets the access control policy for the bucket.
  1472. //
  1473. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1474. // with awserr.Error's Code and Message methods to get detailed information about
  1475. // the error.
  1476. //
  1477. // See the AWS API reference guide for Amazon Simple Storage Service's
  1478. // API operation GetBucketAcl for usage and error information.
  1479. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAcl
  1480. func (c *S3) GetBucketAcl(input *GetBucketAclInput) (*GetBucketAclOutput, error) {
  1481. req, out := c.GetBucketAclRequest(input)
  1482. return out, req.Send()
  1483. }
  1484. // GetBucketAclWithContext is the same as GetBucketAcl with the addition of
  1485. // the ability to pass a context and additional request options.
  1486. //
  1487. // See GetBucketAcl for details on how to use this API operation.
  1488. //
  1489. // The context must be non-nil and will be used for request cancellation. If
  1490. // the context is nil a panic will occur. In the future the SDK may create
  1491. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1492. // for more information on using Contexts.
  1493. func (c *S3) GetBucketAclWithContext(ctx aws.Context, input *GetBucketAclInput, opts ...request.Option) (*GetBucketAclOutput, error) {
  1494. req, out := c.GetBucketAclRequest(input)
  1495. req.SetContext(ctx)
  1496. req.ApplyOptions(opts...)
  1497. return out, req.Send()
  1498. }
  1499. const opGetBucketAnalyticsConfiguration = "GetBucketAnalyticsConfiguration"
  1500. // GetBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the
  1501. // client's request for the GetBucketAnalyticsConfiguration operation. The "output" return
  1502. // value will be populated with the request's response once the request complets
  1503. // successfuly.
  1504. //
  1505. // Use "Send" method on the returned Request to send the API call to the service.
  1506. // the "output" return value is not valid until after Send returns without error.
  1507. //
  1508. // See GetBucketAnalyticsConfiguration for more information on using the GetBucketAnalyticsConfiguration
  1509. // API call, and error handling.
  1510. //
  1511. // This method is useful when you want to inject custom logic or configuration
  1512. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1513. //
  1514. //
  1515. // // Example sending a request using the GetBucketAnalyticsConfigurationRequest method.
  1516. // req, resp := client.GetBucketAnalyticsConfigurationRequest(params)
  1517. //
  1518. // err := req.Send()
  1519. // if err == nil { // resp is now filled
  1520. // fmt.Println(resp)
  1521. // }
  1522. //
  1523. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfiguration
  1524. func (c *S3) GetBucketAnalyticsConfigurationRequest(input *GetBucketAnalyticsConfigurationInput) (req *request.Request, output *GetBucketAnalyticsConfigurationOutput) {
  1525. op := &request.Operation{
  1526. Name: opGetBucketAnalyticsConfiguration,
  1527. HTTPMethod: "GET",
  1528. HTTPPath: "/{Bucket}?analytics",
  1529. }
  1530. if input == nil {
  1531. input = &GetBucketAnalyticsConfigurationInput{}
  1532. }
  1533. output = &GetBucketAnalyticsConfigurationOutput{}
  1534. req = c.newRequest(op, input, output)
  1535. return
  1536. }
  1537. // GetBucketAnalyticsConfiguration API operation for Amazon Simple Storage Service.
  1538. //
  1539. // Gets an analytics configuration for the bucket (specified by the analytics
  1540. // configuration ID).
  1541. //
  1542. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1543. // with awserr.Error's Code and Message methods to get detailed information about
  1544. // the error.
  1545. //
  1546. // See the AWS API reference guide for Amazon Simple Storage Service's
  1547. // API operation GetBucketAnalyticsConfiguration for usage and error information.
  1548. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfiguration
  1549. func (c *S3) GetBucketAnalyticsConfiguration(input *GetBucketAnalyticsConfigurationInput) (*GetBucketAnalyticsConfigurationOutput, error) {
  1550. req, out := c.GetBucketAnalyticsConfigurationRequest(input)
  1551. return out, req.Send()
  1552. }
  1553. // GetBucketAnalyticsConfigurationWithContext is the same as GetBucketAnalyticsConfiguration with the addition of
  1554. // the ability to pass a context and additional request options.
  1555. //
  1556. // See GetBucketAnalyticsConfiguration for details on how to use this API operation.
  1557. //
  1558. // The context must be non-nil and will be used for request cancellation. If
  1559. // the context is nil a panic will occur. In the future the SDK may create
  1560. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1561. // for more information on using Contexts.
  1562. func (c *S3) GetBucketAnalyticsConfigurationWithContext(ctx aws.Context, input *GetBucketAnalyticsConfigurationInput, opts ...request.Option) (*GetBucketAnalyticsConfigurationOutput, error) {
  1563. req, out := c.GetBucketAnalyticsConfigurationRequest(input)
  1564. req.SetContext(ctx)
  1565. req.ApplyOptions(opts...)
  1566. return out, req.Send()
  1567. }
  1568. const opGetBucketCors = "GetBucketCors"
  1569. // GetBucketCorsRequest generates a "aws/request.Request" representing the
  1570. // client's request for the GetBucketCors operation. The "output" return
  1571. // value will be populated with the request's response once the request complets
  1572. // successfuly.
  1573. //
  1574. // Use "Send" method on the returned Request to send the API call to the service.
  1575. // the "output" return value is not valid until after Send returns without error.
  1576. //
  1577. // See GetBucketCors for more information on using the GetBucketCors
  1578. // API call, and error handling.
  1579. //
  1580. // This method is useful when you want to inject custom logic or configuration
  1581. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1582. //
  1583. //
  1584. // // Example sending a request using the GetBucketCorsRequest method.
  1585. // req, resp := client.GetBucketCorsRequest(params)
  1586. //
  1587. // err := req.Send()
  1588. // if err == nil { // resp is now filled
  1589. // fmt.Println(resp)
  1590. // }
  1591. //
  1592. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCors
  1593. func (c *S3) GetBucketCorsRequest(input *GetBucketCorsInput) (req *request.Request, output *GetBucketCorsOutput) {
  1594. op := &request.Operation{
  1595. Name: opGetBucketCors,
  1596. HTTPMethod: "GET",
  1597. HTTPPath: "/{Bucket}?cors",
  1598. }
  1599. if input == nil {
  1600. input = &GetBucketCorsInput{}
  1601. }
  1602. output = &GetBucketCorsOutput{}
  1603. req = c.newRequest(op, input, output)
  1604. return
  1605. }
  1606. // GetBucketCors API operation for Amazon Simple Storage Service.
  1607. //
  1608. // Returns the cors configuration for the bucket.
  1609. //
  1610. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1611. // with awserr.Error's Code and Message methods to get detailed information about
  1612. // the error.
  1613. //
  1614. // See the AWS API reference guide for Amazon Simple Storage Service's
  1615. // API operation GetBucketCors for usage and error information.
  1616. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCors
  1617. func (c *S3) GetBucketCors(input *GetBucketCorsInput) (*GetBucketCorsOutput, error) {
  1618. req, out := c.GetBucketCorsRequest(input)
  1619. return out, req.Send()
  1620. }
  1621. // GetBucketCorsWithContext is the same as GetBucketCors with the addition of
  1622. // the ability to pass a context and additional request options.
  1623. //
  1624. // See GetBucketCors for details on how to use this API operation.
  1625. //
  1626. // The context must be non-nil and will be used for request cancellation. If
  1627. // the context is nil a panic will occur. In the future the SDK may create
  1628. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1629. // for more information on using Contexts.
  1630. func (c *S3) GetBucketCorsWithContext(ctx aws.Context, input *GetBucketCorsInput, opts ...request.Option) (*GetBucketCorsOutput, error) {
  1631. req, out := c.GetBucketCorsRequest(input)
  1632. req.SetContext(ctx)
  1633. req.ApplyOptions(opts...)
  1634. return out, req.Send()
  1635. }
  1636. const opGetBucketEncryption = "GetBucketEncryption"
  1637. // GetBucketEncryptionRequest generates a "aws/request.Request" representing the
  1638. // client's request for the GetBucketEncryption operation. The "output" return
  1639. // value will be populated with the request's response once the request complets
  1640. // successfuly.
  1641. //
  1642. // Use "Send" method on the returned Request to send the API call to the service.
  1643. // the "output" return value is not valid until after Send returns without error.
  1644. //
  1645. // See GetBucketEncryption for more information on using the GetBucketEncryption
  1646. // API call, and error handling.
  1647. //
  1648. // This method is useful when you want to inject custom logic or configuration
  1649. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1650. //
  1651. //
  1652. // // Example sending a request using the GetBucketEncryptionRequest method.
  1653. // req, resp := client.GetBucketEncryptionRequest(params)
  1654. //
  1655. // err := req.Send()
  1656. // if err == nil { // resp is now filled
  1657. // fmt.Println(resp)
  1658. // }
  1659. //
  1660. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryption
  1661. func (c *S3) GetBucketEncryptionRequest(input *GetBucketEncryptionInput) (req *request.Request, output *GetBucketEncryptionOutput) {
  1662. op := &request.Operation{
  1663. Name: opGetBucketEncryption,
  1664. HTTPMethod: "GET",
  1665. HTTPPath: "/{Bucket}?encryption",
  1666. }
  1667. if input == nil {
  1668. input = &GetBucketEncryptionInput{}
  1669. }
  1670. output = &GetBucketEncryptionOutput{}
  1671. req = c.newRequest(op, input, output)
  1672. return
  1673. }
  1674. // GetBucketEncryption API operation for Amazon Simple Storage Service.
  1675. //
  1676. // Returns the server-side encryption configuration of a bucket.
  1677. //
  1678. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1679. // with awserr.Error's Code and Message methods to get detailed information about
  1680. // the error.
  1681. //
  1682. // See the AWS API reference guide for Amazon Simple Storage Service's
  1683. // API operation GetBucketEncryption for usage and error information.
  1684. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryption
  1685. func (c *S3) GetBucketEncryption(input *GetBucketEncryptionInput) (*GetBucketEncryptionOutput, error) {
  1686. req, out := c.GetBucketEncryptionRequest(input)
  1687. return out, req.Send()
  1688. }
  1689. // GetBucketEncryptionWithContext is the same as GetBucketEncryption with the addition of
  1690. // the ability to pass a context and additional request options.
  1691. //
  1692. // See GetBucketEncryption for details on how to use this API operation.
  1693. //
  1694. // The context must be non-nil and will be used for request cancellation. If
  1695. // the context is nil a panic will occur. In the future the SDK may create
  1696. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1697. // for more information on using Contexts.
  1698. func (c *S3) GetBucketEncryptionWithContext(ctx aws.Context, input *GetBucketEncryptionInput, opts ...request.Option) (*GetBucketEncryptionOutput, error) {
  1699. req, out := c.GetBucketEncryptionRequest(input)
  1700. req.SetContext(ctx)
  1701. req.ApplyOptions(opts...)
  1702. return out, req.Send()
  1703. }
  1704. const opGetBucketInventoryConfiguration = "GetBucketInventoryConfiguration"
  1705. // GetBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the
  1706. // client's request for the GetBucketInventoryConfiguration operation. The "output" return
  1707. // value will be populated with the request's response once the request complets
  1708. // successfuly.
  1709. //
  1710. // Use "Send" method on the returned Request to send the API call to the service.
  1711. // the "output" return value is not valid until after Send returns without error.
  1712. //
  1713. // See GetBucketInventoryConfiguration for more information on using the GetBucketInventoryConfiguration
  1714. // API call, and error handling.
  1715. //
  1716. // This method is useful when you want to inject custom logic or configuration
  1717. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1718. //
  1719. //
  1720. // // Example sending a request using the GetBucketInventoryConfigurationRequest method.
  1721. // req, resp := client.GetBucketInventoryConfigurationRequest(params)
  1722. //
  1723. // err := req.Send()
  1724. // if err == nil { // resp is now filled
  1725. // fmt.Println(resp)
  1726. // }
  1727. //
  1728. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfiguration
  1729. func (c *S3) GetBucketInventoryConfigurationRequest(input *GetBucketInventoryConfigurationInput) (req *request.Request, output *GetBucketInventoryConfigurationOutput) {
  1730. op := &request.Operation{
  1731. Name: opGetBucketInventoryConfiguration,
  1732. HTTPMethod: "GET",
  1733. HTTPPath: "/{Bucket}?inventory",
  1734. }
  1735. if input == nil {
  1736. input = &GetBucketInventoryConfigurationInput{}
  1737. }
  1738. output = &GetBucketInventoryConfigurationOutput{}
  1739. req = c.newRequest(op, input, output)
  1740. return
  1741. }
  1742. // GetBucketInventoryConfiguration API operation for Amazon Simple Storage Service.
  1743. //
  1744. // Returns an inventory configuration (identified by the inventory ID) from
  1745. // the bucket.
  1746. //
  1747. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1748. // with awserr.Error's Code and Message methods to get detailed information about
  1749. // the error.
  1750. //
  1751. // See the AWS API reference guide for Amazon Simple Storage Service's
  1752. // API operation GetBucketInventoryConfiguration for usage and error information.
  1753. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfiguration
  1754. func (c *S3) GetBucketInventoryConfiguration(input *GetBucketInventoryConfigurationInput) (*GetBucketInventoryConfigurationOutput, error) {
  1755. req, out := c.GetBucketInventoryConfigurationRequest(input)
  1756. return out, req.Send()
  1757. }
  1758. // GetBucketInventoryConfigurationWithContext is the same as GetBucketInventoryConfiguration with the addition of
  1759. // the ability to pass a context and additional request options.
  1760. //
  1761. // See GetBucketInventoryConfiguration for details on how to use this API operation.
  1762. //
  1763. // The context must be non-nil and will be used for request cancellation. If
  1764. // the context is nil a panic will occur. In the future the SDK may create
  1765. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1766. // for more information on using Contexts.
  1767. func (c *S3) GetBucketInventoryConfigurationWithContext(ctx aws.Context, input *GetBucketInventoryConfigurationInput, opts ...request.Option) (*GetBucketInventoryConfigurationOutput, error) {
  1768. req, out := c.GetBucketInventoryConfigurationRequest(input)
  1769. req.SetContext(ctx)
  1770. req.ApplyOptions(opts...)
  1771. return out, req.Send()
  1772. }
  1773. const opGetBucketLifecycle = "GetBucketLifecycle"
  1774. // GetBucketLifecycleRequest generates a "aws/request.Request" representing the
  1775. // client's request for the GetBucketLifecycle operation. The "output" return
  1776. // value will be populated with the request's response once the request complets
  1777. // successfuly.
  1778. //
  1779. // Use "Send" method on the returned Request to send the API call to the service.
  1780. // the "output" return value is not valid until after Send returns without error.
  1781. //
  1782. // See GetBucketLifecycle for more information on using the GetBucketLifecycle
  1783. // API call, and error handling.
  1784. //
  1785. // This method is useful when you want to inject custom logic or configuration
  1786. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1787. //
  1788. //
  1789. // // Example sending a request using the GetBucketLifecycleRequest method.
  1790. // req, resp := client.GetBucketLifecycleRequest(params)
  1791. //
  1792. // err := req.Send()
  1793. // if err == nil { // resp is now filled
  1794. // fmt.Println(resp)
  1795. // }
  1796. //
  1797. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycle
  1798. func (c *S3) GetBucketLifecycleRequest(input *GetBucketLifecycleInput) (req *request.Request, output *GetBucketLifecycleOutput) {
  1799. if c.Client.Config.Logger != nil {
  1800. c.Client.Config.Logger.Log("This operation, GetBucketLifecycle, has been deprecated")
  1801. }
  1802. op := &request.Operation{
  1803. Name: opGetBucketLifecycle,
  1804. HTTPMethod: "GET",
  1805. HTTPPath: "/{Bucket}?lifecycle",
  1806. }
  1807. if input == nil {
  1808. input = &GetBucketLifecycleInput{}
  1809. }
  1810. output = &GetBucketLifecycleOutput{}
  1811. req = c.newRequest(op, input, output)
  1812. return
  1813. }
  1814. // GetBucketLifecycle API operation for Amazon Simple Storage Service.
  1815. //
  1816. // Deprecated, see the GetBucketLifecycleConfiguration operation.
  1817. //
  1818. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1819. // with awserr.Error's Code and Message methods to get detailed information about
  1820. // the error.
  1821. //
  1822. // See the AWS API reference guide for Amazon Simple Storage Service's
  1823. // API operation GetBucketLifecycle for usage and error information.
  1824. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycle
  1825. func (c *S3) GetBucketLifecycle(input *GetBucketLifecycleInput) (*GetBucketLifecycleOutput, error) {
  1826. req, out := c.GetBucketLifecycleRequest(input)
  1827. return out, req.Send()
  1828. }
  1829. // GetBucketLifecycleWithContext is the same as GetBucketLifecycle with the addition of
  1830. // the ability to pass a context and additional request options.
  1831. //
  1832. // See GetBucketLifecycle for details on how to use this API operation.
  1833. //
  1834. // The context must be non-nil and will be used for request cancellation. If
  1835. // the context is nil a panic will occur. In the future the SDK may create
  1836. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1837. // for more information on using Contexts.
  1838. func (c *S3) GetBucketLifecycleWithContext(ctx aws.Context, input *GetBucketLifecycleInput, opts ...request.Option) (*GetBucketLifecycleOutput, error) {
  1839. req, out := c.GetBucketLifecycleRequest(input)
  1840. req.SetContext(ctx)
  1841. req.ApplyOptions(opts...)
  1842. return out, req.Send()
  1843. }
  1844. const opGetBucketLifecycleConfiguration = "GetBucketLifecycleConfiguration"
  1845. // GetBucketLifecycleConfigurationRequest generates a "aws/request.Request" representing the
  1846. // client's request for the GetBucketLifecycleConfiguration operation. The "output" return
  1847. // value will be populated with the request's response once the request complets
  1848. // successfuly.
  1849. //
  1850. // Use "Send" method on the returned Request to send the API call to the service.
  1851. // the "output" return value is not valid until after Send returns without error.
  1852. //
  1853. // See GetBucketLifecycleConfiguration for more information on using the GetBucketLifecycleConfiguration
  1854. // API call, and error handling.
  1855. //
  1856. // This method is useful when you want to inject custom logic or configuration
  1857. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1858. //
  1859. //
  1860. // // Example sending a request using the GetBucketLifecycleConfigurationRequest method.
  1861. // req, resp := client.GetBucketLifecycleConfigurationRequest(params)
  1862. //
  1863. // err := req.Send()
  1864. // if err == nil { // resp is now filled
  1865. // fmt.Println(resp)
  1866. // }
  1867. //
  1868. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfiguration
  1869. func (c *S3) GetBucketLifecycleConfigurationRequest(input *GetBucketLifecycleConfigurationInput) (req *request.Request, output *GetBucketLifecycleConfigurationOutput) {
  1870. op := &request.Operation{
  1871. Name: opGetBucketLifecycleConfiguration,
  1872. HTTPMethod: "GET",
  1873. HTTPPath: "/{Bucket}?lifecycle",
  1874. }
  1875. if input == nil {
  1876. input = &GetBucketLifecycleConfigurationInput{}
  1877. }
  1878. output = &GetBucketLifecycleConfigurationOutput{}
  1879. req = c.newRequest(op, input, output)
  1880. return
  1881. }
  1882. // GetBucketLifecycleConfiguration API operation for Amazon Simple Storage Service.
  1883. //
  1884. // Returns the lifecycle configuration information set on the bucket.
  1885. //
  1886. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1887. // with awserr.Error's Code and Message methods to get detailed information about
  1888. // the error.
  1889. //
  1890. // See the AWS API reference guide for Amazon Simple Storage Service's
  1891. // API operation GetBucketLifecycleConfiguration for usage and error information.
  1892. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfiguration
  1893. func (c *S3) GetBucketLifecycleConfiguration(input *GetBucketLifecycleConfigurationInput) (*GetBucketLifecycleConfigurationOutput, error) {
  1894. req, out := c.GetBucketLifecycleConfigurationRequest(input)
  1895. return out, req.Send()
  1896. }
  1897. // GetBucketLifecycleConfigurationWithContext is the same as GetBucketLifecycleConfiguration with the addition of
  1898. // the ability to pass a context and additional request options.
  1899. //
  1900. // See GetBucketLifecycleConfiguration for details on how to use this API operation.
  1901. //
  1902. // The context must be non-nil and will be used for request cancellation. If
  1903. // the context is nil a panic will occur. In the future the SDK may create
  1904. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1905. // for more information on using Contexts.
  1906. func (c *S3) GetBucketLifecycleConfigurationWithContext(ctx aws.Context, input *GetBucketLifecycleConfigurationInput, opts ...request.Option) (*GetBucketLifecycleConfigurationOutput, error) {
  1907. req, out := c.GetBucketLifecycleConfigurationRequest(input)
  1908. req.SetContext(ctx)
  1909. req.ApplyOptions(opts...)
  1910. return out, req.Send()
  1911. }
  1912. const opGetBucketLocation = "GetBucketLocation"
  1913. // GetBucketLocationRequest generates a "aws/request.Request" representing the
  1914. // client's request for the GetBucketLocation operation. The "output" return
  1915. // value will be populated with the request's response once the request complets
  1916. // successfuly.
  1917. //
  1918. // Use "Send" method on the returned Request to send the API call to the service.
  1919. // the "output" return value is not valid until after Send returns without error.
  1920. //
  1921. // See GetBucketLocation for more information on using the GetBucketLocation
  1922. // API call, and error handling.
  1923. //
  1924. // This method is useful when you want to inject custom logic or configuration
  1925. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1926. //
  1927. //
  1928. // // Example sending a request using the GetBucketLocationRequest method.
  1929. // req, resp := client.GetBucketLocationRequest(params)
  1930. //
  1931. // err := req.Send()
  1932. // if err == nil { // resp is now filled
  1933. // fmt.Println(resp)
  1934. // }
  1935. //
  1936. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocation
  1937. func (c *S3) GetBucketLocationRequest(input *GetBucketLocationInput) (req *request.Request, output *GetBucketLocationOutput) {
  1938. op := &request.Operation{
  1939. Name: opGetBucketLocation,
  1940. HTTPMethod: "GET",
  1941. HTTPPath: "/{Bucket}?location",
  1942. }
  1943. if input == nil {
  1944. input = &GetBucketLocationInput{}
  1945. }
  1946. output = &GetBucketLocationOutput{}
  1947. req = c.newRequest(op, input, output)
  1948. return
  1949. }
  1950. // GetBucketLocation API operation for Amazon Simple Storage Service.
  1951. //
  1952. // Returns the region the bucket resides in.
  1953. //
  1954. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  1955. // with awserr.Error's Code and Message methods to get detailed information about
  1956. // the error.
  1957. //
  1958. // See the AWS API reference guide for Amazon Simple Storage Service's
  1959. // API operation GetBucketLocation for usage and error information.
  1960. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocation
  1961. func (c *S3) GetBucketLocation(input *GetBucketLocationInput) (*GetBucketLocationOutput, error) {
  1962. req, out := c.GetBucketLocationRequest(input)
  1963. return out, req.Send()
  1964. }
  1965. // GetBucketLocationWithContext is the same as GetBucketLocation with the addition of
  1966. // the ability to pass a context and additional request options.
  1967. //
  1968. // See GetBucketLocation for details on how to use this API operation.
  1969. //
  1970. // The context must be non-nil and will be used for request cancellation. If
  1971. // the context is nil a panic will occur. In the future the SDK may create
  1972. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  1973. // for more information on using Contexts.
  1974. func (c *S3) GetBucketLocationWithContext(ctx aws.Context, input *GetBucketLocationInput, opts ...request.Option) (*GetBucketLocationOutput, error) {
  1975. req, out := c.GetBucketLocationRequest(input)
  1976. req.SetContext(ctx)
  1977. req.ApplyOptions(opts...)
  1978. return out, req.Send()
  1979. }
  1980. const opGetBucketLogging = "GetBucketLogging"
  1981. // GetBucketLoggingRequest generates a "aws/request.Request" representing the
  1982. // client's request for the GetBucketLogging operation. The "output" return
  1983. // value will be populated with the request's response once the request complets
  1984. // successfuly.
  1985. //
  1986. // Use "Send" method on the returned Request to send the API call to the service.
  1987. // the "output" return value is not valid until after Send returns without error.
  1988. //
  1989. // See GetBucketLogging for more information on using the GetBucketLogging
  1990. // API call, and error handling.
  1991. //
  1992. // This method is useful when you want to inject custom logic or configuration
  1993. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  1994. //
  1995. //
  1996. // // Example sending a request using the GetBucketLoggingRequest method.
  1997. // req, resp := client.GetBucketLoggingRequest(params)
  1998. //
  1999. // err := req.Send()
  2000. // if err == nil { // resp is now filled
  2001. // fmt.Println(resp)
  2002. // }
  2003. //
  2004. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLogging
  2005. func (c *S3) GetBucketLoggingRequest(input *GetBucketLoggingInput) (req *request.Request, output *GetBucketLoggingOutput) {
  2006. op := &request.Operation{
  2007. Name: opGetBucketLogging,
  2008. HTTPMethod: "GET",
  2009. HTTPPath: "/{Bucket}?logging",
  2010. }
  2011. if input == nil {
  2012. input = &GetBucketLoggingInput{}
  2013. }
  2014. output = &GetBucketLoggingOutput{}
  2015. req = c.newRequest(op, input, output)
  2016. return
  2017. }
  2018. // GetBucketLogging API operation for Amazon Simple Storage Service.
  2019. //
  2020. // Returns the logging status of a bucket and the permissions users have to
  2021. // view and modify that status. To use GET, you must be the bucket owner.
  2022. //
  2023. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2024. // with awserr.Error's Code and Message methods to get detailed information about
  2025. // the error.
  2026. //
  2027. // See the AWS API reference guide for Amazon Simple Storage Service's
  2028. // API operation GetBucketLogging for usage and error information.
  2029. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLogging
  2030. func (c *S3) GetBucketLogging(input *GetBucketLoggingInput) (*GetBucketLoggingOutput, error) {
  2031. req, out := c.GetBucketLoggingRequest(input)
  2032. return out, req.Send()
  2033. }
  2034. // GetBucketLoggingWithContext is the same as GetBucketLogging with the addition of
  2035. // the ability to pass a context and additional request options.
  2036. //
  2037. // See GetBucketLogging for details on how to use this API operation.
  2038. //
  2039. // The context must be non-nil and will be used for request cancellation. If
  2040. // the context is nil a panic will occur. In the future the SDK may create
  2041. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2042. // for more information on using Contexts.
  2043. func (c *S3) GetBucketLoggingWithContext(ctx aws.Context, input *GetBucketLoggingInput, opts ...request.Option) (*GetBucketLoggingOutput, error) {
  2044. req, out := c.GetBucketLoggingRequest(input)
  2045. req.SetContext(ctx)
  2046. req.ApplyOptions(opts...)
  2047. return out, req.Send()
  2048. }
  2049. const opGetBucketMetricsConfiguration = "GetBucketMetricsConfiguration"
  2050. // GetBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the
  2051. // client's request for the GetBucketMetricsConfiguration operation. The "output" return
  2052. // value will be populated with the request's response once the request complets
  2053. // successfuly.
  2054. //
  2055. // Use "Send" method on the returned Request to send the API call to the service.
  2056. // the "output" return value is not valid until after Send returns without error.
  2057. //
  2058. // See GetBucketMetricsConfiguration for more information on using the GetBucketMetricsConfiguration
  2059. // API call, and error handling.
  2060. //
  2061. // This method is useful when you want to inject custom logic or configuration
  2062. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2063. //
  2064. //
  2065. // // Example sending a request using the GetBucketMetricsConfigurationRequest method.
  2066. // req, resp := client.GetBucketMetricsConfigurationRequest(params)
  2067. //
  2068. // err := req.Send()
  2069. // if err == nil { // resp is now filled
  2070. // fmt.Println(resp)
  2071. // }
  2072. //
  2073. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfiguration
  2074. func (c *S3) GetBucketMetricsConfigurationRequest(input *GetBucketMetricsConfigurationInput) (req *request.Request, output *GetBucketMetricsConfigurationOutput) {
  2075. op := &request.Operation{
  2076. Name: opGetBucketMetricsConfiguration,
  2077. HTTPMethod: "GET",
  2078. HTTPPath: "/{Bucket}?metrics",
  2079. }
  2080. if input == nil {
  2081. input = &GetBucketMetricsConfigurationInput{}
  2082. }
  2083. output = &GetBucketMetricsConfigurationOutput{}
  2084. req = c.newRequest(op, input, output)
  2085. return
  2086. }
  2087. // GetBucketMetricsConfiguration API operation for Amazon Simple Storage Service.
  2088. //
  2089. // Gets a metrics configuration (specified by the metrics configuration ID)
  2090. // from the bucket.
  2091. //
  2092. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2093. // with awserr.Error's Code and Message methods to get detailed information about
  2094. // the error.
  2095. //
  2096. // See the AWS API reference guide for Amazon Simple Storage Service's
  2097. // API operation GetBucketMetricsConfiguration for usage and error information.
  2098. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfiguration
  2099. func (c *S3) GetBucketMetricsConfiguration(input *GetBucketMetricsConfigurationInput) (*GetBucketMetricsConfigurationOutput, error) {
  2100. req, out := c.GetBucketMetricsConfigurationRequest(input)
  2101. return out, req.Send()
  2102. }
  2103. // GetBucketMetricsConfigurationWithContext is the same as GetBucketMetricsConfiguration with the addition of
  2104. // the ability to pass a context and additional request options.
  2105. //
  2106. // See GetBucketMetricsConfiguration for details on how to use this API operation.
  2107. //
  2108. // The context must be non-nil and will be used for request cancellation. If
  2109. // the context is nil a panic will occur. In the future the SDK may create
  2110. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2111. // for more information on using Contexts.
  2112. func (c *S3) GetBucketMetricsConfigurationWithContext(ctx aws.Context, input *GetBucketMetricsConfigurationInput, opts ...request.Option) (*GetBucketMetricsConfigurationOutput, error) {
  2113. req, out := c.GetBucketMetricsConfigurationRequest(input)
  2114. req.SetContext(ctx)
  2115. req.ApplyOptions(opts...)
  2116. return out, req.Send()
  2117. }
  2118. const opGetBucketNotification = "GetBucketNotification"
  2119. // GetBucketNotificationRequest generates a "aws/request.Request" representing the
  2120. // client's request for the GetBucketNotification operation. The "output" return
  2121. // value will be populated with the request's response once the request complets
  2122. // successfuly.
  2123. //
  2124. // Use "Send" method on the returned Request to send the API call to the service.
  2125. // the "output" return value is not valid until after Send returns without error.
  2126. //
  2127. // See GetBucketNotification for more information on using the GetBucketNotification
  2128. // API call, and error handling.
  2129. //
  2130. // This method is useful when you want to inject custom logic or configuration
  2131. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2132. //
  2133. //
  2134. // // Example sending a request using the GetBucketNotificationRequest method.
  2135. // req, resp := client.GetBucketNotificationRequest(params)
  2136. //
  2137. // err := req.Send()
  2138. // if err == nil { // resp is now filled
  2139. // fmt.Println(resp)
  2140. // }
  2141. //
  2142. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotification
  2143. func (c *S3) GetBucketNotificationRequest(input *GetBucketNotificationConfigurationRequest) (req *request.Request, output *NotificationConfigurationDeprecated) {
  2144. if c.Client.Config.Logger != nil {
  2145. c.Client.Config.Logger.Log("This operation, GetBucketNotification, has been deprecated")
  2146. }
  2147. op := &request.Operation{
  2148. Name: opGetBucketNotification,
  2149. HTTPMethod: "GET",
  2150. HTTPPath: "/{Bucket}?notification",
  2151. }
  2152. if input == nil {
  2153. input = &GetBucketNotificationConfigurationRequest{}
  2154. }
  2155. output = &NotificationConfigurationDeprecated{}
  2156. req = c.newRequest(op, input, output)
  2157. return
  2158. }
  2159. // GetBucketNotification API operation for Amazon Simple Storage Service.
  2160. //
  2161. // Deprecated, see the GetBucketNotificationConfiguration operation.
  2162. //
  2163. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2164. // with awserr.Error's Code and Message methods to get detailed information about
  2165. // the error.
  2166. //
  2167. // See the AWS API reference guide for Amazon Simple Storage Service's
  2168. // API operation GetBucketNotification for usage and error information.
  2169. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotification
  2170. func (c *S3) GetBucketNotification(input *GetBucketNotificationConfigurationRequest) (*NotificationConfigurationDeprecated, error) {
  2171. req, out := c.GetBucketNotificationRequest(input)
  2172. return out, req.Send()
  2173. }
  2174. // GetBucketNotificationWithContext is the same as GetBucketNotification with the addition of
  2175. // the ability to pass a context and additional request options.
  2176. //
  2177. // See GetBucketNotification for details on how to use this API operation.
  2178. //
  2179. // The context must be non-nil and will be used for request cancellation. If
  2180. // the context is nil a panic will occur. In the future the SDK may create
  2181. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2182. // for more information on using Contexts.
  2183. func (c *S3) GetBucketNotificationWithContext(ctx aws.Context, input *GetBucketNotificationConfigurationRequest, opts ...request.Option) (*NotificationConfigurationDeprecated, error) {
  2184. req, out := c.GetBucketNotificationRequest(input)
  2185. req.SetContext(ctx)
  2186. req.ApplyOptions(opts...)
  2187. return out, req.Send()
  2188. }
  2189. const opGetBucketNotificationConfiguration = "GetBucketNotificationConfiguration"
  2190. // GetBucketNotificationConfigurationRequest generates a "aws/request.Request" representing the
  2191. // client's request for the GetBucketNotificationConfiguration operation. The "output" return
  2192. // value will be populated with the request's response once the request complets
  2193. // successfuly.
  2194. //
  2195. // Use "Send" method on the returned Request to send the API call to the service.
  2196. // the "output" return value is not valid until after Send returns without error.
  2197. //
  2198. // See GetBucketNotificationConfiguration for more information on using the GetBucketNotificationConfiguration
  2199. // API call, and error handling.
  2200. //
  2201. // This method is useful when you want to inject custom logic or configuration
  2202. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2203. //
  2204. //
  2205. // // Example sending a request using the GetBucketNotificationConfigurationRequest method.
  2206. // req, resp := client.GetBucketNotificationConfigurationRequest(params)
  2207. //
  2208. // err := req.Send()
  2209. // if err == nil { // resp is now filled
  2210. // fmt.Println(resp)
  2211. // }
  2212. //
  2213. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotificationConfiguration
  2214. func (c *S3) GetBucketNotificationConfigurationRequest(input *GetBucketNotificationConfigurationRequest) (req *request.Request, output *NotificationConfiguration) {
  2215. op := &request.Operation{
  2216. Name: opGetBucketNotificationConfiguration,
  2217. HTTPMethod: "GET",
  2218. HTTPPath: "/{Bucket}?notification",
  2219. }
  2220. if input == nil {
  2221. input = &GetBucketNotificationConfigurationRequest{}
  2222. }
  2223. output = &NotificationConfiguration{}
  2224. req = c.newRequest(op, input, output)
  2225. return
  2226. }
  2227. // GetBucketNotificationConfiguration API operation for Amazon Simple Storage Service.
  2228. //
  2229. // Returns the notification configuration of a bucket.
  2230. //
  2231. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2232. // with awserr.Error's Code and Message methods to get detailed information about
  2233. // the error.
  2234. //
  2235. // See the AWS API reference guide for Amazon Simple Storage Service's
  2236. // API operation GetBucketNotificationConfiguration for usage and error information.
  2237. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotificationConfiguration
  2238. func (c *S3) GetBucketNotificationConfiguration(input *GetBucketNotificationConfigurationRequest) (*NotificationConfiguration, error) {
  2239. req, out := c.GetBucketNotificationConfigurationRequest(input)
  2240. return out, req.Send()
  2241. }
  2242. // GetBucketNotificationConfigurationWithContext is the same as GetBucketNotificationConfiguration with the addition of
  2243. // the ability to pass a context and additional request options.
  2244. //
  2245. // See GetBucketNotificationConfiguration for details on how to use this API operation.
  2246. //
  2247. // The context must be non-nil and will be used for request cancellation. If
  2248. // the context is nil a panic will occur. In the future the SDK may create
  2249. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2250. // for more information on using Contexts.
  2251. func (c *S3) GetBucketNotificationConfigurationWithContext(ctx aws.Context, input *GetBucketNotificationConfigurationRequest, opts ...request.Option) (*NotificationConfiguration, error) {
  2252. req, out := c.GetBucketNotificationConfigurationRequest(input)
  2253. req.SetContext(ctx)
  2254. req.ApplyOptions(opts...)
  2255. return out, req.Send()
  2256. }
  2257. const opGetBucketPolicy = "GetBucketPolicy"
  2258. // GetBucketPolicyRequest generates a "aws/request.Request" representing the
  2259. // client's request for the GetBucketPolicy operation. The "output" return
  2260. // value will be populated with the request's response once the request complets
  2261. // successfuly.
  2262. //
  2263. // Use "Send" method on the returned Request to send the API call to the service.
  2264. // the "output" return value is not valid until after Send returns without error.
  2265. //
  2266. // See GetBucketPolicy for more information on using the GetBucketPolicy
  2267. // API call, and error handling.
  2268. //
  2269. // This method is useful when you want to inject custom logic or configuration
  2270. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2271. //
  2272. //
  2273. // // Example sending a request using the GetBucketPolicyRequest method.
  2274. // req, resp := client.GetBucketPolicyRequest(params)
  2275. //
  2276. // err := req.Send()
  2277. // if err == nil { // resp is now filled
  2278. // fmt.Println(resp)
  2279. // }
  2280. //
  2281. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicy
  2282. func (c *S3) GetBucketPolicyRequest(input *GetBucketPolicyInput) (req *request.Request, output *GetBucketPolicyOutput) {
  2283. op := &request.Operation{
  2284. Name: opGetBucketPolicy,
  2285. HTTPMethod: "GET",
  2286. HTTPPath: "/{Bucket}?policy",
  2287. }
  2288. if input == nil {
  2289. input = &GetBucketPolicyInput{}
  2290. }
  2291. output = &GetBucketPolicyOutput{}
  2292. req = c.newRequest(op, input, output)
  2293. return
  2294. }
  2295. // GetBucketPolicy API operation for Amazon Simple Storage Service.
  2296. //
  2297. // Returns the policy of a specified bucket.
  2298. //
  2299. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2300. // with awserr.Error's Code and Message methods to get detailed information about
  2301. // the error.
  2302. //
  2303. // See the AWS API reference guide for Amazon Simple Storage Service's
  2304. // API operation GetBucketPolicy for usage and error information.
  2305. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicy
  2306. func (c *S3) GetBucketPolicy(input *GetBucketPolicyInput) (*GetBucketPolicyOutput, error) {
  2307. req, out := c.GetBucketPolicyRequest(input)
  2308. return out, req.Send()
  2309. }
  2310. // GetBucketPolicyWithContext is the same as GetBucketPolicy with the addition of
  2311. // the ability to pass a context and additional request options.
  2312. //
  2313. // See GetBucketPolicy for details on how to use this API operation.
  2314. //
  2315. // The context must be non-nil and will be used for request cancellation. If
  2316. // the context is nil a panic will occur. In the future the SDK may create
  2317. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2318. // for more information on using Contexts.
  2319. func (c *S3) GetBucketPolicyWithContext(ctx aws.Context, input *GetBucketPolicyInput, opts ...request.Option) (*GetBucketPolicyOutput, error) {
  2320. req, out := c.GetBucketPolicyRequest(input)
  2321. req.SetContext(ctx)
  2322. req.ApplyOptions(opts...)
  2323. return out, req.Send()
  2324. }
  2325. const opGetBucketReplication = "GetBucketReplication"
  2326. // GetBucketReplicationRequest generates a "aws/request.Request" representing the
  2327. // client's request for the GetBucketReplication operation. The "output" return
  2328. // value will be populated with the request's response once the request complets
  2329. // successfuly.
  2330. //
  2331. // Use "Send" method on the returned Request to send the API call to the service.
  2332. // the "output" return value is not valid until after Send returns without error.
  2333. //
  2334. // See GetBucketReplication for more information on using the GetBucketReplication
  2335. // API call, and error handling.
  2336. //
  2337. // This method is useful when you want to inject custom logic or configuration
  2338. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2339. //
  2340. //
  2341. // // Example sending a request using the GetBucketReplicationRequest method.
  2342. // req, resp := client.GetBucketReplicationRequest(params)
  2343. //
  2344. // err := req.Send()
  2345. // if err == nil { // resp is now filled
  2346. // fmt.Println(resp)
  2347. // }
  2348. //
  2349. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplication
  2350. func (c *S3) GetBucketReplicationRequest(input *GetBucketReplicationInput) (req *request.Request, output *GetBucketReplicationOutput) {
  2351. op := &request.Operation{
  2352. Name: opGetBucketReplication,
  2353. HTTPMethod: "GET",
  2354. HTTPPath: "/{Bucket}?replication",
  2355. }
  2356. if input == nil {
  2357. input = &GetBucketReplicationInput{}
  2358. }
  2359. output = &GetBucketReplicationOutput{}
  2360. req = c.newRequest(op, input, output)
  2361. return
  2362. }
  2363. // GetBucketReplication API operation for Amazon Simple Storage Service.
  2364. //
  2365. // Returns the replication configuration of a bucket.
  2366. //
  2367. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2368. // with awserr.Error's Code and Message methods to get detailed information about
  2369. // the error.
  2370. //
  2371. // See the AWS API reference guide for Amazon Simple Storage Service's
  2372. // API operation GetBucketReplication for usage and error information.
  2373. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplication
  2374. func (c *S3) GetBucketReplication(input *GetBucketReplicationInput) (*GetBucketReplicationOutput, error) {
  2375. req, out := c.GetBucketReplicationRequest(input)
  2376. return out, req.Send()
  2377. }
  2378. // GetBucketReplicationWithContext is the same as GetBucketReplication with the addition of
  2379. // the ability to pass a context and additional request options.
  2380. //
  2381. // See GetBucketReplication for details on how to use this API operation.
  2382. //
  2383. // The context must be non-nil and will be used for request cancellation. If
  2384. // the context is nil a panic will occur. In the future the SDK may create
  2385. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2386. // for more information on using Contexts.
  2387. func (c *S3) GetBucketReplicationWithContext(ctx aws.Context, input *GetBucketReplicationInput, opts ...request.Option) (*GetBucketReplicationOutput, error) {
  2388. req, out := c.GetBucketReplicationRequest(input)
  2389. req.SetContext(ctx)
  2390. req.ApplyOptions(opts...)
  2391. return out, req.Send()
  2392. }
  2393. const opGetBucketRequestPayment = "GetBucketRequestPayment"
  2394. // GetBucketRequestPaymentRequest generates a "aws/request.Request" representing the
  2395. // client's request for the GetBucketRequestPayment operation. The "output" return
  2396. // value will be populated with the request's response once the request complets
  2397. // successfuly.
  2398. //
  2399. // Use "Send" method on the returned Request to send the API call to the service.
  2400. // the "output" return value is not valid until after Send returns without error.
  2401. //
  2402. // See GetBucketRequestPayment for more information on using the GetBucketRequestPayment
  2403. // API call, and error handling.
  2404. //
  2405. // This method is useful when you want to inject custom logic or configuration
  2406. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2407. //
  2408. //
  2409. // // Example sending a request using the GetBucketRequestPaymentRequest method.
  2410. // req, resp := client.GetBucketRequestPaymentRequest(params)
  2411. //
  2412. // err := req.Send()
  2413. // if err == nil { // resp is now filled
  2414. // fmt.Println(resp)
  2415. // }
  2416. //
  2417. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPayment
  2418. func (c *S3) GetBucketRequestPaymentRequest(input *GetBucketRequestPaymentInput) (req *request.Request, output *GetBucketRequestPaymentOutput) {
  2419. op := &request.Operation{
  2420. Name: opGetBucketRequestPayment,
  2421. HTTPMethod: "GET",
  2422. HTTPPath: "/{Bucket}?requestPayment",
  2423. }
  2424. if input == nil {
  2425. input = &GetBucketRequestPaymentInput{}
  2426. }
  2427. output = &GetBucketRequestPaymentOutput{}
  2428. req = c.newRequest(op, input, output)
  2429. return
  2430. }
  2431. // GetBucketRequestPayment API operation for Amazon Simple Storage Service.
  2432. //
  2433. // Returns the request payment configuration of a bucket.
  2434. //
  2435. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2436. // with awserr.Error's Code and Message methods to get detailed information about
  2437. // the error.
  2438. //
  2439. // See the AWS API reference guide for Amazon Simple Storage Service's
  2440. // API operation GetBucketRequestPayment for usage and error information.
  2441. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPayment
  2442. func (c *S3) GetBucketRequestPayment(input *GetBucketRequestPaymentInput) (*GetBucketRequestPaymentOutput, error) {
  2443. req, out := c.GetBucketRequestPaymentRequest(input)
  2444. return out, req.Send()
  2445. }
  2446. // GetBucketRequestPaymentWithContext is the same as GetBucketRequestPayment with the addition of
  2447. // the ability to pass a context and additional request options.
  2448. //
  2449. // See GetBucketRequestPayment for details on how to use this API operation.
  2450. //
  2451. // The context must be non-nil and will be used for request cancellation. If
  2452. // the context is nil a panic will occur. In the future the SDK may create
  2453. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2454. // for more information on using Contexts.
  2455. func (c *S3) GetBucketRequestPaymentWithContext(ctx aws.Context, input *GetBucketRequestPaymentInput, opts ...request.Option) (*GetBucketRequestPaymentOutput, error) {
  2456. req, out := c.GetBucketRequestPaymentRequest(input)
  2457. req.SetContext(ctx)
  2458. req.ApplyOptions(opts...)
  2459. return out, req.Send()
  2460. }
  2461. const opGetBucketTagging = "GetBucketTagging"
  2462. // GetBucketTaggingRequest generates a "aws/request.Request" representing the
  2463. // client's request for the GetBucketTagging operation. The "output" return
  2464. // value will be populated with the request's response once the request complets
  2465. // successfuly.
  2466. //
  2467. // Use "Send" method on the returned Request to send the API call to the service.
  2468. // the "output" return value is not valid until after Send returns without error.
  2469. //
  2470. // See GetBucketTagging for more information on using the GetBucketTagging
  2471. // API call, and error handling.
  2472. //
  2473. // This method is useful when you want to inject custom logic or configuration
  2474. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2475. //
  2476. //
  2477. // // Example sending a request using the GetBucketTaggingRequest method.
  2478. // req, resp := client.GetBucketTaggingRequest(params)
  2479. //
  2480. // err := req.Send()
  2481. // if err == nil { // resp is now filled
  2482. // fmt.Println(resp)
  2483. // }
  2484. //
  2485. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTagging
  2486. func (c *S3) GetBucketTaggingRequest(input *GetBucketTaggingInput) (req *request.Request, output *GetBucketTaggingOutput) {
  2487. op := &request.Operation{
  2488. Name: opGetBucketTagging,
  2489. HTTPMethod: "GET",
  2490. HTTPPath: "/{Bucket}?tagging",
  2491. }
  2492. if input == nil {
  2493. input = &GetBucketTaggingInput{}
  2494. }
  2495. output = &GetBucketTaggingOutput{}
  2496. req = c.newRequest(op, input, output)
  2497. return
  2498. }
  2499. // GetBucketTagging API operation for Amazon Simple Storage Service.
  2500. //
  2501. // Returns the tag set associated with the bucket.
  2502. //
  2503. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2504. // with awserr.Error's Code and Message methods to get detailed information about
  2505. // the error.
  2506. //
  2507. // See the AWS API reference guide for Amazon Simple Storage Service's
  2508. // API operation GetBucketTagging for usage and error information.
  2509. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTagging
  2510. func (c *S3) GetBucketTagging(input *GetBucketTaggingInput) (*GetBucketTaggingOutput, error) {
  2511. req, out := c.GetBucketTaggingRequest(input)
  2512. return out, req.Send()
  2513. }
  2514. // GetBucketTaggingWithContext is the same as GetBucketTagging with the addition of
  2515. // the ability to pass a context and additional request options.
  2516. //
  2517. // See GetBucketTagging for details on how to use this API operation.
  2518. //
  2519. // The context must be non-nil and will be used for request cancellation. If
  2520. // the context is nil a panic will occur. In the future the SDK may create
  2521. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2522. // for more information on using Contexts.
  2523. func (c *S3) GetBucketTaggingWithContext(ctx aws.Context, input *GetBucketTaggingInput, opts ...request.Option) (*GetBucketTaggingOutput, error) {
  2524. req, out := c.GetBucketTaggingRequest(input)
  2525. req.SetContext(ctx)
  2526. req.ApplyOptions(opts...)
  2527. return out, req.Send()
  2528. }
  2529. const opGetBucketVersioning = "GetBucketVersioning"
  2530. // GetBucketVersioningRequest generates a "aws/request.Request" representing the
  2531. // client's request for the GetBucketVersioning operation. The "output" return
  2532. // value will be populated with the request's response once the request complets
  2533. // successfuly.
  2534. //
  2535. // Use "Send" method on the returned Request to send the API call to the service.
  2536. // the "output" return value is not valid until after Send returns without error.
  2537. //
  2538. // See GetBucketVersioning for more information on using the GetBucketVersioning
  2539. // API call, and error handling.
  2540. //
  2541. // This method is useful when you want to inject custom logic or configuration
  2542. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2543. //
  2544. //
  2545. // // Example sending a request using the GetBucketVersioningRequest method.
  2546. // req, resp := client.GetBucketVersioningRequest(params)
  2547. //
  2548. // err := req.Send()
  2549. // if err == nil { // resp is now filled
  2550. // fmt.Println(resp)
  2551. // }
  2552. //
  2553. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioning
  2554. func (c *S3) GetBucketVersioningRequest(input *GetBucketVersioningInput) (req *request.Request, output *GetBucketVersioningOutput) {
  2555. op := &request.Operation{
  2556. Name: opGetBucketVersioning,
  2557. HTTPMethod: "GET",
  2558. HTTPPath: "/{Bucket}?versioning",
  2559. }
  2560. if input == nil {
  2561. input = &GetBucketVersioningInput{}
  2562. }
  2563. output = &GetBucketVersioningOutput{}
  2564. req = c.newRequest(op, input, output)
  2565. return
  2566. }
  2567. // GetBucketVersioning API operation for Amazon Simple Storage Service.
  2568. //
  2569. // Returns the versioning state of a bucket.
  2570. //
  2571. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2572. // with awserr.Error's Code and Message methods to get detailed information about
  2573. // the error.
  2574. //
  2575. // See the AWS API reference guide for Amazon Simple Storage Service's
  2576. // API operation GetBucketVersioning for usage and error information.
  2577. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioning
  2578. func (c *S3) GetBucketVersioning(input *GetBucketVersioningInput) (*GetBucketVersioningOutput, error) {
  2579. req, out := c.GetBucketVersioningRequest(input)
  2580. return out, req.Send()
  2581. }
  2582. // GetBucketVersioningWithContext is the same as GetBucketVersioning with the addition of
  2583. // the ability to pass a context and additional request options.
  2584. //
  2585. // See GetBucketVersioning for details on how to use this API operation.
  2586. //
  2587. // The context must be non-nil and will be used for request cancellation. If
  2588. // the context is nil a panic will occur. In the future the SDK may create
  2589. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2590. // for more information on using Contexts.
  2591. func (c *S3) GetBucketVersioningWithContext(ctx aws.Context, input *GetBucketVersioningInput, opts ...request.Option) (*GetBucketVersioningOutput, error) {
  2592. req, out := c.GetBucketVersioningRequest(input)
  2593. req.SetContext(ctx)
  2594. req.ApplyOptions(opts...)
  2595. return out, req.Send()
  2596. }
  2597. const opGetBucketWebsite = "GetBucketWebsite"
  2598. // GetBucketWebsiteRequest generates a "aws/request.Request" representing the
  2599. // client's request for the GetBucketWebsite operation. The "output" return
  2600. // value will be populated with the request's response once the request complets
  2601. // successfuly.
  2602. //
  2603. // Use "Send" method on the returned Request to send the API call to the service.
  2604. // the "output" return value is not valid until after Send returns without error.
  2605. //
  2606. // See GetBucketWebsite for more information on using the GetBucketWebsite
  2607. // API call, and error handling.
  2608. //
  2609. // This method is useful when you want to inject custom logic or configuration
  2610. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2611. //
  2612. //
  2613. // // Example sending a request using the GetBucketWebsiteRequest method.
  2614. // req, resp := client.GetBucketWebsiteRequest(params)
  2615. //
  2616. // err := req.Send()
  2617. // if err == nil { // resp is now filled
  2618. // fmt.Println(resp)
  2619. // }
  2620. //
  2621. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsite
  2622. func (c *S3) GetBucketWebsiteRequest(input *GetBucketWebsiteInput) (req *request.Request, output *GetBucketWebsiteOutput) {
  2623. op := &request.Operation{
  2624. Name: opGetBucketWebsite,
  2625. HTTPMethod: "GET",
  2626. HTTPPath: "/{Bucket}?website",
  2627. }
  2628. if input == nil {
  2629. input = &GetBucketWebsiteInput{}
  2630. }
  2631. output = &GetBucketWebsiteOutput{}
  2632. req = c.newRequest(op, input, output)
  2633. return
  2634. }
  2635. // GetBucketWebsite API operation for Amazon Simple Storage Service.
  2636. //
  2637. // Returns the website configuration for a bucket.
  2638. //
  2639. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2640. // with awserr.Error's Code and Message methods to get detailed information about
  2641. // the error.
  2642. //
  2643. // See the AWS API reference guide for Amazon Simple Storage Service's
  2644. // API operation GetBucketWebsite for usage and error information.
  2645. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsite
  2646. func (c *S3) GetBucketWebsite(input *GetBucketWebsiteInput) (*GetBucketWebsiteOutput, error) {
  2647. req, out := c.GetBucketWebsiteRequest(input)
  2648. return out, req.Send()
  2649. }
  2650. // GetBucketWebsiteWithContext is the same as GetBucketWebsite with the addition of
  2651. // the ability to pass a context and additional request options.
  2652. //
  2653. // See GetBucketWebsite for details on how to use this API operation.
  2654. //
  2655. // The context must be non-nil and will be used for request cancellation. If
  2656. // the context is nil a panic will occur. In the future the SDK may create
  2657. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2658. // for more information on using Contexts.
  2659. func (c *S3) GetBucketWebsiteWithContext(ctx aws.Context, input *GetBucketWebsiteInput, opts ...request.Option) (*GetBucketWebsiteOutput, error) {
  2660. req, out := c.GetBucketWebsiteRequest(input)
  2661. req.SetContext(ctx)
  2662. req.ApplyOptions(opts...)
  2663. return out, req.Send()
  2664. }
  2665. const opGetObject = "GetObject"
  2666. // GetObjectRequest generates a "aws/request.Request" representing the
  2667. // client's request for the GetObject operation. The "output" return
  2668. // value will be populated with the request's response once the request complets
  2669. // successfuly.
  2670. //
  2671. // Use "Send" method on the returned Request to send the API call to the service.
  2672. // the "output" return value is not valid until after Send returns without error.
  2673. //
  2674. // See GetObject for more information on using the GetObject
  2675. // API call, and error handling.
  2676. //
  2677. // This method is useful when you want to inject custom logic or configuration
  2678. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2679. //
  2680. //
  2681. // // Example sending a request using the GetObjectRequest method.
  2682. // req, resp := client.GetObjectRequest(params)
  2683. //
  2684. // err := req.Send()
  2685. // if err == nil { // resp is now filled
  2686. // fmt.Println(resp)
  2687. // }
  2688. //
  2689. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObject
  2690. func (c *S3) GetObjectRequest(input *GetObjectInput) (req *request.Request, output *GetObjectOutput) {
  2691. op := &request.Operation{
  2692. Name: opGetObject,
  2693. HTTPMethod: "GET",
  2694. HTTPPath: "/{Bucket}/{Key+}",
  2695. }
  2696. if input == nil {
  2697. input = &GetObjectInput{}
  2698. }
  2699. output = &GetObjectOutput{}
  2700. req = c.newRequest(op, input, output)
  2701. return
  2702. }
  2703. // GetObject API operation for Amazon Simple Storage Service.
  2704. //
  2705. // Retrieves objects from Amazon S3.
  2706. //
  2707. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2708. // with awserr.Error's Code and Message methods to get detailed information about
  2709. // the error.
  2710. //
  2711. // See the AWS API reference guide for Amazon Simple Storage Service's
  2712. // API operation GetObject for usage and error information.
  2713. //
  2714. // Returned Error Codes:
  2715. // * ErrCodeNoSuchKey "NoSuchKey"
  2716. // The specified key does not exist.
  2717. //
  2718. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObject
  2719. func (c *S3) GetObject(input *GetObjectInput) (*GetObjectOutput, error) {
  2720. req, out := c.GetObjectRequest(input)
  2721. return out, req.Send()
  2722. }
  2723. // GetObjectWithContext is the same as GetObject with the addition of
  2724. // the ability to pass a context and additional request options.
  2725. //
  2726. // See GetObject for details on how to use this API operation.
  2727. //
  2728. // The context must be non-nil and will be used for request cancellation. If
  2729. // the context is nil a panic will occur. In the future the SDK may create
  2730. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2731. // for more information on using Contexts.
  2732. func (c *S3) GetObjectWithContext(ctx aws.Context, input *GetObjectInput, opts ...request.Option) (*GetObjectOutput, error) {
  2733. req, out := c.GetObjectRequest(input)
  2734. req.SetContext(ctx)
  2735. req.ApplyOptions(opts...)
  2736. return out, req.Send()
  2737. }
  2738. const opGetObjectAcl = "GetObjectAcl"
  2739. // GetObjectAclRequest generates a "aws/request.Request" representing the
  2740. // client's request for the GetObjectAcl operation. The "output" return
  2741. // value will be populated with the request's response once the request complets
  2742. // successfuly.
  2743. //
  2744. // Use "Send" method on the returned Request to send the API call to the service.
  2745. // the "output" return value is not valid until after Send returns without error.
  2746. //
  2747. // See GetObjectAcl for more information on using the GetObjectAcl
  2748. // API call, and error handling.
  2749. //
  2750. // This method is useful when you want to inject custom logic or configuration
  2751. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2752. //
  2753. //
  2754. // // Example sending a request using the GetObjectAclRequest method.
  2755. // req, resp := client.GetObjectAclRequest(params)
  2756. //
  2757. // err := req.Send()
  2758. // if err == nil { // resp is now filled
  2759. // fmt.Println(resp)
  2760. // }
  2761. //
  2762. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAcl
  2763. func (c *S3) GetObjectAclRequest(input *GetObjectAclInput) (req *request.Request, output *GetObjectAclOutput) {
  2764. op := &request.Operation{
  2765. Name: opGetObjectAcl,
  2766. HTTPMethod: "GET",
  2767. HTTPPath: "/{Bucket}/{Key+}?acl",
  2768. }
  2769. if input == nil {
  2770. input = &GetObjectAclInput{}
  2771. }
  2772. output = &GetObjectAclOutput{}
  2773. req = c.newRequest(op, input, output)
  2774. return
  2775. }
  2776. // GetObjectAcl API operation for Amazon Simple Storage Service.
  2777. //
  2778. // Returns the access control list (ACL) of an object.
  2779. //
  2780. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2781. // with awserr.Error's Code and Message methods to get detailed information about
  2782. // the error.
  2783. //
  2784. // See the AWS API reference guide for Amazon Simple Storage Service's
  2785. // API operation GetObjectAcl for usage and error information.
  2786. //
  2787. // Returned Error Codes:
  2788. // * ErrCodeNoSuchKey "NoSuchKey"
  2789. // The specified key does not exist.
  2790. //
  2791. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAcl
  2792. func (c *S3) GetObjectAcl(input *GetObjectAclInput) (*GetObjectAclOutput, error) {
  2793. req, out := c.GetObjectAclRequest(input)
  2794. return out, req.Send()
  2795. }
  2796. // GetObjectAclWithContext is the same as GetObjectAcl with the addition of
  2797. // the ability to pass a context and additional request options.
  2798. //
  2799. // See GetObjectAcl for details on how to use this API operation.
  2800. //
  2801. // The context must be non-nil and will be used for request cancellation. If
  2802. // the context is nil a panic will occur. In the future the SDK may create
  2803. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2804. // for more information on using Contexts.
  2805. func (c *S3) GetObjectAclWithContext(ctx aws.Context, input *GetObjectAclInput, opts ...request.Option) (*GetObjectAclOutput, error) {
  2806. req, out := c.GetObjectAclRequest(input)
  2807. req.SetContext(ctx)
  2808. req.ApplyOptions(opts...)
  2809. return out, req.Send()
  2810. }
  2811. const opGetObjectTagging = "GetObjectTagging"
  2812. // GetObjectTaggingRequest generates a "aws/request.Request" representing the
  2813. // client's request for the GetObjectTagging operation. The "output" return
  2814. // value will be populated with the request's response once the request complets
  2815. // successfuly.
  2816. //
  2817. // Use "Send" method on the returned Request to send the API call to the service.
  2818. // the "output" return value is not valid until after Send returns without error.
  2819. //
  2820. // See GetObjectTagging for more information on using the GetObjectTagging
  2821. // API call, and error handling.
  2822. //
  2823. // This method is useful when you want to inject custom logic or configuration
  2824. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2825. //
  2826. //
  2827. // // Example sending a request using the GetObjectTaggingRequest method.
  2828. // req, resp := client.GetObjectTaggingRequest(params)
  2829. //
  2830. // err := req.Send()
  2831. // if err == nil { // resp is now filled
  2832. // fmt.Println(resp)
  2833. // }
  2834. //
  2835. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTagging
  2836. func (c *S3) GetObjectTaggingRequest(input *GetObjectTaggingInput) (req *request.Request, output *GetObjectTaggingOutput) {
  2837. op := &request.Operation{
  2838. Name: opGetObjectTagging,
  2839. HTTPMethod: "GET",
  2840. HTTPPath: "/{Bucket}/{Key+}?tagging",
  2841. }
  2842. if input == nil {
  2843. input = &GetObjectTaggingInput{}
  2844. }
  2845. output = &GetObjectTaggingOutput{}
  2846. req = c.newRequest(op, input, output)
  2847. return
  2848. }
  2849. // GetObjectTagging API operation for Amazon Simple Storage Service.
  2850. //
  2851. // Returns the tag-set of an object.
  2852. //
  2853. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2854. // with awserr.Error's Code and Message methods to get detailed information about
  2855. // the error.
  2856. //
  2857. // See the AWS API reference guide for Amazon Simple Storage Service's
  2858. // API operation GetObjectTagging for usage and error information.
  2859. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTagging
  2860. func (c *S3) GetObjectTagging(input *GetObjectTaggingInput) (*GetObjectTaggingOutput, error) {
  2861. req, out := c.GetObjectTaggingRequest(input)
  2862. return out, req.Send()
  2863. }
  2864. // GetObjectTaggingWithContext is the same as GetObjectTagging with the addition of
  2865. // the ability to pass a context and additional request options.
  2866. //
  2867. // See GetObjectTagging for details on how to use this API operation.
  2868. //
  2869. // The context must be non-nil and will be used for request cancellation. If
  2870. // the context is nil a panic will occur. In the future the SDK may create
  2871. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2872. // for more information on using Contexts.
  2873. func (c *S3) GetObjectTaggingWithContext(ctx aws.Context, input *GetObjectTaggingInput, opts ...request.Option) (*GetObjectTaggingOutput, error) {
  2874. req, out := c.GetObjectTaggingRequest(input)
  2875. req.SetContext(ctx)
  2876. req.ApplyOptions(opts...)
  2877. return out, req.Send()
  2878. }
  2879. const opGetObjectTorrent = "GetObjectTorrent"
  2880. // GetObjectTorrentRequest generates a "aws/request.Request" representing the
  2881. // client's request for the GetObjectTorrent operation. The "output" return
  2882. // value will be populated with the request's response once the request complets
  2883. // successfuly.
  2884. //
  2885. // Use "Send" method on the returned Request to send the API call to the service.
  2886. // the "output" return value is not valid until after Send returns without error.
  2887. //
  2888. // See GetObjectTorrent for more information on using the GetObjectTorrent
  2889. // API call, and error handling.
  2890. //
  2891. // This method is useful when you want to inject custom logic or configuration
  2892. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2893. //
  2894. //
  2895. // // Example sending a request using the GetObjectTorrentRequest method.
  2896. // req, resp := client.GetObjectTorrentRequest(params)
  2897. //
  2898. // err := req.Send()
  2899. // if err == nil { // resp is now filled
  2900. // fmt.Println(resp)
  2901. // }
  2902. //
  2903. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrent
  2904. func (c *S3) GetObjectTorrentRequest(input *GetObjectTorrentInput) (req *request.Request, output *GetObjectTorrentOutput) {
  2905. op := &request.Operation{
  2906. Name: opGetObjectTorrent,
  2907. HTTPMethod: "GET",
  2908. HTTPPath: "/{Bucket}/{Key+}?torrent",
  2909. }
  2910. if input == nil {
  2911. input = &GetObjectTorrentInput{}
  2912. }
  2913. output = &GetObjectTorrentOutput{}
  2914. req = c.newRequest(op, input, output)
  2915. return
  2916. }
  2917. // GetObjectTorrent API operation for Amazon Simple Storage Service.
  2918. //
  2919. // Return torrent files from a bucket.
  2920. //
  2921. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2922. // with awserr.Error's Code and Message methods to get detailed information about
  2923. // the error.
  2924. //
  2925. // See the AWS API reference guide for Amazon Simple Storage Service's
  2926. // API operation GetObjectTorrent for usage and error information.
  2927. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrent
  2928. func (c *S3) GetObjectTorrent(input *GetObjectTorrentInput) (*GetObjectTorrentOutput, error) {
  2929. req, out := c.GetObjectTorrentRequest(input)
  2930. return out, req.Send()
  2931. }
  2932. // GetObjectTorrentWithContext is the same as GetObjectTorrent with the addition of
  2933. // the ability to pass a context and additional request options.
  2934. //
  2935. // See GetObjectTorrent for details on how to use this API operation.
  2936. //
  2937. // The context must be non-nil and will be used for request cancellation. If
  2938. // the context is nil a panic will occur. In the future the SDK may create
  2939. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  2940. // for more information on using Contexts.
  2941. func (c *S3) GetObjectTorrentWithContext(ctx aws.Context, input *GetObjectTorrentInput, opts ...request.Option) (*GetObjectTorrentOutput, error) {
  2942. req, out := c.GetObjectTorrentRequest(input)
  2943. req.SetContext(ctx)
  2944. req.ApplyOptions(opts...)
  2945. return out, req.Send()
  2946. }
  2947. const opHeadBucket = "HeadBucket"
  2948. // HeadBucketRequest generates a "aws/request.Request" representing the
  2949. // client's request for the HeadBucket operation. The "output" return
  2950. // value will be populated with the request's response once the request complets
  2951. // successfuly.
  2952. //
  2953. // Use "Send" method on the returned Request to send the API call to the service.
  2954. // the "output" return value is not valid until after Send returns without error.
  2955. //
  2956. // See HeadBucket for more information on using the HeadBucket
  2957. // API call, and error handling.
  2958. //
  2959. // This method is useful when you want to inject custom logic or configuration
  2960. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  2961. //
  2962. //
  2963. // // Example sending a request using the HeadBucketRequest method.
  2964. // req, resp := client.HeadBucketRequest(params)
  2965. //
  2966. // err := req.Send()
  2967. // if err == nil { // resp is now filled
  2968. // fmt.Println(resp)
  2969. // }
  2970. //
  2971. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucket
  2972. func (c *S3) HeadBucketRequest(input *HeadBucketInput) (req *request.Request, output *HeadBucketOutput) {
  2973. op := &request.Operation{
  2974. Name: opHeadBucket,
  2975. HTTPMethod: "HEAD",
  2976. HTTPPath: "/{Bucket}",
  2977. }
  2978. if input == nil {
  2979. input = &HeadBucketInput{}
  2980. }
  2981. output = &HeadBucketOutput{}
  2982. req = c.newRequest(op, input, output)
  2983. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  2984. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2985. return
  2986. }
  2987. // HeadBucket API operation for Amazon Simple Storage Service.
  2988. //
  2989. // This operation is useful to determine if a bucket exists and you have permission
  2990. // to access it.
  2991. //
  2992. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  2993. // with awserr.Error's Code and Message methods to get detailed information about
  2994. // the error.
  2995. //
  2996. // See the AWS API reference guide for Amazon Simple Storage Service's
  2997. // API operation HeadBucket for usage and error information.
  2998. //
  2999. // Returned Error Codes:
  3000. // * ErrCodeNoSuchBucket "NoSuchBucket"
  3001. // The specified bucket does not exist.
  3002. //
  3003. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucket
  3004. func (c *S3) HeadBucket(input *HeadBucketInput) (*HeadBucketOutput, error) {
  3005. req, out := c.HeadBucketRequest(input)
  3006. return out, req.Send()
  3007. }
  3008. // HeadBucketWithContext is the same as HeadBucket with the addition of
  3009. // the ability to pass a context and additional request options.
  3010. //
  3011. // See HeadBucket for details on how to use this API operation.
  3012. //
  3013. // The context must be non-nil and will be used for request cancellation. If
  3014. // the context is nil a panic will occur. In the future the SDK may create
  3015. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3016. // for more information on using Contexts.
  3017. func (c *S3) HeadBucketWithContext(ctx aws.Context, input *HeadBucketInput, opts ...request.Option) (*HeadBucketOutput, error) {
  3018. req, out := c.HeadBucketRequest(input)
  3019. req.SetContext(ctx)
  3020. req.ApplyOptions(opts...)
  3021. return out, req.Send()
  3022. }
  3023. const opHeadObject = "HeadObject"
  3024. // HeadObjectRequest generates a "aws/request.Request" representing the
  3025. // client's request for the HeadObject operation. The "output" return
  3026. // value will be populated with the request's response once the request complets
  3027. // successfuly.
  3028. //
  3029. // Use "Send" method on the returned Request to send the API call to the service.
  3030. // the "output" return value is not valid until after Send returns without error.
  3031. //
  3032. // See HeadObject for more information on using the HeadObject
  3033. // API call, and error handling.
  3034. //
  3035. // This method is useful when you want to inject custom logic or configuration
  3036. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3037. //
  3038. //
  3039. // // Example sending a request using the HeadObjectRequest method.
  3040. // req, resp := client.HeadObjectRequest(params)
  3041. //
  3042. // err := req.Send()
  3043. // if err == nil { // resp is now filled
  3044. // fmt.Println(resp)
  3045. // }
  3046. //
  3047. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObject
  3048. func (c *S3) HeadObjectRequest(input *HeadObjectInput) (req *request.Request, output *HeadObjectOutput) {
  3049. op := &request.Operation{
  3050. Name: opHeadObject,
  3051. HTTPMethod: "HEAD",
  3052. HTTPPath: "/{Bucket}/{Key+}",
  3053. }
  3054. if input == nil {
  3055. input = &HeadObjectInput{}
  3056. }
  3057. output = &HeadObjectOutput{}
  3058. req = c.newRequest(op, input, output)
  3059. return
  3060. }
  3061. // HeadObject API operation for Amazon Simple Storage Service.
  3062. //
  3063. // The HEAD operation retrieves metadata from an object without returning the
  3064. // object itself. This operation is useful if you're only interested in an object's
  3065. // metadata. To use HEAD, you must have READ access to the object.
  3066. //
  3067. // See http://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#RESTErrorResponses
  3068. // for more information on returned errors.
  3069. //
  3070. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3071. // with awserr.Error's Code and Message methods to get detailed information about
  3072. // the error.
  3073. //
  3074. // See the AWS API reference guide for Amazon Simple Storage Service's
  3075. // API operation HeadObject for usage and error information.
  3076. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObject
  3077. func (c *S3) HeadObject(input *HeadObjectInput) (*HeadObjectOutput, error) {
  3078. req, out := c.HeadObjectRequest(input)
  3079. return out, req.Send()
  3080. }
  3081. // HeadObjectWithContext is the same as HeadObject with the addition of
  3082. // the ability to pass a context and additional request options.
  3083. //
  3084. // See HeadObject for details on how to use this API operation.
  3085. //
  3086. // The context must be non-nil and will be used for request cancellation. If
  3087. // the context is nil a panic will occur. In the future the SDK may create
  3088. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3089. // for more information on using Contexts.
  3090. func (c *S3) HeadObjectWithContext(ctx aws.Context, input *HeadObjectInput, opts ...request.Option) (*HeadObjectOutput, error) {
  3091. req, out := c.HeadObjectRequest(input)
  3092. req.SetContext(ctx)
  3093. req.ApplyOptions(opts...)
  3094. return out, req.Send()
  3095. }
  3096. const opListBucketAnalyticsConfigurations = "ListBucketAnalyticsConfigurations"
  3097. // ListBucketAnalyticsConfigurationsRequest generates a "aws/request.Request" representing the
  3098. // client's request for the ListBucketAnalyticsConfigurations operation. The "output" return
  3099. // value will be populated with the request's response once the request complets
  3100. // successfuly.
  3101. //
  3102. // Use "Send" method on the returned Request to send the API call to the service.
  3103. // the "output" return value is not valid until after Send returns without error.
  3104. //
  3105. // See ListBucketAnalyticsConfigurations for more information on using the ListBucketAnalyticsConfigurations
  3106. // API call, and error handling.
  3107. //
  3108. // This method is useful when you want to inject custom logic or configuration
  3109. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3110. //
  3111. //
  3112. // // Example sending a request using the ListBucketAnalyticsConfigurationsRequest method.
  3113. // req, resp := client.ListBucketAnalyticsConfigurationsRequest(params)
  3114. //
  3115. // err := req.Send()
  3116. // if err == nil { // resp is now filled
  3117. // fmt.Println(resp)
  3118. // }
  3119. //
  3120. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurations
  3121. func (c *S3) ListBucketAnalyticsConfigurationsRequest(input *ListBucketAnalyticsConfigurationsInput) (req *request.Request, output *ListBucketAnalyticsConfigurationsOutput) {
  3122. op := &request.Operation{
  3123. Name: opListBucketAnalyticsConfigurations,
  3124. HTTPMethod: "GET",
  3125. HTTPPath: "/{Bucket}?analytics",
  3126. }
  3127. if input == nil {
  3128. input = &ListBucketAnalyticsConfigurationsInput{}
  3129. }
  3130. output = &ListBucketAnalyticsConfigurationsOutput{}
  3131. req = c.newRequest(op, input, output)
  3132. return
  3133. }
  3134. // ListBucketAnalyticsConfigurations API operation for Amazon Simple Storage Service.
  3135. //
  3136. // Lists the analytics configurations for the bucket.
  3137. //
  3138. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3139. // with awserr.Error's Code and Message methods to get detailed information about
  3140. // the error.
  3141. //
  3142. // See the AWS API reference guide for Amazon Simple Storage Service's
  3143. // API operation ListBucketAnalyticsConfigurations for usage and error information.
  3144. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurations
  3145. func (c *S3) ListBucketAnalyticsConfigurations(input *ListBucketAnalyticsConfigurationsInput) (*ListBucketAnalyticsConfigurationsOutput, error) {
  3146. req, out := c.ListBucketAnalyticsConfigurationsRequest(input)
  3147. return out, req.Send()
  3148. }
  3149. // ListBucketAnalyticsConfigurationsWithContext is the same as ListBucketAnalyticsConfigurations with the addition of
  3150. // the ability to pass a context and additional request options.
  3151. //
  3152. // See ListBucketAnalyticsConfigurations for details on how to use this API operation.
  3153. //
  3154. // The context must be non-nil and will be used for request cancellation. If
  3155. // the context is nil a panic will occur. In the future the SDK may create
  3156. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3157. // for more information on using Contexts.
  3158. func (c *S3) ListBucketAnalyticsConfigurationsWithContext(ctx aws.Context, input *ListBucketAnalyticsConfigurationsInput, opts ...request.Option) (*ListBucketAnalyticsConfigurationsOutput, error) {
  3159. req, out := c.ListBucketAnalyticsConfigurationsRequest(input)
  3160. req.SetContext(ctx)
  3161. req.ApplyOptions(opts...)
  3162. return out, req.Send()
  3163. }
  3164. const opListBucketInventoryConfigurations = "ListBucketInventoryConfigurations"
  3165. // ListBucketInventoryConfigurationsRequest generates a "aws/request.Request" representing the
  3166. // client's request for the ListBucketInventoryConfigurations operation. The "output" return
  3167. // value will be populated with the request's response once the request complets
  3168. // successfuly.
  3169. //
  3170. // Use "Send" method on the returned Request to send the API call to the service.
  3171. // the "output" return value is not valid until after Send returns without error.
  3172. //
  3173. // See ListBucketInventoryConfigurations for more information on using the ListBucketInventoryConfigurations
  3174. // API call, and error handling.
  3175. //
  3176. // This method is useful when you want to inject custom logic or configuration
  3177. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3178. //
  3179. //
  3180. // // Example sending a request using the ListBucketInventoryConfigurationsRequest method.
  3181. // req, resp := client.ListBucketInventoryConfigurationsRequest(params)
  3182. //
  3183. // err := req.Send()
  3184. // if err == nil { // resp is now filled
  3185. // fmt.Println(resp)
  3186. // }
  3187. //
  3188. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurations
  3189. func (c *S3) ListBucketInventoryConfigurationsRequest(input *ListBucketInventoryConfigurationsInput) (req *request.Request, output *ListBucketInventoryConfigurationsOutput) {
  3190. op := &request.Operation{
  3191. Name: opListBucketInventoryConfigurations,
  3192. HTTPMethod: "GET",
  3193. HTTPPath: "/{Bucket}?inventory",
  3194. }
  3195. if input == nil {
  3196. input = &ListBucketInventoryConfigurationsInput{}
  3197. }
  3198. output = &ListBucketInventoryConfigurationsOutput{}
  3199. req = c.newRequest(op, input, output)
  3200. return
  3201. }
  3202. // ListBucketInventoryConfigurations API operation for Amazon Simple Storage Service.
  3203. //
  3204. // Returns a list of inventory configurations for the bucket.
  3205. //
  3206. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3207. // with awserr.Error's Code and Message methods to get detailed information about
  3208. // the error.
  3209. //
  3210. // See the AWS API reference guide for Amazon Simple Storage Service's
  3211. // API operation ListBucketInventoryConfigurations for usage and error information.
  3212. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurations
  3213. func (c *S3) ListBucketInventoryConfigurations(input *ListBucketInventoryConfigurationsInput) (*ListBucketInventoryConfigurationsOutput, error) {
  3214. req, out := c.ListBucketInventoryConfigurationsRequest(input)
  3215. return out, req.Send()
  3216. }
  3217. // ListBucketInventoryConfigurationsWithContext is the same as ListBucketInventoryConfigurations with the addition of
  3218. // the ability to pass a context and additional request options.
  3219. //
  3220. // See ListBucketInventoryConfigurations for details on how to use this API operation.
  3221. //
  3222. // The context must be non-nil and will be used for request cancellation. If
  3223. // the context is nil a panic will occur. In the future the SDK may create
  3224. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3225. // for more information on using Contexts.
  3226. func (c *S3) ListBucketInventoryConfigurationsWithContext(ctx aws.Context, input *ListBucketInventoryConfigurationsInput, opts ...request.Option) (*ListBucketInventoryConfigurationsOutput, error) {
  3227. req, out := c.ListBucketInventoryConfigurationsRequest(input)
  3228. req.SetContext(ctx)
  3229. req.ApplyOptions(opts...)
  3230. return out, req.Send()
  3231. }
  3232. const opListBucketMetricsConfigurations = "ListBucketMetricsConfigurations"
  3233. // ListBucketMetricsConfigurationsRequest generates a "aws/request.Request" representing the
  3234. // client's request for the ListBucketMetricsConfigurations operation. The "output" return
  3235. // value will be populated with the request's response once the request complets
  3236. // successfuly.
  3237. //
  3238. // Use "Send" method on the returned Request to send the API call to the service.
  3239. // the "output" return value is not valid until after Send returns without error.
  3240. //
  3241. // See ListBucketMetricsConfigurations for more information on using the ListBucketMetricsConfigurations
  3242. // API call, and error handling.
  3243. //
  3244. // This method is useful when you want to inject custom logic or configuration
  3245. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3246. //
  3247. //
  3248. // // Example sending a request using the ListBucketMetricsConfigurationsRequest method.
  3249. // req, resp := client.ListBucketMetricsConfigurationsRequest(params)
  3250. //
  3251. // err := req.Send()
  3252. // if err == nil { // resp is now filled
  3253. // fmt.Println(resp)
  3254. // }
  3255. //
  3256. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurations
  3257. func (c *S3) ListBucketMetricsConfigurationsRequest(input *ListBucketMetricsConfigurationsInput) (req *request.Request, output *ListBucketMetricsConfigurationsOutput) {
  3258. op := &request.Operation{
  3259. Name: opListBucketMetricsConfigurations,
  3260. HTTPMethod: "GET",
  3261. HTTPPath: "/{Bucket}?metrics",
  3262. }
  3263. if input == nil {
  3264. input = &ListBucketMetricsConfigurationsInput{}
  3265. }
  3266. output = &ListBucketMetricsConfigurationsOutput{}
  3267. req = c.newRequest(op, input, output)
  3268. return
  3269. }
  3270. // ListBucketMetricsConfigurations API operation for Amazon Simple Storage Service.
  3271. //
  3272. // Lists the metrics configurations for the bucket.
  3273. //
  3274. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3275. // with awserr.Error's Code and Message methods to get detailed information about
  3276. // the error.
  3277. //
  3278. // See the AWS API reference guide for Amazon Simple Storage Service's
  3279. // API operation ListBucketMetricsConfigurations for usage and error information.
  3280. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurations
  3281. func (c *S3) ListBucketMetricsConfigurations(input *ListBucketMetricsConfigurationsInput) (*ListBucketMetricsConfigurationsOutput, error) {
  3282. req, out := c.ListBucketMetricsConfigurationsRequest(input)
  3283. return out, req.Send()
  3284. }
  3285. // ListBucketMetricsConfigurationsWithContext is the same as ListBucketMetricsConfigurations with the addition of
  3286. // the ability to pass a context and additional request options.
  3287. //
  3288. // See ListBucketMetricsConfigurations for details on how to use this API operation.
  3289. //
  3290. // The context must be non-nil and will be used for request cancellation. If
  3291. // the context is nil a panic will occur. In the future the SDK may create
  3292. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3293. // for more information on using Contexts.
  3294. func (c *S3) ListBucketMetricsConfigurationsWithContext(ctx aws.Context, input *ListBucketMetricsConfigurationsInput, opts ...request.Option) (*ListBucketMetricsConfigurationsOutput, error) {
  3295. req, out := c.ListBucketMetricsConfigurationsRequest(input)
  3296. req.SetContext(ctx)
  3297. req.ApplyOptions(opts...)
  3298. return out, req.Send()
  3299. }
  3300. const opListBuckets = "ListBuckets"
  3301. // ListBucketsRequest generates a "aws/request.Request" representing the
  3302. // client's request for the ListBuckets operation. The "output" return
  3303. // value will be populated with the request's response once the request complets
  3304. // successfuly.
  3305. //
  3306. // Use "Send" method on the returned Request to send the API call to the service.
  3307. // the "output" return value is not valid until after Send returns without error.
  3308. //
  3309. // See ListBuckets for more information on using the ListBuckets
  3310. // API call, and error handling.
  3311. //
  3312. // This method is useful when you want to inject custom logic or configuration
  3313. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3314. //
  3315. //
  3316. // // Example sending a request using the ListBucketsRequest method.
  3317. // req, resp := client.ListBucketsRequest(params)
  3318. //
  3319. // err := req.Send()
  3320. // if err == nil { // resp is now filled
  3321. // fmt.Println(resp)
  3322. // }
  3323. //
  3324. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBuckets
  3325. func (c *S3) ListBucketsRequest(input *ListBucketsInput) (req *request.Request, output *ListBucketsOutput) {
  3326. op := &request.Operation{
  3327. Name: opListBuckets,
  3328. HTTPMethod: "GET",
  3329. HTTPPath: "/",
  3330. }
  3331. if input == nil {
  3332. input = &ListBucketsInput{}
  3333. }
  3334. output = &ListBucketsOutput{}
  3335. req = c.newRequest(op, input, output)
  3336. return
  3337. }
  3338. // ListBuckets API operation for Amazon Simple Storage Service.
  3339. //
  3340. // Returns a list of all buckets owned by the authenticated sender of the request.
  3341. //
  3342. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3343. // with awserr.Error's Code and Message methods to get detailed information about
  3344. // the error.
  3345. //
  3346. // See the AWS API reference guide for Amazon Simple Storage Service's
  3347. // API operation ListBuckets for usage and error information.
  3348. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBuckets
  3349. func (c *S3) ListBuckets(input *ListBucketsInput) (*ListBucketsOutput, error) {
  3350. req, out := c.ListBucketsRequest(input)
  3351. return out, req.Send()
  3352. }
  3353. // ListBucketsWithContext is the same as ListBuckets with the addition of
  3354. // the ability to pass a context and additional request options.
  3355. //
  3356. // See ListBuckets for details on how to use this API operation.
  3357. //
  3358. // The context must be non-nil and will be used for request cancellation. If
  3359. // the context is nil a panic will occur. In the future the SDK may create
  3360. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3361. // for more information on using Contexts.
  3362. func (c *S3) ListBucketsWithContext(ctx aws.Context, input *ListBucketsInput, opts ...request.Option) (*ListBucketsOutput, error) {
  3363. req, out := c.ListBucketsRequest(input)
  3364. req.SetContext(ctx)
  3365. req.ApplyOptions(opts...)
  3366. return out, req.Send()
  3367. }
  3368. const opListMultipartUploads = "ListMultipartUploads"
  3369. // ListMultipartUploadsRequest generates a "aws/request.Request" representing the
  3370. // client's request for the ListMultipartUploads operation. The "output" return
  3371. // value will be populated with the request's response once the request complets
  3372. // successfuly.
  3373. //
  3374. // Use "Send" method on the returned Request to send the API call to the service.
  3375. // the "output" return value is not valid until after Send returns without error.
  3376. //
  3377. // See ListMultipartUploads for more information on using the ListMultipartUploads
  3378. // API call, and error handling.
  3379. //
  3380. // This method is useful when you want to inject custom logic or configuration
  3381. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3382. //
  3383. //
  3384. // // Example sending a request using the ListMultipartUploadsRequest method.
  3385. // req, resp := client.ListMultipartUploadsRequest(params)
  3386. //
  3387. // err := req.Send()
  3388. // if err == nil { // resp is now filled
  3389. // fmt.Println(resp)
  3390. // }
  3391. //
  3392. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploads
  3393. func (c *S3) ListMultipartUploadsRequest(input *ListMultipartUploadsInput) (req *request.Request, output *ListMultipartUploadsOutput) {
  3394. op := &request.Operation{
  3395. Name: opListMultipartUploads,
  3396. HTTPMethod: "GET",
  3397. HTTPPath: "/{Bucket}?uploads",
  3398. Paginator: &request.Paginator{
  3399. InputTokens: []string{"KeyMarker", "UploadIdMarker"},
  3400. OutputTokens: []string{"NextKeyMarker", "NextUploadIdMarker"},
  3401. LimitToken: "MaxUploads",
  3402. TruncationToken: "IsTruncated",
  3403. },
  3404. }
  3405. if input == nil {
  3406. input = &ListMultipartUploadsInput{}
  3407. }
  3408. output = &ListMultipartUploadsOutput{}
  3409. req = c.newRequest(op, input, output)
  3410. return
  3411. }
  3412. // ListMultipartUploads API operation for Amazon Simple Storage Service.
  3413. //
  3414. // This operation lists in-progress multipart uploads.
  3415. //
  3416. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3417. // with awserr.Error's Code and Message methods to get detailed information about
  3418. // the error.
  3419. //
  3420. // See the AWS API reference guide for Amazon Simple Storage Service's
  3421. // API operation ListMultipartUploads for usage and error information.
  3422. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploads
  3423. func (c *S3) ListMultipartUploads(input *ListMultipartUploadsInput) (*ListMultipartUploadsOutput, error) {
  3424. req, out := c.ListMultipartUploadsRequest(input)
  3425. return out, req.Send()
  3426. }
  3427. // ListMultipartUploadsWithContext is the same as ListMultipartUploads with the addition of
  3428. // the ability to pass a context and additional request options.
  3429. //
  3430. // See ListMultipartUploads for details on how to use this API operation.
  3431. //
  3432. // The context must be non-nil and will be used for request cancellation. If
  3433. // the context is nil a panic will occur. In the future the SDK may create
  3434. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3435. // for more information on using Contexts.
  3436. func (c *S3) ListMultipartUploadsWithContext(ctx aws.Context, input *ListMultipartUploadsInput, opts ...request.Option) (*ListMultipartUploadsOutput, error) {
  3437. req, out := c.ListMultipartUploadsRequest(input)
  3438. req.SetContext(ctx)
  3439. req.ApplyOptions(opts...)
  3440. return out, req.Send()
  3441. }
  3442. // ListMultipartUploadsPages iterates over the pages of a ListMultipartUploads operation,
  3443. // calling the "fn" function with the response data for each page. To stop
  3444. // iterating, return false from the fn function.
  3445. //
  3446. // See ListMultipartUploads method for more information on how to use this operation.
  3447. //
  3448. // Note: This operation can generate multiple requests to a service.
  3449. //
  3450. // // Example iterating over at most 3 pages of a ListMultipartUploads operation.
  3451. // pageNum := 0
  3452. // err := client.ListMultipartUploadsPages(params,
  3453. // func(page *ListMultipartUploadsOutput, lastPage bool) bool {
  3454. // pageNum++
  3455. // fmt.Println(page)
  3456. // return pageNum <= 3
  3457. // })
  3458. //
  3459. func (c *S3) ListMultipartUploadsPages(input *ListMultipartUploadsInput, fn func(*ListMultipartUploadsOutput, bool) bool) error {
  3460. return c.ListMultipartUploadsPagesWithContext(aws.BackgroundContext(), input, fn)
  3461. }
  3462. // ListMultipartUploadsPagesWithContext same as ListMultipartUploadsPages except
  3463. // it takes a Context and allows setting request options on the pages.
  3464. //
  3465. // The context must be non-nil and will be used for request cancellation. If
  3466. // the context is nil a panic will occur. In the future the SDK may create
  3467. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3468. // for more information on using Contexts.
  3469. func (c *S3) ListMultipartUploadsPagesWithContext(ctx aws.Context, input *ListMultipartUploadsInput, fn func(*ListMultipartUploadsOutput, bool) bool, opts ...request.Option) error {
  3470. p := request.Pagination{
  3471. NewRequest: func() (*request.Request, error) {
  3472. var inCpy *ListMultipartUploadsInput
  3473. if input != nil {
  3474. tmp := *input
  3475. inCpy = &tmp
  3476. }
  3477. req, _ := c.ListMultipartUploadsRequest(inCpy)
  3478. req.SetContext(ctx)
  3479. req.ApplyOptions(opts...)
  3480. return req, nil
  3481. },
  3482. }
  3483. cont := true
  3484. for p.Next() && cont {
  3485. cont = fn(p.Page().(*ListMultipartUploadsOutput), !p.HasNextPage())
  3486. }
  3487. return p.Err()
  3488. }
  3489. const opListObjectVersions = "ListObjectVersions"
  3490. // ListObjectVersionsRequest generates a "aws/request.Request" representing the
  3491. // client's request for the ListObjectVersions operation. The "output" return
  3492. // value will be populated with the request's response once the request complets
  3493. // successfuly.
  3494. //
  3495. // Use "Send" method on the returned Request to send the API call to the service.
  3496. // the "output" return value is not valid until after Send returns without error.
  3497. //
  3498. // See ListObjectVersions for more information on using the ListObjectVersions
  3499. // API call, and error handling.
  3500. //
  3501. // This method is useful when you want to inject custom logic or configuration
  3502. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3503. //
  3504. //
  3505. // // Example sending a request using the ListObjectVersionsRequest method.
  3506. // req, resp := client.ListObjectVersionsRequest(params)
  3507. //
  3508. // err := req.Send()
  3509. // if err == nil { // resp is now filled
  3510. // fmt.Println(resp)
  3511. // }
  3512. //
  3513. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersions
  3514. func (c *S3) ListObjectVersionsRequest(input *ListObjectVersionsInput) (req *request.Request, output *ListObjectVersionsOutput) {
  3515. op := &request.Operation{
  3516. Name: opListObjectVersions,
  3517. HTTPMethod: "GET",
  3518. HTTPPath: "/{Bucket}?versions",
  3519. Paginator: &request.Paginator{
  3520. InputTokens: []string{"KeyMarker", "VersionIdMarker"},
  3521. OutputTokens: []string{"NextKeyMarker", "NextVersionIdMarker"},
  3522. LimitToken: "MaxKeys",
  3523. TruncationToken: "IsTruncated",
  3524. },
  3525. }
  3526. if input == nil {
  3527. input = &ListObjectVersionsInput{}
  3528. }
  3529. output = &ListObjectVersionsOutput{}
  3530. req = c.newRequest(op, input, output)
  3531. return
  3532. }
  3533. // ListObjectVersions API operation for Amazon Simple Storage Service.
  3534. //
  3535. // Returns metadata about all of the versions of objects in a bucket.
  3536. //
  3537. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3538. // with awserr.Error's Code and Message methods to get detailed information about
  3539. // the error.
  3540. //
  3541. // See the AWS API reference guide for Amazon Simple Storage Service's
  3542. // API operation ListObjectVersions for usage and error information.
  3543. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersions
  3544. func (c *S3) ListObjectVersions(input *ListObjectVersionsInput) (*ListObjectVersionsOutput, error) {
  3545. req, out := c.ListObjectVersionsRequest(input)
  3546. return out, req.Send()
  3547. }
  3548. // ListObjectVersionsWithContext is the same as ListObjectVersions with the addition of
  3549. // the ability to pass a context and additional request options.
  3550. //
  3551. // See ListObjectVersions for details on how to use this API operation.
  3552. //
  3553. // The context must be non-nil and will be used for request cancellation. If
  3554. // the context is nil a panic will occur. In the future the SDK may create
  3555. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3556. // for more information on using Contexts.
  3557. func (c *S3) ListObjectVersionsWithContext(ctx aws.Context, input *ListObjectVersionsInput, opts ...request.Option) (*ListObjectVersionsOutput, error) {
  3558. req, out := c.ListObjectVersionsRequest(input)
  3559. req.SetContext(ctx)
  3560. req.ApplyOptions(opts...)
  3561. return out, req.Send()
  3562. }
  3563. // ListObjectVersionsPages iterates over the pages of a ListObjectVersions operation,
  3564. // calling the "fn" function with the response data for each page. To stop
  3565. // iterating, return false from the fn function.
  3566. //
  3567. // See ListObjectVersions method for more information on how to use this operation.
  3568. //
  3569. // Note: This operation can generate multiple requests to a service.
  3570. //
  3571. // // Example iterating over at most 3 pages of a ListObjectVersions operation.
  3572. // pageNum := 0
  3573. // err := client.ListObjectVersionsPages(params,
  3574. // func(page *ListObjectVersionsOutput, lastPage bool) bool {
  3575. // pageNum++
  3576. // fmt.Println(page)
  3577. // return pageNum <= 3
  3578. // })
  3579. //
  3580. func (c *S3) ListObjectVersionsPages(input *ListObjectVersionsInput, fn func(*ListObjectVersionsOutput, bool) bool) error {
  3581. return c.ListObjectVersionsPagesWithContext(aws.BackgroundContext(), input, fn)
  3582. }
  3583. // ListObjectVersionsPagesWithContext same as ListObjectVersionsPages except
  3584. // it takes a Context and allows setting request options on the pages.
  3585. //
  3586. // The context must be non-nil and will be used for request cancellation. If
  3587. // the context is nil a panic will occur. In the future the SDK may create
  3588. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3589. // for more information on using Contexts.
  3590. func (c *S3) ListObjectVersionsPagesWithContext(ctx aws.Context, input *ListObjectVersionsInput, fn func(*ListObjectVersionsOutput, bool) bool, opts ...request.Option) error {
  3591. p := request.Pagination{
  3592. NewRequest: func() (*request.Request, error) {
  3593. var inCpy *ListObjectVersionsInput
  3594. if input != nil {
  3595. tmp := *input
  3596. inCpy = &tmp
  3597. }
  3598. req, _ := c.ListObjectVersionsRequest(inCpy)
  3599. req.SetContext(ctx)
  3600. req.ApplyOptions(opts...)
  3601. return req, nil
  3602. },
  3603. }
  3604. cont := true
  3605. for p.Next() && cont {
  3606. cont = fn(p.Page().(*ListObjectVersionsOutput), !p.HasNextPage())
  3607. }
  3608. return p.Err()
  3609. }
  3610. const opListObjects = "ListObjects"
  3611. // ListObjectsRequest generates a "aws/request.Request" representing the
  3612. // client's request for the ListObjects operation. The "output" return
  3613. // value will be populated with the request's response once the request complets
  3614. // successfuly.
  3615. //
  3616. // Use "Send" method on the returned Request to send the API call to the service.
  3617. // the "output" return value is not valid until after Send returns without error.
  3618. //
  3619. // See ListObjects for more information on using the ListObjects
  3620. // API call, and error handling.
  3621. //
  3622. // This method is useful when you want to inject custom logic or configuration
  3623. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3624. //
  3625. //
  3626. // // Example sending a request using the ListObjectsRequest method.
  3627. // req, resp := client.ListObjectsRequest(params)
  3628. //
  3629. // err := req.Send()
  3630. // if err == nil { // resp is now filled
  3631. // fmt.Println(resp)
  3632. // }
  3633. //
  3634. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjects
  3635. func (c *S3) ListObjectsRequest(input *ListObjectsInput) (req *request.Request, output *ListObjectsOutput) {
  3636. op := &request.Operation{
  3637. Name: opListObjects,
  3638. HTTPMethod: "GET",
  3639. HTTPPath: "/{Bucket}",
  3640. Paginator: &request.Paginator{
  3641. InputTokens: []string{"Marker"},
  3642. OutputTokens: []string{"NextMarker || Contents[-1].Key"},
  3643. LimitToken: "MaxKeys",
  3644. TruncationToken: "IsTruncated",
  3645. },
  3646. }
  3647. if input == nil {
  3648. input = &ListObjectsInput{}
  3649. }
  3650. output = &ListObjectsOutput{}
  3651. req = c.newRequest(op, input, output)
  3652. return
  3653. }
  3654. // ListObjects API operation for Amazon Simple Storage Service.
  3655. //
  3656. // Returns some or all (up to 1000) of the objects in a bucket. You can use
  3657. // the request parameters as selection criteria to return a subset of the objects
  3658. // in a bucket.
  3659. //
  3660. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3661. // with awserr.Error's Code and Message methods to get detailed information about
  3662. // the error.
  3663. //
  3664. // See the AWS API reference guide for Amazon Simple Storage Service's
  3665. // API operation ListObjects for usage and error information.
  3666. //
  3667. // Returned Error Codes:
  3668. // * ErrCodeNoSuchBucket "NoSuchBucket"
  3669. // The specified bucket does not exist.
  3670. //
  3671. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjects
  3672. func (c *S3) ListObjects(input *ListObjectsInput) (*ListObjectsOutput, error) {
  3673. req, out := c.ListObjectsRequest(input)
  3674. return out, req.Send()
  3675. }
  3676. // ListObjectsWithContext is the same as ListObjects with the addition of
  3677. // the ability to pass a context and additional request options.
  3678. //
  3679. // See ListObjects for details on how to use this API operation.
  3680. //
  3681. // The context must be non-nil and will be used for request cancellation. If
  3682. // the context is nil a panic will occur. In the future the SDK may create
  3683. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3684. // for more information on using Contexts.
  3685. func (c *S3) ListObjectsWithContext(ctx aws.Context, input *ListObjectsInput, opts ...request.Option) (*ListObjectsOutput, error) {
  3686. req, out := c.ListObjectsRequest(input)
  3687. req.SetContext(ctx)
  3688. req.ApplyOptions(opts...)
  3689. return out, req.Send()
  3690. }
  3691. // ListObjectsPages iterates over the pages of a ListObjects operation,
  3692. // calling the "fn" function with the response data for each page. To stop
  3693. // iterating, return false from the fn function.
  3694. //
  3695. // See ListObjects method for more information on how to use this operation.
  3696. //
  3697. // Note: This operation can generate multiple requests to a service.
  3698. //
  3699. // // Example iterating over at most 3 pages of a ListObjects operation.
  3700. // pageNum := 0
  3701. // err := client.ListObjectsPages(params,
  3702. // func(page *ListObjectsOutput, lastPage bool) bool {
  3703. // pageNum++
  3704. // fmt.Println(page)
  3705. // return pageNum <= 3
  3706. // })
  3707. //
  3708. func (c *S3) ListObjectsPages(input *ListObjectsInput, fn func(*ListObjectsOutput, bool) bool) error {
  3709. return c.ListObjectsPagesWithContext(aws.BackgroundContext(), input, fn)
  3710. }
  3711. // ListObjectsPagesWithContext same as ListObjectsPages except
  3712. // it takes a Context and allows setting request options on the pages.
  3713. //
  3714. // The context must be non-nil and will be used for request cancellation. If
  3715. // the context is nil a panic will occur. In the future the SDK may create
  3716. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3717. // for more information on using Contexts.
  3718. func (c *S3) ListObjectsPagesWithContext(ctx aws.Context, input *ListObjectsInput, fn func(*ListObjectsOutput, bool) bool, opts ...request.Option) error {
  3719. p := request.Pagination{
  3720. NewRequest: func() (*request.Request, error) {
  3721. var inCpy *ListObjectsInput
  3722. if input != nil {
  3723. tmp := *input
  3724. inCpy = &tmp
  3725. }
  3726. req, _ := c.ListObjectsRequest(inCpy)
  3727. req.SetContext(ctx)
  3728. req.ApplyOptions(opts...)
  3729. return req, nil
  3730. },
  3731. }
  3732. cont := true
  3733. for p.Next() && cont {
  3734. cont = fn(p.Page().(*ListObjectsOutput), !p.HasNextPage())
  3735. }
  3736. return p.Err()
  3737. }
  3738. const opListObjectsV2 = "ListObjectsV2"
  3739. // ListObjectsV2Request generates a "aws/request.Request" representing the
  3740. // client's request for the ListObjectsV2 operation. The "output" return
  3741. // value will be populated with the request's response once the request complets
  3742. // successfuly.
  3743. //
  3744. // Use "Send" method on the returned Request to send the API call to the service.
  3745. // the "output" return value is not valid until after Send returns without error.
  3746. //
  3747. // See ListObjectsV2 for more information on using the ListObjectsV2
  3748. // API call, and error handling.
  3749. //
  3750. // This method is useful when you want to inject custom logic or configuration
  3751. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3752. //
  3753. //
  3754. // // Example sending a request using the ListObjectsV2Request method.
  3755. // req, resp := client.ListObjectsV2Request(params)
  3756. //
  3757. // err := req.Send()
  3758. // if err == nil { // resp is now filled
  3759. // fmt.Println(resp)
  3760. // }
  3761. //
  3762. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2
  3763. func (c *S3) ListObjectsV2Request(input *ListObjectsV2Input) (req *request.Request, output *ListObjectsV2Output) {
  3764. op := &request.Operation{
  3765. Name: opListObjectsV2,
  3766. HTTPMethod: "GET",
  3767. HTTPPath: "/{Bucket}?list-type=2",
  3768. Paginator: &request.Paginator{
  3769. InputTokens: []string{"ContinuationToken"},
  3770. OutputTokens: []string{"NextContinuationToken"},
  3771. LimitToken: "MaxKeys",
  3772. TruncationToken: "",
  3773. },
  3774. }
  3775. if input == nil {
  3776. input = &ListObjectsV2Input{}
  3777. }
  3778. output = &ListObjectsV2Output{}
  3779. req = c.newRequest(op, input, output)
  3780. return
  3781. }
  3782. // ListObjectsV2 API operation for Amazon Simple Storage Service.
  3783. //
  3784. // Returns some or all (up to 1000) of the objects in a bucket. You can use
  3785. // the request parameters as selection criteria to return a subset of the objects
  3786. // in a bucket. Note: ListObjectsV2 is the revised List Objects API and we recommend
  3787. // you use this revised API for new application development.
  3788. //
  3789. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3790. // with awserr.Error's Code and Message methods to get detailed information about
  3791. // the error.
  3792. //
  3793. // See the AWS API reference guide for Amazon Simple Storage Service's
  3794. // API operation ListObjectsV2 for usage and error information.
  3795. //
  3796. // Returned Error Codes:
  3797. // * ErrCodeNoSuchBucket "NoSuchBucket"
  3798. // The specified bucket does not exist.
  3799. //
  3800. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2
  3801. func (c *S3) ListObjectsV2(input *ListObjectsV2Input) (*ListObjectsV2Output, error) {
  3802. req, out := c.ListObjectsV2Request(input)
  3803. return out, req.Send()
  3804. }
  3805. // ListObjectsV2WithContext is the same as ListObjectsV2 with the addition of
  3806. // the ability to pass a context and additional request options.
  3807. //
  3808. // See ListObjectsV2 for details on how to use this API operation.
  3809. //
  3810. // The context must be non-nil and will be used for request cancellation. If
  3811. // the context is nil a panic will occur. In the future the SDK may create
  3812. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3813. // for more information on using Contexts.
  3814. func (c *S3) ListObjectsV2WithContext(ctx aws.Context, input *ListObjectsV2Input, opts ...request.Option) (*ListObjectsV2Output, error) {
  3815. req, out := c.ListObjectsV2Request(input)
  3816. req.SetContext(ctx)
  3817. req.ApplyOptions(opts...)
  3818. return out, req.Send()
  3819. }
  3820. // ListObjectsV2Pages iterates over the pages of a ListObjectsV2 operation,
  3821. // calling the "fn" function with the response data for each page. To stop
  3822. // iterating, return false from the fn function.
  3823. //
  3824. // See ListObjectsV2 method for more information on how to use this operation.
  3825. //
  3826. // Note: This operation can generate multiple requests to a service.
  3827. //
  3828. // // Example iterating over at most 3 pages of a ListObjectsV2 operation.
  3829. // pageNum := 0
  3830. // err := client.ListObjectsV2Pages(params,
  3831. // func(page *ListObjectsV2Output, lastPage bool) bool {
  3832. // pageNum++
  3833. // fmt.Println(page)
  3834. // return pageNum <= 3
  3835. // })
  3836. //
  3837. func (c *S3) ListObjectsV2Pages(input *ListObjectsV2Input, fn func(*ListObjectsV2Output, bool) bool) error {
  3838. return c.ListObjectsV2PagesWithContext(aws.BackgroundContext(), input, fn)
  3839. }
  3840. // ListObjectsV2PagesWithContext same as ListObjectsV2Pages except
  3841. // it takes a Context and allows setting request options on the pages.
  3842. //
  3843. // The context must be non-nil and will be used for request cancellation. If
  3844. // the context is nil a panic will occur. In the future the SDK may create
  3845. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3846. // for more information on using Contexts.
  3847. func (c *S3) ListObjectsV2PagesWithContext(ctx aws.Context, input *ListObjectsV2Input, fn func(*ListObjectsV2Output, bool) bool, opts ...request.Option) error {
  3848. p := request.Pagination{
  3849. NewRequest: func() (*request.Request, error) {
  3850. var inCpy *ListObjectsV2Input
  3851. if input != nil {
  3852. tmp := *input
  3853. inCpy = &tmp
  3854. }
  3855. req, _ := c.ListObjectsV2Request(inCpy)
  3856. req.SetContext(ctx)
  3857. req.ApplyOptions(opts...)
  3858. return req, nil
  3859. },
  3860. }
  3861. cont := true
  3862. for p.Next() && cont {
  3863. cont = fn(p.Page().(*ListObjectsV2Output), !p.HasNextPage())
  3864. }
  3865. return p.Err()
  3866. }
  3867. const opListParts = "ListParts"
  3868. // ListPartsRequest generates a "aws/request.Request" representing the
  3869. // client's request for the ListParts operation. The "output" return
  3870. // value will be populated with the request's response once the request complets
  3871. // successfuly.
  3872. //
  3873. // Use "Send" method on the returned Request to send the API call to the service.
  3874. // the "output" return value is not valid until after Send returns without error.
  3875. //
  3876. // See ListParts for more information on using the ListParts
  3877. // API call, and error handling.
  3878. //
  3879. // This method is useful when you want to inject custom logic or configuration
  3880. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  3881. //
  3882. //
  3883. // // Example sending a request using the ListPartsRequest method.
  3884. // req, resp := client.ListPartsRequest(params)
  3885. //
  3886. // err := req.Send()
  3887. // if err == nil { // resp is now filled
  3888. // fmt.Println(resp)
  3889. // }
  3890. //
  3891. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListParts
  3892. func (c *S3) ListPartsRequest(input *ListPartsInput) (req *request.Request, output *ListPartsOutput) {
  3893. op := &request.Operation{
  3894. Name: opListParts,
  3895. HTTPMethod: "GET",
  3896. HTTPPath: "/{Bucket}/{Key+}",
  3897. Paginator: &request.Paginator{
  3898. InputTokens: []string{"PartNumberMarker"},
  3899. OutputTokens: []string{"NextPartNumberMarker"},
  3900. LimitToken: "MaxParts",
  3901. TruncationToken: "IsTruncated",
  3902. },
  3903. }
  3904. if input == nil {
  3905. input = &ListPartsInput{}
  3906. }
  3907. output = &ListPartsOutput{}
  3908. req = c.newRequest(op, input, output)
  3909. return
  3910. }
  3911. // ListParts API operation for Amazon Simple Storage Service.
  3912. //
  3913. // Lists the parts that have been uploaded for a specific multipart upload.
  3914. //
  3915. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  3916. // with awserr.Error's Code and Message methods to get detailed information about
  3917. // the error.
  3918. //
  3919. // See the AWS API reference guide for Amazon Simple Storage Service's
  3920. // API operation ListParts for usage and error information.
  3921. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListParts
  3922. func (c *S3) ListParts(input *ListPartsInput) (*ListPartsOutput, error) {
  3923. req, out := c.ListPartsRequest(input)
  3924. return out, req.Send()
  3925. }
  3926. // ListPartsWithContext is the same as ListParts with the addition of
  3927. // the ability to pass a context and additional request options.
  3928. //
  3929. // See ListParts for details on how to use this API operation.
  3930. //
  3931. // The context must be non-nil and will be used for request cancellation. If
  3932. // the context is nil a panic will occur. In the future the SDK may create
  3933. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3934. // for more information on using Contexts.
  3935. func (c *S3) ListPartsWithContext(ctx aws.Context, input *ListPartsInput, opts ...request.Option) (*ListPartsOutput, error) {
  3936. req, out := c.ListPartsRequest(input)
  3937. req.SetContext(ctx)
  3938. req.ApplyOptions(opts...)
  3939. return out, req.Send()
  3940. }
  3941. // ListPartsPages iterates over the pages of a ListParts operation,
  3942. // calling the "fn" function with the response data for each page. To stop
  3943. // iterating, return false from the fn function.
  3944. //
  3945. // See ListParts method for more information on how to use this operation.
  3946. //
  3947. // Note: This operation can generate multiple requests to a service.
  3948. //
  3949. // // Example iterating over at most 3 pages of a ListParts operation.
  3950. // pageNum := 0
  3951. // err := client.ListPartsPages(params,
  3952. // func(page *ListPartsOutput, lastPage bool) bool {
  3953. // pageNum++
  3954. // fmt.Println(page)
  3955. // return pageNum <= 3
  3956. // })
  3957. //
  3958. func (c *S3) ListPartsPages(input *ListPartsInput, fn func(*ListPartsOutput, bool) bool) error {
  3959. return c.ListPartsPagesWithContext(aws.BackgroundContext(), input, fn)
  3960. }
  3961. // ListPartsPagesWithContext same as ListPartsPages except
  3962. // it takes a Context and allows setting request options on the pages.
  3963. //
  3964. // The context must be non-nil and will be used for request cancellation. If
  3965. // the context is nil a panic will occur. In the future the SDK may create
  3966. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  3967. // for more information on using Contexts.
  3968. func (c *S3) ListPartsPagesWithContext(ctx aws.Context, input *ListPartsInput, fn func(*ListPartsOutput, bool) bool, opts ...request.Option) error {
  3969. p := request.Pagination{
  3970. NewRequest: func() (*request.Request, error) {
  3971. var inCpy *ListPartsInput
  3972. if input != nil {
  3973. tmp := *input
  3974. inCpy = &tmp
  3975. }
  3976. req, _ := c.ListPartsRequest(inCpy)
  3977. req.SetContext(ctx)
  3978. req.ApplyOptions(opts...)
  3979. return req, nil
  3980. },
  3981. }
  3982. cont := true
  3983. for p.Next() && cont {
  3984. cont = fn(p.Page().(*ListPartsOutput), !p.HasNextPage())
  3985. }
  3986. return p.Err()
  3987. }
  3988. const opPutBucketAccelerateConfiguration = "PutBucketAccelerateConfiguration"
  3989. // PutBucketAccelerateConfigurationRequest generates a "aws/request.Request" representing the
  3990. // client's request for the PutBucketAccelerateConfiguration operation. The "output" return
  3991. // value will be populated with the request's response once the request complets
  3992. // successfuly.
  3993. //
  3994. // Use "Send" method on the returned Request to send the API call to the service.
  3995. // the "output" return value is not valid until after Send returns without error.
  3996. //
  3997. // See PutBucketAccelerateConfiguration for more information on using the PutBucketAccelerateConfiguration
  3998. // API call, and error handling.
  3999. //
  4000. // This method is useful when you want to inject custom logic or configuration
  4001. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4002. //
  4003. //
  4004. // // Example sending a request using the PutBucketAccelerateConfigurationRequest method.
  4005. // req, resp := client.PutBucketAccelerateConfigurationRequest(params)
  4006. //
  4007. // err := req.Send()
  4008. // if err == nil { // resp is now filled
  4009. // fmt.Println(resp)
  4010. // }
  4011. //
  4012. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfiguration
  4013. func (c *S3) PutBucketAccelerateConfigurationRequest(input *PutBucketAccelerateConfigurationInput) (req *request.Request, output *PutBucketAccelerateConfigurationOutput) {
  4014. op := &request.Operation{
  4015. Name: opPutBucketAccelerateConfiguration,
  4016. HTTPMethod: "PUT",
  4017. HTTPPath: "/{Bucket}?accelerate",
  4018. }
  4019. if input == nil {
  4020. input = &PutBucketAccelerateConfigurationInput{}
  4021. }
  4022. output = &PutBucketAccelerateConfigurationOutput{}
  4023. req = c.newRequest(op, input, output)
  4024. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4025. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4026. return
  4027. }
  4028. // PutBucketAccelerateConfiguration API operation for Amazon Simple Storage Service.
  4029. //
  4030. // Sets the accelerate configuration of an existing bucket.
  4031. //
  4032. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4033. // with awserr.Error's Code and Message methods to get detailed information about
  4034. // the error.
  4035. //
  4036. // See the AWS API reference guide for Amazon Simple Storage Service's
  4037. // API operation PutBucketAccelerateConfiguration for usage and error information.
  4038. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfiguration
  4039. func (c *S3) PutBucketAccelerateConfiguration(input *PutBucketAccelerateConfigurationInput) (*PutBucketAccelerateConfigurationOutput, error) {
  4040. req, out := c.PutBucketAccelerateConfigurationRequest(input)
  4041. return out, req.Send()
  4042. }
  4043. // PutBucketAccelerateConfigurationWithContext is the same as PutBucketAccelerateConfiguration with the addition of
  4044. // the ability to pass a context and additional request options.
  4045. //
  4046. // See PutBucketAccelerateConfiguration for details on how to use this API operation.
  4047. //
  4048. // The context must be non-nil and will be used for request cancellation. If
  4049. // the context is nil a panic will occur. In the future the SDK may create
  4050. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4051. // for more information on using Contexts.
  4052. func (c *S3) PutBucketAccelerateConfigurationWithContext(ctx aws.Context, input *PutBucketAccelerateConfigurationInput, opts ...request.Option) (*PutBucketAccelerateConfigurationOutput, error) {
  4053. req, out := c.PutBucketAccelerateConfigurationRequest(input)
  4054. req.SetContext(ctx)
  4055. req.ApplyOptions(opts...)
  4056. return out, req.Send()
  4057. }
  4058. const opPutBucketAcl = "PutBucketAcl"
  4059. // PutBucketAclRequest generates a "aws/request.Request" representing the
  4060. // client's request for the PutBucketAcl operation. The "output" return
  4061. // value will be populated with the request's response once the request complets
  4062. // successfuly.
  4063. //
  4064. // Use "Send" method on the returned Request to send the API call to the service.
  4065. // the "output" return value is not valid until after Send returns without error.
  4066. //
  4067. // See PutBucketAcl for more information on using the PutBucketAcl
  4068. // API call, and error handling.
  4069. //
  4070. // This method is useful when you want to inject custom logic or configuration
  4071. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4072. //
  4073. //
  4074. // // Example sending a request using the PutBucketAclRequest method.
  4075. // req, resp := client.PutBucketAclRequest(params)
  4076. //
  4077. // err := req.Send()
  4078. // if err == nil { // resp is now filled
  4079. // fmt.Println(resp)
  4080. // }
  4081. //
  4082. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAcl
  4083. func (c *S3) PutBucketAclRequest(input *PutBucketAclInput) (req *request.Request, output *PutBucketAclOutput) {
  4084. op := &request.Operation{
  4085. Name: opPutBucketAcl,
  4086. HTTPMethod: "PUT",
  4087. HTTPPath: "/{Bucket}?acl",
  4088. }
  4089. if input == nil {
  4090. input = &PutBucketAclInput{}
  4091. }
  4092. output = &PutBucketAclOutput{}
  4093. req = c.newRequest(op, input, output)
  4094. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4095. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4096. return
  4097. }
  4098. // PutBucketAcl API operation for Amazon Simple Storage Service.
  4099. //
  4100. // Sets the permissions on a bucket using access control lists (ACL).
  4101. //
  4102. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4103. // with awserr.Error's Code and Message methods to get detailed information about
  4104. // the error.
  4105. //
  4106. // See the AWS API reference guide for Amazon Simple Storage Service's
  4107. // API operation PutBucketAcl for usage and error information.
  4108. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAcl
  4109. func (c *S3) PutBucketAcl(input *PutBucketAclInput) (*PutBucketAclOutput, error) {
  4110. req, out := c.PutBucketAclRequest(input)
  4111. return out, req.Send()
  4112. }
  4113. // PutBucketAclWithContext is the same as PutBucketAcl with the addition of
  4114. // the ability to pass a context and additional request options.
  4115. //
  4116. // See PutBucketAcl for details on how to use this API operation.
  4117. //
  4118. // The context must be non-nil and will be used for request cancellation. If
  4119. // the context is nil a panic will occur. In the future the SDK may create
  4120. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4121. // for more information on using Contexts.
  4122. func (c *S3) PutBucketAclWithContext(ctx aws.Context, input *PutBucketAclInput, opts ...request.Option) (*PutBucketAclOutput, error) {
  4123. req, out := c.PutBucketAclRequest(input)
  4124. req.SetContext(ctx)
  4125. req.ApplyOptions(opts...)
  4126. return out, req.Send()
  4127. }
  4128. const opPutBucketAnalyticsConfiguration = "PutBucketAnalyticsConfiguration"
  4129. // PutBucketAnalyticsConfigurationRequest generates a "aws/request.Request" representing the
  4130. // client's request for the PutBucketAnalyticsConfiguration operation. The "output" return
  4131. // value will be populated with the request's response once the request complets
  4132. // successfuly.
  4133. //
  4134. // Use "Send" method on the returned Request to send the API call to the service.
  4135. // the "output" return value is not valid until after Send returns without error.
  4136. //
  4137. // See PutBucketAnalyticsConfiguration for more information on using the PutBucketAnalyticsConfiguration
  4138. // API call, and error handling.
  4139. //
  4140. // This method is useful when you want to inject custom logic or configuration
  4141. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4142. //
  4143. //
  4144. // // Example sending a request using the PutBucketAnalyticsConfigurationRequest method.
  4145. // req, resp := client.PutBucketAnalyticsConfigurationRequest(params)
  4146. //
  4147. // err := req.Send()
  4148. // if err == nil { // resp is now filled
  4149. // fmt.Println(resp)
  4150. // }
  4151. //
  4152. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfiguration
  4153. func (c *S3) PutBucketAnalyticsConfigurationRequest(input *PutBucketAnalyticsConfigurationInput) (req *request.Request, output *PutBucketAnalyticsConfigurationOutput) {
  4154. op := &request.Operation{
  4155. Name: opPutBucketAnalyticsConfiguration,
  4156. HTTPMethod: "PUT",
  4157. HTTPPath: "/{Bucket}?analytics",
  4158. }
  4159. if input == nil {
  4160. input = &PutBucketAnalyticsConfigurationInput{}
  4161. }
  4162. output = &PutBucketAnalyticsConfigurationOutput{}
  4163. req = c.newRequest(op, input, output)
  4164. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4165. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4166. return
  4167. }
  4168. // PutBucketAnalyticsConfiguration API operation for Amazon Simple Storage Service.
  4169. //
  4170. // Sets an analytics configuration for the bucket (specified by the analytics
  4171. // configuration ID).
  4172. //
  4173. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4174. // with awserr.Error's Code and Message methods to get detailed information about
  4175. // the error.
  4176. //
  4177. // See the AWS API reference guide for Amazon Simple Storage Service's
  4178. // API operation PutBucketAnalyticsConfiguration for usage and error information.
  4179. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfiguration
  4180. func (c *S3) PutBucketAnalyticsConfiguration(input *PutBucketAnalyticsConfigurationInput) (*PutBucketAnalyticsConfigurationOutput, error) {
  4181. req, out := c.PutBucketAnalyticsConfigurationRequest(input)
  4182. return out, req.Send()
  4183. }
  4184. // PutBucketAnalyticsConfigurationWithContext is the same as PutBucketAnalyticsConfiguration with the addition of
  4185. // the ability to pass a context and additional request options.
  4186. //
  4187. // See PutBucketAnalyticsConfiguration for details on how to use this API operation.
  4188. //
  4189. // The context must be non-nil and will be used for request cancellation. If
  4190. // the context is nil a panic will occur. In the future the SDK may create
  4191. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4192. // for more information on using Contexts.
  4193. func (c *S3) PutBucketAnalyticsConfigurationWithContext(ctx aws.Context, input *PutBucketAnalyticsConfigurationInput, opts ...request.Option) (*PutBucketAnalyticsConfigurationOutput, error) {
  4194. req, out := c.PutBucketAnalyticsConfigurationRequest(input)
  4195. req.SetContext(ctx)
  4196. req.ApplyOptions(opts...)
  4197. return out, req.Send()
  4198. }
  4199. const opPutBucketCors = "PutBucketCors"
  4200. // PutBucketCorsRequest generates a "aws/request.Request" representing the
  4201. // client's request for the PutBucketCors operation. The "output" return
  4202. // value will be populated with the request's response once the request complets
  4203. // successfuly.
  4204. //
  4205. // Use "Send" method on the returned Request to send the API call to the service.
  4206. // the "output" return value is not valid until after Send returns without error.
  4207. //
  4208. // See PutBucketCors for more information on using the PutBucketCors
  4209. // API call, and error handling.
  4210. //
  4211. // This method is useful when you want to inject custom logic or configuration
  4212. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4213. //
  4214. //
  4215. // // Example sending a request using the PutBucketCorsRequest method.
  4216. // req, resp := client.PutBucketCorsRequest(params)
  4217. //
  4218. // err := req.Send()
  4219. // if err == nil { // resp is now filled
  4220. // fmt.Println(resp)
  4221. // }
  4222. //
  4223. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCors
  4224. func (c *S3) PutBucketCorsRequest(input *PutBucketCorsInput) (req *request.Request, output *PutBucketCorsOutput) {
  4225. op := &request.Operation{
  4226. Name: opPutBucketCors,
  4227. HTTPMethod: "PUT",
  4228. HTTPPath: "/{Bucket}?cors",
  4229. }
  4230. if input == nil {
  4231. input = &PutBucketCorsInput{}
  4232. }
  4233. output = &PutBucketCorsOutput{}
  4234. req = c.newRequest(op, input, output)
  4235. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4236. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4237. return
  4238. }
  4239. // PutBucketCors API operation for Amazon Simple Storage Service.
  4240. //
  4241. // Sets the cors configuration for a bucket.
  4242. //
  4243. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4244. // with awserr.Error's Code and Message methods to get detailed information about
  4245. // the error.
  4246. //
  4247. // See the AWS API reference guide for Amazon Simple Storage Service's
  4248. // API operation PutBucketCors for usage and error information.
  4249. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCors
  4250. func (c *S3) PutBucketCors(input *PutBucketCorsInput) (*PutBucketCorsOutput, error) {
  4251. req, out := c.PutBucketCorsRequest(input)
  4252. return out, req.Send()
  4253. }
  4254. // PutBucketCorsWithContext is the same as PutBucketCors with the addition of
  4255. // the ability to pass a context and additional request options.
  4256. //
  4257. // See PutBucketCors for details on how to use this API operation.
  4258. //
  4259. // The context must be non-nil and will be used for request cancellation. If
  4260. // the context is nil a panic will occur. In the future the SDK may create
  4261. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4262. // for more information on using Contexts.
  4263. func (c *S3) PutBucketCorsWithContext(ctx aws.Context, input *PutBucketCorsInput, opts ...request.Option) (*PutBucketCorsOutput, error) {
  4264. req, out := c.PutBucketCorsRequest(input)
  4265. req.SetContext(ctx)
  4266. req.ApplyOptions(opts...)
  4267. return out, req.Send()
  4268. }
  4269. const opPutBucketEncryption = "PutBucketEncryption"
  4270. // PutBucketEncryptionRequest generates a "aws/request.Request" representing the
  4271. // client's request for the PutBucketEncryption operation. The "output" return
  4272. // value will be populated with the request's response once the request complets
  4273. // successfuly.
  4274. //
  4275. // Use "Send" method on the returned Request to send the API call to the service.
  4276. // the "output" return value is not valid until after Send returns without error.
  4277. //
  4278. // See PutBucketEncryption for more information on using the PutBucketEncryption
  4279. // API call, and error handling.
  4280. //
  4281. // This method is useful when you want to inject custom logic or configuration
  4282. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4283. //
  4284. //
  4285. // // Example sending a request using the PutBucketEncryptionRequest method.
  4286. // req, resp := client.PutBucketEncryptionRequest(params)
  4287. //
  4288. // err := req.Send()
  4289. // if err == nil { // resp is now filled
  4290. // fmt.Println(resp)
  4291. // }
  4292. //
  4293. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryption
  4294. func (c *S3) PutBucketEncryptionRequest(input *PutBucketEncryptionInput) (req *request.Request, output *PutBucketEncryptionOutput) {
  4295. op := &request.Operation{
  4296. Name: opPutBucketEncryption,
  4297. HTTPMethod: "PUT",
  4298. HTTPPath: "/{Bucket}?encryption",
  4299. }
  4300. if input == nil {
  4301. input = &PutBucketEncryptionInput{}
  4302. }
  4303. output = &PutBucketEncryptionOutput{}
  4304. req = c.newRequest(op, input, output)
  4305. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4306. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4307. return
  4308. }
  4309. // PutBucketEncryption API operation for Amazon Simple Storage Service.
  4310. //
  4311. // Creates a new server-side encryption configuration (or replaces an existing
  4312. // one, if present).
  4313. //
  4314. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4315. // with awserr.Error's Code and Message methods to get detailed information about
  4316. // the error.
  4317. //
  4318. // See the AWS API reference guide for Amazon Simple Storage Service's
  4319. // API operation PutBucketEncryption for usage and error information.
  4320. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryption
  4321. func (c *S3) PutBucketEncryption(input *PutBucketEncryptionInput) (*PutBucketEncryptionOutput, error) {
  4322. req, out := c.PutBucketEncryptionRequest(input)
  4323. return out, req.Send()
  4324. }
  4325. // PutBucketEncryptionWithContext is the same as PutBucketEncryption with the addition of
  4326. // the ability to pass a context and additional request options.
  4327. //
  4328. // See PutBucketEncryption for details on how to use this API operation.
  4329. //
  4330. // The context must be non-nil and will be used for request cancellation. If
  4331. // the context is nil a panic will occur. In the future the SDK may create
  4332. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4333. // for more information on using Contexts.
  4334. func (c *S3) PutBucketEncryptionWithContext(ctx aws.Context, input *PutBucketEncryptionInput, opts ...request.Option) (*PutBucketEncryptionOutput, error) {
  4335. req, out := c.PutBucketEncryptionRequest(input)
  4336. req.SetContext(ctx)
  4337. req.ApplyOptions(opts...)
  4338. return out, req.Send()
  4339. }
  4340. const opPutBucketInventoryConfiguration = "PutBucketInventoryConfiguration"
  4341. // PutBucketInventoryConfigurationRequest generates a "aws/request.Request" representing the
  4342. // client's request for the PutBucketInventoryConfiguration operation. The "output" return
  4343. // value will be populated with the request's response once the request complets
  4344. // successfuly.
  4345. //
  4346. // Use "Send" method on the returned Request to send the API call to the service.
  4347. // the "output" return value is not valid until after Send returns without error.
  4348. //
  4349. // See PutBucketInventoryConfiguration for more information on using the PutBucketInventoryConfiguration
  4350. // API call, and error handling.
  4351. //
  4352. // This method is useful when you want to inject custom logic or configuration
  4353. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4354. //
  4355. //
  4356. // // Example sending a request using the PutBucketInventoryConfigurationRequest method.
  4357. // req, resp := client.PutBucketInventoryConfigurationRequest(params)
  4358. //
  4359. // err := req.Send()
  4360. // if err == nil { // resp is now filled
  4361. // fmt.Println(resp)
  4362. // }
  4363. //
  4364. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfiguration
  4365. func (c *S3) PutBucketInventoryConfigurationRequest(input *PutBucketInventoryConfigurationInput) (req *request.Request, output *PutBucketInventoryConfigurationOutput) {
  4366. op := &request.Operation{
  4367. Name: opPutBucketInventoryConfiguration,
  4368. HTTPMethod: "PUT",
  4369. HTTPPath: "/{Bucket}?inventory",
  4370. }
  4371. if input == nil {
  4372. input = &PutBucketInventoryConfigurationInput{}
  4373. }
  4374. output = &PutBucketInventoryConfigurationOutput{}
  4375. req = c.newRequest(op, input, output)
  4376. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4377. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4378. return
  4379. }
  4380. // PutBucketInventoryConfiguration API operation for Amazon Simple Storage Service.
  4381. //
  4382. // Adds an inventory configuration (identified by the inventory ID) from the
  4383. // bucket.
  4384. //
  4385. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4386. // with awserr.Error's Code and Message methods to get detailed information about
  4387. // the error.
  4388. //
  4389. // See the AWS API reference guide for Amazon Simple Storage Service's
  4390. // API operation PutBucketInventoryConfiguration for usage and error information.
  4391. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfiguration
  4392. func (c *S3) PutBucketInventoryConfiguration(input *PutBucketInventoryConfigurationInput) (*PutBucketInventoryConfigurationOutput, error) {
  4393. req, out := c.PutBucketInventoryConfigurationRequest(input)
  4394. return out, req.Send()
  4395. }
  4396. // PutBucketInventoryConfigurationWithContext is the same as PutBucketInventoryConfiguration with the addition of
  4397. // the ability to pass a context and additional request options.
  4398. //
  4399. // See PutBucketInventoryConfiguration for details on how to use this API operation.
  4400. //
  4401. // The context must be non-nil and will be used for request cancellation. If
  4402. // the context is nil a panic will occur. In the future the SDK may create
  4403. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4404. // for more information on using Contexts.
  4405. func (c *S3) PutBucketInventoryConfigurationWithContext(ctx aws.Context, input *PutBucketInventoryConfigurationInput, opts ...request.Option) (*PutBucketInventoryConfigurationOutput, error) {
  4406. req, out := c.PutBucketInventoryConfigurationRequest(input)
  4407. req.SetContext(ctx)
  4408. req.ApplyOptions(opts...)
  4409. return out, req.Send()
  4410. }
  4411. const opPutBucketLifecycle = "PutBucketLifecycle"
  4412. // PutBucketLifecycleRequest generates a "aws/request.Request" representing the
  4413. // client's request for the PutBucketLifecycle operation. The "output" return
  4414. // value will be populated with the request's response once the request complets
  4415. // successfuly.
  4416. //
  4417. // Use "Send" method on the returned Request to send the API call to the service.
  4418. // the "output" return value is not valid until after Send returns without error.
  4419. //
  4420. // See PutBucketLifecycle for more information on using the PutBucketLifecycle
  4421. // API call, and error handling.
  4422. //
  4423. // This method is useful when you want to inject custom logic or configuration
  4424. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4425. //
  4426. //
  4427. // // Example sending a request using the PutBucketLifecycleRequest method.
  4428. // req, resp := client.PutBucketLifecycleRequest(params)
  4429. //
  4430. // err := req.Send()
  4431. // if err == nil { // resp is now filled
  4432. // fmt.Println(resp)
  4433. // }
  4434. //
  4435. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycle
  4436. func (c *S3) PutBucketLifecycleRequest(input *PutBucketLifecycleInput) (req *request.Request, output *PutBucketLifecycleOutput) {
  4437. if c.Client.Config.Logger != nil {
  4438. c.Client.Config.Logger.Log("This operation, PutBucketLifecycle, has been deprecated")
  4439. }
  4440. op := &request.Operation{
  4441. Name: opPutBucketLifecycle,
  4442. HTTPMethod: "PUT",
  4443. HTTPPath: "/{Bucket}?lifecycle",
  4444. }
  4445. if input == nil {
  4446. input = &PutBucketLifecycleInput{}
  4447. }
  4448. output = &PutBucketLifecycleOutput{}
  4449. req = c.newRequest(op, input, output)
  4450. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4451. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4452. return
  4453. }
  4454. // PutBucketLifecycle API operation for Amazon Simple Storage Service.
  4455. //
  4456. // Deprecated, see the PutBucketLifecycleConfiguration operation.
  4457. //
  4458. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4459. // with awserr.Error's Code and Message methods to get detailed information about
  4460. // the error.
  4461. //
  4462. // See the AWS API reference guide for Amazon Simple Storage Service's
  4463. // API operation PutBucketLifecycle for usage and error information.
  4464. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycle
  4465. func (c *S3) PutBucketLifecycle(input *PutBucketLifecycleInput) (*PutBucketLifecycleOutput, error) {
  4466. req, out := c.PutBucketLifecycleRequest(input)
  4467. return out, req.Send()
  4468. }
  4469. // PutBucketLifecycleWithContext is the same as PutBucketLifecycle with the addition of
  4470. // the ability to pass a context and additional request options.
  4471. //
  4472. // See PutBucketLifecycle for details on how to use this API operation.
  4473. //
  4474. // The context must be non-nil and will be used for request cancellation. If
  4475. // the context is nil a panic will occur. In the future the SDK may create
  4476. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4477. // for more information on using Contexts.
  4478. func (c *S3) PutBucketLifecycleWithContext(ctx aws.Context, input *PutBucketLifecycleInput, opts ...request.Option) (*PutBucketLifecycleOutput, error) {
  4479. req, out := c.PutBucketLifecycleRequest(input)
  4480. req.SetContext(ctx)
  4481. req.ApplyOptions(opts...)
  4482. return out, req.Send()
  4483. }
  4484. const opPutBucketLifecycleConfiguration = "PutBucketLifecycleConfiguration"
  4485. // PutBucketLifecycleConfigurationRequest generates a "aws/request.Request" representing the
  4486. // client's request for the PutBucketLifecycleConfiguration operation. The "output" return
  4487. // value will be populated with the request's response once the request complets
  4488. // successfuly.
  4489. //
  4490. // Use "Send" method on the returned Request to send the API call to the service.
  4491. // the "output" return value is not valid until after Send returns without error.
  4492. //
  4493. // See PutBucketLifecycleConfiguration for more information on using the PutBucketLifecycleConfiguration
  4494. // API call, and error handling.
  4495. //
  4496. // This method is useful when you want to inject custom logic or configuration
  4497. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4498. //
  4499. //
  4500. // // Example sending a request using the PutBucketLifecycleConfigurationRequest method.
  4501. // req, resp := client.PutBucketLifecycleConfigurationRequest(params)
  4502. //
  4503. // err := req.Send()
  4504. // if err == nil { // resp is now filled
  4505. // fmt.Println(resp)
  4506. // }
  4507. //
  4508. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfiguration
  4509. func (c *S3) PutBucketLifecycleConfigurationRequest(input *PutBucketLifecycleConfigurationInput) (req *request.Request, output *PutBucketLifecycleConfigurationOutput) {
  4510. op := &request.Operation{
  4511. Name: opPutBucketLifecycleConfiguration,
  4512. HTTPMethod: "PUT",
  4513. HTTPPath: "/{Bucket}?lifecycle",
  4514. }
  4515. if input == nil {
  4516. input = &PutBucketLifecycleConfigurationInput{}
  4517. }
  4518. output = &PutBucketLifecycleConfigurationOutput{}
  4519. req = c.newRequest(op, input, output)
  4520. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4521. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4522. return
  4523. }
  4524. // PutBucketLifecycleConfiguration API operation for Amazon Simple Storage Service.
  4525. //
  4526. // Sets lifecycle configuration for your bucket. If a lifecycle configuration
  4527. // exists, it replaces it.
  4528. //
  4529. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4530. // with awserr.Error's Code and Message methods to get detailed information about
  4531. // the error.
  4532. //
  4533. // See the AWS API reference guide for Amazon Simple Storage Service's
  4534. // API operation PutBucketLifecycleConfiguration for usage and error information.
  4535. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfiguration
  4536. func (c *S3) PutBucketLifecycleConfiguration(input *PutBucketLifecycleConfigurationInput) (*PutBucketLifecycleConfigurationOutput, error) {
  4537. req, out := c.PutBucketLifecycleConfigurationRequest(input)
  4538. return out, req.Send()
  4539. }
  4540. // PutBucketLifecycleConfigurationWithContext is the same as PutBucketLifecycleConfiguration with the addition of
  4541. // the ability to pass a context and additional request options.
  4542. //
  4543. // See PutBucketLifecycleConfiguration for details on how to use this API operation.
  4544. //
  4545. // The context must be non-nil and will be used for request cancellation. If
  4546. // the context is nil a panic will occur. In the future the SDK may create
  4547. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4548. // for more information on using Contexts.
  4549. func (c *S3) PutBucketLifecycleConfigurationWithContext(ctx aws.Context, input *PutBucketLifecycleConfigurationInput, opts ...request.Option) (*PutBucketLifecycleConfigurationOutput, error) {
  4550. req, out := c.PutBucketLifecycleConfigurationRequest(input)
  4551. req.SetContext(ctx)
  4552. req.ApplyOptions(opts...)
  4553. return out, req.Send()
  4554. }
  4555. const opPutBucketLogging = "PutBucketLogging"
  4556. // PutBucketLoggingRequest generates a "aws/request.Request" representing the
  4557. // client's request for the PutBucketLogging operation. The "output" return
  4558. // value will be populated with the request's response once the request complets
  4559. // successfuly.
  4560. //
  4561. // Use "Send" method on the returned Request to send the API call to the service.
  4562. // the "output" return value is not valid until after Send returns without error.
  4563. //
  4564. // See PutBucketLogging for more information on using the PutBucketLogging
  4565. // API call, and error handling.
  4566. //
  4567. // This method is useful when you want to inject custom logic or configuration
  4568. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4569. //
  4570. //
  4571. // // Example sending a request using the PutBucketLoggingRequest method.
  4572. // req, resp := client.PutBucketLoggingRequest(params)
  4573. //
  4574. // err := req.Send()
  4575. // if err == nil { // resp is now filled
  4576. // fmt.Println(resp)
  4577. // }
  4578. //
  4579. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLogging
  4580. func (c *S3) PutBucketLoggingRequest(input *PutBucketLoggingInput) (req *request.Request, output *PutBucketLoggingOutput) {
  4581. op := &request.Operation{
  4582. Name: opPutBucketLogging,
  4583. HTTPMethod: "PUT",
  4584. HTTPPath: "/{Bucket}?logging",
  4585. }
  4586. if input == nil {
  4587. input = &PutBucketLoggingInput{}
  4588. }
  4589. output = &PutBucketLoggingOutput{}
  4590. req = c.newRequest(op, input, output)
  4591. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4592. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4593. return
  4594. }
  4595. // PutBucketLogging API operation for Amazon Simple Storage Service.
  4596. //
  4597. // Set the logging parameters for a bucket and to specify permissions for who
  4598. // can view and modify the logging parameters. To set the logging status of
  4599. // a bucket, you must be the bucket owner.
  4600. //
  4601. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4602. // with awserr.Error's Code and Message methods to get detailed information about
  4603. // the error.
  4604. //
  4605. // See the AWS API reference guide for Amazon Simple Storage Service's
  4606. // API operation PutBucketLogging for usage and error information.
  4607. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLogging
  4608. func (c *S3) PutBucketLogging(input *PutBucketLoggingInput) (*PutBucketLoggingOutput, error) {
  4609. req, out := c.PutBucketLoggingRequest(input)
  4610. return out, req.Send()
  4611. }
  4612. // PutBucketLoggingWithContext is the same as PutBucketLogging with the addition of
  4613. // the ability to pass a context and additional request options.
  4614. //
  4615. // See PutBucketLogging for details on how to use this API operation.
  4616. //
  4617. // The context must be non-nil and will be used for request cancellation. If
  4618. // the context is nil a panic will occur. In the future the SDK may create
  4619. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4620. // for more information on using Contexts.
  4621. func (c *S3) PutBucketLoggingWithContext(ctx aws.Context, input *PutBucketLoggingInput, opts ...request.Option) (*PutBucketLoggingOutput, error) {
  4622. req, out := c.PutBucketLoggingRequest(input)
  4623. req.SetContext(ctx)
  4624. req.ApplyOptions(opts...)
  4625. return out, req.Send()
  4626. }
  4627. const opPutBucketMetricsConfiguration = "PutBucketMetricsConfiguration"
  4628. // PutBucketMetricsConfigurationRequest generates a "aws/request.Request" representing the
  4629. // client's request for the PutBucketMetricsConfiguration operation. The "output" return
  4630. // value will be populated with the request's response once the request complets
  4631. // successfuly.
  4632. //
  4633. // Use "Send" method on the returned Request to send the API call to the service.
  4634. // the "output" return value is not valid until after Send returns without error.
  4635. //
  4636. // See PutBucketMetricsConfiguration for more information on using the PutBucketMetricsConfiguration
  4637. // API call, and error handling.
  4638. //
  4639. // This method is useful when you want to inject custom logic or configuration
  4640. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4641. //
  4642. //
  4643. // // Example sending a request using the PutBucketMetricsConfigurationRequest method.
  4644. // req, resp := client.PutBucketMetricsConfigurationRequest(params)
  4645. //
  4646. // err := req.Send()
  4647. // if err == nil { // resp is now filled
  4648. // fmt.Println(resp)
  4649. // }
  4650. //
  4651. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfiguration
  4652. func (c *S3) PutBucketMetricsConfigurationRequest(input *PutBucketMetricsConfigurationInput) (req *request.Request, output *PutBucketMetricsConfigurationOutput) {
  4653. op := &request.Operation{
  4654. Name: opPutBucketMetricsConfiguration,
  4655. HTTPMethod: "PUT",
  4656. HTTPPath: "/{Bucket}?metrics",
  4657. }
  4658. if input == nil {
  4659. input = &PutBucketMetricsConfigurationInput{}
  4660. }
  4661. output = &PutBucketMetricsConfigurationOutput{}
  4662. req = c.newRequest(op, input, output)
  4663. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4664. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4665. return
  4666. }
  4667. // PutBucketMetricsConfiguration API operation for Amazon Simple Storage Service.
  4668. //
  4669. // Sets a metrics configuration (specified by the metrics configuration ID)
  4670. // for the bucket.
  4671. //
  4672. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4673. // with awserr.Error's Code and Message methods to get detailed information about
  4674. // the error.
  4675. //
  4676. // See the AWS API reference guide for Amazon Simple Storage Service's
  4677. // API operation PutBucketMetricsConfiguration for usage and error information.
  4678. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfiguration
  4679. func (c *S3) PutBucketMetricsConfiguration(input *PutBucketMetricsConfigurationInput) (*PutBucketMetricsConfigurationOutput, error) {
  4680. req, out := c.PutBucketMetricsConfigurationRequest(input)
  4681. return out, req.Send()
  4682. }
  4683. // PutBucketMetricsConfigurationWithContext is the same as PutBucketMetricsConfiguration with the addition of
  4684. // the ability to pass a context and additional request options.
  4685. //
  4686. // See PutBucketMetricsConfiguration for details on how to use this API operation.
  4687. //
  4688. // The context must be non-nil and will be used for request cancellation. If
  4689. // the context is nil a panic will occur. In the future the SDK may create
  4690. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4691. // for more information on using Contexts.
  4692. func (c *S3) PutBucketMetricsConfigurationWithContext(ctx aws.Context, input *PutBucketMetricsConfigurationInput, opts ...request.Option) (*PutBucketMetricsConfigurationOutput, error) {
  4693. req, out := c.PutBucketMetricsConfigurationRequest(input)
  4694. req.SetContext(ctx)
  4695. req.ApplyOptions(opts...)
  4696. return out, req.Send()
  4697. }
  4698. const opPutBucketNotification = "PutBucketNotification"
  4699. // PutBucketNotificationRequest generates a "aws/request.Request" representing the
  4700. // client's request for the PutBucketNotification operation. The "output" return
  4701. // value will be populated with the request's response once the request complets
  4702. // successfuly.
  4703. //
  4704. // Use "Send" method on the returned Request to send the API call to the service.
  4705. // the "output" return value is not valid until after Send returns without error.
  4706. //
  4707. // See PutBucketNotification for more information on using the PutBucketNotification
  4708. // API call, and error handling.
  4709. //
  4710. // This method is useful when you want to inject custom logic or configuration
  4711. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4712. //
  4713. //
  4714. // // Example sending a request using the PutBucketNotificationRequest method.
  4715. // req, resp := client.PutBucketNotificationRequest(params)
  4716. //
  4717. // err := req.Send()
  4718. // if err == nil { // resp is now filled
  4719. // fmt.Println(resp)
  4720. // }
  4721. //
  4722. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotification
  4723. func (c *S3) PutBucketNotificationRequest(input *PutBucketNotificationInput) (req *request.Request, output *PutBucketNotificationOutput) {
  4724. if c.Client.Config.Logger != nil {
  4725. c.Client.Config.Logger.Log("This operation, PutBucketNotification, has been deprecated")
  4726. }
  4727. op := &request.Operation{
  4728. Name: opPutBucketNotification,
  4729. HTTPMethod: "PUT",
  4730. HTTPPath: "/{Bucket}?notification",
  4731. }
  4732. if input == nil {
  4733. input = &PutBucketNotificationInput{}
  4734. }
  4735. output = &PutBucketNotificationOutput{}
  4736. req = c.newRequest(op, input, output)
  4737. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4738. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4739. return
  4740. }
  4741. // PutBucketNotification API operation for Amazon Simple Storage Service.
  4742. //
  4743. // Deprecated, see the PutBucketNotificationConfiguraiton operation.
  4744. //
  4745. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4746. // with awserr.Error's Code and Message methods to get detailed information about
  4747. // the error.
  4748. //
  4749. // See the AWS API reference guide for Amazon Simple Storage Service's
  4750. // API operation PutBucketNotification for usage and error information.
  4751. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotification
  4752. func (c *S3) PutBucketNotification(input *PutBucketNotificationInput) (*PutBucketNotificationOutput, error) {
  4753. req, out := c.PutBucketNotificationRequest(input)
  4754. return out, req.Send()
  4755. }
  4756. // PutBucketNotificationWithContext is the same as PutBucketNotification with the addition of
  4757. // the ability to pass a context and additional request options.
  4758. //
  4759. // See PutBucketNotification for details on how to use this API operation.
  4760. //
  4761. // The context must be non-nil and will be used for request cancellation. If
  4762. // the context is nil a panic will occur. In the future the SDK may create
  4763. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4764. // for more information on using Contexts.
  4765. func (c *S3) PutBucketNotificationWithContext(ctx aws.Context, input *PutBucketNotificationInput, opts ...request.Option) (*PutBucketNotificationOutput, error) {
  4766. req, out := c.PutBucketNotificationRequest(input)
  4767. req.SetContext(ctx)
  4768. req.ApplyOptions(opts...)
  4769. return out, req.Send()
  4770. }
  4771. const opPutBucketNotificationConfiguration = "PutBucketNotificationConfiguration"
  4772. // PutBucketNotificationConfigurationRequest generates a "aws/request.Request" representing the
  4773. // client's request for the PutBucketNotificationConfiguration operation. The "output" return
  4774. // value will be populated with the request's response once the request complets
  4775. // successfuly.
  4776. //
  4777. // Use "Send" method on the returned Request to send the API call to the service.
  4778. // the "output" return value is not valid until after Send returns without error.
  4779. //
  4780. // See PutBucketNotificationConfiguration for more information on using the PutBucketNotificationConfiguration
  4781. // API call, and error handling.
  4782. //
  4783. // This method is useful when you want to inject custom logic or configuration
  4784. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4785. //
  4786. //
  4787. // // Example sending a request using the PutBucketNotificationConfigurationRequest method.
  4788. // req, resp := client.PutBucketNotificationConfigurationRequest(params)
  4789. //
  4790. // err := req.Send()
  4791. // if err == nil { // resp is now filled
  4792. // fmt.Println(resp)
  4793. // }
  4794. //
  4795. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfiguration
  4796. func (c *S3) PutBucketNotificationConfigurationRequest(input *PutBucketNotificationConfigurationInput) (req *request.Request, output *PutBucketNotificationConfigurationOutput) {
  4797. op := &request.Operation{
  4798. Name: opPutBucketNotificationConfiguration,
  4799. HTTPMethod: "PUT",
  4800. HTTPPath: "/{Bucket}?notification",
  4801. }
  4802. if input == nil {
  4803. input = &PutBucketNotificationConfigurationInput{}
  4804. }
  4805. output = &PutBucketNotificationConfigurationOutput{}
  4806. req = c.newRequest(op, input, output)
  4807. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4808. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4809. return
  4810. }
  4811. // PutBucketNotificationConfiguration API operation for Amazon Simple Storage Service.
  4812. //
  4813. // Enables notifications of specified events for a bucket.
  4814. //
  4815. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4816. // with awserr.Error's Code and Message methods to get detailed information about
  4817. // the error.
  4818. //
  4819. // See the AWS API reference guide for Amazon Simple Storage Service's
  4820. // API operation PutBucketNotificationConfiguration for usage and error information.
  4821. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfiguration
  4822. func (c *S3) PutBucketNotificationConfiguration(input *PutBucketNotificationConfigurationInput) (*PutBucketNotificationConfigurationOutput, error) {
  4823. req, out := c.PutBucketNotificationConfigurationRequest(input)
  4824. return out, req.Send()
  4825. }
  4826. // PutBucketNotificationConfigurationWithContext is the same as PutBucketNotificationConfiguration with the addition of
  4827. // the ability to pass a context and additional request options.
  4828. //
  4829. // See PutBucketNotificationConfiguration for details on how to use this API operation.
  4830. //
  4831. // The context must be non-nil and will be used for request cancellation. If
  4832. // the context is nil a panic will occur. In the future the SDK may create
  4833. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4834. // for more information on using Contexts.
  4835. func (c *S3) PutBucketNotificationConfigurationWithContext(ctx aws.Context, input *PutBucketNotificationConfigurationInput, opts ...request.Option) (*PutBucketNotificationConfigurationOutput, error) {
  4836. req, out := c.PutBucketNotificationConfigurationRequest(input)
  4837. req.SetContext(ctx)
  4838. req.ApplyOptions(opts...)
  4839. return out, req.Send()
  4840. }
  4841. const opPutBucketPolicy = "PutBucketPolicy"
  4842. // PutBucketPolicyRequest generates a "aws/request.Request" representing the
  4843. // client's request for the PutBucketPolicy operation. The "output" return
  4844. // value will be populated with the request's response once the request complets
  4845. // successfuly.
  4846. //
  4847. // Use "Send" method on the returned Request to send the API call to the service.
  4848. // the "output" return value is not valid until after Send returns without error.
  4849. //
  4850. // See PutBucketPolicy for more information on using the PutBucketPolicy
  4851. // API call, and error handling.
  4852. //
  4853. // This method is useful when you want to inject custom logic or configuration
  4854. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4855. //
  4856. //
  4857. // // Example sending a request using the PutBucketPolicyRequest method.
  4858. // req, resp := client.PutBucketPolicyRequest(params)
  4859. //
  4860. // err := req.Send()
  4861. // if err == nil { // resp is now filled
  4862. // fmt.Println(resp)
  4863. // }
  4864. //
  4865. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicy
  4866. func (c *S3) PutBucketPolicyRequest(input *PutBucketPolicyInput) (req *request.Request, output *PutBucketPolicyOutput) {
  4867. op := &request.Operation{
  4868. Name: opPutBucketPolicy,
  4869. HTTPMethod: "PUT",
  4870. HTTPPath: "/{Bucket}?policy",
  4871. }
  4872. if input == nil {
  4873. input = &PutBucketPolicyInput{}
  4874. }
  4875. output = &PutBucketPolicyOutput{}
  4876. req = c.newRequest(op, input, output)
  4877. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4878. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4879. return
  4880. }
  4881. // PutBucketPolicy API operation for Amazon Simple Storage Service.
  4882. //
  4883. // Replaces a policy on a bucket. If the bucket already has a policy, the one
  4884. // in this request completely replaces it.
  4885. //
  4886. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4887. // with awserr.Error's Code and Message methods to get detailed information about
  4888. // the error.
  4889. //
  4890. // See the AWS API reference guide for Amazon Simple Storage Service's
  4891. // API operation PutBucketPolicy for usage and error information.
  4892. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicy
  4893. func (c *S3) PutBucketPolicy(input *PutBucketPolicyInput) (*PutBucketPolicyOutput, error) {
  4894. req, out := c.PutBucketPolicyRequest(input)
  4895. return out, req.Send()
  4896. }
  4897. // PutBucketPolicyWithContext is the same as PutBucketPolicy with the addition of
  4898. // the ability to pass a context and additional request options.
  4899. //
  4900. // See PutBucketPolicy for details on how to use this API operation.
  4901. //
  4902. // The context must be non-nil and will be used for request cancellation. If
  4903. // the context is nil a panic will occur. In the future the SDK may create
  4904. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4905. // for more information on using Contexts.
  4906. func (c *S3) PutBucketPolicyWithContext(ctx aws.Context, input *PutBucketPolicyInput, opts ...request.Option) (*PutBucketPolicyOutput, error) {
  4907. req, out := c.PutBucketPolicyRequest(input)
  4908. req.SetContext(ctx)
  4909. req.ApplyOptions(opts...)
  4910. return out, req.Send()
  4911. }
  4912. const opPutBucketReplication = "PutBucketReplication"
  4913. // PutBucketReplicationRequest generates a "aws/request.Request" representing the
  4914. // client's request for the PutBucketReplication operation. The "output" return
  4915. // value will be populated with the request's response once the request complets
  4916. // successfuly.
  4917. //
  4918. // Use "Send" method on the returned Request to send the API call to the service.
  4919. // the "output" return value is not valid until after Send returns without error.
  4920. //
  4921. // See PutBucketReplication for more information on using the PutBucketReplication
  4922. // API call, and error handling.
  4923. //
  4924. // This method is useful when you want to inject custom logic or configuration
  4925. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4926. //
  4927. //
  4928. // // Example sending a request using the PutBucketReplicationRequest method.
  4929. // req, resp := client.PutBucketReplicationRequest(params)
  4930. //
  4931. // err := req.Send()
  4932. // if err == nil { // resp is now filled
  4933. // fmt.Println(resp)
  4934. // }
  4935. //
  4936. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplication
  4937. func (c *S3) PutBucketReplicationRequest(input *PutBucketReplicationInput) (req *request.Request, output *PutBucketReplicationOutput) {
  4938. op := &request.Operation{
  4939. Name: opPutBucketReplication,
  4940. HTTPMethod: "PUT",
  4941. HTTPPath: "/{Bucket}?replication",
  4942. }
  4943. if input == nil {
  4944. input = &PutBucketReplicationInput{}
  4945. }
  4946. output = &PutBucketReplicationOutput{}
  4947. req = c.newRequest(op, input, output)
  4948. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  4949. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  4950. return
  4951. }
  4952. // PutBucketReplication API operation for Amazon Simple Storage Service.
  4953. //
  4954. // Creates a new replication configuration (or replaces an existing one, if
  4955. // present).
  4956. //
  4957. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  4958. // with awserr.Error's Code and Message methods to get detailed information about
  4959. // the error.
  4960. //
  4961. // See the AWS API reference guide for Amazon Simple Storage Service's
  4962. // API operation PutBucketReplication for usage and error information.
  4963. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplication
  4964. func (c *S3) PutBucketReplication(input *PutBucketReplicationInput) (*PutBucketReplicationOutput, error) {
  4965. req, out := c.PutBucketReplicationRequest(input)
  4966. return out, req.Send()
  4967. }
  4968. // PutBucketReplicationWithContext is the same as PutBucketReplication with the addition of
  4969. // the ability to pass a context and additional request options.
  4970. //
  4971. // See PutBucketReplication for details on how to use this API operation.
  4972. //
  4973. // The context must be non-nil and will be used for request cancellation. If
  4974. // the context is nil a panic will occur. In the future the SDK may create
  4975. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  4976. // for more information on using Contexts.
  4977. func (c *S3) PutBucketReplicationWithContext(ctx aws.Context, input *PutBucketReplicationInput, opts ...request.Option) (*PutBucketReplicationOutput, error) {
  4978. req, out := c.PutBucketReplicationRequest(input)
  4979. req.SetContext(ctx)
  4980. req.ApplyOptions(opts...)
  4981. return out, req.Send()
  4982. }
  4983. const opPutBucketRequestPayment = "PutBucketRequestPayment"
  4984. // PutBucketRequestPaymentRequest generates a "aws/request.Request" representing the
  4985. // client's request for the PutBucketRequestPayment operation. The "output" return
  4986. // value will be populated with the request's response once the request complets
  4987. // successfuly.
  4988. //
  4989. // Use "Send" method on the returned Request to send the API call to the service.
  4990. // the "output" return value is not valid until after Send returns without error.
  4991. //
  4992. // See PutBucketRequestPayment for more information on using the PutBucketRequestPayment
  4993. // API call, and error handling.
  4994. //
  4995. // This method is useful when you want to inject custom logic or configuration
  4996. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  4997. //
  4998. //
  4999. // // Example sending a request using the PutBucketRequestPaymentRequest method.
  5000. // req, resp := client.PutBucketRequestPaymentRequest(params)
  5001. //
  5002. // err := req.Send()
  5003. // if err == nil { // resp is now filled
  5004. // fmt.Println(resp)
  5005. // }
  5006. //
  5007. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPayment
  5008. func (c *S3) PutBucketRequestPaymentRequest(input *PutBucketRequestPaymentInput) (req *request.Request, output *PutBucketRequestPaymentOutput) {
  5009. op := &request.Operation{
  5010. Name: opPutBucketRequestPayment,
  5011. HTTPMethod: "PUT",
  5012. HTTPPath: "/{Bucket}?requestPayment",
  5013. }
  5014. if input == nil {
  5015. input = &PutBucketRequestPaymentInput{}
  5016. }
  5017. output = &PutBucketRequestPaymentOutput{}
  5018. req = c.newRequest(op, input, output)
  5019. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  5020. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  5021. return
  5022. }
  5023. // PutBucketRequestPayment API operation for Amazon Simple Storage Service.
  5024. //
  5025. // Sets the request payment configuration for a bucket. By default, the bucket
  5026. // owner pays for downloads from the bucket. This configuration parameter enables
  5027. // the bucket owner (only) to specify that the person requesting the download
  5028. // will be charged for the download. Documentation on requester pays buckets
  5029. // can be found at http://docs.aws.amazon.com/AmazonS3/latest/dev/RequesterPaysBuckets.html
  5030. //
  5031. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5032. // with awserr.Error's Code and Message methods to get detailed information about
  5033. // the error.
  5034. //
  5035. // See the AWS API reference guide for Amazon Simple Storage Service's
  5036. // API operation PutBucketRequestPayment for usage and error information.
  5037. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPayment
  5038. func (c *S3) PutBucketRequestPayment(input *PutBucketRequestPaymentInput) (*PutBucketRequestPaymentOutput, error) {
  5039. req, out := c.PutBucketRequestPaymentRequest(input)
  5040. return out, req.Send()
  5041. }
  5042. // PutBucketRequestPaymentWithContext is the same as PutBucketRequestPayment with the addition of
  5043. // the ability to pass a context and additional request options.
  5044. //
  5045. // See PutBucketRequestPayment for details on how to use this API operation.
  5046. //
  5047. // The context must be non-nil and will be used for request cancellation. If
  5048. // the context is nil a panic will occur. In the future the SDK may create
  5049. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5050. // for more information on using Contexts.
  5051. func (c *S3) PutBucketRequestPaymentWithContext(ctx aws.Context, input *PutBucketRequestPaymentInput, opts ...request.Option) (*PutBucketRequestPaymentOutput, error) {
  5052. req, out := c.PutBucketRequestPaymentRequest(input)
  5053. req.SetContext(ctx)
  5054. req.ApplyOptions(opts...)
  5055. return out, req.Send()
  5056. }
  5057. const opPutBucketTagging = "PutBucketTagging"
  5058. // PutBucketTaggingRequest generates a "aws/request.Request" representing the
  5059. // client's request for the PutBucketTagging operation. The "output" return
  5060. // value will be populated with the request's response once the request complets
  5061. // successfuly.
  5062. //
  5063. // Use "Send" method on the returned Request to send the API call to the service.
  5064. // the "output" return value is not valid until after Send returns without error.
  5065. //
  5066. // See PutBucketTagging for more information on using the PutBucketTagging
  5067. // API call, and error handling.
  5068. //
  5069. // This method is useful when you want to inject custom logic or configuration
  5070. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5071. //
  5072. //
  5073. // // Example sending a request using the PutBucketTaggingRequest method.
  5074. // req, resp := client.PutBucketTaggingRequest(params)
  5075. //
  5076. // err := req.Send()
  5077. // if err == nil { // resp is now filled
  5078. // fmt.Println(resp)
  5079. // }
  5080. //
  5081. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTagging
  5082. func (c *S3) PutBucketTaggingRequest(input *PutBucketTaggingInput) (req *request.Request, output *PutBucketTaggingOutput) {
  5083. op := &request.Operation{
  5084. Name: opPutBucketTagging,
  5085. HTTPMethod: "PUT",
  5086. HTTPPath: "/{Bucket}?tagging",
  5087. }
  5088. if input == nil {
  5089. input = &PutBucketTaggingInput{}
  5090. }
  5091. output = &PutBucketTaggingOutput{}
  5092. req = c.newRequest(op, input, output)
  5093. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  5094. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  5095. return
  5096. }
  5097. // PutBucketTagging API operation for Amazon Simple Storage Service.
  5098. //
  5099. // Sets the tags for a bucket.
  5100. //
  5101. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5102. // with awserr.Error's Code and Message methods to get detailed information about
  5103. // the error.
  5104. //
  5105. // See the AWS API reference guide for Amazon Simple Storage Service's
  5106. // API operation PutBucketTagging for usage and error information.
  5107. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTagging
  5108. func (c *S3) PutBucketTagging(input *PutBucketTaggingInput) (*PutBucketTaggingOutput, error) {
  5109. req, out := c.PutBucketTaggingRequest(input)
  5110. return out, req.Send()
  5111. }
  5112. // PutBucketTaggingWithContext is the same as PutBucketTagging with the addition of
  5113. // the ability to pass a context and additional request options.
  5114. //
  5115. // See PutBucketTagging for details on how to use this API operation.
  5116. //
  5117. // The context must be non-nil and will be used for request cancellation. If
  5118. // the context is nil a panic will occur. In the future the SDK may create
  5119. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5120. // for more information on using Contexts.
  5121. func (c *S3) PutBucketTaggingWithContext(ctx aws.Context, input *PutBucketTaggingInput, opts ...request.Option) (*PutBucketTaggingOutput, error) {
  5122. req, out := c.PutBucketTaggingRequest(input)
  5123. req.SetContext(ctx)
  5124. req.ApplyOptions(opts...)
  5125. return out, req.Send()
  5126. }
  5127. const opPutBucketVersioning = "PutBucketVersioning"
  5128. // PutBucketVersioningRequest generates a "aws/request.Request" representing the
  5129. // client's request for the PutBucketVersioning operation. The "output" return
  5130. // value will be populated with the request's response once the request complets
  5131. // successfuly.
  5132. //
  5133. // Use "Send" method on the returned Request to send the API call to the service.
  5134. // the "output" return value is not valid until after Send returns without error.
  5135. //
  5136. // See PutBucketVersioning for more information on using the PutBucketVersioning
  5137. // API call, and error handling.
  5138. //
  5139. // This method is useful when you want to inject custom logic or configuration
  5140. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5141. //
  5142. //
  5143. // // Example sending a request using the PutBucketVersioningRequest method.
  5144. // req, resp := client.PutBucketVersioningRequest(params)
  5145. //
  5146. // err := req.Send()
  5147. // if err == nil { // resp is now filled
  5148. // fmt.Println(resp)
  5149. // }
  5150. //
  5151. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioning
  5152. func (c *S3) PutBucketVersioningRequest(input *PutBucketVersioningInput) (req *request.Request, output *PutBucketVersioningOutput) {
  5153. op := &request.Operation{
  5154. Name: opPutBucketVersioning,
  5155. HTTPMethod: "PUT",
  5156. HTTPPath: "/{Bucket}?versioning",
  5157. }
  5158. if input == nil {
  5159. input = &PutBucketVersioningInput{}
  5160. }
  5161. output = &PutBucketVersioningOutput{}
  5162. req = c.newRequest(op, input, output)
  5163. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  5164. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  5165. return
  5166. }
  5167. // PutBucketVersioning API operation for Amazon Simple Storage Service.
  5168. //
  5169. // Sets the versioning state of an existing bucket. To set the versioning state,
  5170. // you must be the bucket owner.
  5171. //
  5172. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5173. // with awserr.Error's Code and Message methods to get detailed information about
  5174. // the error.
  5175. //
  5176. // See the AWS API reference guide for Amazon Simple Storage Service's
  5177. // API operation PutBucketVersioning for usage and error information.
  5178. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioning
  5179. func (c *S3) PutBucketVersioning(input *PutBucketVersioningInput) (*PutBucketVersioningOutput, error) {
  5180. req, out := c.PutBucketVersioningRequest(input)
  5181. return out, req.Send()
  5182. }
  5183. // PutBucketVersioningWithContext is the same as PutBucketVersioning with the addition of
  5184. // the ability to pass a context and additional request options.
  5185. //
  5186. // See PutBucketVersioning for details on how to use this API operation.
  5187. //
  5188. // The context must be non-nil and will be used for request cancellation. If
  5189. // the context is nil a panic will occur. In the future the SDK may create
  5190. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5191. // for more information on using Contexts.
  5192. func (c *S3) PutBucketVersioningWithContext(ctx aws.Context, input *PutBucketVersioningInput, opts ...request.Option) (*PutBucketVersioningOutput, error) {
  5193. req, out := c.PutBucketVersioningRequest(input)
  5194. req.SetContext(ctx)
  5195. req.ApplyOptions(opts...)
  5196. return out, req.Send()
  5197. }
  5198. const opPutBucketWebsite = "PutBucketWebsite"
  5199. // PutBucketWebsiteRequest generates a "aws/request.Request" representing the
  5200. // client's request for the PutBucketWebsite operation. The "output" return
  5201. // value will be populated with the request's response once the request complets
  5202. // successfuly.
  5203. //
  5204. // Use "Send" method on the returned Request to send the API call to the service.
  5205. // the "output" return value is not valid until after Send returns without error.
  5206. //
  5207. // See PutBucketWebsite for more information on using the PutBucketWebsite
  5208. // API call, and error handling.
  5209. //
  5210. // This method is useful when you want to inject custom logic or configuration
  5211. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5212. //
  5213. //
  5214. // // Example sending a request using the PutBucketWebsiteRequest method.
  5215. // req, resp := client.PutBucketWebsiteRequest(params)
  5216. //
  5217. // err := req.Send()
  5218. // if err == nil { // resp is now filled
  5219. // fmt.Println(resp)
  5220. // }
  5221. //
  5222. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsite
  5223. func (c *S3) PutBucketWebsiteRequest(input *PutBucketWebsiteInput) (req *request.Request, output *PutBucketWebsiteOutput) {
  5224. op := &request.Operation{
  5225. Name: opPutBucketWebsite,
  5226. HTTPMethod: "PUT",
  5227. HTTPPath: "/{Bucket}?website",
  5228. }
  5229. if input == nil {
  5230. input = &PutBucketWebsiteInput{}
  5231. }
  5232. output = &PutBucketWebsiteOutput{}
  5233. req = c.newRequest(op, input, output)
  5234. req.Handlers.Unmarshal.Remove(restxml.UnmarshalHandler)
  5235. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  5236. return
  5237. }
  5238. // PutBucketWebsite API operation for Amazon Simple Storage Service.
  5239. //
  5240. // Set the website configuration for a bucket.
  5241. //
  5242. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5243. // with awserr.Error's Code and Message methods to get detailed information about
  5244. // the error.
  5245. //
  5246. // See the AWS API reference guide for Amazon Simple Storage Service's
  5247. // API operation PutBucketWebsite for usage and error information.
  5248. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsite
  5249. func (c *S3) PutBucketWebsite(input *PutBucketWebsiteInput) (*PutBucketWebsiteOutput, error) {
  5250. req, out := c.PutBucketWebsiteRequest(input)
  5251. return out, req.Send()
  5252. }
  5253. // PutBucketWebsiteWithContext is the same as PutBucketWebsite with the addition of
  5254. // the ability to pass a context and additional request options.
  5255. //
  5256. // See PutBucketWebsite for details on how to use this API operation.
  5257. //
  5258. // The context must be non-nil and will be used for request cancellation. If
  5259. // the context is nil a panic will occur. In the future the SDK may create
  5260. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5261. // for more information on using Contexts.
  5262. func (c *S3) PutBucketWebsiteWithContext(ctx aws.Context, input *PutBucketWebsiteInput, opts ...request.Option) (*PutBucketWebsiteOutput, error) {
  5263. req, out := c.PutBucketWebsiteRequest(input)
  5264. req.SetContext(ctx)
  5265. req.ApplyOptions(opts...)
  5266. return out, req.Send()
  5267. }
  5268. const opPutObject = "PutObject"
  5269. // PutObjectRequest generates a "aws/request.Request" representing the
  5270. // client's request for the PutObject operation. The "output" return
  5271. // value will be populated with the request's response once the request complets
  5272. // successfuly.
  5273. //
  5274. // Use "Send" method on the returned Request to send the API call to the service.
  5275. // the "output" return value is not valid until after Send returns without error.
  5276. //
  5277. // See PutObject for more information on using the PutObject
  5278. // API call, and error handling.
  5279. //
  5280. // This method is useful when you want to inject custom logic or configuration
  5281. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5282. //
  5283. //
  5284. // // Example sending a request using the PutObjectRequest method.
  5285. // req, resp := client.PutObjectRequest(params)
  5286. //
  5287. // err := req.Send()
  5288. // if err == nil { // resp is now filled
  5289. // fmt.Println(resp)
  5290. // }
  5291. //
  5292. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObject
  5293. func (c *S3) PutObjectRequest(input *PutObjectInput) (req *request.Request, output *PutObjectOutput) {
  5294. op := &request.Operation{
  5295. Name: opPutObject,
  5296. HTTPMethod: "PUT",
  5297. HTTPPath: "/{Bucket}/{Key+}",
  5298. }
  5299. if input == nil {
  5300. input = &PutObjectInput{}
  5301. }
  5302. output = &PutObjectOutput{}
  5303. req = c.newRequest(op, input, output)
  5304. return
  5305. }
  5306. // PutObject API operation for Amazon Simple Storage Service.
  5307. //
  5308. // Adds an object to a bucket.
  5309. //
  5310. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5311. // with awserr.Error's Code and Message methods to get detailed information about
  5312. // the error.
  5313. //
  5314. // See the AWS API reference guide for Amazon Simple Storage Service's
  5315. // API operation PutObject for usage and error information.
  5316. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObject
  5317. func (c *S3) PutObject(input *PutObjectInput) (*PutObjectOutput, error) {
  5318. req, out := c.PutObjectRequest(input)
  5319. return out, req.Send()
  5320. }
  5321. // PutObjectWithContext is the same as PutObject with the addition of
  5322. // the ability to pass a context and additional request options.
  5323. //
  5324. // See PutObject for details on how to use this API operation.
  5325. //
  5326. // The context must be non-nil and will be used for request cancellation. If
  5327. // the context is nil a panic will occur. In the future the SDK may create
  5328. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5329. // for more information on using Contexts.
  5330. func (c *S3) PutObjectWithContext(ctx aws.Context, input *PutObjectInput, opts ...request.Option) (*PutObjectOutput, error) {
  5331. req, out := c.PutObjectRequest(input)
  5332. req.SetContext(ctx)
  5333. req.ApplyOptions(opts...)
  5334. return out, req.Send()
  5335. }
  5336. const opPutObjectAcl = "PutObjectAcl"
  5337. // PutObjectAclRequest generates a "aws/request.Request" representing the
  5338. // client's request for the PutObjectAcl operation. The "output" return
  5339. // value will be populated with the request's response once the request complets
  5340. // successfuly.
  5341. //
  5342. // Use "Send" method on the returned Request to send the API call to the service.
  5343. // the "output" return value is not valid until after Send returns without error.
  5344. //
  5345. // See PutObjectAcl for more information on using the PutObjectAcl
  5346. // API call, and error handling.
  5347. //
  5348. // This method is useful when you want to inject custom logic or configuration
  5349. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5350. //
  5351. //
  5352. // // Example sending a request using the PutObjectAclRequest method.
  5353. // req, resp := client.PutObjectAclRequest(params)
  5354. //
  5355. // err := req.Send()
  5356. // if err == nil { // resp is now filled
  5357. // fmt.Println(resp)
  5358. // }
  5359. //
  5360. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAcl
  5361. func (c *S3) PutObjectAclRequest(input *PutObjectAclInput) (req *request.Request, output *PutObjectAclOutput) {
  5362. op := &request.Operation{
  5363. Name: opPutObjectAcl,
  5364. HTTPMethod: "PUT",
  5365. HTTPPath: "/{Bucket}/{Key+}?acl",
  5366. }
  5367. if input == nil {
  5368. input = &PutObjectAclInput{}
  5369. }
  5370. output = &PutObjectAclOutput{}
  5371. req = c.newRequest(op, input, output)
  5372. return
  5373. }
  5374. // PutObjectAcl API operation for Amazon Simple Storage Service.
  5375. //
  5376. // uses the acl subresource to set the access control list (ACL) permissions
  5377. // for an object that already exists in a bucket
  5378. //
  5379. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5380. // with awserr.Error's Code and Message methods to get detailed information about
  5381. // the error.
  5382. //
  5383. // See the AWS API reference guide for Amazon Simple Storage Service's
  5384. // API operation PutObjectAcl for usage and error information.
  5385. //
  5386. // Returned Error Codes:
  5387. // * ErrCodeNoSuchKey "NoSuchKey"
  5388. // The specified key does not exist.
  5389. //
  5390. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAcl
  5391. func (c *S3) PutObjectAcl(input *PutObjectAclInput) (*PutObjectAclOutput, error) {
  5392. req, out := c.PutObjectAclRequest(input)
  5393. return out, req.Send()
  5394. }
  5395. // PutObjectAclWithContext is the same as PutObjectAcl with the addition of
  5396. // the ability to pass a context and additional request options.
  5397. //
  5398. // See PutObjectAcl for details on how to use this API operation.
  5399. //
  5400. // The context must be non-nil and will be used for request cancellation. If
  5401. // the context is nil a panic will occur. In the future the SDK may create
  5402. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5403. // for more information on using Contexts.
  5404. func (c *S3) PutObjectAclWithContext(ctx aws.Context, input *PutObjectAclInput, opts ...request.Option) (*PutObjectAclOutput, error) {
  5405. req, out := c.PutObjectAclRequest(input)
  5406. req.SetContext(ctx)
  5407. req.ApplyOptions(opts...)
  5408. return out, req.Send()
  5409. }
  5410. const opPutObjectTagging = "PutObjectTagging"
  5411. // PutObjectTaggingRequest generates a "aws/request.Request" representing the
  5412. // client's request for the PutObjectTagging operation. The "output" return
  5413. // value will be populated with the request's response once the request complets
  5414. // successfuly.
  5415. //
  5416. // Use "Send" method on the returned Request to send the API call to the service.
  5417. // the "output" return value is not valid until after Send returns without error.
  5418. //
  5419. // See PutObjectTagging for more information on using the PutObjectTagging
  5420. // API call, and error handling.
  5421. //
  5422. // This method is useful when you want to inject custom logic or configuration
  5423. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5424. //
  5425. //
  5426. // // Example sending a request using the PutObjectTaggingRequest method.
  5427. // req, resp := client.PutObjectTaggingRequest(params)
  5428. //
  5429. // err := req.Send()
  5430. // if err == nil { // resp is now filled
  5431. // fmt.Println(resp)
  5432. // }
  5433. //
  5434. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTagging
  5435. func (c *S3) PutObjectTaggingRequest(input *PutObjectTaggingInput) (req *request.Request, output *PutObjectTaggingOutput) {
  5436. op := &request.Operation{
  5437. Name: opPutObjectTagging,
  5438. HTTPMethod: "PUT",
  5439. HTTPPath: "/{Bucket}/{Key+}?tagging",
  5440. }
  5441. if input == nil {
  5442. input = &PutObjectTaggingInput{}
  5443. }
  5444. output = &PutObjectTaggingOutput{}
  5445. req = c.newRequest(op, input, output)
  5446. return
  5447. }
  5448. // PutObjectTagging API operation for Amazon Simple Storage Service.
  5449. //
  5450. // Sets the supplied tag-set to an object that already exists in a bucket
  5451. //
  5452. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5453. // with awserr.Error's Code and Message methods to get detailed information about
  5454. // the error.
  5455. //
  5456. // See the AWS API reference guide for Amazon Simple Storage Service's
  5457. // API operation PutObjectTagging for usage and error information.
  5458. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTagging
  5459. func (c *S3) PutObjectTagging(input *PutObjectTaggingInput) (*PutObjectTaggingOutput, error) {
  5460. req, out := c.PutObjectTaggingRequest(input)
  5461. return out, req.Send()
  5462. }
  5463. // PutObjectTaggingWithContext is the same as PutObjectTagging with the addition of
  5464. // the ability to pass a context and additional request options.
  5465. //
  5466. // See PutObjectTagging for details on how to use this API operation.
  5467. //
  5468. // The context must be non-nil and will be used for request cancellation. If
  5469. // the context is nil a panic will occur. In the future the SDK may create
  5470. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5471. // for more information on using Contexts.
  5472. func (c *S3) PutObjectTaggingWithContext(ctx aws.Context, input *PutObjectTaggingInput, opts ...request.Option) (*PutObjectTaggingOutput, error) {
  5473. req, out := c.PutObjectTaggingRequest(input)
  5474. req.SetContext(ctx)
  5475. req.ApplyOptions(opts...)
  5476. return out, req.Send()
  5477. }
  5478. const opRestoreObject = "RestoreObject"
  5479. // RestoreObjectRequest generates a "aws/request.Request" representing the
  5480. // client's request for the RestoreObject operation. The "output" return
  5481. // value will be populated with the request's response once the request complets
  5482. // successfuly.
  5483. //
  5484. // Use "Send" method on the returned Request to send the API call to the service.
  5485. // the "output" return value is not valid until after Send returns without error.
  5486. //
  5487. // See RestoreObject for more information on using the RestoreObject
  5488. // API call, and error handling.
  5489. //
  5490. // This method is useful when you want to inject custom logic or configuration
  5491. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5492. //
  5493. //
  5494. // // Example sending a request using the RestoreObjectRequest method.
  5495. // req, resp := client.RestoreObjectRequest(params)
  5496. //
  5497. // err := req.Send()
  5498. // if err == nil { // resp is now filled
  5499. // fmt.Println(resp)
  5500. // }
  5501. //
  5502. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObject
  5503. func (c *S3) RestoreObjectRequest(input *RestoreObjectInput) (req *request.Request, output *RestoreObjectOutput) {
  5504. op := &request.Operation{
  5505. Name: opRestoreObject,
  5506. HTTPMethod: "POST",
  5507. HTTPPath: "/{Bucket}/{Key+}?restore",
  5508. }
  5509. if input == nil {
  5510. input = &RestoreObjectInput{}
  5511. }
  5512. output = &RestoreObjectOutput{}
  5513. req = c.newRequest(op, input, output)
  5514. return
  5515. }
  5516. // RestoreObject API operation for Amazon Simple Storage Service.
  5517. //
  5518. // Restores an archived copy of an object back into Amazon S3
  5519. //
  5520. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5521. // with awserr.Error's Code and Message methods to get detailed information about
  5522. // the error.
  5523. //
  5524. // See the AWS API reference guide for Amazon Simple Storage Service's
  5525. // API operation RestoreObject for usage and error information.
  5526. //
  5527. // Returned Error Codes:
  5528. // * ErrCodeObjectAlreadyInActiveTierError "ObjectAlreadyInActiveTierError"
  5529. // This operation is not allowed against this storage tier
  5530. //
  5531. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObject
  5532. func (c *S3) RestoreObject(input *RestoreObjectInput) (*RestoreObjectOutput, error) {
  5533. req, out := c.RestoreObjectRequest(input)
  5534. return out, req.Send()
  5535. }
  5536. // RestoreObjectWithContext is the same as RestoreObject with the addition of
  5537. // the ability to pass a context and additional request options.
  5538. //
  5539. // See RestoreObject for details on how to use this API operation.
  5540. //
  5541. // The context must be non-nil and will be used for request cancellation. If
  5542. // the context is nil a panic will occur. In the future the SDK may create
  5543. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5544. // for more information on using Contexts.
  5545. func (c *S3) RestoreObjectWithContext(ctx aws.Context, input *RestoreObjectInput, opts ...request.Option) (*RestoreObjectOutput, error) {
  5546. req, out := c.RestoreObjectRequest(input)
  5547. req.SetContext(ctx)
  5548. req.ApplyOptions(opts...)
  5549. return out, req.Send()
  5550. }
  5551. const opUploadPart = "UploadPart"
  5552. // UploadPartRequest generates a "aws/request.Request" representing the
  5553. // client's request for the UploadPart operation. The "output" return
  5554. // value will be populated with the request's response once the request complets
  5555. // successfuly.
  5556. //
  5557. // Use "Send" method on the returned Request to send the API call to the service.
  5558. // the "output" return value is not valid until after Send returns without error.
  5559. //
  5560. // See UploadPart for more information on using the UploadPart
  5561. // API call, and error handling.
  5562. //
  5563. // This method is useful when you want to inject custom logic or configuration
  5564. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5565. //
  5566. //
  5567. // // Example sending a request using the UploadPartRequest method.
  5568. // req, resp := client.UploadPartRequest(params)
  5569. //
  5570. // err := req.Send()
  5571. // if err == nil { // resp is now filled
  5572. // fmt.Println(resp)
  5573. // }
  5574. //
  5575. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPart
  5576. func (c *S3) UploadPartRequest(input *UploadPartInput) (req *request.Request, output *UploadPartOutput) {
  5577. op := &request.Operation{
  5578. Name: opUploadPart,
  5579. HTTPMethod: "PUT",
  5580. HTTPPath: "/{Bucket}/{Key+}",
  5581. }
  5582. if input == nil {
  5583. input = &UploadPartInput{}
  5584. }
  5585. output = &UploadPartOutput{}
  5586. req = c.newRequest(op, input, output)
  5587. return
  5588. }
  5589. // UploadPart API operation for Amazon Simple Storage Service.
  5590. //
  5591. // Uploads a part in a multipart upload.
  5592. //
  5593. // Note: After you initiate multipart upload and upload one or more parts, you
  5594. // must either complete or abort multipart upload in order to stop getting charged
  5595. // for storage of the uploaded parts. Only after you either complete or abort
  5596. // multipart upload, Amazon S3 frees up the parts storage and stops charging
  5597. // you for the parts storage.
  5598. //
  5599. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5600. // with awserr.Error's Code and Message methods to get detailed information about
  5601. // the error.
  5602. //
  5603. // See the AWS API reference guide for Amazon Simple Storage Service's
  5604. // API operation UploadPart for usage and error information.
  5605. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPart
  5606. func (c *S3) UploadPart(input *UploadPartInput) (*UploadPartOutput, error) {
  5607. req, out := c.UploadPartRequest(input)
  5608. return out, req.Send()
  5609. }
  5610. // UploadPartWithContext is the same as UploadPart with the addition of
  5611. // the ability to pass a context and additional request options.
  5612. //
  5613. // See UploadPart for details on how to use this API operation.
  5614. //
  5615. // The context must be non-nil and will be used for request cancellation. If
  5616. // the context is nil a panic will occur. In the future the SDK may create
  5617. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5618. // for more information on using Contexts.
  5619. func (c *S3) UploadPartWithContext(ctx aws.Context, input *UploadPartInput, opts ...request.Option) (*UploadPartOutput, error) {
  5620. req, out := c.UploadPartRequest(input)
  5621. req.SetContext(ctx)
  5622. req.ApplyOptions(opts...)
  5623. return out, req.Send()
  5624. }
  5625. const opUploadPartCopy = "UploadPartCopy"
  5626. // UploadPartCopyRequest generates a "aws/request.Request" representing the
  5627. // client's request for the UploadPartCopy operation. The "output" return
  5628. // value will be populated with the request's response once the request complets
  5629. // successfuly.
  5630. //
  5631. // Use "Send" method on the returned Request to send the API call to the service.
  5632. // the "output" return value is not valid until after Send returns without error.
  5633. //
  5634. // See UploadPartCopy for more information on using the UploadPartCopy
  5635. // API call, and error handling.
  5636. //
  5637. // This method is useful when you want to inject custom logic or configuration
  5638. // into the SDK's request lifecycle. Such as custom headers, or retry logic.
  5639. //
  5640. //
  5641. // // Example sending a request using the UploadPartCopyRequest method.
  5642. // req, resp := client.UploadPartCopyRequest(params)
  5643. //
  5644. // err := req.Send()
  5645. // if err == nil { // resp is now filled
  5646. // fmt.Println(resp)
  5647. // }
  5648. //
  5649. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopy
  5650. func (c *S3) UploadPartCopyRequest(input *UploadPartCopyInput) (req *request.Request, output *UploadPartCopyOutput) {
  5651. op := &request.Operation{
  5652. Name: opUploadPartCopy,
  5653. HTTPMethod: "PUT",
  5654. HTTPPath: "/{Bucket}/{Key+}",
  5655. }
  5656. if input == nil {
  5657. input = &UploadPartCopyInput{}
  5658. }
  5659. output = &UploadPartCopyOutput{}
  5660. req = c.newRequest(op, input, output)
  5661. return
  5662. }
  5663. // UploadPartCopy API operation for Amazon Simple Storage Service.
  5664. //
  5665. // Uploads a part by copying data from an existing object as data source.
  5666. //
  5667. // Returns awserr.Error for service API and SDK errors. Use runtime type assertions
  5668. // with awserr.Error's Code and Message methods to get detailed information about
  5669. // the error.
  5670. //
  5671. // See the AWS API reference guide for Amazon Simple Storage Service's
  5672. // API operation UploadPartCopy for usage and error information.
  5673. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopy
  5674. func (c *S3) UploadPartCopy(input *UploadPartCopyInput) (*UploadPartCopyOutput, error) {
  5675. req, out := c.UploadPartCopyRequest(input)
  5676. return out, req.Send()
  5677. }
  5678. // UploadPartCopyWithContext is the same as UploadPartCopy with the addition of
  5679. // the ability to pass a context and additional request options.
  5680. //
  5681. // See UploadPartCopy for details on how to use this API operation.
  5682. //
  5683. // The context must be non-nil and will be used for request cancellation. If
  5684. // the context is nil a panic will occur. In the future the SDK may create
  5685. // sub-contexts for http.Requests. See https://golang.org/pkg/context/
  5686. // for more information on using Contexts.
  5687. func (c *S3) UploadPartCopyWithContext(ctx aws.Context, input *UploadPartCopyInput, opts ...request.Option) (*UploadPartCopyOutput, error) {
  5688. req, out := c.UploadPartCopyRequest(input)
  5689. req.SetContext(ctx)
  5690. req.ApplyOptions(opts...)
  5691. return out, req.Send()
  5692. }
  5693. // Specifies the days since the initiation of an Incomplete Multipart Upload
  5694. // that Lifecycle will wait before permanently removing all parts of the upload.
  5695. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortIncompleteMultipartUpload
  5696. type AbortIncompleteMultipartUpload struct {
  5697. _ struct{} `type:"structure"`
  5698. // Indicates the number of days that must pass since initiation for Lifecycle
  5699. // to abort an Incomplete Multipart Upload.
  5700. DaysAfterInitiation *int64 `type:"integer"`
  5701. }
  5702. // String returns the string representation
  5703. func (s AbortIncompleteMultipartUpload) String() string {
  5704. return awsutil.Prettify(s)
  5705. }
  5706. // GoString returns the string representation
  5707. func (s AbortIncompleteMultipartUpload) GoString() string {
  5708. return s.String()
  5709. }
  5710. // SetDaysAfterInitiation sets the DaysAfterInitiation field's value.
  5711. func (s *AbortIncompleteMultipartUpload) SetDaysAfterInitiation(v int64) *AbortIncompleteMultipartUpload {
  5712. s.DaysAfterInitiation = &v
  5713. return s
  5714. }
  5715. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUploadRequest
  5716. type AbortMultipartUploadInput struct {
  5717. _ struct{} `type:"structure"`
  5718. // Bucket is a required field
  5719. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  5720. // Key is a required field
  5721. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  5722. // Confirms that the requester knows that she or he will be charged for the
  5723. // request. Bucket owners need not specify this parameter in their requests.
  5724. // Documentation on downloading objects from requester pays buckets can be found
  5725. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  5726. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  5727. // UploadId is a required field
  5728. UploadId *string `location:"querystring" locationName:"uploadId" type:"string" required:"true"`
  5729. }
  5730. // String returns the string representation
  5731. func (s AbortMultipartUploadInput) String() string {
  5732. return awsutil.Prettify(s)
  5733. }
  5734. // GoString returns the string representation
  5735. func (s AbortMultipartUploadInput) GoString() string {
  5736. return s.String()
  5737. }
  5738. // Validate inspects the fields of the type to determine if they are valid.
  5739. func (s *AbortMultipartUploadInput) Validate() error {
  5740. invalidParams := request.ErrInvalidParams{Context: "AbortMultipartUploadInput"}
  5741. if s.Bucket == nil {
  5742. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  5743. }
  5744. if s.Key == nil {
  5745. invalidParams.Add(request.NewErrParamRequired("Key"))
  5746. }
  5747. if s.Key != nil && len(*s.Key) < 1 {
  5748. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  5749. }
  5750. if s.UploadId == nil {
  5751. invalidParams.Add(request.NewErrParamRequired("UploadId"))
  5752. }
  5753. if invalidParams.Len() > 0 {
  5754. return invalidParams
  5755. }
  5756. return nil
  5757. }
  5758. // SetBucket sets the Bucket field's value.
  5759. func (s *AbortMultipartUploadInput) SetBucket(v string) *AbortMultipartUploadInput {
  5760. s.Bucket = &v
  5761. return s
  5762. }
  5763. func (s *AbortMultipartUploadInput) getBucket() (v string) {
  5764. if s.Bucket == nil {
  5765. return v
  5766. }
  5767. return *s.Bucket
  5768. }
  5769. // SetKey sets the Key field's value.
  5770. func (s *AbortMultipartUploadInput) SetKey(v string) *AbortMultipartUploadInput {
  5771. s.Key = &v
  5772. return s
  5773. }
  5774. // SetRequestPayer sets the RequestPayer field's value.
  5775. func (s *AbortMultipartUploadInput) SetRequestPayer(v string) *AbortMultipartUploadInput {
  5776. s.RequestPayer = &v
  5777. return s
  5778. }
  5779. // SetUploadId sets the UploadId field's value.
  5780. func (s *AbortMultipartUploadInput) SetUploadId(v string) *AbortMultipartUploadInput {
  5781. s.UploadId = &v
  5782. return s
  5783. }
  5784. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AbortMultipartUploadOutput
  5785. type AbortMultipartUploadOutput struct {
  5786. _ struct{} `type:"structure"`
  5787. // If present, indicates that the requester was successfully charged for the
  5788. // request.
  5789. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  5790. }
  5791. // String returns the string representation
  5792. func (s AbortMultipartUploadOutput) String() string {
  5793. return awsutil.Prettify(s)
  5794. }
  5795. // GoString returns the string representation
  5796. func (s AbortMultipartUploadOutput) GoString() string {
  5797. return s.String()
  5798. }
  5799. // SetRequestCharged sets the RequestCharged field's value.
  5800. func (s *AbortMultipartUploadOutput) SetRequestCharged(v string) *AbortMultipartUploadOutput {
  5801. s.RequestCharged = &v
  5802. return s
  5803. }
  5804. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccelerateConfiguration
  5805. type AccelerateConfiguration struct {
  5806. _ struct{} `type:"structure"`
  5807. // The accelerate configuration of the bucket.
  5808. Status *string `type:"string" enum:"BucketAccelerateStatus"`
  5809. }
  5810. // String returns the string representation
  5811. func (s AccelerateConfiguration) String() string {
  5812. return awsutil.Prettify(s)
  5813. }
  5814. // GoString returns the string representation
  5815. func (s AccelerateConfiguration) GoString() string {
  5816. return s.String()
  5817. }
  5818. // SetStatus sets the Status field's value.
  5819. func (s *AccelerateConfiguration) SetStatus(v string) *AccelerateConfiguration {
  5820. s.Status = &v
  5821. return s
  5822. }
  5823. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccessControlPolicy
  5824. type AccessControlPolicy struct {
  5825. _ struct{} `type:"structure"`
  5826. // A list of grants.
  5827. Grants []*Grant `locationName:"AccessControlList" locationNameList:"Grant" type:"list"`
  5828. Owner *Owner `type:"structure"`
  5829. }
  5830. // String returns the string representation
  5831. func (s AccessControlPolicy) String() string {
  5832. return awsutil.Prettify(s)
  5833. }
  5834. // GoString returns the string representation
  5835. func (s AccessControlPolicy) GoString() string {
  5836. return s.String()
  5837. }
  5838. // Validate inspects the fields of the type to determine if they are valid.
  5839. func (s *AccessControlPolicy) Validate() error {
  5840. invalidParams := request.ErrInvalidParams{Context: "AccessControlPolicy"}
  5841. if s.Grants != nil {
  5842. for i, v := range s.Grants {
  5843. if v == nil {
  5844. continue
  5845. }
  5846. if err := v.Validate(); err != nil {
  5847. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Grants", i), err.(request.ErrInvalidParams))
  5848. }
  5849. }
  5850. }
  5851. if invalidParams.Len() > 0 {
  5852. return invalidParams
  5853. }
  5854. return nil
  5855. }
  5856. // SetGrants sets the Grants field's value.
  5857. func (s *AccessControlPolicy) SetGrants(v []*Grant) *AccessControlPolicy {
  5858. s.Grants = v
  5859. return s
  5860. }
  5861. // SetOwner sets the Owner field's value.
  5862. func (s *AccessControlPolicy) SetOwner(v *Owner) *AccessControlPolicy {
  5863. s.Owner = v
  5864. return s
  5865. }
  5866. // Container for information regarding the access control for replicas.
  5867. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccessControlTranslation
  5868. type AccessControlTranslation struct {
  5869. _ struct{} `type:"structure"`
  5870. // The override value for the owner of the replica object.
  5871. //
  5872. // Owner is a required field
  5873. Owner *string `type:"string" required:"true" enum:"OwnerOverride"`
  5874. }
  5875. // String returns the string representation
  5876. func (s AccessControlTranslation) String() string {
  5877. return awsutil.Prettify(s)
  5878. }
  5879. // GoString returns the string representation
  5880. func (s AccessControlTranslation) GoString() string {
  5881. return s.String()
  5882. }
  5883. // Validate inspects the fields of the type to determine if they are valid.
  5884. func (s *AccessControlTranslation) Validate() error {
  5885. invalidParams := request.ErrInvalidParams{Context: "AccessControlTranslation"}
  5886. if s.Owner == nil {
  5887. invalidParams.Add(request.NewErrParamRequired("Owner"))
  5888. }
  5889. if invalidParams.Len() > 0 {
  5890. return invalidParams
  5891. }
  5892. return nil
  5893. }
  5894. // SetOwner sets the Owner field's value.
  5895. func (s *AccessControlTranslation) SetOwner(v string) *AccessControlTranslation {
  5896. s.Owner = &v
  5897. return s
  5898. }
  5899. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsAndOperator
  5900. type AnalyticsAndOperator struct {
  5901. _ struct{} `type:"structure"`
  5902. // The prefix to use when evaluating an AND predicate.
  5903. Prefix *string `type:"string"`
  5904. // The list of tags to use when evaluating an AND predicate.
  5905. Tags []*Tag `locationName:"Tag" locationNameList:"Tag" type:"list" flattened:"true"`
  5906. }
  5907. // String returns the string representation
  5908. func (s AnalyticsAndOperator) String() string {
  5909. return awsutil.Prettify(s)
  5910. }
  5911. // GoString returns the string representation
  5912. func (s AnalyticsAndOperator) GoString() string {
  5913. return s.String()
  5914. }
  5915. // Validate inspects the fields of the type to determine if they are valid.
  5916. func (s *AnalyticsAndOperator) Validate() error {
  5917. invalidParams := request.ErrInvalidParams{Context: "AnalyticsAndOperator"}
  5918. if s.Tags != nil {
  5919. for i, v := range s.Tags {
  5920. if v == nil {
  5921. continue
  5922. }
  5923. if err := v.Validate(); err != nil {
  5924. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
  5925. }
  5926. }
  5927. }
  5928. if invalidParams.Len() > 0 {
  5929. return invalidParams
  5930. }
  5931. return nil
  5932. }
  5933. // SetPrefix sets the Prefix field's value.
  5934. func (s *AnalyticsAndOperator) SetPrefix(v string) *AnalyticsAndOperator {
  5935. s.Prefix = &v
  5936. return s
  5937. }
  5938. // SetTags sets the Tags field's value.
  5939. func (s *AnalyticsAndOperator) SetTags(v []*Tag) *AnalyticsAndOperator {
  5940. s.Tags = v
  5941. return s
  5942. }
  5943. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsConfiguration
  5944. type AnalyticsConfiguration struct {
  5945. _ struct{} `type:"structure"`
  5946. // The filter used to describe a set of objects for analyses. A filter must
  5947. // have exactly one prefix, one tag, or one conjunction (AnalyticsAndOperator).
  5948. // If no filter is provided, all objects will be considered in any analysis.
  5949. Filter *AnalyticsFilter `type:"structure"`
  5950. // The identifier used to represent an analytics configuration.
  5951. //
  5952. // Id is a required field
  5953. Id *string `type:"string" required:"true"`
  5954. // If present, it indicates that data related to access patterns will be collected
  5955. // and made available to analyze the tradeoffs between different storage classes.
  5956. //
  5957. // StorageClassAnalysis is a required field
  5958. StorageClassAnalysis *StorageClassAnalysis `type:"structure" required:"true"`
  5959. }
  5960. // String returns the string representation
  5961. func (s AnalyticsConfiguration) String() string {
  5962. return awsutil.Prettify(s)
  5963. }
  5964. // GoString returns the string representation
  5965. func (s AnalyticsConfiguration) GoString() string {
  5966. return s.String()
  5967. }
  5968. // Validate inspects the fields of the type to determine if they are valid.
  5969. func (s *AnalyticsConfiguration) Validate() error {
  5970. invalidParams := request.ErrInvalidParams{Context: "AnalyticsConfiguration"}
  5971. if s.Id == nil {
  5972. invalidParams.Add(request.NewErrParamRequired("Id"))
  5973. }
  5974. if s.StorageClassAnalysis == nil {
  5975. invalidParams.Add(request.NewErrParamRequired("StorageClassAnalysis"))
  5976. }
  5977. if s.Filter != nil {
  5978. if err := s.Filter.Validate(); err != nil {
  5979. invalidParams.AddNested("Filter", err.(request.ErrInvalidParams))
  5980. }
  5981. }
  5982. if s.StorageClassAnalysis != nil {
  5983. if err := s.StorageClassAnalysis.Validate(); err != nil {
  5984. invalidParams.AddNested("StorageClassAnalysis", err.(request.ErrInvalidParams))
  5985. }
  5986. }
  5987. if invalidParams.Len() > 0 {
  5988. return invalidParams
  5989. }
  5990. return nil
  5991. }
  5992. // SetFilter sets the Filter field's value.
  5993. func (s *AnalyticsConfiguration) SetFilter(v *AnalyticsFilter) *AnalyticsConfiguration {
  5994. s.Filter = v
  5995. return s
  5996. }
  5997. // SetId sets the Id field's value.
  5998. func (s *AnalyticsConfiguration) SetId(v string) *AnalyticsConfiguration {
  5999. s.Id = &v
  6000. return s
  6001. }
  6002. // SetStorageClassAnalysis sets the StorageClassAnalysis field's value.
  6003. func (s *AnalyticsConfiguration) SetStorageClassAnalysis(v *StorageClassAnalysis) *AnalyticsConfiguration {
  6004. s.StorageClassAnalysis = v
  6005. return s
  6006. }
  6007. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsExportDestination
  6008. type AnalyticsExportDestination struct {
  6009. _ struct{} `type:"structure"`
  6010. // A destination signifying output to an S3 bucket.
  6011. //
  6012. // S3BucketDestination is a required field
  6013. S3BucketDestination *AnalyticsS3BucketDestination `type:"structure" required:"true"`
  6014. }
  6015. // String returns the string representation
  6016. func (s AnalyticsExportDestination) String() string {
  6017. return awsutil.Prettify(s)
  6018. }
  6019. // GoString returns the string representation
  6020. func (s AnalyticsExportDestination) GoString() string {
  6021. return s.String()
  6022. }
  6023. // Validate inspects the fields of the type to determine if they are valid.
  6024. func (s *AnalyticsExportDestination) Validate() error {
  6025. invalidParams := request.ErrInvalidParams{Context: "AnalyticsExportDestination"}
  6026. if s.S3BucketDestination == nil {
  6027. invalidParams.Add(request.NewErrParamRequired("S3BucketDestination"))
  6028. }
  6029. if s.S3BucketDestination != nil {
  6030. if err := s.S3BucketDestination.Validate(); err != nil {
  6031. invalidParams.AddNested("S3BucketDestination", err.(request.ErrInvalidParams))
  6032. }
  6033. }
  6034. if invalidParams.Len() > 0 {
  6035. return invalidParams
  6036. }
  6037. return nil
  6038. }
  6039. // SetS3BucketDestination sets the S3BucketDestination field's value.
  6040. func (s *AnalyticsExportDestination) SetS3BucketDestination(v *AnalyticsS3BucketDestination) *AnalyticsExportDestination {
  6041. s.S3BucketDestination = v
  6042. return s
  6043. }
  6044. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsFilter
  6045. type AnalyticsFilter struct {
  6046. _ struct{} `type:"structure"`
  6047. // A conjunction (logical AND) of predicates, which is used in evaluating an
  6048. // analytics filter. The operator must have at least two predicates.
  6049. And *AnalyticsAndOperator `type:"structure"`
  6050. // The prefix to use when evaluating an analytics filter.
  6051. Prefix *string `type:"string"`
  6052. // The tag to use when evaluating an analytics filter.
  6053. Tag *Tag `type:"structure"`
  6054. }
  6055. // String returns the string representation
  6056. func (s AnalyticsFilter) String() string {
  6057. return awsutil.Prettify(s)
  6058. }
  6059. // GoString returns the string representation
  6060. func (s AnalyticsFilter) GoString() string {
  6061. return s.String()
  6062. }
  6063. // Validate inspects the fields of the type to determine if they are valid.
  6064. func (s *AnalyticsFilter) Validate() error {
  6065. invalidParams := request.ErrInvalidParams{Context: "AnalyticsFilter"}
  6066. if s.And != nil {
  6067. if err := s.And.Validate(); err != nil {
  6068. invalidParams.AddNested("And", err.(request.ErrInvalidParams))
  6069. }
  6070. }
  6071. if s.Tag != nil {
  6072. if err := s.Tag.Validate(); err != nil {
  6073. invalidParams.AddNested("Tag", err.(request.ErrInvalidParams))
  6074. }
  6075. }
  6076. if invalidParams.Len() > 0 {
  6077. return invalidParams
  6078. }
  6079. return nil
  6080. }
  6081. // SetAnd sets the And field's value.
  6082. func (s *AnalyticsFilter) SetAnd(v *AnalyticsAndOperator) *AnalyticsFilter {
  6083. s.And = v
  6084. return s
  6085. }
  6086. // SetPrefix sets the Prefix field's value.
  6087. func (s *AnalyticsFilter) SetPrefix(v string) *AnalyticsFilter {
  6088. s.Prefix = &v
  6089. return s
  6090. }
  6091. // SetTag sets the Tag field's value.
  6092. func (s *AnalyticsFilter) SetTag(v *Tag) *AnalyticsFilter {
  6093. s.Tag = v
  6094. return s
  6095. }
  6096. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AnalyticsS3BucketDestination
  6097. type AnalyticsS3BucketDestination struct {
  6098. _ struct{} `type:"structure"`
  6099. // The Amazon resource name (ARN) of the bucket to which data is exported.
  6100. //
  6101. // Bucket is a required field
  6102. Bucket *string `type:"string" required:"true"`
  6103. // The account ID that owns the destination bucket. If no account ID is provided,
  6104. // the owner will not be validated prior to exporting data.
  6105. BucketAccountId *string `type:"string"`
  6106. // The file format used when exporting data to Amazon S3.
  6107. //
  6108. // Format is a required field
  6109. Format *string `type:"string" required:"true" enum:"AnalyticsS3ExportFileFormat"`
  6110. // The prefix to use when exporting data. The exported data begins with this
  6111. // prefix.
  6112. Prefix *string `type:"string"`
  6113. }
  6114. // String returns the string representation
  6115. func (s AnalyticsS3BucketDestination) String() string {
  6116. return awsutil.Prettify(s)
  6117. }
  6118. // GoString returns the string representation
  6119. func (s AnalyticsS3BucketDestination) GoString() string {
  6120. return s.String()
  6121. }
  6122. // Validate inspects the fields of the type to determine if they are valid.
  6123. func (s *AnalyticsS3BucketDestination) Validate() error {
  6124. invalidParams := request.ErrInvalidParams{Context: "AnalyticsS3BucketDestination"}
  6125. if s.Bucket == nil {
  6126. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  6127. }
  6128. if s.Format == nil {
  6129. invalidParams.Add(request.NewErrParamRequired("Format"))
  6130. }
  6131. if invalidParams.Len() > 0 {
  6132. return invalidParams
  6133. }
  6134. return nil
  6135. }
  6136. // SetBucket sets the Bucket field's value.
  6137. func (s *AnalyticsS3BucketDestination) SetBucket(v string) *AnalyticsS3BucketDestination {
  6138. s.Bucket = &v
  6139. return s
  6140. }
  6141. func (s *AnalyticsS3BucketDestination) getBucket() (v string) {
  6142. if s.Bucket == nil {
  6143. return v
  6144. }
  6145. return *s.Bucket
  6146. }
  6147. // SetBucketAccountId sets the BucketAccountId field's value.
  6148. func (s *AnalyticsS3BucketDestination) SetBucketAccountId(v string) *AnalyticsS3BucketDestination {
  6149. s.BucketAccountId = &v
  6150. return s
  6151. }
  6152. // SetFormat sets the Format field's value.
  6153. func (s *AnalyticsS3BucketDestination) SetFormat(v string) *AnalyticsS3BucketDestination {
  6154. s.Format = &v
  6155. return s
  6156. }
  6157. // SetPrefix sets the Prefix field's value.
  6158. func (s *AnalyticsS3BucketDestination) SetPrefix(v string) *AnalyticsS3BucketDestination {
  6159. s.Prefix = &v
  6160. return s
  6161. }
  6162. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Bucket
  6163. type Bucket struct {
  6164. _ struct{} `type:"structure"`
  6165. // Date the bucket was created.
  6166. CreationDate *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  6167. // The name of the bucket.
  6168. Name *string `type:"string"`
  6169. }
  6170. // String returns the string representation
  6171. func (s Bucket) String() string {
  6172. return awsutil.Prettify(s)
  6173. }
  6174. // GoString returns the string representation
  6175. func (s Bucket) GoString() string {
  6176. return s.String()
  6177. }
  6178. // SetCreationDate sets the CreationDate field's value.
  6179. func (s *Bucket) SetCreationDate(v time.Time) *Bucket {
  6180. s.CreationDate = &v
  6181. return s
  6182. }
  6183. // SetName sets the Name field's value.
  6184. func (s *Bucket) SetName(v string) *Bucket {
  6185. s.Name = &v
  6186. return s
  6187. }
  6188. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketLifecycleConfiguration
  6189. type BucketLifecycleConfiguration struct {
  6190. _ struct{} `type:"structure"`
  6191. // Rules is a required field
  6192. Rules []*LifecycleRule `locationName:"Rule" type:"list" flattened:"true" required:"true"`
  6193. }
  6194. // String returns the string representation
  6195. func (s BucketLifecycleConfiguration) String() string {
  6196. return awsutil.Prettify(s)
  6197. }
  6198. // GoString returns the string representation
  6199. func (s BucketLifecycleConfiguration) GoString() string {
  6200. return s.String()
  6201. }
  6202. // Validate inspects the fields of the type to determine if they are valid.
  6203. func (s *BucketLifecycleConfiguration) Validate() error {
  6204. invalidParams := request.ErrInvalidParams{Context: "BucketLifecycleConfiguration"}
  6205. if s.Rules == nil {
  6206. invalidParams.Add(request.NewErrParamRequired("Rules"))
  6207. }
  6208. if s.Rules != nil {
  6209. for i, v := range s.Rules {
  6210. if v == nil {
  6211. continue
  6212. }
  6213. if err := v.Validate(); err != nil {
  6214. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams))
  6215. }
  6216. }
  6217. }
  6218. if invalidParams.Len() > 0 {
  6219. return invalidParams
  6220. }
  6221. return nil
  6222. }
  6223. // SetRules sets the Rules field's value.
  6224. func (s *BucketLifecycleConfiguration) SetRules(v []*LifecycleRule) *BucketLifecycleConfiguration {
  6225. s.Rules = v
  6226. return s
  6227. }
  6228. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/BucketLoggingStatus
  6229. type BucketLoggingStatus struct {
  6230. _ struct{} `type:"structure"`
  6231. LoggingEnabled *LoggingEnabled `type:"structure"`
  6232. }
  6233. // String returns the string representation
  6234. func (s BucketLoggingStatus) String() string {
  6235. return awsutil.Prettify(s)
  6236. }
  6237. // GoString returns the string representation
  6238. func (s BucketLoggingStatus) GoString() string {
  6239. return s.String()
  6240. }
  6241. // Validate inspects the fields of the type to determine if they are valid.
  6242. func (s *BucketLoggingStatus) Validate() error {
  6243. invalidParams := request.ErrInvalidParams{Context: "BucketLoggingStatus"}
  6244. if s.LoggingEnabled != nil {
  6245. if err := s.LoggingEnabled.Validate(); err != nil {
  6246. invalidParams.AddNested("LoggingEnabled", err.(request.ErrInvalidParams))
  6247. }
  6248. }
  6249. if invalidParams.Len() > 0 {
  6250. return invalidParams
  6251. }
  6252. return nil
  6253. }
  6254. // SetLoggingEnabled sets the LoggingEnabled field's value.
  6255. func (s *BucketLoggingStatus) SetLoggingEnabled(v *LoggingEnabled) *BucketLoggingStatus {
  6256. s.LoggingEnabled = v
  6257. return s
  6258. }
  6259. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CORSConfiguration
  6260. type CORSConfiguration struct {
  6261. _ struct{} `type:"structure"`
  6262. // CORSRules is a required field
  6263. CORSRules []*CORSRule `locationName:"CORSRule" type:"list" flattened:"true" required:"true"`
  6264. }
  6265. // String returns the string representation
  6266. func (s CORSConfiguration) String() string {
  6267. return awsutil.Prettify(s)
  6268. }
  6269. // GoString returns the string representation
  6270. func (s CORSConfiguration) GoString() string {
  6271. return s.String()
  6272. }
  6273. // Validate inspects the fields of the type to determine if they are valid.
  6274. func (s *CORSConfiguration) Validate() error {
  6275. invalidParams := request.ErrInvalidParams{Context: "CORSConfiguration"}
  6276. if s.CORSRules == nil {
  6277. invalidParams.Add(request.NewErrParamRequired("CORSRules"))
  6278. }
  6279. if s.CORSRules != nil {
  6280. for i, v := range s.CORSRules {
  6281. if v == nil {
  6282. continue
  6283. }
  6284. if err := v.Validate(); err != nil {
  6285. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "CORSRules", i), err.(request.ErrInvalidParams))
  6286. }
  6287. }
  6288. }
  6289. if invalidParams.Len() > 0 {
  6290. return invalidParams
  6291. }
  6292. return nil
  6293. }
  6294. // SetCORSRules sets the CORSRules field's value.
  6295. func (s *CORSConfiguration) SetCORSRules(v []*CORSRule) *CORSConfiguration {
  6296. s.CORSRules = v
  6297. return s
  6298. }
  6299. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CORSRule
  6300. type CORSRule struct {
  6301. _ struct{} `type:"structure"`
  6302. // Specifies which headers are allowed in a pre-flight OPTIONS request.
  6303. AllowedHeaders []*string `locationName:"AllowedHeader" type:"list" flattened:"true"`
  6304. // Identifies HTTP methods that the domain/origin specified in the rule is allowed
  6305. // to execute.
  6306. //
  6307. // AllowedMethods is a required field
  6308. AllowedMethods []*string `locationName:"AllowedMethod" type:"list" flattened:"true" required:"true"`
  6309. // One or more origins you want customers to be able to access the bucket from.
  6310. //
  6311. // AllowedOrigins is a required field
  6312. AllowedOrigins []*string `locationName:"AllowedOrigin" type:"list" flattened:"true" required:"true"`
  6313. // One or more headers in the response that you want customers to be able to
  6314. // access from their applications (for example, from a JavaScript XMLHttpRequest
  6315. // object).
  6316. ExposeHeaders []*string `locationName:"ExposeHeader" type:"list" flattened:"true"`
  6317. // The time in seconds that your browser is to cache the preflight response
  6318. // for the specified resource.
  6319. MaxAgeSeconds *int64 `type:"integer"`
  6320. }
  6321. // String returns the string representation
  6322. func (s CORSRule) String() string {
  6323. return awsutil.Prettify(s)
  6324. }
  6325. // GoString returns the string representation
  6326. func (s CORSRule) GoString() string {
  6327. return s.String()
  6328. }
  6329. // Validate inspects the fields of the type to determine if they are valid.
  6330. func (s *CORSRule) Validate() error {
  6331. invalidParams := request.ErrInvalidParams{Context: "CORSRule"}
  6332. if s.AllowedMethods == nil {
  6333. invalidParams.Add(request.NewErrParamRequired("AllowedMethods"))
  6334. }
  6335. if s.AllowedOrigins == nil {
  6336. invalidParams.Add(request.NewErrParamRequired("AllowedOrigins"))
  6337. }
  6338. if invalidParams.Len() > 0 {
  6339. return invalidParams
  6340. }
  6341. return nil
  6342. }
  6343. // SetAllowedHeaders sets the AllowedHeaders field's value.
  6344. func (s *CORSRule) SetAllowedHeaders(v []*string) *CORSRule {
  6345. s.AllowedHeaders = v
  6346. return s
  6347. }
  6348. // SetAllowedMethods sets the AllowedMethods field's value.
  6349. func (s *CORSRule) SetAllowedMethods(v []*string) *CORSRule {
  6350. s.AllowedMethods = v
  6351. return s
  6352. }
  6353. // SetAllowedOrigins sets the AllowedOrigins field's value.
  6354. func (s *CORSRule) SetAllowedOrigins(v []*string) *CORSRule {
  6355. s.AllowedOrigins = v
  6356. return s
  6357. }
  6358. // SetExposeHeaders sets the ExposeHeaders field's value.
  6359. func (s *CORSRule) SetExposeHeaders(v []*string) *CORSRule {
  6360. s.ExposeHeaders = v
  6361. return s
  6362. }
  6363. // SetMaxAgeSeconds sets the MaxAgeSeconds field's value.
  6364. func (s *CORSRule) SetMaxAgeSeconds(v int64) *CORSRule {
  6365. s.MaxAgeSeconds = &v
  6366. return s
  6367. }
  6368. // Describes how a CSV-formatted input object is formatted.
  6369. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CSVInput
  6370. type CSVInput struct {
  6371. _ struct{} `type:"structure"`
  6372. // Single character used to indicate a row should be ignored when present at
  6373. // the start of a row.
  6374. Comments *string `type:"string"`
  6375. // Value used to separate individual fields in a record.
  6376. FieldDelimiter *string `type:"string"`
  6377. // Describes the first line of input. Valid values: None, Ignore, Use.
  6378. FileHeaderInfo *string `type:"string" enum:"FileHeaderInfo"`
  6379. // Value used for escaping where the field delimiter is part of the value.
  6380. QuoteCharacter *string `type:"string"`
  6381. // Single character used for escaping the quote character inside an already
  6382. // escaped value.
  6383. QuoteEscapeCharacter *string `type:"string"`
  6384. // Value used to separate individual records.
  6385. RecordDelimiter *string `type:"string"`
  6386. }
  6387. // String returns the string representation
  6388. func (s CSVInput) String() string {
  6389. return awsutil.Prettify(s)
  6390. }
  6391. // GoString returns the string representation
  6392. func (s CSVInput) GoString() string {
  6393. return s.String()
  6394. }
  6395. // SetComments sets the Comments field's value.
  6396. func (s *CSVInput) SetComments(v string) *CSVInput {
  6397. s.Comments = &v
  6398. return s
  6399. }
  6400. // SetFieldDelimiter sets the FieldDelimiter field's value.
  6401. func (s *CSVInput) SetFieldDelimiter(v string) *CSVInput {
  6402. s.FieldDelimiter = &v
  6403. return s
  6404. }
  6405. // SetFileHeaderInfo sets the FileHeaderInfo field's value.
  6406. func (s *CSVInput) SetFileHeaderInfo(v string) *CSVInput {
  6407. s.FileHeaderInfo = &v
  6408. return s
  6409. }
  6410. // SetQuoteCharacter sets the QuoteCharacter field's value.
  6411. func (s *CSVInput) SetQuoteCharacter(v string) *CSVInput {
  6412. s.QuoteCharacter = &v
  6413. return s
  6414. }
  6415. // SetQuoteEscapeCharacter sets the QuoteEscapeCharacter field's value.
  6416. func (s *CSVInput) SetQuoteEscapeCharacter(v string) *CSVInput {
  6417. s.QuoteEscapeCharacter = &v
  6418. return s
  6419. }
  6420. // SetRecordDelimiter sets the RecordDelimiter field's value.
  6421. func (s *CSVInput) SetRecordDelimiter(v string) *CSVInput {
  6422. s.RecordDelimiter = &v
  6423. return s
  6424. }
  6425. // Describes how CSV-formatted results are formatted.
  6426. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CSVOutput
  6427. type CSVOutput struct {
  6428. _ struct{} `type:"structure"`
  6429. // Value used to separate individual fields in a record.
  6430. FieldDelimiter *string `type:"string"`
  6431. // Value used for escaping where the field delimiter is part of the value.
  6432. QuoteCharacter *string `type:"string"`
  6433. // Single character used for escaping the quote character inside an already
  6434. // escaped value.
  6435. QuoteEscapeCharacter *string `type:"string"`
  6436. // Indicates whether or not all output fields should be quoted.
  6437. QuoteFields *string `type:"string" enum:"QuoteFields"`
  6438. // Value used to separate individual records.
  6439. RecordDelimiter *string `type:"string"`
  6440. }
  6441. // String returns the string representation
  6442. func (s CSVOutput) String() string {
  6443. return awsutil.Prettify(s)
  6444. }
  6445. // GoString returns the string representation
  6446. func (s CSVOutput) GoString() string {
  6447. return s.String()
  6448. }
  6449. // SetFieldDelimiter sets the FieldDelimiter field's value.
  6450. func (s *CSVOutput) SetFieldDelimiter(v string) *CSVOutput {
  6451. s.FieldDelimiter = &v
  6452. return s
  6453. }
  6454. // SetQuoteCharacter sets the QuoteCharacter field's value.
  6455. func (s *CSVOutput) SetQuoteCharacter(v string) *CSVOutput {
  6456. s.QuoteCharacter = &v
  6457. return s
  6458. }
  6459. // SetQuoteEscapeCharacter sets the QuoteEscapeCharacter field's value.
  6460. func (s *CSVOutput) SetQuoteEscapeCharacter(v string) *CSVOutput {
  6461. s.QuoteEscapeCharacter = &v
  6462. return s
  6463. }
  6464. // SetQuoteFields sets the QuoteFields field's value.
  6465. func (s *CSVOutput) SetQuoteFields(v string) *CSVOutput {
  6466. s.QuoteFields = &v
  6467. return s
  6468. }
  6469. // SetRecordDelimiter sets the RecordDelimiter field's value.
  6470. func (s *CSVOutput) SetRecordDelimiter(v string) *CSVOutput {
  6471. s.RecordDelimiter = &v
  6472. return s
  6473. }
  6474. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CloudFunctionConfiguration
  6475. type CloudFunctionConfiguration struct {
  6476. _ struct{} `type:"structure"`
  6477. CloudFunction *string `type:"string"`
  6478. // Bucket event for which to send notifications.
  6479. Event *string `deprecated:"true" type:"string" enum:"Event"`
  6480. Events []*string `locationName:"Event" type:"list" flattened:"true"`
  6481. // Optional unique identifier for configurations in a notification configuration.
  6482. // If you don't provide one, Amazon S3 will assign an ID.
  6483. Id *string `type:"string"`
  6484. InvocationRole *string `type:"string"`
  6485. }
  6486. // String returns the string representation
  6487. func (s CloudFunctionConfiguration) String() string {
  6488. return awsutil.Prettify(s)
  6489. }
  6490. // GoString returns the string representation
  6491. func (s CloudFunctionConfiguration) GoString() string {
  6492. return s.String()
  6493. }
  6494. // SetCloudFunction sets the CloudFunction field's value.
  6495. func (s *CloudFunctionConfiguration) SetCloudFunction(v string) *CloudFunctionConfiguration {
  6496. s.CloudFunction = &v
  6497. return s
  6498. }
  6499. // SetEvent sets the Event field's value.
  6500. func (s *CloudFunctionConfiguration) SetEvent(v string) *CloudFunctionConfiguration {
  6501. s.Event = &v
  6502. return s
  6503. }
  6504. // SetEvents sets the Events field's value.
  6505. func (s *CloudFunctionConfiguration) SetEvents(v []*string) *CloudFunctionConfiguration {
  6506. s.Events = v
  6507. return s
  6508. }
  6509. // SetId sets the Id field's value.
  6510. func (s *CloudFunctionConfiguration) SetId(v string) *CloudFunctionConfiguration {
  6511. s.Id = &v
  6512. return s
  6513. }
  6514. // SetInvocationRole sets the InvocationRole field's value.
  6515. func (s *CloudFunctionConfiguration) SetInvocationRole(v string) *CloudFunctionConfiguration {
  6516. s.InvocationRole = &v
  6517. return s
  6518. }
  6519. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CommonPrefix
  6520. type CommonPrefix struct {
  6521. _ struct{} `type:"structure"`
  6522. Prefix *string `type:"string"`
  6523. }
  6524. // String returns the string representation
  6525. func (s CommonPrefix) String() string {
  6526. return awsutil.Prettify(s)
  6527. }
  6528. // GoString returns the string representation
  6529. func (s CommonPrefix) GoString() string {
  6530. return s.String()
  6531. }
  6532. // SetPrefix sets the Prefix field's value.
  6533. func (s *CommonPrefix) SetPrefix(v string) *CommonPrefix {
  6534. s.Prefix = &v
  6535. return s
  6536. }
  6537. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUploadRequest
  6538. type CompleteMultipartUploadInput struct {
  6539. _ struct{} `type:"structure" payload:"MultipartUpload"`
  6540. // Bucket is a required field
  6541. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  6542. // Key is a required field
  6543. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  6544. MultipartUpload *CompletedMultipartUpload `locationName:"CompleteMultipartUpload" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  6545. // Confirms that the requester knows that she or he will be charged for the
  6546. // request. Bucket owners need not specify this parameter in their requests.
  6547. // Documentation on downloading objects from requester pays buckets can be found
  6548. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  6549. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  6550. // UploadId is a required field
  6551. UploadId *string `location:"querystring" locationName:"uploadId" type:"string" required:"true"`
  6552. }
  6553. // String returns the string representation
  6554. func (s CompleteMultipartUploadInput) String() string {
  6555. return awsutil.Prettify(s)
  6556. }
  6557. // GoString returns the string representation
  6558. func (s CompleteMultipartUploadInput) GoString() string {
  6559. return s.String()
  6560. }
  6561. // Validate inspects the fields of the type to determine if they are valid.
  6562. func (s *CompleteMultipartUploadInput) Validate() error {
  6563. invalidParams := request.ErrInvalidParams{Context: "CompleteMultipartUploadInput"}
  6564. if s.Bucket == nil {
  6565. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  6566. }
  6567. if s.Key == nil {
  6568. invalidParams.Add(request.NewErrParamRequired("Key"))
  6569. }
  6570. if s.Key != nil && len(*s.Key) < 1 {
  6571. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  6572. }
  6573. if s.UploadId == nil {
  6574. invalidParams.Add(request.NewErrParamRequired("UploadId"))
  6575. }
  6576. if invalidParams.Len() > 0 {
  6577. return invalidParams
  6578. }
  6579. return nil
  6580. }
  6581. // SetBucket sets the Bucket field's value.
  6582. func (s *CompleteMultipartUploadInput) SetBucket(v string) *CompleteMultipartUploadInput {
  6583. s.Bucket = &v
  6584. return s
  6585. }
  6586. func (s *CompleteMultipartUploadInput) getBucket() (v string) {
  6587. if s.Bucket == nil {
  6588. return v
  6589. }
  6590. return *s.Bucket
  6591. }
  6592. // SetKey sets the Key field's value.
  6593. func (s *CompleteMultipartUploadInput) SetKey(v string) *CompleteMultipartUploadInput {
  6594. s.Key = &v
  6595. return s
  6596. }
  6597. // SetMultipartUpload sets the MultipartUpload field's value.
  6598. func (s *CompleteMultipartUploadInput) SetMultipartUpload(v *CompletedMultipartUpload) *CompleteMultipartUploadInput {
  6599. s.MultipartUpload = v
  6600. return s
  6601. }
  6602. // SetRequestPayer sets the RequestPayer field's value.
  6603. func (s *CompleteMultipartUploadInput) SetRequestPayer(v string) *CompleteMultipartUploadInput {
  6604. s.RequestPayer = &v
  6605. return s
  6606. }
  6607. // SetUploadId sets the UploadId field's value.
  6608. func (s *CompleteMultipartUploadInput) SetUploadId(v string) *CompleteMultipartUploadInput {
  6609. s.UploadId = &v
  6610. return s
  6611. }
  6612. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompleteMultipartUploadOutput
  6613. type CompleteMultipartUploadOutput struct {
  6614. _ struct{} `type:"structure"`
  6615. Bucket *string `type:"string"`
  6616. // Entity tag of the object.
  6617. ETag *string `type:"string"`
  6618. // If the object expiration is configured, this will contain the expiration
  6619. // date (expiry-date) and rule ID (rule-id). The value of rule-id is URL encoded.
  6620. Expiration *string `location:"header" locationName:"x-amz-expiration" type:"string"`
  6621. Key *string `min:"1" type:"string"`
  6622. Location *string `type:"string"`
  6623. // If present, indicates that the requester was successfully charged for the
  6624. // request.
  6625. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  6626. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  6627. // encryption key that was used for the object.
  6628. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  6629. // The Server-side encryption algorithm used when storing this object in S3
  6630. // (e.g., AES256, aws:kms).
  6631. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  6632. // Version of the object.
  6633. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  6634. }
  6635. // String returns the string representation
  6636. func (s CompleteMultipartUploadOutput) String() string {
  6637. return awsutil.Prettify(s)
  6638. }
  6639. // GoString returns the string representation
  6640. func (s CompleteMultipartUploadOutput) GoString() string {
  6641. return s.String()
  6642. }
  6643. // SetBucket sets the Bucket field's value.
  6644. func (s *CompleteMultipartUploadOutput) SetBucket(v string) *CompleteMultipartUploadOutput {
  6645. s.Bucket = &v
  6646. return s
  6647. }
  6648. func (s *CompleteMultipartUploadOutput) getBucket() (v string) {
  6649. if s.Bucket == nil {
  6650. return v
  6651. }
  6652. return *s.Bucket
  6653. }
  6654. // SetETag sets the ETag field's value.
  6655. func (s *CompleteMultipartUploadOutput) SetETag(v string) *CompleteMultipartUploadOutput {
  6656. s.ETag = &v
  6657. return s
  6658. }
  6659. // SetExpiration sets the Expiration field's value.
  6660. func (s *CompleteMultipartUploadOutput) SetExpiration(v string) *CompleteMultipartUploadOutput {
  6661. s.Expiration = &v
  6662. return s
  6663. }
  6664. // SetKey sets the Key field's value.
  6665. func (s *CompleteMultipartUploadOutput) SetKey(v string) *CompleteMultipartUploadOutput {
  6666. s.Key = &v
  6667. return s
  6668. }
  6669. // SetLocation sets the Location field's value.
  6670. func (s *CompleteMultipartUploadOutput) SetLocation(v string) *CompleteMultipartUploadOutput {
  6671. s.Location = &v
  6672. return s
  6673. }
  6674. // SetRequestCharged sets the RequestCharged field's value.
  6675. func (s *CompleteMultipartUploadOutput) SetRequestCharged(v string) *CompleteMultipartUploadOutput {
  6676. s.RequestCharged = &v
  6677. return s
  6678. }
  6679. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  6680. func (s *CompleteMultipartUploadOutput) SetSSEKMSKeyId(v string) *CompleteMultipartUploadOutput {
  6681. s.SSEKMSKeyId = &v
  6682. return s
  6683. }
  6684. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  6685. func (s *CompleteMultipartUploadOutput) SetServerSideEncryption(v string) *CompleteMultipartUploadOutput {
  6686. s.ServerSideEncryption = &v
  6687. return s
  6688. }
  6689. // SetVersionId sets the VersionId field's value.
  6690. func (s *CompleteMultipartUploadOutput) SetVersionId(v string) *CompleteMultipartUploadOutput {
  6691. s.VersionId = &v
  6692. return s
  6693. }
  6694. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompletedMultipartUpload
  6695. type CompletedMultipartUpload struct {
  6696. _ struct{} `type:"structure"`
  6697. Parts []*CompletedPart `locationName:"Part" type:"list" flattened:"true"`
  6698. }
  6699. // String returns the string representation
  6700. func (s CompletedMultipartUpload) String() string {
  6701. return awsutil.Prettify(s)
  6702. }
  6703. // GoString returns the string representation
  6704. func (s CompletedMultipartUpload) GoString() string {
  6705. return s.String()
  6706. }
  6707. // SetParts sets the Parts field's value.
  6708. func (s *CompletedMultipartUpload) SetParts(v []*CompletedPart) *CompletedMultipartUpload {
  6709. s.Parts = v
  6710. return s
  6711. }
  6712. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CompletedPart
  6713. type CompletedPart struct {
  6714. _ struct{} `type:"structure"`
  6715. // Entity tag returned when the part was uploaded.
  6716. ETag *string `type:"string"`
  6717. // Part number that identifies the part. This is a positive integer between
  6718. // 1 and 10,000.
  6719. PartNumber *int64 `type:"integer"`
  6720. }
  6721. // String returns the string representation
  6722. func (s CompletedPart) String() string {
  6723. return awsutil.Prettify(s)
  6724. }
  6725. // GoString returns the string representation
  6726. func (s CompletedPart) GoString() string {
  6727. return s.String()
  6728. }
  6729. // SetETag sets the ETag field's value.
  6730. func (s *CompletedPart) SetETag(v string) *CompletedPart {
  6731. s.ETag = &v
  6732. return s
  6733. }
  6734. // SetPartNumber sets the PartNumber field's value.
  6735. func (s *CompletedPart) SetPartNumber(v int64) *CompletedPart {
  6736. s.PartNumber = &v
  6737. return s
  6738. }
  6739. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Condition
  6740. type Condition struct {
  6741. _ struct{} `type:"structure"`
  6742. // The HTTP error code when the redirect is applied. In the event of an error,
  6743. // if the error code equals this value, then the specified redirect is applied.
  6744. // Required when parent element Condition is specified and sibling KeyPrefixEquals
  6745. // is not specified. If both are specified, then both must be true for the redirect
  6746. // to be applied.
  6747. HttpErrorCodeReturnedEquals *string `type:"string"`
  6748. // The object key name prefix when the redirect is applied. For example, to
  6749. // redirect requests for ExamplePage.html, the key prefix will be ExamplePage.html.
  6750. // To redirect request for all pages with the prefix docs/, the key prefix will
  6751. // be /docs, which identifies all objects in the docs/ folder. Required when
  6752. // the parent element Condition is specified and sibling HttpErrorCodeReturnedEquals
  6753. // is not specified. If both conditions are specified, both must be true for
  6754. // the redirect to be applied.
  6755. KeyPrefixEquals *string `type:"string"`
  6756. }
  6757. // String returns the string representation
  6758. func (s Condition) String() string {
  6759. return awsutil.Prettify(s)
  6760. }
  6761. // GoString returns the string representation
  6762. func (s Condition) GoString() string {
  6763. return s.String()
  6764. }
  6765. // SetHttpErrorCodeReturnedEquals sets the HttpErrorCodeReturnedEquals field's value.
  6766. func (s *Condition) SetHttpErrorCodeReturnedEquals(v string) *Condition {
  6767. s.HttpErrorCodeReturnedEquals = &v
  6768. return s
  6769. }
  6770. // SetKeyPrefixEquals sets the KeyPrefixEquals field's value.
  6771. func (s *Condition) SetKeyPrefixEquals(v string) *Condition {
  6772. s.KeyPrefixEquals = &v
  6773. return s
  6774. }
  6775. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectRequest
  6776. type CopyObjectInput struct {
  6777. _ struct{} `type:"structure"`
  6778. // The canned ACL to apply to the object.
  6779. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"ObjectCannedACL"`
  6780. // Bucket is a required field
  6781. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  6782. // Specifies caching behavior along the request/reply chain.
  6783. CacheControl *string `location:"header" locationName:"Cache-Control" type:"string"`
  6784. // Specifies presentational information for the object.
  6785. ContentDisposition *string `location:"header" locationName:"Content-Disposition" type:"string"`
  6786. // Specifies what content encodings have been applied to the object and thus
  6787. // what decoding mechanisms must be applied to obtain the media-type referenced
  6788. // by the Content-Type header field.
  6789. ContentEncoding *string `location:"header" locationName:"Content-Encoding" type:"string"`
  6790. // The language the content is in.
  6791. ContentLanguage *string `location:"header" locationName:"Content-Language" type:"string"`
  6792. // A standard MIME type describing the format of the object data.
  6793. ContentType *string `location:"header" locationName:"Content-Type" type:"string"`
  6794. // The name of the source bucket and key name of the source object, separated
  6795. // by a slash (/). Must be URL-encoded.
  6796. //
  6797. // CopySource is a required field
  6798. CopySource *string `location:"header" locationName:"x-amz-copy-source" type:"string" required:"true"`
  6799. // Copies the object if its entity tag (ETag) matches the specified tag.
  6800. CopySourceIfMatch *string `location:"header" locationName:"x-amz-copy-source-if-match" type:"string"`
  6801. // Copies the object if it has been modified since the specified time.
  6802. CopySourceIfModifiedSince *time.Time `location:"header" locationName:"x-amz-copy-source-if-modified-since" type:"timestamp" timestampFormat:"rfc822"`
  6803. // Copies the object if its entity tag (ETag) is different than the specified
  6804. // ETag.
  6805. CopySourceIfNoneMatch *string `location:"header" locationName:"x-amz-copy-source-if-none-match" type:"string"`
  6806. // Copies the object if it hasn't been modified since the specified time.
  6807. CopySourceIfUnmodifiedSince *time.Time `location:"header" locationName:"x-amz-copy-source-if-unmodified-since" type:"timestamp" timestampFormat:"rfc822"`
  6808. // Specifies the algorithm to use when decrypting the source object (e.g., AES256).
  6809. CopySourceSSECustomerAlgorithm *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-algorithm" type:"string"`
  6810. // Specifies the customer-provided encryption key for Amazon S3 to use to decrypt
  6811. // the source object. The encryption key provided in this header must be one
  6812. // that was used when the source object was created.
  6813. CopySourceSSECustomerKey *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-key" type:"string"`
  6814. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  6815. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  6816. // key was transmitted without error.
  6817. CopySourceSSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-key-MD5" type:"string"`
  6818. // The date and time at which the object is no longer cacheable.
  6819. Expires *time.Time `location:"header" locationName:"Expires" type:"timestamp" timestampFormat:"rfc822"`
  6820. // Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.
  6821. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  6822. // Allows grantee to read the object data and its metadata.
  6823. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  6824. // Allows grantee to read the object ACL.
  6825. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  6826. // Allows grantee to write the ACL for the applicable object.
  6827. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  6828. // Key is a required field
  6829. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  6830. // A map of metadata to store with the object in S3.
  6831. Metadata map[string]*string `location:"headers" locationName:"x-amz-meta-" type:"map"`
  6832. // Specifies whether the metadata is copied from the source object or replaced
  6833. // with metadata provided in the request.
  6834. MetadataDirective *string `location:"header" locationName:"x-amz-metadata-directive" type:"string" enum:"MetadataDirective"`
  6835. // Confirms that the requester knows that she or he will be charged for the
  6836. // request. Bucket owners need not specify this parameter in their requests.
  6837. // Documentation on downloading objects from requester pays buckets can be found
  6838. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  6839. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  6840. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  6841. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  6842. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  6843. // data. This value is used to store the object and then it is discarded; Amazon
  6844. // does not store the encryption key. The key must be appropriate for use with
  6845. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  6846. // header.
  6847. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  6848. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  6849. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  6850. // key was transmitted without error.
  6851. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  6852. // Specifies the AWS KMS key ID to use for object encryption. All GET and PUT
  6853. // requests for an object protected by AWS KMS will fail if not made via SSL
  6854. // or using SigV4. Documentation on configuring any of the officially supported
  6855. // AWS SDKs and CLI can be found at http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
  6856. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  6857. // The Server-side encryption algorithm used when storing this object in S3
  6858. // (e.g., AES256, aws:kms).
  6859. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  6860. // The type of storage to use for the object. Defaults to 'STANDARD'.
  6861. StorageClass *string `location:"header" locationName:"x-amz-storage-class" type:"string" enum:"StorageClass"`
  6862. // The tag-set for the object destination object this value must be used in
  6863. // conjunction with the TaggingDirective. The tag-set must be encoded as URL
  6864. // Query parameters
  6865. Tagging *string `location:"header" locationName:"x-amz-tagging" type:"string"`
  6866. // Specifies whether the object tag-set are copied from the source object or
  6867. // replaced with tag-set provided in the request.
  6868. TaggingDirective *string `location:"header" locationName:"x-amz-tagging-directive" type:"string" enum:"TaggingDirective"`
  6869. // If the bucket is configured as a website, redirects requests for this object
  6870. // to another object in the same bucket or to an external URL. Amazon S3 stores
  6871. // the value of this header in the object metadata.
  6872. WebsiteRedirectLocation *string `location:"header" locationName:"x-amz-website-redirect-location" type:"string"`
  6873. }
  6874. // String returns the string representation
  6875. func (s CopyObjectInput) String() string {
  6876. return awsutil.Prettify(s)
  6877. }
  6878. // GoString returns the string representation
  6879. func (s CopyObjectInput) GoString() string {
  6880. return s.String()
  6881. }
  6882. // Validate inspects the fields of the type to determine if they are valid.
  6883. func (s *CopyObjectInput) Validate() error {
  6884. invalidParams := request.ErrInvalidParams{Context: "CopyObjectInput"}
  6885. if s.Bucket == nil {
  6886. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  6887. }
  6888. if s.CopySource == nil {
  6889. invalidParams.Add(request.NewErrParamRequired("CopySource"))
  6890. }
  6891. if s.Key == nil {
  6892. invalidParams.Add(request.NewErrParamRequired("Key"))
  6893. }
  6894. if s.Key != nil && len(*s.Key) < 1 {
  6895. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  6896. }
  6897. if invalidParams.Len() > 0 {
  6898. return invalidParams
  6899. }
  6900. return nil
  6901. }
  6902. // SetACL sets the ACL field's value.
  6903. func (s *CopyObjectInput) SetACL(v string) *CopyObjectInput {
  6904. s.ACL = &v
  6905. return s
  6906. }
  6907. // SetBucket sets the Bucket field's value.
  6908. func (s *CopyObjectInput) SetBucket(v string) *CopyObjectInput {
  6909. s.Bucket = &v
  6910. return s
  6911. }
  6912. func (s *CopyObjectInput) getBucket() (v string) {
  6913. if s.Bucket == nil {
  6914. return v
  6915. }
  6916. return *s.Bucket
  6917. }
  6918. // SetCacheControl sets the CacheControl field's value.
  6919. func (s *CopyObjectInput) SetCacheControl(v string) *CopyObjectInput {
  6920. s.CacheControl = &v
  6921. return s
  6922. }
  6923. // SetContentDisposition sets the ContentDisposition field's value.
  6924. func (s *CopyObjectInput) SetContentDisposition(v string) *CopyObjectInput {
  6925. s.ContentDisposition = &v
  6926. return s
  6927. }
  6928. // SetContentEncoding sets the ContentEncoding field's value.
  6929. func (s *CopyObjectInput) SetContentEncoding(v string) *CopyObjectInput {
  6930. s.ContentEncoding = &v
  6931. return s
  6932. }
  6933. // SetContentLanguage sets the ContentLanguage field's value.
  6934. func (s *CopyObjectInput) SetContentLanguage(v string) *CopyObjectInput {
  6935. s.ContentLanguage = &v
  6936. return s
  6937. }
  6938. // SetContentType sets the ContentType field's value.
  6939. func (s *CopyObjectInput) SetContentType(v string) *CopyObjectInput {
  6940. s.ContentType = &v
  6941. return s
  6942. }
  6943. // SetCopySource sets the CopySource field's value.
  6944. func (s *CopyObjectInput) SetCopySource(v string) *CopyObjectInput {
  6945. s.CopySource = &v
  6946. return s
  6947. }
  6948. // SetCopySourceIfMatch sets the CopySourceIfMatch field's value.
  6949. func (s *CopyObjectInput) SetCopySourceIfMatch(v string) *CopyObjectInput {
  6950. s.CopySourceIfMatch = &v
  6951. return s
  6952. }
  6953. // SetCopySourceIfModifiedSince sets the CopySourceIfModifiedSince field's value.
  6954. func (s *CopyObjectInput) SetCopySourceIfModifiedSince(v time.Time) *CopyObjectInput {
  6955. s.CopySourceIfModifiedSince = &v
  6956. return s
  6957. }
  6958. // SetCopySourceIfNoneMatch sets the CopySourceIfNoneMatch field's value.
  6959. func (s *CopyObjectInput) SetCopySourceIfNoneMatch(v string) *CopyObjectInput {
  6960. s.CopySourceIfNoneMatch = &v
  6961. return s
  6962. }
  6963. // SetCopySourceIfUnmodifiedSince sets the CopySourceIfUnmodifiedSince field's value.
  6964. func (s *CopyObjectInput) SetCopySourceIfUnmodifiedSince(v time.Time) *CopyObjectInput {
  6965. s.CopySourceIfUnmodifiedSince = &v
  6966. return s
  6967. }
  6968. // SetCopySourceSSECustomerAlgorithm sets the CopySourceSSECustomerAlgorithm field's value.
  6969. func (s *CopyObjectInput) SetCopySourceSSECustomerAlgorithm(v string) *CopyObjectInput {
  6970. s.CopySourceSSECustomerAlgorithm = &v
  6971. return s
  6972. }
  6973. // SetCopySourceSSECustomerKey sets the CopySourceSSECustomerKey field's value.
  6974. func (s *CopyObjectInput) SetCopySourceSSECustomerKey(v string) *CopyObjectInput {
  6975. s.CopySourceSSECustomerKey = &v
  6976. return s
  6977. }
  6978. func (s *CopyObjectInput) getCopySourceSSECustomerKey() (v string) {
  6979. if s.CopySourceSSECustomerKey == nil {
  6980. return v
  6981. }
  6982. return *s.CopySourceSSECustomerKey
  6983. }
  6984. // SetCopySourceSSECustomerKeyMD5 sets the CopySourceSSECustomerKeyMD5 field's value.
  6985. func (s *CopyObjectInput) SetCopySourceSSECustomerKeyMD5(v string) *CopyObjectInput {
  6986. s.CopySourceSSECustomerKeyMD5 = &v
  6987. return s
  6988. }
  6989. // SetExpires sets the Expires field's value.
  6990. func (s *CopyObjectInput) SetExpires(v time.Time) *CopyObjectInput {
  6991. s.Expires = &v
  6992. return s
  6993. }
  6994. // SetGrantFullControl sets the GrantFullControl field's value.
  6995. func (s *CopyObjectInput) SetGrantFullControl(v string) *CopyObjectInput {
  6996. s.GrantFullControl = &v
  6997. return s
  6998. }
  6999. // SetGrantRead sets the GrantRead field's value.
  7000. func (s *CopyObjectInput) SetGrantRead(v string) *CopyObjectInput {
  7001. s.GrantRead = &v
  7002. return s
  7003. }
  7004. // SetGrantReadACP sets the GrantReadACP field's value.
  7005. func (s *CopyObjectInput) SetGrantReadACP(v string) *CopyObjectInput {
  7006. s.GrantReadACP = &v
  7007. return s
  7008. }
  7009. // SetGrantWriteACP sets the GrantWriteACP field's value.
  7010. func (s *CopyObjectInput) SetGrantWriteACP(v string) *CopyObjectInput {
  7011. s.GrantWriteACP = &v
  7012. return s
  7013. }
  7014. // SetKey sets the Key field's value.
  7015. func (s *CopyObjectInput) SetKey(v string) *CopyObjectInput {
  7016. s.Key = &v
  7017. return s
  7018. }
  7019. // SetMetadata sets the Metadata field's value.
  7020. func (s *CopyObjectInput) SetMetadata(v map[string]*string) *CopyObjectInput {
  7021. s.Metadata = v
  7022. return s
  7023. }
  7024. // SetMetadataDirective sets the MetadataDirective field's value.
  7025. func (s *CopyObjectInput) SetMetadataDirective(v string) *CopyObjectInput {
  7026. s.MetadataDirective = &v
  7027. return s
  7028. }
  7029. // SetRequestPayer sets the RequestPayer field's value.
  7030. func (s *CopyObjectInput) SetRequestPayer(v string) *CopyObjectInput {
  7031. s.RequestPayer = &v
  7032. return s
  7033. }
  7034. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  7035. func (s *CopyObjectInput) SetSSECustomerAlgorithm(v string) *CopyObjectInput {
  7036. s.SSECustomerAlgorithm = &v
  7037. return s
  7038. }
  7039. // SetSSECustomerKey sets the SSECustomerKey field's value.
  7040. func (s *CopyObjectInput) SetSSECustomerKey(v string) *CopyObjectInput {
  7041. s.SSECustomerKey = &v
  7042. return s
  7043. }
  7044. func (s *CopyObjectInput) getSSECustomerKey() (v string) {
  7045. if s.SSECustomerKey == nil {
  7046. return v
  7047. }
  7048. return *s.SSECustomerKey
  7049. }
  7050. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  7051. func (s *CopyObjectInput) SetSSECustomerKeyMD5(v string) *CopyObjectInput {
  7052. s.SSECustomerKeyMD5 = &v
  7053. return s
  7054. }
  7055. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  7056. func (s *CopyObjectInput) SetSSEKMSKeyId(v string) *CopyObjectInput {
  7057. s.SSEKMSKeyId = &v
  7058. return s
  7059. }
  7060. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  7061. func (s *CopyObjectInput) SetServerSideEncryption(v string) *CopyObjectInput {
  7062. s.ServerSideEncryption = &v
  7063. return s
  7064. }
  7065. // SetStorageClass sets the StorageClass field's value.
  7066. func (s *CopyObjectInput) SetStorageClass(v string) *CopyObjectInput {
  7067. s.StorageClass = &v
  7068. return s
  7069. }
  7070. // SetTagging sets the Tagging field's value.
  7071. func (s *CopyObjectInput) SetTagging(v string) *CopyObjectInput {
  7072. s.Tagging = &v
  7073. return s
  7074. }
  7075. // SetTaggingDirective sets the TaggingDirective field's value.
  7076. func (s *CopyObjectInput) SetTaggingDirective(v string) *CopyObjectInput {
  7077. s.TaggingDirective = &v
  7078. return s
  7079. }
  7080. // SetWebsiteRedirectLocation sets the WebsiteRedirectLocation field's value.
  7081. func (s *CopyObjectInput) SetWebsiteRedirectLocation(v string) *CopyObjectInput {
  7082. s.WebsiteRedirectLocation = &v
  7083. return s
  7084. }
  7085. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectOutput
  7086. type CopyObjectOutput struct {
  7087. _ struct{} `type:"structure" payload:"CopyObjectResult"`
  7088. CopyObjectResult *CopyObjectResult `type:"structure"`
  7089. CopySourceVersionId *string `location:"header" locationName:"x-amz-copy-source-version-id" type:"string"`
  7090. // If the object expiration is configured, the response includes this header.
  7091. Expiration *string `location:"header" locationName:"x-amz-expiration" type:"string"`
  7092. // If present, indicates that the requester was successfully charged for the
  7093. // request.
  7094. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  7095. // If server-side encryption with a customer-provided encryption key was requested,
  7096. // the response will include this header confirming the encryption algorithm
  7097. // used.
  7098. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  7099. // If server-side encryption with a customer-provided encryption key was requested,
  7100. // the response will include this header to provide round trip message integrity
  7101. // verification of the customer-provided encryption key.
  7102. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  7103. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  7104. // encryption key that was used for the object.
  7105. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  7106. // The Server-side encryption algorithm used when storing this object in S3
  7107. // (e.g., AES256, aws:kms).
  7108. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  7109. // Version ID of the newly created copy.
  7110. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  7111. }
  7112. // String returns the string representation
  7113. func (s CopyObjectOutput) String() string {
  7114. return awsutil.Prettify(s)
  7115. }
  7116. // GoString returns the string representation
  7117. func (s CopyObjectOutput) GoString() string {
  7118. return s.String()
  7119. }
  7120. // SetCopyObjectResult sets the CopyObjectResult field's value.
  7121. func (s *CopyObjectOutput) SetCopyObjectResult(v *CopyObjectResult) *CopyObjectOutput {
  7122. s.CopyObjectResult = v
  7123. return s
  7124. }
  7125. // SetCopySourceVersionId sets the CopySourceVersionId field's value.
  7126. func (s *CopyObjectOutput) SetCopySourceVersionId(v string) *CopyObjectOutput {
  7127. s.CopySourceVersionId = &v
  7128. return s
  7129. }
  7130. // SetExpiration sets the Expiration field's value.
  7131. func (s *CopyObjectOutput) SetExpiration(v string) *CopyObjectOutput {
  7132. s.Expiration = &v
  7133. return s
  7134. }
  7135. // SetRequestCharged sets the RequestCharged field's value.
  7136. func (s *CopyObjectOutput) SetRequestCharged(v string) *CopyObjectOutput {
  7137. s.RequestCharged = &v
  7138. return s
  7139. }
  7140. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  7141. func (s *CopyObjectOutput) SetSSECustomerAlgorithm(v string) *CopyObjectOutput {
  7142. s.SSECustomerAlgorithm = &v
  7143. return s
  7144. }
  7145. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  7146. func (s *CopyObjectOutput) SetSSECustomerKeyMD5(v string) *CopyObjectOutput {
  7147. s.SSECustomerKeyMD5 = &v
  7148. return s
  7149. }
  7150. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  7151. func (s *CopyObjectOutput) SetSSEKMSKeyId(v string) *CopyObjectOutput {
  7152. s.SSEKMSKeyId = &v
  7153. return s
  7154. }
  7155. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  7156. func (s *CopyObjectOutput) SetServerSideEncryption(v string) *CopyObjectOutput {
  7157. s.ServerSideEncryption = &v
  7158. return s
  7159. }
  7160. // SetVersionId sets the VersionId field's value.
  7161. func (s *CopyObjectOutput) SetVersionId(v string) *CopyObjectOutput {
  7162. s.VersionId = &v
  7163. return s
  7164. }
  7165. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyObjectResult
  7166. type CopyObjectResult struct {
  7167. _ struct{} `type:"structure"`
  7168. ETag *string `type:"string"`
  7169. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  7170. }
  7171. // String returns the string representation
  7172. func (s CopyObjectResult) String() string {
  7173. return awsutil.Prettify(s)
  7174. }
  7175. // GoString returns the string representation
  7176. func (s CopyObjectResult) GoString() string {
  7177. return s.String()
  7178. }
  7179. // SetETag sets the ETag field's value.
  7180. func (s *CopyObjectResult) SetETag(v string) *CopyObjectResult {
  7181. s.ETag = &v
  7182. return s
  7183. }
  7184. // SetLastModified sets the LastModified field's value.
  7185. func (s *CopyObjectResult) SetLastModified(v time.Time) *CopyObjectResult {
  7186. s.LastModified = &v
  7187. return s
  7188. }
  7189. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CopyPartResult
  7190. type CopyPartResult struct {
  7191. _ struct{} `type:"structure"`
  7192. // Entity tag of the object.
  7193. ETag *string `type:"string"`
  7194. // Date and time at which the object was uploaded.
  7195. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  7196. }
  7197. // String returns the string representation
  7198. func (s CopyPartResult) String() string {
  7199. return awsutil.Prettify(s)
  7200. }
  7201. // GoString returns the string representation
  7202. func (s CopyPartResult) GoString() string {
  7203. return s.String()
  7204. }
  7205. // SetETag sets the ETag field's value.
  7206. func (s *CopyPartResult) SetETag(v string) *CopyPartResult {
  7207. s.ETag = &v
  7208. return s
  7209. }
  7210. // SetLastModified sets the LastModified field's value.
  7211. func (s *CopyPartResult) SetLastModified(v time.Time) *CopyPartResult {
  7212. s.LastModified = &v
  7213. return s
  7214. }
  7215. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketConfiguration
  7216. type CreateBucketConfiguration struct {
  7217. _ struct{} `type:"structure"`
  7218. // Specifies the region where the bucket will be created. If you don't specify
  7219. // a region, the bucket will be created in US Standard.
  7220. LocationConstraint *string `type:"string" enum:"BucketLocationConstraint"`
  7221. }
  7222. // String returns the string representation
  7223. func (s CreateBucketConfiguration) String() string {
  7224. return awsutil.Prettify(s)
  7225. }
  7226. // GoString returns the string representation
  7227. func (s CreateBucketConfiguration) GoString() string {
  7228. return s.String()
  7229. }
  7230. // SetLocationConstraint sets the LocationConstraint field's value.
  7231. func (s *CreateBucketConfiguration) SetLocationConstraint(v string) *CreateBucketConfiguration {
  7232. s.LocationConstraint = &v
  7233. return s
  7234. }
  7235. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketRequest
  7236. type CreateBucketInput struct {
  7237. _ struct{} `type:"structure" payload:"CreateBucketConfiguration"`
  7238. // The canned ACL to apply to the bucket.
  7239. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"BucketCannedACL"`
  7240. // Bucket is a required field
  7241. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7242. CreateBucketConfiguration *CreateBucketConfiguration `locationName:"CreateBucketConfiguration" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  7243. // Allows grantee the read, write, read ACP, and write ACP permissions on the
  7244. // bucket.
  7245. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  7246. // Allows grantee to list the objects in the bucket.
  7247. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  7248. // Allows grantee to read the bucket ACL.
  7249. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  7250. // Allows grantee to create, overwrite, and delete any object in the bucket.
  7251. GrantWrite *string `location:"header" locationName:"x-amz-grant-write" type:"string"`
  7252. // Allows grantee to write the ACL for the applicable bucket.
  7253. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  7254. }
  7255. // String returns the string representation
  7256. func (s CreateBucketInput) String() string {
  7257. return awsutil.Prettify(s)
  7258. }
  7259. // GoString returns the string representation
  7260. func (s CreateBucketInput) GoString() string {
  7261. return s.String()
  7262. }
  7263. // Validate inspects the fields of the type to determine if they are valid.
  7264. func (s *CreateBucketInput) Validate() error {
  7265. invalidParams := request.ErrInvalidParams{Context: "CreateBucketInput"}
  7266. if s.Bucket == nil {
  7267. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7268. }
  7269. if invalidParams.Len() > 0 {
  7270. return invalidParams
  7271. }
  7272. return nil
  7273. }
  7274. // SetACL sets the ACL field's value.
  7275. func (s *CreateBucketInput) SetACL(v string) *CreateBucketInput {
  7276. s.ACL = &v
  7277. return s
  7278. }
  7279. // SetBucket sets the Bucket field's value.
  7280. func (s *CreateBucketInput) SetBucket(v string) *CreateBucketInput {
  7281. s.Bucket = &v
  7282. return s
  7283. }
  7284. func (s *CreateBucketInput) getBucket() (v string) {
  7285. if s.Bucket == nil {
  7286. return v
  7287. }
  7288. return *s.Bucket
  7289. }
  7290. // SetCreateBucketConfiguration sets the CreateBucketConfiguration field's value.
  7291. func (s *CreateBucketInput) SetCreateBucketConfiguration(v *CreateBucketConfiguration) *CreateBucketInput {
  7292. s.CreateBucketConfiguration = v
  7293. return s
  7294. }
  7295. // SetGrantFullControl sets the GrantFullControl field's value.
  7296. func (s *CreateBucketInput) SetGrantFullControl(v string) *CreateBucketInput {
  7297. s.GrantFullControl = &v
  7298. return s
  7299. }
  7300. // SetGrantRead sets the GrantRead field's value.
  7301. func (s *CreateBucketInput) SetGrantRead(v string) *CreateBucketInput {
  7302. s.GrantRead = &v
  7303. return s
  7304. }
  7305. // SetGrantReadACP sets the GrantReadACP field's value.
  7306. func (s *CreateBucketInput) SetGrantReadACP(v string) *CreateBucketInput {
  7307. s.GrantReadACP = &v
  7308. return s
  7309. }
  7310. // SetGrantWrite sets the GrantWrite field's value.
  7311. func (s *CreateBucketInput) SetGrantWrite(v string) *CreateBucketInput {
  7312. s.GrantWrite = &v
  7313. return s
  7314. }
  7315. // SetGrantWriteACP sets the GrantWriteACP field's value.
  7316. func (s *CreateBucketInput) SetGrantWriteACP(v string) *CreateBucketInput {
  7317. s.GrantWriteACP = &v
  7318. return s
  7319. }
  7320. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateBucketOutput
  7321. type CreateBucketOutput struct {
  7322. _ struct{} `type:"structure"`
  7323. Location *string `location:"header" locationName:"Location" type:"string"`
  7324. }
  7325. // String returns the string representation
  7326. func (s CreateBucketOutput) String() string {
  7327. return awsutil.Prettify(s)
  7328. }
  7329. // GoString returns the string representation
  7330. func (s CreateBucketOutput) GoString() string {
  7331. return s.String()
  7332. }
  7333. // SetLocation sets the Location field's value.
  7334. func (s *CreateBucketOutput) SetLocation(v string) *CreateBucketOutput {
  7335. s.Location = &v
  7336. return s
  7337. }
  7338. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUploadRequest
  7339. type CreateMultipartUploadInput struct {
  7340. _ struct{} `type:"structure"`
  7341. // The canned ACL to apply to the object.
  7342. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"ObjectCannedACL"`
  7343. // Bucket is a required field
  7344. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7345. // Specifies caching behavior along the request/reply chain.
  7346. CacheControl *string `location:"header" locationName:"Cache-Control" type:"string"`
  7347. // Specifies presentational information for the object.
  7348. ContentDisposition *string `location:"header" locationName:"Content-Disposition" type:"string"`
  7349. // Specifies what content encodings have been applied to the object and thus
  7350. // what decoding mechanisms must be applied to obtain the media-type referenced
  7351. // by the Content-Type header field.
  7352. ContentEncoding *string `location:"header" locationName:"Content-Encoding" type:"string"`
  7353. // The language the content is in.
  7354. ContentLanguage *string `location:"header" locationName:"Content-Language" type:"string"`
  7355. // A standard MIME type describing the format of the object data.
  7356. ContentType *string `location:"header" locationName:"Content-Type" type:"string"`
  7357. // The date and time at which the object is no longer cacheable.
  7358. Expires *time.Time `location:"header" locationName:"Expires" type:"timestamp" timestampFormat:"rfc822"`
  7359. // Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.
  7360. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  7361. // Allows grantee to read the object data and its metadata.
  7362. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  7363. // Allows grantee to read the object ACL.
  7364. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  7365. // Allows grantee to write the ACL for the applicable object.
  7366. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  7367. // Key is a required field
  7368. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  7369. // A map of metadata to store with the object in S3.
  7370. Metadata map[string]*string `location:"headers" locationName:"x-amz-meta-" type:"map"`
  7371. // Confirms that the requester knows that she or he will be charged for the
  7372. // request. Bucket owners need not specify this parameter in their requests.
  7373. // Documentation on downloading objects from requester pays buckets can be found
  7374. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  7375. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  7376. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  7377. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  7378. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  7379. // data. This value is used to store the object and then it is discarded; Amazon
  7380. // does not store the encryption key. The key must be appropriate for use with
  7381. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  7382. // header.
  7383. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  7384. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  7385. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  7386. // key was transmitted without error.
  7387. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  7388. // Specifies the AWS KMS key ID to use for object encryption. All GET and PUT
  7389. // requests for an object protected by AWS KMS will fail if not made via SSL
  7390. // or using SigV4. Documentation on configuring any of the officially supported
  7391. // AWS SDKs and CLI can be found at http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
  7392. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  7393. // The Server-side encryption algorithm used when storing this object in S3
  7394. // (e.g., AES256, aws:kms).
  7395. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  7396. // The type of storage to use for the object. Defaults to 'STANDARD'.
  7397. StorageClass *string `location:"header" locationName:"x-amz-storage-class" type:"string" enum:"StorageClass"`
  7398. // The tag-set for the object. The tag-set must be encoded as URL Query parameters
  7399. Tagging *string `location:"header" locationName:"x-amz-tagging" type:"string"`
  7400. // If the bucket is configured as a website, redirects requests for this object
  7401. // to another object in the same bucket or to an external URL. Amazon S3 stores
  7402. // the value of this header in the object metadata.
  7403. WebsiteRedirectLocation *string `location:"header" locationName:"x-amz-website-redirect-location" type:"string"`
  7404. }
  7405. // String returns the string representation
  7406. func (s CreateMultipartUploadInput) String() string {
  7407. return awsutil.Prettify(s)
  7408. }
  7409. // GoString returns the string representation
  7410. func (s CreateMultipartUploadInput) GoString() string {
  7411. return s.String()
  7412. }
  7413. // Validate inspects the fields of the type to determine if they are valid.
  7414. func (s *CreateMultipartUploadInput) Validate() error {
  7415. invalidParams := request.ErrInvalidParams{Context: "CreateMultipartUploadInput"}
  7416. if s.Bucket == nil {
  7417. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7418. }
  7419. if s.Key == nil {
  7420. invalidParams.Add(request.NewErrParamRequired("Key"))
  7421. }
  7422. if s.Key != nil && len(*s.Key) < 1 {
  7423. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  7424. }
  7425. if invalidParams.Len() > 0 {
  7426. return invalidParams
  7427. }
  7428. return nil
  7429. }
  7430. // SetACL sets the ACL field's value.
  7431. func (s *CreateMultipartUploadInput) SetACL(v string) *CreateMultipartUploadInput {
  7432. s.ACL = &v
  7433. return s
  7434. }
  7435. // SetBucket sets the Bucket field's value.
  7436. func (s *CreateMultipartUploadInput) SetBucket(v string) *CreateMultipartUploadInput {
  7437. s.Bucket = &v
  7438. return s
  7439. }
  7440. func (s *CreateMultipartUploadInput) getBucket() (v string) {
  7441. if s.Bucket == nil {
  7442. return v
  7443. }
  7444. return *s.Bucket
  7445. }
  7446. // SetCacheControl sets the CacheControl field's value.
  7447. func (s *CreateMultipartUploadInput) SetCacheControl(v string) *CreateMultipartUploadInput {
  7448. s.CacheControl = &v
  7449. return s
  7450. }
  7451. // SetContentDisposition sets the ContentDisposition field's value.
  7452. func (s *CreateMultipartUploadInput) SetContentDisposition(v string) *CreateMultipartUploadInput {
  7453. s.ContentDisposition = &v
  7454. return s
  7455. }
  7456. // SetContentEncoding sets the ContentEncoding field's value.
  7457. func (s *CreateMultipartUploadInput) SetContentEncoding(v string) *CreateMultipartUploadInput {
  7458. s.ContentEncoding = &v
  7459. return s
  7460. }
  7461. // SetContentLanguage sets the ContentLanguage field's value.
  7462. func (s *CreateMultipartUploadInput) SetContentLanguage(v string) *CreateMultipartUploadInput {
  7463. s.ContentLanguage = &v
  7464. return s
  7465. }
  7466. // SetContentType sets the ContentType field's value.
  7467. func (s *CreateMultipartUploadInput) SetContentType(v string) *CreateMultipartUploadInput {
  7468. s.ContentType = &v
  7469. return s
  7470. }
  7471. // SetExpires sets the Expires field's value.
  7472. func (s *CreateMultipartUploadInput) SetExpires(v time.Time) *CreateMultipartUploadInput {
  7473. s.Expires = &v
  7474. return s
  7475. }
  7476. // SetGrantFullControl sets the GrantFullControl field's value.
  7477. func (s *CreateMultipartUploadInput) SetGrantFullControl(v string) *CreateMultipartUploadInput {
  7478. s.GrantFullControl = &v
  7479. return s
  7480. }
  7481. // SetGrantRead sets the GrantRead field's value.
  7482. func (s *CreateMultipartUploadInput) SetGrantRead(v string) *CreateMultipartUploadInput {
  7483. s.GrantRead = &v
  7484. return s
  7485. }
  7486. // SetGrantReadACP sets the GrantReadACP field's value.
  7487. func (s *CreateMultipartUploadInput) SetGrantReadACP(v string) *CreateMultipartUploadInput {
  7488. s.GrantReadACP = &v
  7489. return s
  7490. }
  7491. // SetGrantWriteACP sets the GrantWriteACP field's value.
  7492. func (s *CreateMultipartUploadInput) SetGrantWriteACP(v string) *CreateMultipartUploadInput {
  7493. s.GrantWriteACP = &v
  7494. return s
  7495. }
  7496. // SetKey sets the Key field's value.
  7497. func (s *CreateMultipartUploadInput) SetKey(v string) *CreateMultipartUploadInput {
  7498. s.Key = &v
  7499. return s
  7500. }
  7501. // SetMetadata sets the Metadata field's value.
  7502. func (s *CreateMultipartUploadInput) SetMetadata(v map[string]*string) *CreateMultipartUploadInput {
  7503. s.Metadata = v
  7504. return s
  7505. }
  7506. // SetRequestPayer sets the RequestPayer field's value.
  7507. func (s *CreateMultipartUploadInput) SetRequestPayer(v string) *CreateMultipartUploadInput {
  7508. s.RequestPayer = &v
  7509. return s
  7510. }
  7511. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  7512. func (s *CreateMultipartUploadInput) SetSSECustomerAlgorithm(v string) *CreateMultipartUploadInput {
  7513. s.SSECustomerAlgorithm = &v
  7514. return s
  7515. }
  7516. // SetSSECustomerKey sets the SSECustomerKey field's value.
  7517. func (s *CreateMultipartUploadInput) SetSSECustomerKey(v string) *CreateMultipartUploadInput {
  7518. s.SSECustomerKey = &v
  7519. return s
  7520. }
  7521. func (s *CreateMultipartUploadInput) getSSECustomerKey() (v string) {
  7522. if s.SSECustomerKey == nil {
  7523. return v
  7524. }
  7525. return *s.SSECustomerKey
  7526. }
  7527. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  7528. func (s *CreateMultipartUploadInput) SetSSECustomerKeyMD5(v string) *CreateMultipartUploadInput {
  7529. s.SSECustomerKeyMD5 = &v
  7530. return s
  7531. }
  7532. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  7533. func (s *CreateMultipartUploadInput) SetSSEKMSKeyId(v string) *CreateMultipartUploadInput {
  7534. s.SSEKMSKeyId = &v
  7535. return s
  7536. }
  7537. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  7538. func (s *CreateMultipartUploadInput) SetServerSideEncryption(v string) *CreateMultipartUploadInput {
  7539. s.ServerSideEncryption = &v
  7540. return s
  7541. }
  7542. // SetStorageClass sets the StorageClass field's value.
  7543. func (s *CreateMultipartUploadInput) SetStorageClass(v string) *CreateMultipartUploadInput {
  7544. s.StorageClass = &v
  7545. return s
  7546. }
  7547. // SetTagging sets the Tagging field's value.
  7548. func (s *CreateMultipartUploadInput) SetTagging(v string) *CreateMultipartUploadInput {
  7549. s.Tagging = &v
  7550. return s
  7551. }
  7552. // SetWebsiteRedirectLocation sets the WebsiteRedirectLocation field's value.
  7553. func (s *CreateMultipartUploadInput) SetWebsiteRedirectLocation(v string) *CreateMultipartUploadInput {
  7554. s.WebsiteRedirectLocation = &v
  7555. return s
  7556. }
  7557. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/CreateMultipartUploadOutput
  7558. type CreateMultipartUploadOutput struct {
  7559. _ struct{} `type:"structure"`
  7560. // Date when multipart upload will become eligible for abort operation by lifecycle.
  7561. AbortDate *time.Time `location:"header" locationName:"x-amz-abort-date" type:"timestamp" timestampFormat:"rfc822"`
  7562. // Id of the lifecycle rule that makes a multipart upload eligible for abort
  7563. // operation.
  7564. AbortRuleId *string `location:"header" locationName:"x-amz-abort-rule-id" type:"string"`
  7565. // Name of the bucket to which the multipart upload was initiated.
  7566. Bucket *string `locationName:"Bucket" type:"string"`
  7567. // Object key for which the multipart upload was initiated.
  7568. Key *string `min:"1" type:"string"`
  7569. // If present, indicates that the requester was successfully charged for the
  7570. // request.
  7571. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  7572. // If server-side encryption with a customer-provided encryption key was requested,
  7573. // the response will include this header confirming the encryption algorithm
  7574. // used.
  7575. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  7576. // If server-side encryption with a customer-provided encryption key was requested,
  7577. // the response will include this header to provide round trip message integrity
  7578. // verification of the customer-provided encryption key.
  7579. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  7580. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  7581. // encryption key that was used for the object.
  7582. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  7583. // The Server-side encryption algorithm used when storing this object in S3
  7584. // (e.g., AES256, aws:kms).
  7585. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  7586. // ID for the initiated multipart upload.
  7587. UploadId *string `type:"string"`
  7588. }
  7589. // String returns the string representation
  7590. func (s CreateMultipartUploadOutput) String() string {
  7591. return awsutil.Prettify(s)
  7592. }
  7593. // GoString returns the string representation
  7594. func (s CreateMultipartUploadOutput) GoString() string {
  7595. return s.String()
  7596. }
  7597. // SetAbortDate sets the AbortDate field's value.
  7598. func (s *CreateMultipartUploadOutput) SetAbortDate(v time.Time) *CreateMultipartUploadOutput {
  7599. s.AbortDate = &v
  7600. return s
  7601. }
  7602. // SetAbortRuleId sets the AbortRuleId field's value.
  7603. func (s *CreateMultipartUploadOutput) SetAbortRuleId(v string) *CreateMultipartUploadOutput {
  7604. s.AbortRuleId = &v
  7605. return s
  7606. }
  7607. // SetBucket sets the Bucket field's value.
  7608. func (s *CreateMultipartUploadOutput) SetBucket(v string) *CreateMultipartUploadOutput {
  7609. s.Bucket = &v
  7610. return s
  7611. }
  7612. func (s *CreateMultipartUploadOutput) getBucket() (v string) {
  7613. if s.Bucket == nil {
  7614. return v
  7615. }
  7616. return *s.Bucket
  7617. }
  7618. // SetKey sets the Key field's value.
  7619. func (s *CreateMultipartUploadOutput) SetKey(v string) *CreateMultipartUploadOutput {
  7620. s.Key = &v
  7621. return s
  7622. }
  7623. // SetRequestCharged sets the RequestCharged field's value.
  7624. func (s *CreateMultipartUploadOutput) SetRequestCharged(v string) *CreateMultipartUploadOutput {
  7625. s.RequestCharged = &v
  7626. return s
  7627. }
  7628. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  7629. func (s *CreateMultipartUploadOutput) SetSSECustomerAlgorithm(v string) *CreateMultipartUploadOutput {
  7630. s.SSECustomerAlgorithm = &v
  7631. return s
  7632. }
  7633. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  7634. func (s *CreateMultipartUploadOutput) SetSSECustomerKeyMD5(v string) *CreateMultipartUploadOutput {
  7635. s.SSECustomerKeyMD5 = &v
  7636. return s
  7637. }
  7638. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  7639. func (s *CreateMultipartUploadOutput) SetSSEKMSKeyId(v string) *CreateMultipartUploadOutput {
  7640. s.SSEKMSKeyId = &v
  7641. return s
  7642. }
  7643. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  7644. func (s *CreateMultipartUploadOutput) SetServerSideEncryption(v string) *CreateMultipartUploadOutput {
  7645. s.ServerSideEncryption = &v
  7646. return s
  7647. }
  7648. // SetUploadId sets the UploadId field's value.
  7649. func (s *CreateMultipartUploadOutput) SetUploadId(v string) *CreateMultipartUploadOutput {
  7650. s.UploadId = &v
  7651. return s
  7652. }
  7653. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Delete
  7654. type Delete struct {
  7655. _ struct{} `type:"structure"`
  7656. // Objects is a required field
  7657. Objects []*ObjectIdentifier `locationName:"Object" type:"list" flattened:"true" required:"true"`
  7658. // Element to enable quiet mode for the request. When you add this element,
  7659. // you must set its value to true.
  7660. Quiet *bool `type:"boolean"`
  7661. }
  7662. // String returns the string representation
  7663. func (s Delete) String() string {
  7664. return awsutil.Prettify(s)
  7665. }
  7666. // GoString returns the string representation
  7667. func (s Delete) GoString() string {
  7668. return s.String()
  7669. }
  7670. // Validate inspects the fields of the type to determine if they are valid.
  7671. func (s *Delete) Validate() error {
  7672. invalidParams := request.ErrInvalidParams{Context: "Delete"}
  7673. if s.Objects == nil {
  7674. invalidParams.Add(request.NewErrParamRequired("Objects"))
  7675. }
  7676. if s.Objects != nil {
  7677. for i, v := range s.Objects {
  7678. if v == nil {
  7679. continue
  7680. }
  7681. if err := v.Validate(); err != nil {
  7682. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Objects", i), err.(request.ErrInvalidParams))
  7683. }
  7684. }
  7685. }
  7686. if invalidParams.Len() > 0 {
  7687. return invalidParams
  7688. }
  7689. return nil
  7690. }
  7691. // SetObjects sets the Objects field's value.
  7692. func (s *Delete) SetObjects(v []*ObjectIdentifier) *Delete {
  7693. s.Objects = v
  7694. return s
  7695. }
  7696. // SetQuiet sets the Quiet field's value.
  7697. func (s *Delete) SetQuiet(v bool) *Delete {
  7698. s.Quiet = &v
  7699. return s
  7700. }
  7701. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfigurationRequest
  7702. type DeleteBucketAnalyticsConfigurationInput struct {
  7703. _ struct{} `type:"structure"`
  7704. // The name of the bucket from which an analytics configuration is deleted.
  7705. //
  7706. // Bucket is a required field
  7707. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7708. // The identifier used to represent an analytics configuration.
  7709. //
  7710. // Id is a required field
  7711. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  7712. }
  7713. // String returns the string representation
  7714. func (s DeleteBucketAnalyticsConfigurationInput) String() string {
  7715. return awsutil.Prettify(s)
  7716. }
  7717. // GoString returns the string representation
  7718. func (s DeleteBucketAnalyticsConfigurationInput) GoString() string {
  7719. return s.String()
  7720. }
  7721. // Validate inspects the fields of the type to determine if they are valid.
  7722. func (s *DeleteBucketAnalyticsConfigurationInput) Validate() error {
  7723. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketAnalyticsConfigurationInput"}
  7724. if s.Bucket == nil {
  7725. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7726. }
  7727. if s.Id == nil {
  7728. invalidParams.Add(request.NewErrParamRequired("Id"))
  7729. }
  7730. if invalidParams.Len() > 0 {
  7731. return invalidParams
  7732. }
  7733. return nil
  7734. }
  7735. // SetBucket sets the Bucket field's value.
  7736. func (s *DeleteBucketAnalyticsConfigurationInput) SetBucket(v string) *DeleteBucketAnalyticsConfigurationInput {
  7737. s.Bucket = &v
  7738. return s
  7739. }
  7740. func (s *DeleteBucketAnalyticsConfigurationInput) getBucket() (v string) {
  7741. if s.Bucket == nil {
  7742. return v
  7743. }
  7744. return *s.Bucket
  7745. }
  7746. // SetId sets the Id field's value.
  7747. func (s *DeleteBucketAnalyticsConfigurationInput) SetId(v string) *DeleteBucketAnalyticsConfigurationInput {
  7748. s.Id = &v
  7749. return s
  7750. }
  7751. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketAnalyticsConfigurationOutput
  7752. type DeleteBucketAnalyticsConfigurationOutput struct {
  7753. _ struct{} `type:"structure"`
  7754. }
  7755. // String returns the string representation
  7756. func (s DeleteBucketAnalyticsConfigurationOutput) String() string {
  7757. return awsutil.Prettify(s)
  7758. }
  7759. // GoString returns the string representation
  7760. func (s DeleteBucketAnalyticsConfigurationOutput) GoString() string {
  7761. return s.String()
  7762. }
  7763. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCorsRequest
  7764. type DeleteBucketCorsInput struct {
  7765. _ struct{} `type:"structure"`
  7766. // Bucket is a required field
  7767. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7768. }
  7769. // String returns the string representation
  7770. func (s DeleteBucketCorsInput) String() string {
  7771. return awsutil.Prettify(s)
  7772. }
  7773. // GoString returns the string representation
  7774. func (s DeleteBucketCorsInput) GoString() string {
  7775. return s.String()
  7776. }
  7777. // Validate inspects the fields of the type to determine if they are valid.
  7778. func (s *DeleteBucketCorsInput) Validate() error {
  7779. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketCorsInput"}
  7780. if s.Bucket == nil {
  7781. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7782. }
  7783. if invalidParams.Len() > 0 {
  7784. return invalidParams
  7785. }
  7786. return nil
  7787. }
  7788. // SetBucket sets the Bucket field's value.
  7789. func (s *DeleteBucketCorsInput) SetBucket(v string) *DeleteBucketCorsInput {
  7790. s.Bucket = &v
  7791. return s
  7792. }
  7793. func (s *DeleteBucketCorsInput) getBucket() (v string) {
  7794. if s.Bucket == nil {
  7795. return v
  7796. }
  7797. return *s.Bucket
  7798. }
  7799. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketCorsOutput
  7800. type DeleteBucketCorsOutput struct {
  7801. _ struct{} `type:"structure"`
  7802. }
  7803. // String returns the string representation
  7804. func (s DeleteBucketCorsOutput) String() string {
  7805. return awsutil.Prettify(s)
  7806. }
  7807. // GoString returns the string representation
  7808. func (s DeleteBucketCorsOutput) GoString() string {
  7809. return s.String()
  7810. }
  7811. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryptionRequest
  7812. type DeleteBucketEncryptionInput struct {
  7813. _ struct{} `type:"structure"`
  7814. // The name of the bucket containing the server-side encryption configuration
  7815. // to delete.
  7816. //
  7817. // Bucket is a required field
  7818. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7819. }
  7820. // String returns the string representation
  7821. func (s DeleteBucketEncryptionInput) String() string {
  7822. return awsutil.Prettify(s)
  7823. }
  7824. // GoString returns the string representation
  7825. func (s DeleteBucketEncryptionInput) GoString() string {
  7826. return s.String()
  7827. }
  7828. // Validate inspects the fields of the type to determine if they are valid.
  7829. func (s *DeleteBucketEncryptionInput) Validate() error {
  7830. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketEncryptionInput"}
  7831. if s.Bucket == nil {
  7832. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7833. }
  7834. if invalidParams.Len() > 0 {
  7835. return invalidParams
  7836. }
  7837. return nil
  7838. }
  7839. // SetBucket sets the Bucket field's value.
  7840. func (s *DeleteBucketEncryptionInput) SetBucket(v string) *DeleteBucketEncryptionInput {
  7841. s.Bucket = &v
  7842. return s
  7843. }
  7844. func (s *DeleteBucketEncryptionInput) getBucket() (v string) {
  7845. if s.Bucket == nil {
  7846. return v
  7847. }
  7848. return *s.Bucket
  7849. }
  7850. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketEncryptionOutput
  7851. type DeleteBucketEncryptionOutput struct {
  7852. _ struct{} `type:"structure"`
  7853. }
  7854. // String returns the string representation
  7855. func (s DeleteBucketEncryptionOutput) String() string {
  7856. return awsutil.Prettify(s)
  7857. }
  7858. // GoString returns the string representation
  7859. func (s DeleteBucketEncryptionOutput) GoString() string {
  7860. return s.String()
  7861. }
  7862. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketRequest
  7863. type DeleteBucketInput struct {
  7864. _ struct{} `type:"structure"`
  7865. // Bucket is a required field
  7866. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7867. }
  7868. // String returns the string representation
  7869. func (s DeleteBucketInput) String() string {
  7870. return awsutil.Prettify(s)
  7871. }
  7872. // GoString returns the string representation
  7873. func (s DeleteBucketInput) GoString() string {
  7874. return s.String()
  7875. }
  7876. // Validate inspects the fields of the type to determine if they are valid.
  7877. func (s *DeleteBucketInput) Validate() error {
  7878. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketInput"}
  7879. if s.Bucket == nil {
  7880. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7881. }
  7882. if invalidParams.Len() > 0 {
  7883. return invalidParams
  7884. }
  7885. return nil
  7886. }
  7887. // SetBucket sets the Bucket field's value.
  7888. func (s *DeleteBucketInput) SetBucket(v string) *DeleteBucketInput {
  7889. s.Bucket = &v
  7890. return s
  7891. }
  7892. func (s *DeleteBucketInput) getBucket() (v string) {
  7893. if s.Bucket == nil {
  7894. return v
  7895. }
  7896. return *s.Bucket
  7897. }
  7898. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfigurationRequest
  7899. type DeleteBucketInventoryConfigurationInput struct {
  7900. _ struct{} `type:"structure"`
  7901. // The name of the bucket containing the inventory configuration to delete.
  7902. //
  7903. // Bucket is a required field
  7904. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7905. // The ID used to identify the inventory configuration.
  7906. //
  7907. // Id is a required field
  7908. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  7909. }
  7910. // String returns the string representation
  7911. func (s DeleteBucketInventoryConfigurationInput) String() string {
  7912. return awsutil.Prettify(s)
  7913. }
  7914. // GoString returns the string representation
  7915. func (s DeleteBucketInventoryConfigurationInput) GoString() string {
  7916. return s.String()
  7917. }
  7918. // Validate inspects the fields of the type to determine if they are valid.
  7919. func (s *DeleteBucketInventoryConfigurationInput) Validate() error {
  7920. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketInventoryConfigurationInput"}
  7921. if s.Bucket == nil {
  7922. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7923. }
  7924. if s.Id == nil {
  7925. invalidParams.Add(request.NewErrParamRequired("Id"))
  7926. }
  7927. if invalidParams.Len() > 0 {
  7928. return invalidParams
  7929. }
  7930. return nil
  7931. }
  7932. // SetBucket sets the Bucket field's value.
  7933. func (s *DeleteBucketInventoryConfigurationInput) SetBucket(v string) *DeleteBucketInventoryConfigurationInput {
  7934. s.Bucket = &v
  7935. return s
  7936. }
  7937. func (s *DeleteBucketInventoryConfigurationInput) getBucket() (v string) {
  7938. if s.Bucket == nil {
  7939. return v
  7940. }
  7941. return *s.Bucket
  7942. }
  7943. // SetId sets the Id field's value.
  7944. func (s *DeleteBucketInventoryConfigurationInput) SetId(v string) *DeleteBucketInventoryConfigurationInput {
  7945. s.Id = &v
  7946. return s
  7947. }
  7948. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketInventoryConfigurationOutput
  7949. type DeleteBucketInventoryConfigurationOutput struct {
  7950. _ struct{} `type:"structure"`
  7951. }
  7952. // String returns the string representation
  7953. func (s DeleteBucketInventoryConfigurationOutput) String() string {
  7954. return awsutil.Prettify(s)
  7955. }
  7956. // GoString returns the string representation
  7957. func (s DeleteBucketInventoryConfigurationOutput) GoString() string {
  7958. return s.String()
  7959. }
  7960. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycleRequest
  7961. type DeleteBucketLifecycleInput struct {
  7962. _ struct{} `type:"structure"`
  7963. // Bucket is a required field
  7964. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  7965. }
  7966. // String returns the string representation
  7967. func (s DeleteBucketLifecycleInput) String() string {
  7968. return awsutil.Prettify(s)
  7969. }
  7970. // GoString returns the string representation
  7971. func (s DeleteBucketLifecycleInput) GoString() string {
  7972. return s.String()
  7973. }
  7974. // Validate inspects the fields of the type to determine if they are valid.
  7975. func (s *DeleteBucketLifecycleInput) Validate() error {
  7976. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketLifecycleInput"}
  7977. if s.Bucket == nil {
  7978. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  7979. }
  7980. if invalidParams.Len() > 0 {
  7981. return invalidParams
  7982. }
  7983. return nil
  7984. }
  7985. // SetBucket sets the Bucket field's value.
  7986. func (s *DeleteBucketLifecycleInput) SetBucket(v string) *DeleteBucketLifecycleInput {
  7987. s.Bucket = &v
  7988. return s
  7989. }
  7990. func (s *DeleteBucketLifecycleInput) getBucket() (v string) {
  7991. if s.Bucket == nil {
  7992. return v
  7993. }
  7994. return *s.Bucket
  7995. }
  7996. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketLifecycleOutput
  7997. type DeleteBucketLifecycleOutput struct {
  7998. _ struct{} `type:"structure"`
  7999. }
  8000. // String returns the string representation
  8001. func (s DeleteBucketLifecycleOutput) String() string {
  8002. return awsutil.Prettify(s)
  8003. }
  8004. // GoString returns the string representation
  8005. func (s DeleteBucketLifecycleOutput) GoString() string {
  8006. return s.String()
  8007. }
  8008. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfigurationRequest
  8009. type DeleteBucketMetricsConfigurationInput struct {
  8010. _ struct{} `type:"structure"`
  8011. // The name of the bucket containing the metrics configuration to delete.
  8012. //
  8013. // Bucket is a required field
  8014. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8015. // The ID used to identify the metrics configuration.
  8016. //
  8017. // Id is a required field
  8018. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  8019. }
  8020. // String returns the string representation
  8021. func (s DeleteBucketMetricsConfigurationInput) String() string {
  8022. return awsutil.Prettify(s)
  8023. }
  8024. // GoString returns the string representation
  8025. func (s DeleteBucketMetricsConfigurationInput) GoString() string {
  8026. return s.String()
  8027. }
  8028. // Validate inspects the fields of the type to determine if they are valid.
  8029. func (s *DeleteBucketMetricsConfigurationInput) Validate() error {
  8030. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketMetricsConfigurationInput"}
  8031. if s.Bucket == nil {
  8032. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8033. }
  8034. if s.Id == nil {
  8035. invalidParams.Add(request.NewErrParamRequired("Id"))
  8036. }
  8037. if invalidParams.Len() > 0 {
  8038. return invalidParams
  8039. }
  8040. return nil
  8041. }
  8042. // SetBucket sets the Bucket field's value.
  8043. func (s *DeleteBucketMetricsConfigurationInput) SetBucket(v string) *DeleteBucketMetricsConfigurationInput {
  8044. s.Bucket = &v
  8045. return s
  8046. }
  8047. func (s *DeleteBucketMetricsConfigurationInput) getBucket() (v string) {
  8048. if s.Bucket == nil {
  8049. return v
  8050. }
  8051. return *s.Bucket
  8052. }
  8053. // SetId sets the Id field's value.
  8054. func (s *DeleteBucketMetricsConfigurationInput) SetId(v string) *DeleteBucketMetricsConfigurationInput {
  8055. s.Id = &v
  8056. return s
  8057. }
  8058. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketMetricsConfigurationOutput
  8059. type DeleteBucketMetricsConfigurationOutput struct {
  8060. _ struct{} `type:"structure"`
  8061. }
  8062. // String returns the string representation
  8063. func (s DeleteBucketMetricsConfigurationOutput) String() string {
  8064. return awsutil.Prettify(s)
  8065. }
  8066. // GoString returns the string representation
  8067. func (s DeleteBucketMetricsConfigurationOutput) GoString() string {
  8068. return s.String()
  8069. }
  8070. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketOutput
  8071. type DeleteBucketOutput struct {
  8072. _ struct{} `type:"structure"`
  8073. }
  8074. // String returns the string representation
  8075. func (s DeleteBucketOutput) String() string {
  8076. return awsutil.Prettify(s)
  8077. }
  8078. // GoString returns the string representation
  8079. func (s DeleteBucketOutput) GoString() string {
  8080. return s.String()
  8081. }
  8082. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicyRequest
  8083. type DeleteBucketPolicyInput struct {
  8084. _ struct{} `type:"structure"`
  8085. // Bucket is a required field
  8086. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8087. }
  8088. // String returns the string representation
  8089. func (s DeleteBucketPolicyInput) String() string {
  8090. return awsutil.Prettify(s)
  8091. }
  8092. // GoString returns the string representation
  8093. func (s DeleteBucketPolicyInput) GoString() string {
  8094. return s.String()
  8095. }
  8096. // Validate inspects the fields of the type to determine if they are valid.
  8097. func (s *DeleteBucketPolicyInput) Validate() error {
  8098. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketPolicyInput"}
  8099. if s.Bucket == nil {
  8100. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8101. }
  8102. if invalidParams.Len() > 0 {
  8103. return invalidParams
  8104. }
  8105. return nil
  8106. }
  8107. // SetBucket sets the Bucket field's value.
  8108. func (s *DeleteBucketPolicyInput) SetBucket(v string) *DeleteBucketPolicyInput {
  8109. s.Bucket = &v
  8110. return s
  8111. }
  8112. func (s *DeleteBucketPolicyInput) getBucket() (v string) {
  8113. if s.Bucket == nil {
  8114. return v
  8115. }
  8116. return *s.Bucket
  8117. }
  8118. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketPolicyOutput
  8119. type DeleteBucketPolicyOutput struct {
  8120. _ struct{} `type:"structure"`
  8121. }
  8122. // String returns the string representation
  8123. func (s DeleteBucketPolicyOutput) String() string {
  8124. return awsutil.Prettify(s)
  8125. }
  8126. // GoString returns the string representation
  8127. func (s DeleteBucketPolicyOutput) GoString() string {
  8128. return s.String()
  8129. }
  8130. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplicationRequest
  8131. type DeleteBucketReplicationInput struct {
  8132. _ struct{} `type:"structure"`
  8133. // Bucket is a required field
  8134. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8135. }
  8136. // String returns the string representation
  8137. func (s DeleteBucketReplicationInput) String() string {
  8138. return awsutil.Prettify(s)
  8139. }
  8140. // GoString returns the string representation
  8141. func (s DeleteBucketReplicationInput) GoString() string {
  8142. return s.String()
  8143. }
  8144. // Validate inspects the fields of the type to determine if they are valid.
  8145. func (s *DeleteBucketReplicationInput) Validate() error {
  8146. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketReplicationInput"}
  8147. if s.Bucket == nil {
  8148. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8149. }
  8150. if invalidParams.Len() > 0 {
  8151. return invalidParams
  8152. }
  8153. return nil
  8154. }
  8155. // SetBucket sets the Bucket field's value.
  8156. func (s *DeleteBucketReplicationInput) SetBucket(v string) *DeleteBucketReplicationInput {
  8157. s.Bucket = &v
  8158. return s
  8159. }
  8160. func (s *DeleteBucketReplicationInput) getBucket() (v string) {
  8161. if s.Bucket == nil {
  8162. return v
  8163. }
  8164. return *s.Bucket
  8165. }
  8166. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketReplicationOutput
  8167. type DeleteBucketReplicationOutput struct {
  8168. _ struct{} `type:"structure"`
  8169. }
  8170. // String returns the string representation
  8171. func (s DeleteBucketReplicationOutput) String() string {
  8172. return awsutil.Prettify(s)
  8173. }
  8174. // GoString returns the string representation
  8175. func (s DeleteBucketReplicationOutput) GoString() string {
  8176. return s.String()
  8177. }
  8178. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTaggingRequest
  8179. type DeleteBucketTaggingInput struct {
  8180. _ struct{} `type:"structure"`
  8181. // Bucket is a required field
  8182. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8183. }
  8184. // String returns the string representation
  8185. func (s DeleteBucketTaggingInput) String() string {
  8186. return awsutil.Prettify(s)
  8187. }
  8188. // GoString returns the string representation
  8189. func (s DeleteBucketTaggingInput) GoString() string {
  8190. return s.String()
  8191. }
  8192. // Validate inspects the fields of the type to determine if they are valid.
  8193. func (s *DeleteBucketTaggingInput) Validate() error {
  8194. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketTaggingInput"}
  8195. if s.Bucket == nil {
  8196. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8197. }
  8198. if invalidParams.Len() > 0 {
  8199. return invalidParams
  8200. }
  8201. return nil
  8202. }
  8203. // SetBucket sets the Bucket field's value.
  8204. func (s *DeleteBucketTaggingInput) SetBucket(v string) *DeleteBucketTaggingInput {
  8205. s.Bucket = &v
  8206. return s
  8207. }
  8208. func (s *DeleteBucketTaggingInput) getBucket() (v string) {
  8209. if s.Bucket == nil {
  8210. return v
  8211. }
  8212. return *s.Bucket
  8213. }
  8214. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketTaggingOutput
  8215. type DeleteBucketTaggingOutput struct {
  8216. _ struct{} `type:"structure"`
  8217. }
  8218. // String returns the string representation
  8219. func (s DeleteBucketTaggingOutput) String() string {
  8220. return awsutil.Prettify(s)
  8221. }
  8222. // GoString returns the string representation
  8223. func (s DeleteBucketTaggingOutput) GoString() string {
  8224. return s.String()
  8225. }
  8226. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsiteRequest
  8227. type DeleteBucketWebsiteInput struct {
  8228. _ struct{} `type:"structure"`
  8229. // Bucket is a required field
  8230. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8231. }
  8232. // String returns the string representation
  8233. func (s DeleteBucketWebsiteInput) String() string {
  8234. return awsutil.Prettify(s)
  8235. }
  8236. // GoString returns the string representation
  8237. func (s DeleteBucketWebsiteInput) GoString() string {
  8238. return s.String()
  8239. }
  8240. // Validate inspects the fields of the type to determine if they are valid.
  8241. func (s *DeleteBucketWebsiteInput) Validate() error {
  8242. invalidParams := request.ErrInvalidParams{Context: "DeleteBucketWebsiteInput"}
  8243. if s.Bucket == nil {
  8244. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8245. }
  8246. if invalidParams.Len() > 0 {
  8247. return invalidParams
  8248. }
  8249. return nil
  8250. }
  8251. // SetBucket sets the Bucket field's value.
  8252. func (s *DeleteBucketWebsiteInput) SetBucket(v string) *DeleteBucketWebsiteInput {
  8253. s.Bucket = &v
  8254. return s
  8255. }
  8256. func (s *DeleteBucketWebsiteInput) getBucket() (v string) {
  8257. if s.Bucket == nil {
  8258. return v
  8259. }
  8260. return *s.Bucket
  8261. }
  8262. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketWebsiteOutput
  8263. type DeleteBucketWebsiteOutput struct {
  8264. _ struct{} `type:"structure"`
  8265. }
  8266. // String returns the string representation
  8267. func (s DeleteBucketWebsiteOutput) String() string {
  8268. return awsutil.Prettify(s)
  8269. }
  8270. // GoString returns the string representation
  8271. func (s DeleteBucketWebsiteOutput) GoString() string {
  8272. return s.String()
  8273. }
  8274. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteMarkerEntry
  8275. type DeleteMarkerEntry struct {
  8276. _ struct{} `type:"structure"`
  8277. // Specifies whether the object is (true) or is not (false) the latest version
  8278. // of an object.
  8279. IsLatest *bool `type:"boolean"`
  8280. // The object key.
  8281. Key *string `min:"1" type:"string"`
  8282. // Date and time the object was last modified.
  8283. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  8284. Owner *Owner `type:"structure"`
  8285. // Version ID of an object.
  8286. VersionId *string `type:"string"`
  8287. }
  8288. // String returns the string representation
  8289. func (s DeleteMarkerEntry) String() string {
  8290. return awsutil.Prettify(s)
  8291. }
  8292. // GoString returns the string representation
  8293. func (s DeleteMarkerEntry) GoString() string {
  8294. return s.String()
  8295. }
  8296. // SetIsLatest sets the IsLatest field's value.
  8297. func (s *DeleteMarkerEntry) SetIsLatest(v bool) *DeleteMarkerEntry {
  8298. s.IsLatest = &v
  8299. return s
  8300. }
  8301. // SetKey sets the Key field's value.
  8302. func (s *DeleteMarkerEntry) SetKey(v string) *DeleteMarkerEntry {
  8303. s.Key = &v
  8304. return s
  8305. }
  8306. // SetLastModified sets the LastModified field's value.
  8307. func (s *DeleteMarkerEntry) SetLastModified(v time.Time) *DeleteMarkerEntry {
  8308. s.LastModified = &v
  8309. return s
  8310. }
  8311. // SetOwner sets the Owner field's value.
  8312. func (s *DeleteMarkerEntry) SetOwner(v *Owner) *DeleteMarkerEntry {
  8313. s.Owner = v
  8314. return s
  8315. }
  8316. // SetVersionId sets the VersionId field's value.
  8317. func (s *DeleteMarkerEntry) SetVersionId(v string) *DeleteMarkerEntry {
  8318. s.VersionId = &v
  8319. return s
  8320. }
  8321. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectRequest
  8322. type DeleteObjectInput struct {
  8323. _ struct{} `type:"structure"`
  8324. // Bucket is a required field
  8325. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8326. // Key is a required field
  8327. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  8328. // The concatenation of the authentication device's serial number, a space,
  8329. // and the value that is displayed on your authentication device.
  8330. MFA *string `location:"header" locationName:"x-amz-mfa" type:"string"`
  8331. // Confirms that the requester knows that she or he will be charged for the
  8332. // request. Bucket owners need not specify this parameter in their requests.
  8333. // Documentation on downloading objects from requester pays buckets can be found
  8334. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  8335. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  8336. // VersionId used to reference a specific version of the object.
  8337. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  8338. }
  8339. // String returns the string representation
  8340. func (s DeleteObjectInput) String() string {
  8341. return awsutil.Prettify(s)
  8342. }
  8343. // GoString returns the string representation
  8344. func (s DeleteObjectInput) GoString() string {
  8345. return s.String()
  8346. }
  8347. // Validate inspects the fields of the type to determine if they are valid.
  8348. func (s *DeleteObjectInput) Validate() error {
  8349. invalidParams := request.ErrInvalidParams{Context: "DeleteObjectInput"}
  8350. if s.Bucket == nil {
  8351. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8352. }
  8353. if s.Key == nil {
  8354. invalidParams.Add(request.NewErrParamRequired("Key"))
  8355. }
  8356. if s.Key != nil && len(*s.Key) < 1 {
  8357. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  8358. }
  8359. if invalidParams.Len() > 0 {
  8360. return invalidParams
  8361. }
  8362. return nil
  8363. }
  8364. // SetBucket sets the Bucket field's value.
  8365. func (s *DeleteObjectInput) SetBucket(v string) *DeleteObjectInput {
  8366. s.Bucket = &v
  8367. return s
  8368. }
  8369. func (s *DeleteObjectInput) getBucket() (v string) {
  8370. if s.Bucket == nil {
  8371. return v
  8372. }
  8373. return *s.Bucket
  8374. }
  8375. // SetKey sets the Key field's value.
  8376. func (s *DeleteObjectInput) SetKey(v string) *DeleteObjectInput {
  8377. s.Key = &v
  8378. return s
  8379. }
  8380. // SetMFA sets the MFA field's value.
  8381. func (s *DeleteObjectInput) SetMFA(v string) *DeleteObjectInput {
  8382. s.MFA = &v
  8383. return s
  8384. }
  8385. // SetRequestPayer sets the RequestPayer field's value.
  8386. func (s *DeleteObjectInput) SetRequestPayer(v string) *DeleteObjectInput {
  8387. s.RequestPayer = &v
  8388. return s
  8389. }
  8390. // SetVersionId sets the VersionId field's value.
  8391. func (s *DeleteObjectInput) SetVersionId(v string) *DeleteObjectInput {
  8392. s.VersionId = &v
  8393. return s
  8394. }
  8395. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectOutput
  8396. type DeleteObjectOutput struct {
  8397. _ struct{} `type:"structure"`
  8398. // Specifies whether the versioned object that was permanently deleted was (true)
  8399. // or was not (false) a delete marker.
  8400. DeleteMarker *bool `location:"header" locationName:"x-amz-delete-marker" type:"boolean"`
  8401. // If present, indicates that the requester was successfully charged for the
  8402. // request.
  8403. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  8404. // Returns the version ID of the delete marker created as a result of the DELETE
  8405. // operation.
  8406. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  8407. }
  8408. // String returns the string representation
  8409. func (s DeleteObjectOutput) String() string {
  8410. return awsutil.Prettify(s)
  8411. }
  8412. // GoString returns the string representation
  8413. func (s DeleteObjectOutput) GoString() string {
  8414. return s.String()
  8415. }
  8416. // SetDeleteMarker sets the DeleteMarker field's value.
  8417. func (s *DeleteObjectOutput) SetDeleteMarker(v bool) *DeleteObjectOutput {
  8418. s.DeleteMarker = &v
  8419. return s
  8420. }
  8421. // SetRequestCharged sets the RequestCharged field's value.
  8422. func (s *DeleteObjectOutput) SetRequestCharged(v string) *DeleteObjectOutput {
  8423. s.RequestCharged = &v
  8424. return s
  8425. }
  8426. // SetVersionId sets the VersionId field's value.
  8427. func (s *DeleteObjectOutput) SetVersionId(v string) *DeleteObjectOutput {
  8428. s.VersionId = &v
  8429. return s
  8430. }
  8431. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTaggingRequest
  8432. type DeleteObjectTaggingInput struct {
  8433. _ struct{} `type:"structure"`
  8434. // Bucket is a required field
  8435. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8436. // Key is a required field
  8437. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  8438. // The versionId of the object that the tag-set will be removed from.
  8439. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  8440. }
  8441. // String returns the string representation
  8442. func (s DeleteObjectTaggingInput) String() string {
  8443. return awsutil.Prettify(s)
  8444. }
  8445. // GoString returns the string representation
  8446. func (s DeleteObjectTaggingInput) GoString() string {
  8447. return s.String()
  8448. }
  8449. // Validate inspects the fields of the type to determine if they are valid.
  8450. func (s *DeleteObjectTaggingInput) Validate() error {
  8451. invalidParams := request.ErrInvalidParams{Context: "DeleteObjectTaggingInput"}
  8452. if s.Bucket == nil {
  8453. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8454. }
  8455. if s.Key == nil {
  8456. invalidParams.Add(request.NewErrParamRequired("Key"))
  8457. }
  8458. if s.Key != nil && len(*s.Key) < 1 {
  8459. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  8460. }
  8461. if invalidParams.Len() > 0 {
  8462. return invalidParams
  8463. }
  8464. return nil
  8465. }
  8466. // SetBucket sets the Bucket field's value.
  8467. func (s *DeleteObjectTaggingInput) SetBucket(v string) *DeleteObjectTaggingInput {
  8468. s.Bucket = &v
  8469. return s
  8470. }
  8471. func (s *DeleteObjectTaggingInput) getBucket() (v string) {
  8472. if s.Bucket == nil {
  8473. return v
  8474. }
  8475. return *s.Bucket
  8476. }
  8477. // SetKey sets the Key field's value.
  8478. func (s *DeleteObjectTaggingInput) SetKey(v string) *DeleteObjectTaggingInput {
  8479. s.Key = &v
  8480. return s
  8481. }
  8482. // SetVersionId sets the VersionId field's value.
  8483. func (s *DeleteObjectTaggingInput) SetVersionId(v string) *DeleteObjectTaggingInput {
  8484. s.VersionId = &v
  8485. return s
  8486. }
  8487. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectTaggingOutput
  8488. type DeleteObjectTaggingOutput struct {
  8489. _ struct{} `type:"structure"`
  8490. // The versionId of the object the tag-set was removed from.
  8491. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  8492. }
  8493. // String returns the string representation
  8494. func (s DeleteObjectTaggingOutput) String() string {
  8495. return awsutil.Prettify(s)
  8496. }
  8497. // GoString returns the string representation
  8498. func (s DeleteObjectTaggingOutput) GoString() string {
  8499. return s.String()
  8500. }
  8501. // SetVersionId sets the VersionId field's value.
  8502. func (s *DeleteObjectTaggingOutput) SetVersionId(v string) *DeleteObjectTaggingOutput {
  8503. s.VersionId = &v
  8504. return s
  8505. }
  8506. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectsRequest
  8507. type DeleteObjectsInput struct {
  8508. _ struct{} `type:"structure" payload:"Delete"`
  8509. // Bucket is a required field
  8510. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8511. // Delete is a required field
  8512. Delete *Delete `locationName:"Delete" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  8513. // The concatenation of the authentication device's serial number, a space,
  8514. // and the value that is displayed on your authentication device.
  8515. MFA *string `location:"header" locationName:"x-amz-mfa" type:"string"`
  8516. // Confirms that the requester knows that she or he will be charged for the
  8517. // request. Bucket owners need not specify this parameter in their requests.
  8518. // Documentation on downloading objects from requester pays buckets can be found
  8519. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  8520. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  8521. }
  8522. // String returns the string representation
  8523. func (s DeleteObjectsInput) String() string {
  8524. return awsutil.Prettify(s)
  8525. }
  8526. // GoString returns the string representation
  8527. func (s DeleteObjectsInput) GoString() string {
  8528. return s.String()
  8529. }
  8530. // Validate inspects the fields of the type to determine if they are valid.
  8531. func (s *DeleteObjectsInput) Validate() error {
  8532. invalidParams := request.ErrInvalidParams{Context: "DeleteObjectsInput"}
  8533. if s.Bucket == nil {
  8534. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8535. }
  8536. if s.Delete == nil {
  8537. invalidParams.Add(request.NewErrParamRequired("Delete"))
  8538. }
  8539. if s.Delete != nil {
  8540. if err := s.Delete.Validate(); err != nil {
  8541. invalidParams.AddNested("Delete", err.(request.ErrInvalidParams))
  8542. }
  8543. }
  8544. if invalidParams.Len() > 0 {
  8545. return invalidParams
  8546. }
  8547. return nil
  8548. }
  8549. // SetBucket sets the Bucket field's value.
  8550. func (s *DeleteObjectsInput) SetBucket(v string) *DeleteObjectsInput {
  8551. s.Bucket = &v
  8552. return s
  8553. }
  8554. func (s *DeleteObjectsInput) getBucket() (v string) {
  8555. if s.Bucket == nil {
  8556. return v
  8557. }
  8558. return *s.Bucket
  8559. }
  8560. // SetDelete sets the Delete field's value.
  8561. func (s *DeleteObjectsInput) SetDelete(v *Delete) *DeleteObjectsInput {
  8562. s.Delete = v
  8563. return s
  8564. }
  8565. // SetMFA sets the MFA field's value.
  8566. func (s *DeleteObjectsInput) SetMFA(v string) *DeleteObjectsInput {
  8567. s.MFA = &v
  8568. return s
  8569. }
  8570. // SetRequestPayer sets the RequestPayer field's value.
  8571. func (s *DeleteObjectsInput) SetRequestPayer(v string) *DeleteObjectsInput {
  8572. s.RequestPayer = &v
  8573. return s
  8574. }
  8575. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteObjectsOutput
  8576. type DeleteObjectsOutput struct {
  8577. _ struct{} `type:"structure"`
  8578. Deleted []*DeletedObject `type:"list" flattened:"true"`
  8579. Errors []*Error `locationName:"Error" type:"list" flattened:"true"`
  8580. // If present, indicates that the requester was successfully charged for the
  8581. // request.
  8582. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  8583. }
  8584. // String returns the string representation
  8585. func (s DeleteObjectsOutput) String() string {
  8586. return awsutil.Prettify(s)
  8587. }
  8588. // GoString returns the string representation
  8589. func (s DeleteObjectsOutput) GoString() string {
  8590. return s.String()
  8591. }
  8592. // SetDeleted sets the Deleted field's value.
  8593. func (s *DeleteObjectsOutput) SetDeleted(v []*DeletedObject) *DeleteObjectsOutput {
  8594. s.Deleted = v
  8595. return s
  8596. }
  8597. // SetErrors sets the Errors field's value.
  8598. func (s *DeleteObjectsOutput) SetErrors(v []*Error) *DeleteObjectsOutput {
  8599. s.Errors = v
  8600. return s
  8601. }
  8602. // SetRequestCharged sets the RequestCharged field's value.
  8603. func (s *DeleteObjectsOutput) SetRequestCharged(v string) *DeleteObjectsOutput {
  8604. s.RequestCharged = &v
  8605. return s
  8606. }
  8607. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeletedObject
  8608. type DeletedObject struct {
  8609. _ struct{} `type:"structure"`
  8610. DeleteMarker *bool `type:"boolean"`
  8611. DeleteMarkerVersionId *string `type:"string"`
  8612. Key *string `min:"1" type:"string"`
  8613. VersionId *string `type:"string"`
  8614. }
  8615. // String returns the string representation
  8616. func (s DeletedObject) String() string {
  8617. return awsutil.Prettify(s)
  8618. }
  8619. // GoString returns the string representation
  8620. func (s DeletedObject) GoString() string {
  8621. return s.String()
  8622. }
  8623. // SetDeleteMarker sets the DeleteMarker field's value.
  8624. func (s *DeletedObject) SetDeleteMarker(v bool) *DeletedObject {
  8625. s.DeleteMarker = &v
  8626. return s
  8627. }
  8628. // SetDeleteMarkerVersionId sets the DeleteMarkerVersionId field's value.
  8629. func (s *DeletedObject) SetDeleteMarkerVersionId(v string) *DeletedObject {
  8630. s.DeleteMarkerVersionId = &v
  8631. return s
  8632. }
  8633. // SetKey sets the Key field's value.
  8634. func (s *DeletedObject) SetKey(v string) *DeletedObject {
  8635. s.Key = &v
  8636. return s
  8637. }
  8638. // SetVersionId sets the VersionId field's value.
  8639. func (s *DeletedObject) SetVersionId(v string) *DeletedObject {
  8640. s.VersionId = &v
  8641. return s
  8642. }
  8643. // Container for replication destination information.
  8644. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Destination
  8645. type Destination struct {
  8646. _ struct{} `type:"structure"`
  8647. // Container for information regarding the access control for replicas.
  8648. AccessControlTranslation *AccessControlTranslation `type:"structure"`
  8649. // Account ID of the destination bucket. Currently this is only being verified
  8650. // if Access Control Translation is enabled
  8651. Account *string `type:"string"`
  8652. // Amazon resource name (ARN) of the bucket where you want Amazon S3 to store
  8653. // replicas of the object identified by the rule.
  8654. //
  8655. // Bucket is a required field
  8656. Bucket *string `type:"string" required:"true"`
  8657. // Container for information regarding encryption based configuration for replicas.
  8658. EncryptionConfiguration *EncryptionConfiguration `type:"structure"`
  8659. // The class of storage used to store the object.
  8660. StorageClass *string `type:"string" enum:"StorageClass"`
  8661. }
  8662. // String returns the string representation
  8663. func (s Destination) String() string {
  8664. return awsutil.Prettify(s)
  8665. }
  8666. // GoString returns the string representation
  8667. func (s Destination) GoString() string {
  8668. return s.String()
  8669. }
  8670. // Validate inspects the fields of the type to determine if they are valid.
  8671. func (s *Destination) Validate() error {
  8672. invalidParams := request.ErrInvalidParams{Context: "Destination"}
  8673. if s.Bucket == nil {
  8674. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8675. }
  8676. if s.AccessControlTranslation != nil {
  8677. if err := s.AccessControlTranslation.Validate(); err != nil {
  8678. invalidParams.AddNested("AccessControlTranslation", err.(request.ErrInvalidParams))
  8679. }
  8680. }
  8681. if invalidParams.Len() > 0 {
  8682. return invalidParams
  8683. }
  8684. return nil
  8685. }
  8686. // SetAccessControlTranslation sets the AccessControlTranslation field's value.
  8687. func (s *Destination) SetAccessControlTranslation(v *AccessControlTranslation) *Destination {
  8688. s.AccessControlTranslation = v
  8689. return s
  8690. }
  8691. // SetAccount sets the Account field's value.
  8692. func (s *Destination) SetAccount(v string) *Destination {
  8693. s.Account = &v
  8694. return s
  8695. }
  8696. // SetBucket sets the Bucket field's value.
  8697. func (s *Destination) SetBucket(v string) *Destination {
  8698. s.Bucket = &v
  8699. return s
  8700. }
  8701. func (s *Destination) getBucket() (v string) {
  8702. if s.Bucket == nil {
  8703. return v
  8704. }
  8705. return *s.Bucket
  8706. }
  8707. // SetEncryptionConfiguration sets the EncryptionConfiguration field's value.
  8708. func (s *Destination) SetEncryptionConfiguration(v *EncryptionConfiguration) *Destination {
  8709. s.EncryptionConfiguration = v
  8710. return s
  8711. }
  8712. // SetStorageClass sets the StorageClass field's value.
  8713. func (s *Destination) SetStorageClass(v string) *Destination {
  8714. s.StorageClass = &v
  8715. return s
  8716. }
  8717. // Describes the server-side encryption that will be applied to the restore
  8718. // results.
  8719. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Encryption
  8720. type Encryption struct {
  8721. _ struct{} `type:"structure"`
  8722. // The server-side encryption algorithm used when storing job results in Amazon
  8723. // S3 (e.g., AES256, aws:kms).
  8724. //
  8725. // EncryptionType is a required field
  8726. EncryptionType *string `type:"string" required:"true" enum:"ServerSideEncryption"`
  8727. // If the encryption type is aws:kms, this optional value can be used to specify
  8728. // the encryption context for the restore results.
  8729. KMSContext *string `type:"string"`
  8730. // If the encryption type is aws:kms, this optional value specifies the AWS
  8731. // KMS key ID to use for encryption of job results.
  8732. KMSKeyId *string `type:"string"`
  8733. }
  8734. // String returns the string representation
  8735. func (s Encryption) String() string {
  8736. return awsutil.Prettify(s)
  8737. }
  8738. // GoString returns the string representation
  8739. func (s Encryption) GoString() string {
  8740. return s.String()
  8741. }
  8742. // Validate inspects the fields of the type to determine if they are valid.
  8743. func (s *Encryption) Validate() error {
  8744. invalidParams := request.ErrInvalidParams{Context: "Encryption"}
  8745. if s.EncryptionType == nil {
  8746. invalidParams.Add(request.NewErrParamRequired("EncryptionType"))
  8747. }
  8748. if invalidParams.Len() > 0 {
  8749. return invalidParams
  8750. }
  8751. return nil
  8752. }
  8753. // SetEncryptionType sets the EncryptionType field's value.
  8754. func (s *Encryption) SetEncryptionType(v string) *Encryption {
  8755. s.EncryptionType = &v
  8756. return s
  8757. }
  8758. // SetKMSContext sets the KMSContext field's value.
  8759. func (s *Encryption) SetKMSContext(v string) *Encryption {
  8760. s.KMSContext = &v
  8761. return s
  8762. }
  8763. // SetKMSKeyId sets the KMSKeyId field's value.
  8764. func (s *Encryption) SetKMSKeyId(v string) *Encryption {
  8765. s.KMSKeyId = &v
  8766. return s
  8767. }
  8768. // Container for information regarding encryption based configuration for replicas.
  8769. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/EncryptionConfiguration
  8770. type EncryptionConfiguration struct {
  8771. _ struct{} `type:"structure"`
  8772. // The id of the KMS key used to encrypt the replica object.
  8773. ReplicaKmsKeyID *string `type:"string"`
  8774. }
  8775. // String returns the string representation
  8776. func (s EncryptionConfiguration) String() string {
  8777. return awsutil.Prettify(s)
  8778. }
  8779. // GoString returns the string representation
  8780. func (s EncryptionConfiguration) GoString() string {
  8781. return s.String()
  8782. }
  8783. // SetReplicaKmsKeyID sets the ReplicaKmsKeyID field's value.
  8784. func (s *EncryptionConfiguration) SetReplicaKmsKeyID(v string) *EncryptionConfiguration {
  8785. s.ReplicaKmsKeyID = &v
  8786. return s
  8787. }
  8788. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Error
  8789. type Error struct {
  8790. _ struct{} `type:"structure"`
  8791. Code *string `type:"string"`
  8792. Key *string `min:"1" type:"string"`
  8793. Message *string `type:"string"`
  8794. VersionId *string `type:"string"`
  8795. }
  8796. // String returns the string representation
  8797. func (s Error) String() string {
  8798. return awsutil.Prettify(s)
  8799. }
  8800. // GoString returns the string representation
  8801. func (s Error) GoString() string {
  8802. return s.String()
  8803. }
  8804. // SetCode sets the Code field's value.
  8805. func (s *Error) SetCode(v string) *Error {
  8806. s.Code = &v
  8807. return s
  8808. }
  8809. // SetKey sets the Key field's value.
  8810. func (s *Error) SetKey(v string) *Error {
  8811. s.Key = &v
  8812. return s
  8813. }
  8814. // SetMessage sets the Message field's value.
  8815. func (s *Error) SetMessage(v string) *Error {
  8816. s.Message = &v
  8817. return s
  8818. }
  8819. // SetVersionId sets the VersionId field's value.
  8820. func (s *Error) SetVersionId(v string) *Error {
  8821. s.VersionId = &v
  8822. return s
  8823. }
  8824. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ErrorDocument
  8825. type ErrorDocument struct {
  8826. _ struct{} `type:"structure"`
  8827. // The object key name to use when a 4XX class error occurs.
  8828. //
  8829. // Key is a required field
  8830. Key *string `min:"1" type:"string" required:"true"`
  8831. }
  8832. // String returns the string representation
  8833. func (s ErrorDocument) String() string {
  8834. return awsutil.Prettify(s)
  8835. }
  8836. // GoString returns the string representation
  8837. func (s ErrorDocument) GoString() string {
  8838. return s.String()
  8839. }
  8840. // Validate inspects the fields of the type to determine if they are valid.
  8841. func (s *ErrorDocument) Validate() error {
  8842. invalidParams := request.ErrInvalidParams{Context: "ErrorDocument"}
  8843. if s.Key == nil {
  8844. invalidParams.Add(request.NewErrParamRequired("Key"))
  8845. }
  8846. if s.Key != nil && len(*s.Key) < 1 {
  8847. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  8848. }
  8849. if invalidParams.Len() > 0 {
  8850. return invalidParams
  8851. }
  8852. return nil
  8853. }
  8854. // SetKey sets the Key field's value.
  8855. func (s *ErrorDocument) SetKey(v string) *ErrorDocument {
  8856. s.Key = &v
  8857. return s
  8858. }
  8859. // Container for key value pair that defines the criteria for the filter rule.
  8860. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/FilterRule
  8861. type FilterRule struct {
  8862. _ struct{} `type:"structure"`
  8863. // Object key name prefix or suffix identifying one or more objects to which
  8864. // the filtering rule applies. Maximum prefix length can be up to 1,024 characters.
  8865. // Overlapping prefixes and suffixes are not supported. For more information,
  8866. // go to Configuring Event Notifications (http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  8867. Name *string `type:"string" enum:"FilterRuleName"`
  8868. Value *string `type:"string"`
  8869. }
  8870. // String returns the string representation
  8871. func (s FilterRule) String() string {
  8872. return awsutil.Prettify(s)
  8873. }
  8874. // GoString returns the string representation
  8875. func (s FilterRule) GoString() string {
  8876. return s.String()
  8877. }
  8878. // SetName sets the Name field's value.
  8879. func (s *FilterRule) SetName(v string) *FilterRule {
  8880. s.Name = &v
  8881. return s
  8882. }
  8883. // SetValue sets the Value field's value.
  8884. func (s *FilterRule) SetValue(v string) *FilterRule {
  8885. s.Value = &v
  8886. return s
  8887. }
  8888. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfigurationRequest
  8889. type GetBucketAccelerateConfigurationInput struct {
  8890. _ struct{} `type:"structure"`
  8891. // Name of the bucket for which the accelerate configuration is retrieved.
  8892. //
  8893. // Bucket is a required field
  8894. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8895. }
  8896. // String returns the string representation
  8897. func (s GetBucketAccelerateConfigurationInput) String() string {
  8898. return awsutil.Prettify(s)
  8899. }
  8900. // GoString returns the string representation
  8901. func (s GetBucketAccelerateConfigurationInput) GoString() string {
  8902. return s.String()
  8903. }
  8904. // Validate inspects the fields of the type to determine if they are valid.
  8905. func (s *GetBucketAccelerateConfigurationInput) Validate() error {
  8906. invalidParams := request.ErrInvalidParams{Context: "GetBucketAccelerateConfigurationInput"}
  8907. if s.Bucket == nil {
  8908. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8909. }
  8910. if invalidParams.Len() > 0 {
  8911. return invalidParams
  8912. }
  8913. return nil
  8914. }
  8915. // SetBucket sets the Bucket field's value.
  8916. func (s *GetBucketAccelerateConfigurationInput) SetBucket(v string) *GetBucketAccelerateConfigurationInput {
  8917. s.Bucket = &v
  8918. return s
  8919. }
  8920. func (s *GetBucketAccelerateConfigurationInput) getBucket() (v string) {
  8921. if s.Bucket == nil {
  8922. return v
  8923. }
  8924. return *s.Bucket
  8925. }
  8926. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAccelerateConfigurationOutput
  8927. type GetBucketAccelerateConfigurationOutput struct {
  8928. _ struct{} `type:"structure"`
  8929. // The accelerate configuration of the bucket.
  8930. Status *string `type:"string" enum:"BucketAccelerateStatus"`
  8931. }
  8932. // String returns the string representation
  8933. func (s GetBucketAccelerateConfigurationOutput) String() string {
  8934. return awsutil.Prettify(s)
  8935. }
  8936. // GoString returns the string representation
  8937. func (s GetBucketAccelerateConfigurationOutput) GoString() string {
  8938. return s.String()
  8939. }
  8940. // SetStatus sets the Status field's value.
  8941. func (s *GetBucketAccelerateConfigurationOutput) SetStatus(v string) *GetBucketAccelerateConfigurationOutput {
  8942. s.Status = &v
  8943. return s
  8944. }
  8945. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAclRequest
  8946. type GetBucketAclInput struct {
  8947. _ struct{} `type:"structure"`
  8948. // Bucket is a required field
  8949. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  8950. }
  8951. // String returns the string representation
  8952. func (s GetBucketAclInput) String() string {
  8953. return awsutil.Prettify(s)
  8954. }
  8955. // GoString returns the string representation
  8956. func (s GetBucketAclInput) GoString() string {
  8957. return s.String()
  8958. }
  8959. // Validate inspects the fields of the type to determine if they are valid.
  8960. func (s *GetBucketAclInput) Validate() error {
  8961. invalidParams := request.ErrInvalidParams{Context: "GetBucketAclInput"}
  8962. if s.Bucket == nil {
  8963. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  8964. }
  8965. if invalidParams.Len() > 0 {
  8966. return invalidParams
  8967. }
  8968. return nil
  8969. }
  8970. // SetBucket sets the Bucket field's value.
  8971. func (s *GetBucketAclInput) SetBucket(v string) *GetBucketAclInput {
  8972. s.Bucket = &v
  8973. return s
  8974. }
  8975. func (s *GetBucketAclInput) getBucket() (v string) {
  8976. if s.Bucket == nil {
  8977. return v
  8978. }
  8979. return *s.Bucket
  8980. }
  8981. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAclOutput
  8982. type GetBucketAclOutput struct {
  8983. _ struct{} `type:"structure"`
  8984. // A list of grants.
  8985. Grants []*Grant `locationName:"AccessControlList" locationNameList:"Grant" type:"list"`
  8986. Owner *Owner `type:"structure"`
  8987. }
  8988. // String returns the string representation
  8989. func (s GetBucketAclOutput) String() string {
  8990. return awsutil.Prettify(s)
  8991. }
  8992. // GoString returns the string representation
  8993. func (s GetBucketAclOutput) GoString() string {
  8994. return s.String()
  8995. }
  8996. // SetGrants sets the Grants field's value.
  8997. func (s *GetBucketAclOutput) SetGrants(v []*Grant) *GetBucketAclOutput {
  8998. s.Grants = v
  8999. return s
  9000. }
  9001. // SetOwner sets the Owner field's value.
  9002. func (s *GetBucketAclOutput) SetOwner(v *Owner) *GetBucketAclOutput {
  9003. s.Owner = v
  9004. return s
  9005. }
  9006. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfigurationRequest
  9007. type GetBucketAnalyticsConfigurationInput struct {
  9008. _ struct{} `type:"structure"`
  9009. // The name of the bucket from which an analytics configuration is retrieved.
  9010. //
  9011. // Bucket is a required field
  9012. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9013. // The identifier used to represent an analytics configuration.
  9014. //
  9015. // Id is a required field
  9016. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  9017. }
  9018. // String returns the string representation
  9019. func (s GetBucketAnalyticsConfigurationInput) String() string {
  9020. return awsutil.Prettify(s)
  9021. }
  9022. // GoString returns the string representation
  9023. func (s GetBucketAnalyticsConfigurationInput) GoString() string {
  9024. return s.String()
  9025. }
  9026. // Validate inspects the fields of the type to determine if they are valid.
  9027. func (s *GetBucketAnalyticsConfigurationInput) Validate() error {
  9028. invalidParams := request.ErrInvalidParams{Context: "GetBucketAnalyticsConfigurationInput"}
  9029. if s.Bucket == nil {
  9030. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9031. }
  9032. if s.Id == nil {
  9033. invalidParams.Add(request.NewErrParamRequired("Id"))
  9034. }
  9035. if invalidParams.Len() > 0 {
  9036. return invalidParams
  9037. }
  9038. return nil
  9039. }
  9040. // SetBucket sets the Bucket field's value.
  9041. func (s *GetBucketAnalyticsConfigurationInput) SetBucket(v string) *GetBucketAnalyticsConfigurationInput {
  9042. s.Bucket = &v
  9043. return s
  9044. }
  9045. func (s *GetBucketAnalyticsConfigurationInput) getBucket() (v string) {
  9046. if s.Bucket == nil {
  9047. return v
  9048. }
  9049. return *s.Bucket
  9050. }
  9051. // SetId sets the Id field's value.
  9052. func (s *GetBucketAnalyticsConfigurationInput) SetId(v string) *GetBucketAnalyticsConfigurationInput {
  9053. s.Id = &v
  9054. return s
  9055. }
  9056. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketAnalyticsConfigurationOutput
  9057. type GetBucketAnalyticsConfigurationOutput struct {
  9058. _ struct{} `type:"structure" payload:"AnalyticsConfiguration"`
  9059. // The configuration and any analyses for the analytics filter.
  9060. AnalyticsConfiguration *AnalyticsConfiguration `type:"structure"`
  9061. }
  9062. // String returns the string representation
  9063. func (s GetBucketAnalyticsConfigurationOutput) String() string {
  9064. return awsutil.Prettify(s)
  9065. }
  9066. // GoString returns the string representation
  9067. func (s GetBucketAnalyticsConfigurationOutput) GoString() string {
  9068. return s.String()
  9069. }
  9070. // SetAnalyticsConfiguration sets the AnalyticsConfiguration field's value.
  9071. func (s *GetBucketAnalyticsConfigurationOutput) SetAnalyticsConfiguration(v *AnalyticsConfiguration) *GetBucketAnalyticsConfigurationOutput {
  9072. s.AnalyticsConfiguration = v
  9073. return s
  9074. }
  9075. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCorsRequest
  9076. type GetBucketCorsInput struct {
  9077. _ struct{} `type:"structure"`
  9078. // Bucket is a required field
  9079. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9080. }
  9081. // String returns the string representation
  9082. func (s GetBucketCorsInput) String() string {
  9083. return awsutil.Prettify(s)
  9084. }
  9085. // GoString returns the string representation
  9086. func (s GetBucketCorsInput) GoString() string {
  9087. return s.String()
  9088. }
  9089. // Validate inspects the fields of the type to determine if they are valid.
  9090. func (s *GetBucketCorsInput) Validate() error {
  9091. invalidParams := request.ErrInvalidParams{Context: "GetBucketCorsInput"}
  9092. if s.Bucket == nil {
  9093. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9094. }
  9095. if invalidParams.Len() > 0 {
  9096. return invalidParams
  9097. }
  9098. return nil
  9099. }
  9100. // SetBucket sets the Bucket field's value.
  9101. func (s *GetBucketCorsInput) SetBucket(v string) *GetBucketCorsInput {
  9102. s.Bucket = &v
  9103. return s
  9104. }
  9105. func (s *GetBucketCorsInput) getBucket() (v string) {
  9106. if s.Bucket == nil {
  9107. return v
  9108. }
  9109. return *s.Bucket
  9110. }
  9111. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketCorsOutput
  9112. type GetBucketCorsOutput struct {
  9113. _ struct{} `type:"structure"`
  9114. CORSRules []*CORSRule `locationName:"CORSRule" type:"list" flattened:"true"`
  9115. }
  9116. // String returns the string representation
  9117. func (s GetBucketCorsOutput) String() string {
  9118. return awsutil.Prettify(s)
  9119. }
  9120. // GoString returns the string representation
  9121. func (s GetBucketCorsOutput) GoString() string {
  9122. return s.String()
  9123. }
  9124. // SetCORSRules sets the CORSRules field's value.
  9125. func (s *GetBucketCorsOutput) SetCORSRules(v []*CORSRule) *GetBucketCorsOutput {
  9126. s.CORSRules = v
  9127. return s
  9128. }
  9129. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryptionRequest
  9130. type GetBucketEncryptionInput struct {
  9131. _ struct{} `type:"structure"`
  9132. // The name of the bucket from which the server-side encryption configuration
  9133. // is retrieved.
  9134. //
  9135. // Bucket is a required field
  9136. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9137. }
  9138. // String returns the string representation
  9139. func (s GetBucketEncryptionInput) String() string {
  9140. return awsutil.Prettify(s)
  9141. }
  9142. // GoString returns the string representation
  9143. func (s GetBucketEncryptionInput) GoString() string {
  9144. return s.String()
  9145. }
  9146. // Validate inspects the fields of the type to determine if they are valid.
  9147. func (s *GetBucketEncryptionInput) Validate() error {
  9148. invalidParams := request.ErrInvalidParams{Context: "GetBucketEncryptionInput"}
  9149. if s.Bucket == nil {
  9150. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9151. }
  9152. if invalidParams.Len() > 0 {
  9153. return invalidParams
  9154. }
  9155. return nil
  9156. }
  9157. // SetBucket sets the Bucket field's value.
  9158. func (s *GetBucketEncryptionInput) SetBucket(v string) *GetBucketEncryptionInput {
  9159. s.Bucket = &v
  9160. return s
  9161. }
  9162. func (s *GetBucketEncryptionInput) getBucket() (v string) {
  9163. if s.Bucket == nil {
  9164. return v
  9165. }
  9166. return *s.Bucket
  9167. }
  9168. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketEncryptionOutput
  9169. type GetBucketEncryptionOutput struct {
  9170. _ struct{} `type:"structure" payload:"ServerSideEncryptionConfiguration"`
  9171. // Container for server-side encryption configuration rules. Currently S3 supports
  9172. // one rule only.
  9173. ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `type:"structure"`
  9174. }
  9175. // String returns the string representation
  9176. func (s GetBucketEncryptionOutput) String() string {
  9177. return awsutil.Prettify(s)
  9178. }
  9179. // GoString returns the string representation
  9180. func (s GetBucketEncryptionOutput) GoString() string {
  9181. return s.String()
  9182. }
  9183. // SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value.
  9184. func (s *GetBucketEncryptionOutput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *GetBucketEncryptionOutput {
  9185. s.ServerSideEncryptionConfiguration = v
  9186. return s
  9187. }
  9188. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfigurationRequest
  9189. type GetBucketInventoryConfigurationInput struct {
  9190. _ struct{} `type:"structure"`
  9191. // The name of the bucket containing the inventory configuration to retrieve.
  9192. //
  9193. // Bucket is a required field
  9194. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9195. // The ID used to identify the inventory configuration.
  9196. //
  9197. // Id is a required field
  9198. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  9199. }
  9200. // String returns the string representation
  9201. func (s GetBucketInventoryConfigurationInput) String() string {
  9202. return awsutil.Prettify(s)
  9203. }
  9204. // GoString returns the string representation
  9205. func (s GetBucketInventoryConfigurationInput) GoString() string {
  9206. return s.String()
  9207. }
  9208. // Validate inspects the fields of the type to determine if they are valid.
  9209. func (s *GetBucketInventoryConfigurationInput) Validate() error {
  9210. invalidParams := request.ErrInvalidParams{Context: "GetBucketInventoryConfigurationInput"}
  9211. if s.Bucket == nil {
  9212. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9213. }
  9214. if s.Id == nil {
  9215. invalidParams.Add(request.NewErrParamRequired("Id"))
  9216. }
  9217. if invalidParams.Len() > 0 {
  9218. return invalidParams
  9219. }
  9220. return nil
  9221. }
  9222. // SetBucket sets the Bucket field's value.
  9223. func (s *GetBucketInventoryConfigurationInput) SetBucket(v string) *GetBucketInventoryConfigurationInput {
  9224. s.Bucket = &v
  9225. return s
  9226. }
  9227. func (s *GetBucketInventoryConfigurationInput) getBucket() (v string) {
  9228. if s.Bucket == nil {
  9229. return v
  9230. }
  9231. return *s.Bucket
  9232. }
  9233. // SetId sets the Id field's value.
  9234. func (s *GetBucketInventoryConfigurationInput) SetId(v string) *GetBucketInventoryConfigurationInput {
  9235. s.Id = &v
  9236. return s
  9237. }
  9238. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketInventoryConfigurationOutput
  9239. type GetBucketInventoryConfigurationOutput struct {
  9240. _ struct{} `type:"structure" payload:"InventoryConfiguration"`
  9241. // Specifies the inventory configuration.
  9242. InventoryConfiguration *InventoryConfiguration `type:"structure"`
  9243. }
  9244. // String returns the string representation
  9245. func (s GetBucketInventoryConfigurationOutput) String() string {
  9246. return awsutil.Prettify(s)
  9247. }
  9248. // GoString returns the string representation
  9249. func (s GetBucketInventoryConfigurationOutput) GoString() string {
  9250. return s.String()
  9251. }
  9252. // SetInventoryConfiguration sets the InventoryConfiguration field's value.
  9253. func (s *GetBucketInventoryConfigurationOutput) SetInventoryConfiguration(v *InventoryConfiguration) *GetBucketInventoryConfigurationOutput {
  9254. s.InventoryConfiguration = v
  9255. return s
  9256. }
  9257. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfigurationRequest
  9258. type GetBucketLifecycleConfigurationInput struct {
  9259. _ struct{} `type:"structure"`
  9260. // Bucket is a required field
  9261. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9262. }
  9263. // String returns the string representation
  9264. func (s GetBucketLifecycleConfigurationInput) String() string {
  9265. return awsutil.Prettify(s)
  9266. }
  9267. // GoString returns the string representation
  9268. func (s GetBucketLifecycleConfigurationInput) GoString() string {
  9269. return s.String()
  9270. }
  9271. // Validate inspects the fields of the type to determine if they are valid.
  9272. func (s *GetBucketLifecycleConfigurationInput) Validate() error {
  9273. invalidParams := request.ErrInvalidParams{Context: "GetBucketLifecycleConfigurationInput"}
  9274. if s.Bucket == nil {
  9275. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9276. }
  9277. if invalidParams.Len() > 0 {
  9278. return invalidParams
  9279. }
  9280. return nil
  9281. }
  9282. // SetBucket sets the Bucket field's value.
  9283. func (s *GetBucketLifecycleConfigurationInput) SetBucket(v string) *GetBucketLifecycleConfigurationInput {
  9284. s.Bucket = &v
  9285. return s
  9286. }
  9287. func (s *GetBucketLifecycleConfigurationInput) getBucket() (v string) {
  9288. if s.Bucket == nil {
  9289. return v
  9290. }
  9291. return *s.Bucket
  9292. }
  9293. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleConfigurationOutput
  9294. type GetBucketLifecycleConfigurationOutput struct {
  9295. _ struct{} `type:"structure"`
  9296. Rules []*LifecycleRule `locationName:"Rule" type:"list" flattened:"true"`
  9297. }
  9298. // String returns the string representation
  9299. func (s GetBucketLifecycleConfigurationOutput) String() string {
  9300. return awsutil.Prettify(s)
  9301. }
  9302. // GoString returns the string representation
  9303. func (s GetBucketLifecycleConfigurationOutput) GoString() string {
  9304. return s.String()
  9305. }
  9306. // SetRules sets the Rules field's value.
  9307. func (s *GetBucketLifecycleConfigurationOutput) SetRules(v []*LifecycleRule) *GetBucketLifecycleConfigurationOutput {
  9308. s.Rules = v
  9309. return s
  9310. }
  9311. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleRequest
  9312. type GetBucketLifecycleInput struct {
  9313. _ struct{} `type:"structure"`
  9314. // Bucket is a required field
  9315. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9316. }
  9317. // String returns the string representation
  9318. func (s GetBucketLifecycleInput) String() string {
  9319. return awsutil.Prettify(s)
  9320. }
  9321. // GoString returns the string representation
  9322. func (s GetBucketLifecycleInput) GoString() string {
  9323. return s.String()
  9324. }
  9325. // Validate inspects the fields of the type to determine if they are valid.
  9326. func (s *GetBucketLifecycleInput) Validate() error {
  9327. invalidParams := request.ErrInvalidParams{Context: "GetBucketLifecycleInput"}
  9328. if s.Bucket == nil {
  9329. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9330. }
  9331. if invalidParams.Len() > 0 {
  9332. return invalidParams
  9333. }
  9334. return nil
  9335. }
  9336. // SetBucket sets the Bucket field's value.
  9337. func (s *GetBucketLifecycleInput) SetBucket(v string) *GetBucketLifecycleInput {
  9338. s.Bucket = &v
  9339. return s
  9340. }
  9341. func (s *GetBucketLifecycleInput) getBucket() (v string) {
  9342. if s.Bucket == nil {
  9343. return v
  9344. }
  9345. return *s.Bucket
  9346. }
  9347. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLifecycleOutput
  9348. type GetBucketLifecycleOutput struct {
  9349. _ struct{} `type:"structure"`
  9350. Rules []*Rule `locationName:"Rule" type:"list" flattened:"true"`
  9351. }
  9352. // String returns the string representation
  9353. func (s GetBucketLifecycleOutput) String() string {
  9354. return awsutil.Prettify(s)
  9355. }
  9356. // GoString returns the string representation
  9357. func (s GetBucketLifecycleOutput) GoString() string {
  9358. return s.String()
  9359. }
  9360. // SetRules sets the Rules field's value.
  9361. func (s *GetBucketLifecycleOutput) SetRules(v []*Rule) *GetBucketLifecycleOutput {
  9362. s.Rules = v
  9363. return s
  9364. }
  9365. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocationRequest
  9366. type GetBucketLocationInput struct {
  9367. _ struct{} `type:"structure"`
  9368. // Bucket is a required field
  9369. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9370. }
  9371. // String returns the string representation
  9372. func (s GetBucketLocationInput) String() string {
  9373. return awsutil.Prettify(s)
  9374. }
  9375. // GoString returns the string representation
  9376. func (s GetBucketLocationInput) GoString() string {
  9377. return s.String()
  9378. }
  9379. // Validate inspects the fields of the type to determine if they are valid.
  9380. func (s *GetBucketLocationInput) Validate() error {
  9381. invalidParams := request.ErrInvalidParams{Context: "GetBucketLocationInput"}
  9382. if s.Bucket == nil {
  9383. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9384. }
  9385. if invalidParams.Len() > 0 {
  9386. return invalidParams
  9387. }
  9388. return nil
  9389. }
  9390. // SetBucket sets the Bucket field's value.
  9391. func (s *GetBucketLocationInput) SetBucket(v string) *GetBucketLocationInput {
  9392. s.Bucket = &v
  9393. return s
  9394. }
  9395. func (s *GetBucketLocationInput) getBucket() (v string) {
  9396. if s.Bucket == nil {
  9397. return v
  9398. }
  9399. return *s.Bucket
  9400. }
  9401. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocationOutput
  9402. type GetBucketLocationOutput struct {
  9403. _ struct{} `type:"structure"`
  9404. LocationConstraint *string `type:"string" enum:"BucketLocationConstraint"`
  9405. }
  9406. // String returns the string representation
  9407. func (s GetBucketLocationOutput) String() string {
  9408. return awsutil.Prettify(s)
  9409. }
  9410. // GoString returns the string representation
  9411. func (s GetBucketLocationOutput) GoString() string {
  9412. return s.String()
  9413. }
  9414. // SetLocationConstraint sets the LocationConstraint field's value.
  9415. func (s *GetBucketLocationOutput) SetLocationConstraint(v string) *GetBucketLocationOutput {
  9416. s.LocationConstraint = &v
  9417. return s
  9418. }
  9419. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLoggingRequest
  9420. type GetBucketLoggingInput struct {
  9421. _ struct{} `type:"structure"`
  9422. // Bucket is a required field
  9423. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9424. }
  9425. // String returns the string representation
  9426. func (s GetBucketLoggingInput) String() string {
  9427. return awsutil.Prettify(s)
  9428. }
  9429. // GoString returns the string representation
  9430. func (s GetBucketLoggingInput) GoString() string {
  9431. return s.String()
  9432. }
  9433. // Validate inspects the fields of the type to determine if they are valid.
  9434. func (s *GetBucketLoggingInput) Validate() error {
  9435. invalidParams := request.ErrInvalidParams{Context: "GetBucketLoggingInput"}
  9436. if s.Bucket == nil {
  9437. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9438. }
  9439. if invalidParams.Len() > 0 {
  9440. return invalidParams
  9441. }
  9442. return nil
  9443. }
  9444. // SetBucket sets the Bucket field's value.
  9445. func (s *GetBucketLoggingInput) SetBucket(v string) *GetBucketLoggingInput {
  9446. s.Bucket = &v
  9447. return s
  9448. }
  9449. func (s *GetBucketLoggingInput) getBucket() (v string) {
  9450. if s.Bucket == nil {
  9451. return v
  9452. }
  9453. return *s.Bucket
  9454. }
  9455. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLoggingOutput
  9456. type GetBucketLoggingOutput struct {
  9457. _ struct{} `type:"structure"`
  9458. LoggingEnabled *LoggingEnabled `type:"structure"`
  9459. }
  9460. // String returns the string representation
  9461. func (s GetBucketLoggingOutput) String() string {
  9462. return awsutil.Prettify(s)
  9463. }
  9464. // GoString returns the string representation
  9465. func (s GetBucketLoggingOutput) GoString() string {
  9466. return s.String()
  9467. }
  9468. // SetLoggingEnabled sets the LoggingEnabled field's value.
  9469. func (s *GetBucketLoggingOutput) SetLoggingEnabled(v *LoggingEnabled) *GetBucketLoggingOutput {
  9470. s.LoggingEnabled = v
  9471. return s
  9472. }
  9473. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfigurationRequest
  9474. type GetBucketMetricsConfigurationInput struct {
  9475. _ struct{} `type:"structure"`
  9476. // The name of the bucket containing the metrics configuration to retrieve.
  9477. //
  9478. // Bucket is a required field
  9479. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9480. // The ID used to identify the metrics configuration.
  9481. //
  9482. // Id is a required field
  9483. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  9484. }
  9485. // String returns the string representation
  9486. func (s GetBucketMetricsConfigurationInput) String() string {
  9487. return awsutil.Prettify(s)
  9488. }
  9489. // GoString returns the string representation
  9490. func (s GetBucketMetricsConfigurationInput) GoString() string {
  9491. return s.String()
  9492. }
  9493. // Validate inspects the fields of the type to determine if they are valid.
  9494. func (s *GetBucketMetricsConfigurationInput) Validate() error {
  9495. invalidParams := request.ErrInvalidParams{Context: "GetBucketMetricsConfigurationInput"}
  9496. if s.Bucket == nil {
  9497. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9498. }
  9499. if s.Id == nil {
  9500. invalidParams.Add(request.NewErrParamRequired("Id"))
  9501. }
  9502. if invalidParams.Len() > 0 {
  9503. return invalidParams
  9504. }
  9505. return nil
  9506. }
  9507. // SetBucket sets the Bucket field's value.
  9508. func (s *GetBucketMetricsConfigurationInput) SetBucket(v string) *GetBucketMetricsConfigurationInput {
  9509. s.Bucket = &v
  9510. return s
  9511. }
  9512. func (s *GetBucketMetricsConfigurationInput) getBucket() (v string) {
  9513. if s.Bucket == nil {
  9514. return v
  9515. }
  9516. return *s.Bucket
  9517. }
  9518. // SetId sets the Id field's value.
  9519. func (s *GetBucketMetricsConfigurationInput) SetId(v string) *GetBucketMetricsConfigurationInput {
  9520. s.Id = &v
  9521. return s
  9522. }
  9523. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketMetricsConfigurationOutput
  9524. type GetBucketMetricsConfigurationOutput struct {
  9525. _ struct{} `type:"structure" payload:"MetricsConfiguration"`
  9526. // Specifies the metrics configuration.
  9527. MetricsConfiguration *MetricsConfiguration `type:"structure"`
  9528. }
  9529. // String returns the string representation
  9530. func (s GetBucketMetricsConfigurationOutput) String() string {
  9531. return awsutil.Prettify(s)
  9532. }
  9533. // GoString returns the string representation
  9534. func (s GetBucketMetricsConfigurationOutput) GoString() string {
  9535. return s.String()
  9536. }
  9537. // SetMetricsConfiguration sets the MetricsConfiguration field's value.
  9538. func (s *GetBucketMetricsConfigurationOutput) SetMetricsConfiguration(v *MetricsConfiguration) *GetBucketMetricsConfigurationOutput {
  9539. s.MetricsConfiguration = v
  9540. return s
  9541. }
  9542. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketNotificationConfigurationRequest
  9543. type GetBucketNotificationConfigurationRequest struct {
  9544. _ struct{} `type:"structure"`
  9545. // Name of the bucket to get the notification configuration for.
  9546. //
  9547. // Bucket is a required field
  9548. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9549. }
  9550. // String returns the string representation
  9551. func (s GetBucketNotificationConfigurationRequest) String() string {
  9552. return awsutil.Prettify(s)
  9553. }
  9554. // GoString returns the string representation
  9555. func (s GetBucketNotificationConfigurationRequest) GoString() string {
  9556. return s.String()
  9557. }
  9558. // Validate inspects the fields of the type to determine if they are valid.
  9559. func (s *GetBucketNotificationConfigurationRequest) Validate() error {
  9560. invalidParams := request.ErrInvalidParams{Context: "GetBucketNotificationConfigurationRequest"}
  9561. if s.Bucket == nil {
  9562. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9563. }
  9564. if invalidParams.Len() > 0 {
  9565. return invalidParams
  9566. }
  9567. return nil
  9568. }
  9569. // SetBucket sets the Bucket field's value.
  9570. func (s *GetBucketNotificationConfigurationRequest) SetBucket(v string) *GetBucketNotificationConfigurationRequest {
  9571. s.Bucket = &v
  9572. return s
  9573. }
  9574. func (s *GetBucketNotificationConfigurationRequest) getBucket() (v string) {
  9575. if s.Bucket == nil {
  9576. return v
  9577. }
  9578. return *s.Bucket
  9579. }
  9580. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyRequest
  9581. type GetBucketPolicyInput struct {
  9582. _ struct{} `type:"structure"`
  9583. // Bucket is a required field
  9584. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9585. }
  9586. // String returns the string representation
  9587. func (s GetBucketPolicyInput) String() string {
  9588. return awsutil.Prettify(s)
  9589. }
  9590. // GoString returns the string representation
  9591. func (s GetBucketPolicyInput) GoString() string {
  9592. return s.String()
  9593. }
  9594. // Validate inspects the fields of the type to determine if they are valid.
  9595. func (s *GetBucketPolicyInput) Validate() error {
  9596. invalidParams := request.ErrInvalidParams{Context: "GetBucketPolicyInput"}
  9597. if s.Bucket == nil {
  9598. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9599. }
  9600. if invalidParams.Len() > 0 {
  9601. return invalidParams
  9602. }
  9603. return nil
  9604. }
  9605. // SetBucket sets the Bucket field's value.
  9606. func (s *GetBucketPolicyInput) SetBucket(v string) *GetBucketPolicyInput {
  9607. s.Bucket = &v
  9608. return s
  9609. }
  9610. func (s *GetBucketPolicyInput) getBucket() (v string) {
  9611. if s.Bucket == nil {
  9612. return v
  9613. }
  9614. return *s.Bucket
  9615. }
  9616. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketPolicyOutput
  9617. type GetBucketPolicyOutput struct {
  9618. _ struct{} `type:"structure" payload:"Policy"`
  9619. // The bucket policy as a JSON document.
  9620. Policy *string `type:"string"`
  9621. }
  9622. // String returns the string representation
  9623. func (s GetBucketPolicyOutput) String() string {
  9624. return awsutil.Prettify(s)
  9625. }
  9626. // GoString returns the string representation
  9627. func (s GetBucketPolicyOutput) GoString() string {
  9628. return s.String()
  9629. }
  9630. // SetPolicy sets the Policy field's value.
  9631. func (s *GetBucketPolicyOutput) SetPolicy(v string) *GetBucketPolicyOutput {
  9632. s.Policy = &v
  9633. return s
  9634. }
  9635. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplicationRequest
  9636. type GetBucketReplicationInput struct {
  9637. _ struct{} `type:"structure"`
  9638. // Bucket is a required field
  9639. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9640. }
  9641. // String returns the string representation
  9642. func (s GetBucketReplicationInput) String() string {
  9643. return awsutil.Prettify(s)
  9644. }
  9645. // GoString returns the string representation
  9646. func (s GetBucketReplicationInput) GoString() string {
  9647. return s.String()
  9648. }
  9649. // Validate inspects the fields of the type to determine if they are valid.
  9650. func (s *GetBucketReplicationInput) Validate() error {
  9651. invalidParams := request.ErrInvalidParams{Context: "GetBucketReplicationInput"}
  9652. if s.Bucket == nil {
  9653. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9654. }
  9655. if invalidParams.Len() > 0 {
  9656. return invalidParams
  9657. }
  9658. return nil
  9659. }
  9660. // SetBucket sets the Bucket field's value.
  9661. func (s *GetBucketReplicationInput) SetBucket(v string) *GetBucketReplicationInput {
  9662. s.Bucket = &v
  9663. return s
  9664. }
  9665. func (s *GetBucketReplicationInput) getBucket() (v string) {
  9666. if s.Bucket == nil {
  9667. return v
  9668. }
  9669. return *s.Bucket
  9670. }
  9671. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketReplicationOutput
  9672. type GetBucketReplicationOutput struct {
  9673. _ struct{} `type:"structure" payload:"ReplicationConfiguration"`
  9674. // Container for replication rules. You can add as many as 1,000 rules. Total
  9675. // replication configuration size can be up to 2 MB.
  9676. ReplicationConfiguration *ReplicationConfiguration `type:"structure"`
  9677. }
  9678. // String returns the string representation
  9679. func (s GetBucketReplicationOutput) String() string {
  9680. return awsutil.Prettify(s)
  9681. }
  9682. // GoString returns the string representation
  9683. func (s GetBucketReplicationOutput) GoString() string {
  9684. return s.String()
  9685. }
  9686. // SetReplicationConfiguration sets the ReplicationConfiguration field's value.
  9687. func (s *GetBucketReplicationOutput) SetReplicationConfiguration(v *ReplicationConfiguration) *GetBucketReplicationOutput {
  9688. s.ReplicationConfiguration = v
  9689. return s
  9690. }
  9691. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPaymentRequest
  9692. type GetBucketRequestPaymentInput struct {
  9693. _ struct{} `type:"structure"`
  9694. // Bucket is a required field
  9695. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9696. }
  9697. // String returns the string representation
  9698. func (s GetBucketRequestPaymentInput) String() string {
  9699. return awsutil.Prettify(s)
  9700. }
  9701. // GoString returns the string representation
  9702. func (s GetBucketRequestPaymentInput) GoString() string {
  9703. return s.String()
  9704. }
  9705. // Validate inspects the fields of the type to determine if they are valid.
  9706. func (s *GetBucketRequestPaymentInput) Validate() error {
  9707. invalidParams := request.ErrInvalidParams{Context: "GetBucketRequestPaymentInput"}
  9708. if s.Bucket == nil {
  9709. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9710. }
  9711. if invalidParams.Len() > 0 {
  9712. return invalidParams
  9713. }
  9714. return nil
  9715. }
  9716. // SetBucket sets the Bucket field's value.
  9717. func (s *GetBucketRequestPaymentInput) SetBucket(v string) *GetBucketRequestPaymentInput {
  9718. s.Bucket = &v
  9719. return s
  9720. }
  9721. func (s *GetBucketRequestPaymentInput) getBucket() (v string) {
  9722. if s.Bucket == nil {
  9723. return v
  9724. }
  9725. return *s.Bucket
  9726. }
  9727. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketRequestPaymentOutput
  9728. type GetBucketRequestPaymentOutput struct {
  9729. _ struct{} `type:"structure"`
  9730. // Specifies who pays for the download and request fees.
  9731. Payer *string `type:"string" enum:"Payer"`
  9732. }
  9733. // String returns the string representation
  9734. func (s GetBucketRequestPaymentOutput) String() string {
  9735. return awsutil.Prettify(s)
  9736. }
  9737. // GoString returns the string representation
  9738. func (s GetBucketRequestPaymentOutput) GoString() string {
  9739. return s.String()
  9740. }
  9741. // SetPayer sets the Payer field's value.
  9742. func (s *GetBucketRequestPaymentOutput) SetPayer(v string) *GetBucketRequestPaymentOutput {
  9743. s.Payer = &v
  9744. return s
  9745. }
  9746. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTaggingRequest
  9747. type GetBucketTaggingInput struct {
  9748. _ struct{} `type:"structure"`
  9749. // Bucket is a required field
  9750. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9751. }
  9752. // String returns the string representation
  9753. func (s GetBucketTaggingInput) String() string {
  9754. return awsutil.Prettify(s)
  9755. }
  9756. // GoString returns the string representation
  9757. func (s GetBucketTaggingInput) GoString() string {
  9758. return s.String()
  9759. }
  9760. // Validate inspects the fields of the type to determine if they are valid.
  9761. func (s *GetBucketTaggingInput) Validate() error {
  9762. invalidParams := request.ErrInvalidParams{Context: "GetBucketTaggingInput"}
  9763. if s.Bucket == nil {
  9764. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9765. }
  9766. if invalidParams.Len() > 0 {
  9767. return invalidParams
  9768. }
  9769. return nil
  9770. }
  9771. // SetBucket sets the Bucket field's value.
  9772. func (s *GetBucketTaggingInput) SetBucket(v string) *GetBucketTaggingInput {
  9773. s.Bucket = &v
  9774. return s
  9775. }
  9776. func (s *GetBucketTaggingInput) getBucket() (v string) {
  9777. if s.Bucket == nil {
  9778. return v
  9779. }
  9780. return *s.Bucket
  9781. }
  9782. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketTaggingOutput
  9783. type GetBucketTaggingOutput struct {
  9784. _ struct{} `type:"structure"`
  9785. // TagSet is a required field
  9786. TagSet []*Tag `locationNameList:"Tag" type:"list" required:"true"`
  9787. }
  9788. // String returns the string representation
  9789. func (s GetBucketTaggingOutput) String() string {
  9790. return awsutil.Prettify(s)
  9791. }
  9792. // GoString returns the string representation
  9793. func (s GetBucketTaggingOutput) GoString() string {
  9794. return s.String()
  9795. }
  9796. // SetTagSet sets the TagSet field's value.
  9797. func (s *GetBucketTaggingOutput) SetTagSet(v []*Tag) *GetBucketTaggingOutput {
  9798. s.TagSet = v
  9799. return s
  9800. }
  9801. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioningRequest
  9802. type GetBucketVersioningInput struct {
  9803. _ struct{} `type:"structure"`
  9804. // Bucket is a required field
  9805. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9806. }
  9807. // String returns the string representation
  9808. func (s GetBucketVersioningInput) String() string {
  9809. return awsutil.Prettify(s)
  9810. }
  9811. // GoString returns the string representation
  9812. func (s GetBucketVersioningInput) GoString() string {
  9813. return s.String()
  9814. }
  9815. // Validate inspects the fields of the type to determine if they are valid.
  9816. func (s *GetBucketVersioningInput) Validate() error {
  9817. invalidParams := request.ErrInvalidParams{Context: "GetBucketVersioningInput"}
  9818. if s.Bucket == nil {
  9819. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9820. }
  9821. if invalidParams.Len() > 0 {
  9822. return invalidParams
  9823. }
  9824. return nil
  9825. }
  9826. // SetBucket sets the Bucket field's value.
  9827. func (s *GetBucketVersioningInput) SetBucket(v string) *GetBucketVersioningInput {
  9828. s.Bucket = &v
  9829. return s
  9830. }
  9831. func (s *GetBucketVersioningInput) getBucket() (v string) {
  9832. if s.Bucket == nil {
  9833. return v
  9834. }
  9835. return *s.Bucket
  9836. }
  9837. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketVersioningOutput
  9838. type GetBucketVersioningOutput struct {
  9839. _ struct{} `type:"structure"`
  9840. // Specifies whether MFA delete is enabled in the bucket versioning configuration.
  9841. // This element is only returned if the bucket has been configured with MFA
  9842. // delete. If the bucket has never been so configured, this element is not returned.
  9843. MFADelete *string `locationName:"MfaDelete" type:"string" enum:"MFADeleteStatus"`
  9844. // The versioning state of the bucket.
  9845. Status *string `type:"string" enum:"BucketVersioningStatus"`
  9846. }
  9847. // String returns the string representation
  9848. func (s GetBucketVersioningOutput) String() string {
  9849. return awsutil.Prettify(s)
  9850. }
  9851. // GoString returns the string representation
  9852. func (s GetBucketVersioningOutput) GoString() string {
  9853. return s.String()
  9854. }
  9855. // SetMFADelete sets the MFADelete field's value.
  9856. func (s *GetBucketVersioningOutput) SetMFADelete(v string) *GetBucketVersioningOutput {
  9857. s.MFADelete = &v
  9858. return s
  9859. }
  9860. // SetStatus sets the Status field's value.
  9861. func (s *GetBucketVersioningOutput) SetStatus(v string) *GetBucketVersioningOutput {
  9862. s.Status = &v
  9863. return s
  9864. }
  9865. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsiteRequest
  9866. type GetBucketWebsiteInput struct {
  9867. _ struct{} `type:"structure"`
  9868. // Bucket is a required field
  9869. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9870. }
  9871. // String returns the string representation
  9872. func (s GetBucketWebsiteInput) String() string {
  9873. return awsutil.Prettify(s)
  9874. }
  9875. // GoString returns the string representation
  9876. func (s GetBucketWebsiteInput) GoString() string {
  9877. return s.String()
  9878. }
  9879. // Validate inspects the fields of the type to determine if they are valid.
  9880. func (s *GetBucketWebsiteInput) Validate() error {
  9881. invalidParams := request.ErrInvalidParams{Context: "GetBucketWebsiteInput"}
  9882. if s.Bucket == nil {
  9883. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9884. }
  9885. if invalidParams.Len() > 0 {
  9886. return invalidParams
  9887. }
  9888. return nil
  9889. }
  9890. // SetBucket sets the Bucket field's value.
  9891. func (s *GetBucketWebsiteInput) SetBucket(v string) *GetBucketWebsiteInput {
  9892. s.Bucket = &v
  9893. return s
  9894. }
  9895. func (s *GetBucketWebsiteInput) getBucket() (v string) {
  9896. if s.Bucket == nil {
  9897. return v
  9898. }
  9899. return *s.Bucket
  9900. }
  9901. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketWebsiteOutput
  9902. type GetBucketWebsiteOutput struct {
  9903. _ struct{} `type:"structure"`
  9904. ErrorDocument *ErrorDocument `type:"structure"`
  9905. IndexDocument *IndexDocument `type:"structure"`
  9906. RedirectAllRequestsTo *RedirectAllRequestsTo `type:"structure"`
  9907. RoutingRules []*RoutingRule `locationNameList:"RoutingRule" type:"list"`
  9908. }
  9909. // String returns the string representation
  9910. func (s GetBucketWebsiteOutput) String() string {
  9911. return awsutil.Prettify(s)
  9912. }
  9913. // GoString returns the string representation
  9914. func (s GetBucketWebsiteOutput) GoString() string {
  9915. return s.String()
  9916. }
  9917. // SetErrorDocument sets the ErrorDocument field's value.
  9918. func (s *GetBucketWebsiteOutput) SetErrorDocument(v *ErrorDocument) *GetBucketWebsiteOutput {
  9919. s.ErrorDocument = v
  9920. return s
  9921. }
  9922. // SetIndexDocument sets the IndexDocument field's value.
  9923. func (s *GetBucketWebsiteOutput) SetIndexDocument(v *IndexDocument) *GetBucketWebsiteOutput {
  9924. s.IndexDocument = v
  9925. return s
  9926. }
  9927. // SetRedirectAllRequestsTo sets the RedirectAllRequestsTo field's value.
  9928. func (s *GetBucketWebsiteOutput) SetRedirectAllRequestsTo(v *RedirectAllRequestsTo) *GetBucketWebsiteOutput {
  9929. s.RedirectAllRequestsTo = v
  9930. return s
  9931. }
  9932. // SetRoutingRules sets the RoutingRules field's value.
  9933. func (s *GetBucketWebsiteOutput) SetRoutingRules(v []*RoutingRule) *GetBucketWebsiteOutput {
  9934. s.RoutingRules = v
  9935. return s
  9936. }
  9937. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAclRequest
  9938. type GetObjectAclInput struct {
  9939. _ struct{} `type:"structure"`
  9940. // Bucket is a required field
  9941. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  9942. // Key is a required field
  9943. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  9944. // Confirms that the requester knows that she or he will be charged for the
  9945. // request. Bucket owners need not specify this parameter in their requests.
  9946. // Documentation on downloading objects from requester pays buckets can be found
  9947. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  9948. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  9949. // VersionId used to reference a specific version of the object.
  9950. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  9951. }
  9952. // String returns the string representation
  9953. func (s GetObjectAclInput) String() string {
  9954. return awsutil.Prettify(s)
  9955. }
  9956. // GoString returns the string representation
  9957. func (s GetObjectAclInput) GoString() string {
  9958. return s.String()
  9959. }
  9960. // Validate inspects the fields of the type to determine if they are valid.
  9961. func (s *GetObjectAclInput) Validate() error {
  9962. invalidParams := request.ErrInvalidParams{Context: "GetObjectAclInput"}
  9963. if s.Bucket == nil {
  9964. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  9965. }
  9966. if s.Key == nil {
  9967. invalidParams.Add(request.NewErrParamRequired("Key"))
  9968. }
  9969. if s.Key != nil && len(*s.Key) < 1 {
  9970. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  9971. }
  9972. if invalidParams.Len() > 0 {
  9973. return invalidParams
  9974. }
  9975. return nil
  9976. }
  9977. // SetBucket sets the Bucket field's value.
  9978. func (s *GetObjectAclInput) SetBucket(v string) *GetObjectAclInput {
  9979. s.Bucket = &v
  9980. return s
  9981. }
  9982. func (s *GetObjectAclInput) getBucket() (v string) {
  9983. if s.Bucket == nil {
  9984. return v
  9985. }
  9986. return *s.Bucket
  9987. }
  9988. // SetKey sets the Key field's value.
  9989. func (s *GetObjectAclInput) SetKey(v string) *GetObjectAclInput {
  9990. s.Key = &v
  9991. return s
  9992. }
  9993. // SetRequestPayer sets the RequestPayer field's value.
  9994. func (s *GetObjectAclInput) SetRequestPayer(v string) *GetObjectAclInput {
  9995. s.RequestPayer = &v
  9996. return s
  9997. }
  9998. // SetVersionId sets the VersionId field's value.
  9999. func (s *GetObjectAclInput) SetVersionId(v string) *GetObjectAclInput {
  10000. s.VersionId = &v
  10001. return s
  10002. }
  10003. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectAclOutput
  10004. type GetObjectAclOutput struct {
  10005. _ struct{} `type:"structure"`
  10006. // A list of grants.
  10007. Grants []*Grant `locationName:"AccessControlList" locationNameList:"Grant" type:"list"`
  10008. Owner *Owner `type:"structure"`
  10009. // If present, indicates that the requester was successfully charged for the
  10010. // request.
  10011. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  10012. }
  10013. // String returns the string representation
  10014. func (s GetObjectAclOutput) String() string {
  10015. return awsutil.Prettify(s)
  10016. }
  10017. // GoString returns the string representation
  10018. func (s GetObjectAclOutput) GoString() string {
  10019. return s.String()
  10020. }
  10021. // SetGrants sets the Grants field's value.
  10022. func (s *GetObjectAclOutput) SetGrants(v []*Grant) *GetObjectAclOutput {
  10023. s.Grants = v
  10024. return s
  10025. }
  10026. // SetOwner sets the Owner field's value.
  10027. func (s *GetObjectAclOutput) SetOwner(v *Owner) *GetObjectAclOutput {
  10028. s.Owner = v
  10029. return s
  10030. }
  10031. // SetRequestCharged sets the RequestCharged field's value.
  10032. func (s *GetObjectAclOutput) SetRequestCharged(v string) *GetObjectAclOutput {
  10033. s.RequestCharged = &v
  10034. return s
  10035. }
  10036. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectRequest
  10037. type GetObjectInput struct {
  10038. _ struct{} `type:"structure"`
  10039. // Bucket is a required field
  10040. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  10041. // Return the object only if its entity tag (ETag) is the same as the one specified,
  10042. // otherwise return a 412 (precondition failed).
  10043. IfMatch *string `location:"header" locationName:"If-Match" type:"string"`
  10044. // Return the object only if it has been modified since the specified time,
  10045. // otherwise return a 304 (not modified).
  10046. IfModifiedSince *time.Time `location:"header" locationName:"If-Modified-Since" type:"timestamp" timestampFormat:"rfc822"`
  10047. // Return the object only if its entity tag (ETag) is different from the one
  10048. // specified, otherwise return a 304 (not modified).
  10049. IfNoneMatch *string `location:"header" locationName:"If-None-Match" type:"string"`
  10050. // Return the object only if it has not been modified since the specified time,
  10051. // otherwise return a 412 (precondition failed).
  10052. IfUnmodifiedSince *time.Time `location:"header" locationName:"If-Unmodified-Since" type:"timestamp" timestampFormat:"rfc822"`
  10053. // Key is a required field
  10054. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  10055. // Part number of the object being read. This is a positive integer between
  10056. // 1 and 10,000. Effectively performs a 'ranged' GET request for the part specified.
  10057. // Useful for downloading just a part of an object.
  10058. PartNumber *int64 `location:"querystring" locationName:"partNumber" type:"integer"`
  10059. // Downloads the specified range bytes of an object. For more information about
  10060. // the HTTP Range header, go to http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.35.
  10061. Range *string `location:"header" locationName:"Range" type:"string"`
  10062. // Confirms that the requester knows that she or he will be charged for the
  10063. // request. Bucket owners need not specify this parameter in their requests.
  10064. // Documentation on downloading objects from requester pays buckets can be found
  10065. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  10066. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  10067. // Sets the Cache-Control header of the response.
  10068. ResponseCacheControl *string `location:"querystring" locationName:"response-cache-control" type:"string"`
  10069. // Sets the Content-Disposition header of the response
  10070. ResponseContentDisposition *string `location:"querystring" locationName:"response-content-disposition" type:"string"`
  10071. // Sets the Content-Encoding header of the response.
  10072. ResponseContentEncoding *string `location:"querystring" locationName:"response-content-encoding" type:"string"`
  10073. // Sets the Content-Language header of the response.
  10074. ResponseContentLanguage *string `location:"querystring" locationName:"response-content-language" type:"string"`
  10075. // Sets the Content-Type header of the response.
  10076. ResponseContentType *string `location:"querystring" locationName:"response-content-type" type:"string"`
  10077. // Sets the Expires header of the response.
  10078. ResponseExpires *time.Time `location:"querystring" locationName:"response-expires" type:"timestamp" timestampFormat:"iso8601"`
  10079. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  10080. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  10081. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  10082. // data. This value is used to store the object and then it is discarded; Amazon
  10083. // does not store the encryption key. The key must be appropriate for use with
  10084. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  10085. // header.
  10086. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  10087. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  10088. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  10089. // key was transmitted without error.
  10090. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  10091. // VersionId used to reference a specific version of the object.
  10092. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  10093. }
  10094. // String returns the string representation
  10095. func (s GetObjectInput) String() string {
  10096. return awsutil.Prettify(s)
  10097. }
  10098. // GoString returns the string representation
  10099. func (s GetObjectInput) GoString() string {
  10100. return s.String()
  10101. }
  10102. // Validate inspects the fields of the type to determine if they are valid.
  10103. func (s *GetObjectInput) Validate() error {
  10104. invalidParams := request.ErrInvalidParams{Context: "GetObjectInput"}
  10105. if s.Bucket == nil {
  10106. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  10107. }
  10108. if s.Key == nil {
  10109. invalidParams.Add(request.NewErrParamRequired("Key"))
  10110. }
  10111. if s.Key != nil && len(*s.Key) < 1 {
  10112. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  10113. }
  10114. if invalidParams.Len() > 0 {
  10115. return invalidParams
  10116. }
  10117. return nil
  10118. }
  10119. // SetBucket sets the Bucket field's value.
  10120. func (s *GetObjectInput) SetBucket(v string) *GetObjectInput {
  10121. s.Bucket = &v
  10122. return s
  10123. }
  10124. func (s *GetObjectInput) getBucket() (v string) {
  10125. if s.Bucket == nil {
  10126. return v
  10127. }
  10128. return *s.Bucket
  10129. }
  10130. // SetIfMatch sets the IfMatch field's value.
  10131. func (s *GetObjectInput) SetIfMatch(v string) *GetObjectInput {
  10132. s.IfMatch = &v
  10133. return s
  10134. }
  10135. // SetIfModifiedSince sets the IfModifiedSince field's value.
  10136. func (s *GetObjectInput) SetIfModifiedSince(v time.Time) *GetObjectInput {
  10137. s.IfModifiedSince = &v
  10138. return s
  10139. }
  10140. // SetIfNoneMatch sets the IfNoneMatch field's value.
  10141. func (s *GetObjectInput) SetIfNoneMatch(v string) *GetObjectInput {
  10142. s.IfNoneMatch = &v
  10143. return s
  10144. }
  10145. // SetIfUnmodifiedSince sets the IfUnmodifiedSince field's value.
  10146. func (s *GetObjectInput) SetIfUnmodifiedSince(v time.Time) *GetObjectInput {
  10147. s.IfUnmodifiedSince = &v
  10148. return s
  10149. }
  10150. // SetKey sets the Key field's value.
  10151. func (s *GetObjectInput) SetKey(v string) *GetObjectInput {
  10152. s.Key = &v
  10153. return s
  10154. }
  10155. // SetPartNumber sets the PartNumber field's value.
  10156. func (s *GetObjectInput) SetPartNumber(v int64) *GetObjectInput {
  10157. s.PartNumber = &v
  10158. return s
  10159. }
  10160. // SetRange sets the Range field's value.
  10161. func (s *GetObjectInput) SetRange(v string) *GetObjectInput {
  10162. s.Range = &v
  10163. return s
  10164. }
  10165. // SetRequestPayer sets the RequestPayer field's value.
  10166. func (s *GetObjectInput) SetRequestPayer(v string) *GetObjectInput {
  10167. s.RequestPayer = &v
  10168. return s
  10169. }
  10170. // SetResponseCacheControl sets the ResponseCacheControl field's value.
  10171. func (s *GetObjectInput) SetResponseCacheControl(v string) *GetObjectInput {
  10172. s.ResponseCacheControl = &v
  10173. return s
  10174. }
  10175. // SetResponseContentDisposition sets the ResponseContentDisposition field's value.
  10176. func (s *GetObjectInput) SetResponseContentDisposition(v string) *GetObjectInput {
  10177. s.ResponseContentDisposition = &v
  10178. return s
  10179. }
  10180. // SetResponseContentEncoding sets the ResponseContentEncoding field's value.
  10181. func (s *GetObjectInput) SetResponseContentEncoding(v string) *GetObjectInput {
  10182. s.ResponseContentEncoding = &v
  10183. return s
  10184. }
  10185. // SetResponseContentLanguage sets the ResponseContentLanguage field's value.
  10186. func (s *GetObjectInput) SetResponseContentLanguage(v string) *GetObjectInput {
  10187. s.ResponseContentLanguage = &v
  10188. return s
  10189. }
  10190. // SetResponseContentType sets the ResponseContentType field's value.
  10191. func (s *GetObjectInput) SetResponseContentType(v string) *GetObjectInput {
  10192. s.ResponseContentType = &v
  10193. return s
  10194. }
  10195. // SetResponseExpires sets the ResponseExpires field's value.
  10196. func (s *GetObjectInput) SetResponseExpires(v time.Time) *GetObjectInput {
  10197. s.ResponseExpires = &v
  10198. return s
  10199. }
  10200. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  10201. func (s *GetObjectInput) SetSSECustomerAlgorithm(v string) *GetObjectInput {
  10202. s.SSECustomerAlgorithm = &v
  10203. return s
  10204. }
  10205. // SetSSECustomerKey sets the SSECustomerKey field's value.
  10206. func (s *GetObjectInput) SetSSECustomerKey(v string) *GetObjectInput {
  10207. s.SSECustomerKey = &v
  10208. return s
  10209. }
  10210. func (s *GetObjectInput) getSSECustomerKey() (v string) {
  10211. if s.SSECustomerKey == nil {
  10212. return v
  10213. }
  10214. return *s.SSECustomerKey
  10215. }
  10216. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  10217. func (s *GetObjectInput) SetSSECustomerKeyMD5(v string) *GetObjectInput {
  10218. s.SSECustomerKeyMD5 = &v
  10219. return s
  10220. }
  10221. // SetVersionId sets the VersionId field's value.
  10222. func (s *GetObjectInput) SetVersionId(v string) *GetObjectInput {
  10223. s.VersionId = &v
  10224. return s
  10225. }
  10226. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectOutput
  10227. type GetObjectOutput struct {
  10228. _ struct{} `type:"structure" payload:"Body"`
  10229. AcceptRanges *string `location:"header" locationName:"accept-ranges" type:"string"`
  10230. // Object data.
  10231. Body io.ReadCloser `type:"blob"`
  10232. // Specifies caching behavior along the request/reply chain.
  10233. CacheControl *string `location:"header" locationName:"Cache-Control" type:"string"`
  10234. // Specifies presentational information for the object.
  10235. ContentDisposition *string `location:"header" locationName:"Content-Disposition" type:"string"`
  10236. // Specifies what content encodings have been applied to the object and thus
  10237. // what decoding mechanisms must be applied to obtain the media-type referenced
  10238. // by the Content-Type header field.
  10239. ContentEncoding *string `location:"header" locationName:"Content-Encoding" type:"string"`
  10240. // The language the content is in.
  10241. ContentLanguage *string `location:"header" locationName:"Content-Language" type:"string"`
  10242. // Size of the body in bytes.
  10243. ContentLength *int64 `location:"header" locationName:"Content-Length" type:"long"`
  10244. // The portion of the object returned in the response.
  10245. ContentRange *string `location:"header" locationName:"Content-Range" type:"string"`
  10246. // A standard MIME type describing the format of the object data.
  10247. ContentType *string `location:"header" locationName:"Content-Type" type:"string"`
  10248. // Specifies whether the object retrieved was (true) or was not (false) a Delete
  10249. // Marker. If false, this response header does not appear in the response.
  10250. DeleteMarker *bool `location:"header" locationName:"x-amz-delete-marker" type:"boolean"`
  10251. // An ETag is an opaque identifier assigned by a web server to a specific version
  10252. // of a resource found at a URL
  10253. ETag *string `location:"header" locationName:"ETag" type:"string"`
  10254. // If the object expiration is configured (see PUT Bucket lifecycle), the response
  10255. // includes this header. It includes the expiry-date and rule-id key value pairs
  10256. // providing object expiration information. The value of the rule-id is URL
  10257. // encoded.
  10258. Expiration *string `location:"header" locationName:"x-amz-expiration" type:"string"`
  10259. // The date and time at which the object is no longer cacheable.
  10260. Expires *string `location:"header" locationName:"Expires" type:"string"`
  10261. // Last modified date of the object
  10262. LastModified *time.Time `location:"header" locationName:"Last-Modified" type:"timestamp" timestampFormat:"rfc822"`
  10263. // A map of metadata to store with the object in S3.
  10264. Metadata map[string]*string `location:"headers" locationName:"x-amz-meta-" type:"map"`
  10265. // This is set to the number of metadata entries not returned in x-amz-meta
  10266. // headers. This can happen if you create metadata using an API like SOAP that
  10267. // supports more flexible metadata than the REST API. For example, using SOAP,
  10268. // you can create metadata whose values are not legal HTTP headers.
  10269. MissingMeta *int64 `location:"header" locationName:"x-amz-missing-meta" type:"integer"`
  10270. // The count of parts this object has.
  10271. PartsCount *int64 `location:"header" locationName:"x-amz-mp-parts-count" type:"integer"`
  10272. ReplicationStatus *string `location:"header" locationName:"x-amz-replication-status" type:"string" enum:"ReplicationStatus"`
  10273. // If present, indicates that the requester was successfully charged for the
  10274. // request.
  10275. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  10276. // Provides information about object restoration operation and expiration time
  10277. // of the restored object copy.
  10278. Restore *string `location:"header" locationName:"x-amz-restore" type:"string"`
  10279. // If server-side encryption with a customer-provided encryption key was requested,
  10280. // the response will include this header confirming the encryption algorithm
  10281. // used.
  10282. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  10283. // If server-side encryption with a customer-provided encryption key was requested,
  10284. // the response will include this header to provide round trip message integrity
  10285. // verification of the customer-provided encryption key.
  10286. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  10287. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  10288. // encryption key that was used for the object.
  10289. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  10290. // The Server-side encryption algorithm used when storing this object in S3
  10291. // (e.g., AES256, aws:kms).
  10292. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  10293. StorageClass *string `location:"header" locationName:"x-amz-storage-class" type:"string" enum:"StorageClass"`
  10294. // The number of tags, if any, on the object.
  10295. TagCount *int64 `location:"header" locationName:"x-amz-tagging-count" type:"integer"`
  10296. // Version of the object.
  10297. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  10298. // If the bucket is configured as a website, redirects requests for this object
  10299. // to another object in the same bucket or to an external URL. Amazon S3 stores
  10300. // the value of this header in the object metadata.
  10301. WebsiteRedirectLocation *string `location:"header" locationName:"x-amz-website-redirect-location" type:"string"`
  10302. }
  10303. // String returns the string representation
  10304. func (s GetObjectOutput) String() string {
  10305. return awsutil.Prettify(s)
  10306. }
  10307. // GoString returns the string representation
  10308. func (s GetObjectOutput) GoString() string {
  10309. return s.String()
  10310. }
  10311. // SetAcceptRanges sets the AcceptRanges field's value.
  10312. func (s *GetObjectOutput) SetAcceptRanges(v string) *GetObjectOutput {
  10313. s.AcceptRanges = &v
  10314. return s
  10315. }
  10316. // SetBody sets the Body field's value.
  10317. func (s *GetObjectOutput) SetBody(v io.ReadCloser) *GetObjectOutput {
  10318. s.Body = v
  10319. return s
  10320. }
  10321. // SetCacheControl sets the CacheControl field's value.
  10322. func (s *GetObjectOutput) SetCacheControl(v string) *GetObjectOutput {
  10323. s.CacheControl = &v
  10324. return s
  10325. }
  10326. // SetContentDisposition sets the ContentDisposition field's value.
  10327. func (s *GetObjectOutput) SetContentDisposition(v string) *GetObjectOutput {
  10328. s.ContentDisposition = &v
  10329. return s
  10330. }
  10331. // SetContentEncoding sets the ContentEncoding field's value.
  10332. func (s *GetObjectOutput) SetContentEncoding(v string) *GetObjectOutput {
  10333. s.ContentEncoding = &v
  10334. return s
  10335. }
  10336. // SetContentLanguage sets the ContentLanguage field's value.
  10337. func (s *GetObjectOutput) SetContentLanguage(v string) *GetObjectOutput {
  10338. s.ContentLanguage = &v
  10339. return s
  10340. }
  10341. // SetContentLength sets the ContentLength field's value.
  10342. func (s *GetObjectOutput) SetContentLength(v int64) *GetObjectOutput {
  10343. s.ContentLength = &v
  10344. return s
  10345. }
  10346. // SetContentRange sets the ContentRange field's value.
  10347. func (s *GetObjectOutput) SetContentRange(v string) *GetObjectOutput {
  10348. s.ContentRange = &v
  10349. return s
  10350. }
  10351. // SetContentType sets the ContentType field's value.
  10352. func (s *GetObjectOutput) SetContentType(v string) *GetObjectOutput {
  10353. s.ContentType = &v
  10354. return s
  10355. }
  10356. // SetDeleteMarker sets the DeleteMarker field's value.
  10357. func (s *GetObjectOutput) SetDeleteMarker(v bool) *GetObjectOutput {
  10358. s.DeleteMarker = &v
  10359. return s
  10360. }
  10361. // SetETag sets the ETag field's value.
  10362. func (s *GetObjectOutput) SetETag(v string) *GetObjectOutput {
  10363. s.ETag = &v
  10364. return s
  10365. }
  10366. // SetExpiration sets the Expiration field's value.
  10367. func (s *GetObjectOutput) SetExpiration(v string) *GetObjectOutput {
  10368. s.Expiration = &v
  10369. return s
  10370. }
  10371. // SetExpires sets the Expires field's value.
  10372. func (s *GetObjectOutput) SetExpires(v string) *GetObjectOutput {
  10373. s.Expires = &v
  10374. return s
  10375. }
  10376. // SetLastModified sets the LastModified field's value.
  10377. func (s *GetObjectOutput) SetLastModified(v time.Time) *GetObjectOutput {
  10378. s.LastModified = &v
  10379. return s
  10380. }
  10381. // SetMetadata sets the Metadata field's value.
  10382. func (s *GetObjectOutput) SetMetadata(v map[string]*string) *GetObjectOutput {
  10383. s.Metadata = v
  10384. return s
  10385. }
  10386. // SetMissingMeta sets the MissingMeta field's value.
  10387. func (s *GetObjectOutput) SetMissingMeta(v int64) *GetObjectOutput {
  10388. s.MissingMeta = &v
  10389. return s
  10390. }
  10391. // SetPartsCount sets the PartsCount field's value.
  10392. func (s *GetObjectOutput) SetPartsCount(v int64) *GetObjectOutput {
  10393. s.PartsCount = &v
  10394. return s
  10395. }
  10396. // SetReplicationStatus sets the ReplicationStatus field's value.
  10397. func (s *GetObjectOutput) SetReplicationStatus(v string) *GetObjectOutput {
  10398. s.ReplicationStatus = &v
  10399. return s
  10400. }
  10401. // SetRequestCharged sets the RequestCharged field's value.
  10402. func (s *GetObjectOutput) SetRequestCharged(v string) *GetObjectOutput {
  10403. s.RequestCharged = &v
  10404. return s
  10405. }
  10406. // SetRestore sets the Restore field's value.
  10407. func (s *GetObjectOutput) SetRestore(v string) *GetObjectOutput {
  10408. s.Restore = &v
  10409. return s
  10410. }
  10411. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  10412. func (s *GetObjectOutput) SetSSECustomerAlgorithm(v string) *GetObjectOutput {
  10413. s.SSECustomerAlgorithm = &v
  10414. return s
  10415. }
  10416. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  10417. func (s *GetObjectOutput) SetSSECustomerKeyMD5(v string) *GetObjectOutput {
  10418. s.SSECustomerKeyMD5 = &v
  10419. return s
  10420. }
  10421. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  10422. func (s *GetObjectOutput) SetSSEKMSKeyId(v string) *GetObjectOutput {
  10423. s.SSEKMSKeyId = &v
  10424. return s
  10425. }
  10426. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  10427. func (s *GetObjectOutput) SetServerSideEncryption(v string) *GetObjectOutput {
  10428. s.ServerSideEncryption = &v
  10429. return s
  10430. }
  10431. // SetStorageClass sets the StorageClass field's value.
  10432. func (s *GetObjectOutput) SetStorageClass(v string) *GetObjectOutput {
  10433. s.StorageClass = &v
  10434. return s
  10435. }
  10436. // SetTagCount sets the TagCount field's value.
  10437. func (s *GetObjectOutput) SetTagCount(v int64) *GetObjectOutput {
  10438. s.TagCount = &v
  10439. return s
  10440. }
  10441. // SetVersionId sets the VersionId field's value.
  10442. func (s *GetObjectOutput) SetVersionId(v string) *GetObjectOutput {
  10443. s.VersionId = &v
  10444. return s
  10445. }
  10446. // SetWebsiteRedirectLocation sets the WebsiteRedirectLocation field's value.
  10447. func (s *GetObjectOutput) SetWebsiteRedirectLocation(v string) *GetObjectOutput {
  10448. s.WebsiteRedirectLocation = &v
  10449. return s
  10450. }
  10451. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTaggingRequest
  10452. type GetObjectTaggingInput struct {
  10453. _ struct{} `type:"structure"`
  10454. // Bucket is a required field
  10455. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  10456. // Key is a required field
  10457. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  10458. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  10459. }
  10460. // String returns the string representation
  10461. func (s GetObjectTaggingInput) String() string {
  10462. return awsutil.Prettify(s)
  10463. }
  10464. // GoString returns the string representation
  10465. func (s GetObjectTaggingInput) GoString() string {
  10466. return s.String()
  10467. }
  10468. // Validate inspects the fields of the type to determine if they are valid.
  10469. func (s *GetObjectTaggingInput) Validate() error {
  10470. invalidParams := request.ErrInvalidParams{Context: "GetObjectTaggingInput"}
  10471. if s.Bucket == nil {
  10472. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  10473. }
  10474. if s.Key == nil {
  10475. invalidParams.Add(request.NewErrParamRequired("Key"))
  10476. }
  10477. if s.Key != nil && len(*s.Key) < 1 {
  10478. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  10479. }
  10480. if invalidParams.Len() > 0 {
  10481. return invalidParams
  10482. }
  10483. return nil
  10484. }
  10485. // SetBucket sets the Bucket field's value.
  10486. func (s *GetObjectTaggingInput) SetBucket(v string) *GetObjectTaggingInput {
  10487. s.Bucket = &v
  10488. return s
  10489. }
  10490. func (s *GetObjectTaggingInput) getBucket() (v string) {
  10491. if s.Bucket == nil {
  10492. return v
  10493. }
  10494. return *s.Bucket
  10495. }
  10496. // SetKey sets the Key field's value.
  10497. func (s *GetObjectTaggingInput) SetKey(v string) *GetObjectTaggingInput {
  10498. s.Key = &v
  10499. return s
  10500. }
  10501. // SetVersionId sets the VersionId field's value.
  10502. func (s *GetObjectTaggingInput) SetVersionId(v string) *GetObjectTaggingInput {
  10503. s.VersionId = &v
  10504. return s
  10505. }
  10506. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTaggingOutput
  10507. type GetObjectTaggingOutput struct {
  10508. _ struct{} `type:"structure"`
  10509. // TagSet is a required field
  10510. TagSet []*Tag `locationNameList:"Tag" type:"list" required:"true"`
  10511. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  10512. }
  10513. // String returns the string representation
  10514. func (s GetObjectTaggingOutput) String() string {
  10515. return awsutil.Prettify(s)
  10516. }
  10517. // GoString returns the string representation
  10518. func (s GetObjectTaggingOutput) GoString() string {
  10519. return s.String()
  10520. }
  10521. // SetTagSet sets the TagSet field's value.
  10522. func (s *GetObjectTaggingOutput) SetTagSet(v []*Tag) *GetObjectTaggingOutput {
  10523. s.TagSet = v
  10524. return s
  10525. }
  10526. // SetVersionId sets the VersionId field's value.
  10527. func (s *GetObjectTaggingOutput) SetVersionId(v string) *GetObjectTaggingOutput {
  10528. s.VersionId = &v
  10529. return s
  10530. }
  10531. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrentRequest
  10532. type GetObjectTorrentInput struct {
  10533. _ struct{} `type:"structure"`
  10534. // Bucket is a required field
  10535. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  10536. // Key is a required field
  10537. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  10538. // Confirms that the requester knows that she or he will be charged for the
  10539. // request. Bucket owners need not specify this parameter in their requests.
  10540. // Documentation on downloading objects from requester pays buckets can be found
  10541. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  10542. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  10543. }
  10544. // String returns the string representation
  10545. func (s GetObjectTorrentInput) String() string {
  10546. return awsutil.Prettify(s)
  10547. }
  10548. // GoString returns the string representation
  10549. func (s GetObjectTorrentInput) GoString() string {
  10550. return s.String()
  10551. }
  10552. // Validate inspects the fields of the type to determine if they are valid.
  10553. func (s *GetObjectTorrentInput) Validate() error {
  10554. invalidParams := request.ErrInvalidParams{Context: "GetObjectTorrentInput"}
  10555. if s.Bucket == nil {
  10556. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  10557. }
  10558. if s.Key == nil {
  10559. invalidParams.Add(request.NewErrParamRequired("Key"))
  10560. }
  10561. if s.Key != nil && len(*s.Key) < 1 {
  10562. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  10563. }
  10564. if invalidParams.Len() > 0 {
  10565. return invalidParams
  10566. }
  10567. return nil
  10568. }
  10569. // SetBucket sets the Bucket field's value.
  10570. func (s *GetObjectTorrentInput) SetBucket(v string) *GetObjectTorrentInput {
  10571. s.Bucket = &v
  10572. return s
  10573. }
  10574. func (s *GetObjectTorrentInput) getBucket() (v string) {
  10575. if s.Bucket == nil {
  10576. return v
  10577. }
  10578. return *s.Bucket
  10579. }
  10580. // SetKey sets the Key field's value.
  10581. func (s *GetObjectTorrentInput) SetKey(v string) *GetObjectTorrentInput {
  10582. s.Key = &v
  10583. return s
  10584. }
  10585. // SetRequestPayer sets the RequestPayer field's value.
  10586. func (s *GetObjectTorrentInput) SetRequestPayer(v string) *GetObjectTorrentInput {
  10587. s.RequestPayer = &v
  10588. return s
  10589. }
  10590. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetObjectTorrentOutput
  10591. type GetObjectTorrentOutput struct {
  10592. _ struct{} `type:"structure" payload:"Body"`
  10593. Body io.ReadCloser `type:"blob"`
  10594. // If present, indicates that the requester was successfully charged for the
  10595. // request.
  10596. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  10597. }
  10598. // String returns the string representation
  10599. func (s GetObjectTorrentOutput) String() string {
  10600. return awsutil.Prettify(s)
  10601. }
  10602. // GoString returns the string representation
  10603. func (s GetObjectTorrentOutput) GoString() string {
  10604. return s.String()
  10605. }
  10606. // SetBody sets the Body field's value.
  10607. func (s *GetObjectTorrentOutput) SetBody(v io.ReadCloser) *GetObjectTorrentOutput {
  10608. s.Body = v
  10609. return s
  10610. }
  10611. // SetRequestCharged sets the RequestCharged field's value.
  10612. func (s *GetObjectTorrentOutput) SetRequestCharged(v string) *GetObjectTorrentOutput {
  10613. s.RequestCharged = &v
  10614. return s
  10615. }
  10616. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GlacierJobParameters
  10617. type GlacierJobParameters struct {
  10618. _ struct{} `type:"structure"`
  10619. // Glacier retrieval tier at which the restore will be processed.
  10620. //
  10621. // Tier is a required field
  10622. Tier *string `type:"string" required:"true" enum:"Tier"`
  10623. }
  10624. // String returns the string representation
  10625. func (s GlacierJobParameters) String() string {
  10626. return awsutil.Prettify(s)
  10627. }
  10628. // GoString returns the string representation
  10629. func (s GlacierJobParameters) GoString() string {
  10630. return s.String()
  10631. }
  10632. // Validate inspects the fields of the type to determine if they are valid.
  10633. func (s *GlacierJobParameters) Validate() error {
  10634. invalidParams := request.ErrInvalidParams{Context: "GlacierJobParameters"}
  10635. if s.Tier == nil {
  10636. invalidParams.Add(request.NewErrParamRequired("Tier"))
  10637. }
  10638. if invalidParams.Len() > 0 {
  10639. return invalidParams
  10640. }
  10641. return nil
  10642. }
  10643. // SetTier sets the Tier field's value.
  10644. func (s *GlacierJobParameters) SetTier(v string) *GlacierJobParameters {
  10645. s.Tier = &v
  10646. return s
  10647. }
  10648. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Grant
  10649. type Grant struct {
  10650. _ struct{} `type:"structure"`
  10651. Grantee *Grantee `type:"structure" xmlPrefix:"xsi" xmlURI:"http://www.w3.org/2001/XMLSchema-instance"`
  10652. // Specifies the permission given to the grantee.
  10653. Permission *string `type:"string" enum:"Permission"`
  10654. }
  10655. // String returns the string representation
  10656. func (s Grant) String() string {
  10657. return awsutil.Prettify(s)
  10658. }
  10659. // GoString returns the string representation
  10660. func (s Grant) GoString() string {
  10661. return s.String()
  10662. }
  10663. // Validate inspects the fields of the type to determine if they are valid.
  10664. func (s *Grant) Validate() error {
  10665. invalidParams := request.ErrInvalidParams{Context: "Grant"}
  10666. if s.Grantee != nil {
  10667. if err := s.Grantee.Validate(); err != nil {
  10668. invalidParams.AddNested("Grantee", err.(request.ErrInvalidParams))
  10669. }
  10670. }
  10671. if invalidParams.Len() > 0 {
  10672. return invalidParams
  10673. }
  10674. return nil
  10675. }
  10676. // SetGrantee sets the Grantee field's value.
  10677. func (s *Grant) SetGrantee(v *Grantee) *Grant {
  10678. s.Grantee = v
  10679. return s
  10680. }
  10681. // SetPermission sets the Permission field's value.
  10682. func (s *Grant) SetPermission(v string) *Grant {
  10683. s.Permission = &v
  10684. return s
  10685. }
  10686. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Grantee
  10687. type Grantee struct {
  10688. _ struct{} `type:"structure" xmlPrefix:"xsi" xmlURI:"http://www.w3.org/2001/XMLSchema-instance"`
  10689. // Screen name of the grantee.
  10690. DisplayName *string `type:"string"`
  10691. // Email address of the grantee.
  10692. EmailAddress *string `type:"string"`
  10693. // The canonical user ID of the grantee.
  10694. ID *string `type:"string"`
  10695. // Type of grantee
  10696. //
  10697. // Type is a required field
  10698. Type *string `locationName:"xsi:type" type:"string" xmlAttribute:"true" required:"true" enum:"Type"`
  10699. // URI of the grantee group.
  10700. URI *string `type:"string"`
  10701. }
  10702. // String returns the string representation
  10703. func (s Grantee) String() string {
  10704. return awsutil.Prettify(s)
  10705. }
  10706. // GoString returns the string representation
  10707. func (s Grantee) GoString() string {
  10708. return s.String()
  10709. }
  10710. // Validate inspects the fields of the type to determine if they are valid.
  10711. func (s *Grantee) Validate() error {
  10712. invalidParams := request.ErrInvalidParams{Context: "Grantee"}
  10713. if s.Type == nil {
  10714. invalidParams.Add(request.NewErrParamRequired("Type"))
  10715. }
  10716. if invalidParams.Len() > 0 {
  10717. return invalidParams
  10718. }
  10719. return nil
  10720. }
  10721. // SetDisplayName sets the DisplayName field's value.
  10722. func (s *Grantee) SetDisplayName(v string) *Grantee {
  10723. s.DisplayName = &v
  10724. return s
  10725. }
  10726. // SetEmailAddress sets the EmailAddress field's value.
  10727. func (s *Grantee) SetEmailAddress(v string) *Grantee {
  10728. s.EmailAddress = &v
  10729. return s
  10730. }
  10731. // SetID sets the ID field's value.
  10732. func (s *Grantee) SetID(v string) *Grantee {
  10733. s.ID = &v
  10734. return s
  10735. }
  10736. // SetType sets the Type field's value.
  10737. func (s *Grantee) SetType(v string) *Grantee {
  10738. s.Type = &v
  10739. return s
  10740. }
  10741. // SetURI sets the URI field's value.
  10742. func (s *Grantee) SetURI(v string) *Grantee {
  10743. s.URI = &v
  10744. return s
  10745. }
  10746. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucketRequest
  10747. type HeadBucketInput struct {
  10748. _ struct{} `type:"structure"`
  10749. // Bucket is a required field
  10750. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  10751. }
  10752. // String returns the string representation
  10753. func (s HeadBucketInput) String() string {
  10754. return awsutil.Prettify(s)
  10755. }
  10756. // GoString returns the string representation
  10757. func (s HeadBucketInput) GoString() string {
  10758. return s.String()
  10759. }
  10760. // Validate inspects the fields of the type to determine if they are valid.
  10761. func (s *HeadBucketInput) Validate() error {
  10762. invalidParams := request.ErrInvalidParams{Context: "HeadBucketInput"}
  10763. if s.Bucket == nil {
  10764. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  10765. }
  10766. if invalidParams.Len() > 0 {
  10767. return invalidParams
  10768. }
  10769. return nil
  10770. }
  10771. // SetBucket sets the Bucket field's value.
  10772. func (s *HeadBucketInput) SetBucket(v string) *HeadBucketInput {
  10773. s.Bucket = &v
  10774. return s
  10775. }
  10776. func (s *HeadBucketInput) getBucket() (v string) {
  10777. if s.Bucket == nil {
  10778. return v
  10779. }
  10780. return *s.Bucket
  10781. }
  10782. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadBucketOutput
  10783. type HeadBucketOutput struct {
  10784. _ struct{} `type:"structure"`
  10785. }
  10786. // String returns the string representation
  10787. func (s HeadBucketOutput) String() string {
  10788. return awsutil.Prettify(s)
  10789. }
  10790. // GoString returns the string representation
  10791. func (s HeadBucketOutput) GoString() string {
  10792. return s.String()
  10793. }
  10794. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObjectRequest
  10795. type HeadObjectInput struct {
  10796. _ struct{} `type:"structure"`
  10797. // Bucket is a required field
  10798. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  10799. // Return the object only if its entity tag (ETag) is the same as the one specified,
  10800. // otherwise return a 412 (precondition failed).
  10801. IfMatch *string `location:"header" locationName:"If-Match" type:"string"`
  10802. // Return the object only if it has been modified since the specified time,
  10803. // otherwise return a 304 (not modified).
  10804. IfModifiedSince *time.Time `location:"header" locationName:"If-Modified-Since" type:"timestamp" timestampFormat:"rfc822"`
  10805. // Return the object only if its entity tag (ETag) is different from the one
  10806. // specified, otherwise return a 304 (not modified).
  10807. IfNoneMatch *string `location:"header" locationName:"If-None-Match" type:"string"`
  10808. // Return the object only if it has not been modified since the specified time,
  10809. // otherwise return a 412 (precondition failed).
  10810. IfUnmodifiedSince *time.Time `location:"header" locationName:"If-Unmodified-Since" type:"timestamp" timestampFormat:"rfc822"`
  10811. // Key is a required field
  10812. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  10813. // Part number of the object being read. This is a positive integer between
  10814. // 1 and 10,000. Effectively performs a 'ranged' HEAD request for the part specified.
  10815. // Useful querying about the size of the part and the number of parts in this
  10816. // object.
  10817. PartNumber *int64 `location:"querystring" locationName:"partNumber" type:"integer"`
  10818. // Downloads the specified range bytes of an object. For more information about
  10819. // the HTTP Range header, go to http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.35.
  10820. Range *string `location:"header" locationName:"Range" type:"string"`
  10821. // Confirms that the requester knows that she or he will be charged for the
  10822. // request. Bucket owners need not specify this parameter in their requests.
  10823. // Documentation on downloading objects from requester pays buckets can be found
  10824. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  10825. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  10826. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  10827. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  10828. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  10829. // data. This value is used to store the object and then it is discarded; Amazon
  10830. // does not store the encryption key. The key must be appropriate for use with
  10831. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  10832. // header.
  10833. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  10834. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  10835. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  10836. // key was transmitted without error.
  10837. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  10838. // VersionId used to reference a specific version of the object.
  10839. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  10840. }
  10841. // String returns the string representation
  10842. func (s HeadObjectInput) String() string {
  10843. return awsutil.Prettify(s)
  10844. }
  10845. // GoString returns the string representation
  10846. func (s HeadObjectInput) GoString() string {
  10847. return s.String()
  10848. }
  10849. // Validate inspects the fields of the type to determine if they are valid.
  10850. func (s *HeadObjectInput) Validate() error {
  10851. invalidParams := request.ErrInvalidParams{Context: "HeadObjectInput"}
  10852. if s.Bucket == nil {
  10853. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  10854. }
  10855. if s.Key == nil {
  10856. invalidParams.Add(request.NewErrParamRequired("Key"))
  10857. }
  10858. if s.Key != nil && len(*s.Key) < 1 {
  10859. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  10860. }
  10861. if invalidParams.Len() > 0 {
  10862. return invalidParams
  10863. }
  10864. return nil
  10865. }
  10866. // SetBucket sets the Bucket field's value.
  10867. func (s *HeadObjectInput) SetBucket(v string) *HeadObjectInput {
  10868. s.Bucket = &v
  10869. return s
  10870. }
  10871. func (s *HeadObjectInput) getBucket() (v string) {
  10872. if s.Bucket == nil {
  10873. return v
  10874. }
  10875. return *s.Bucket
  10876. }
  10877. // SetIfMatch sets the IfMatch field's value.
  10878. func (s *HeadObjectInput) SetIfMatch(v string) *HeadObjectInput {
  10879. s.IfMatch = &v
  10880. return s
  10881. }
  10882. // SetIfModifiedSince sets the IfModifiedSince field's value.
  10883. func (s *HeadObjectInput) SetIfModifiedSince(v time.Time) *HeadObjectInput {
  10884. s.IfModifiedSince = &v
  10885. return s
  10886. }
  10887. // SetIfNoneMatch sets the IfNoneMatch field's value.
  10888. func (s *HeadObjectInput) SetIfNoneMatch(v string) *HeadObjectInput {
  10889. s.IfNoneMatch = &v
  10890. return s
  10891. }
  10892. // SetIfUnmodifiedSince sets the IfUnmodifiedSince field's value.
  10893. func (s *HeadObjectInput) SetIfUnmodifiedSince(v time.Time) *HeadObjectInput {
  10894. s.IfUnmodifiedSince = &v
  10895. return s
  10896. }
  10897. // SetKey sets the Key field's value.
  10898. func (s *HeadObjectInput) SetKey(v string) *HeadObjectInput {
  10899. s.Key = &v
  10900. return s
  10901. }
  10902. // SetPartNumber sets the PartNumber field's value.
  10903. func (s *HeadObjectInput) SetPartNumber(v int64) *HeadObjectInput {
  10904. s.PartNumber = &v
  10905. return s
  10906. }
  10907. // SetRange sets the Range field's value.
  10908. func (s *HeadObjectInput) SetRange(v string) *HeadObjectInput {
  10909. s.Range = &v
  10910. return s
  10911. }
  10912. // SetRequestPayer sets the RequestPayer field's value.
  10913. func (s *HeadObjectInput) SetRequestPayer(v string) *HeadObjectInput {
  10914. s.RequestPayer = &v
  10915. return s
  10916. }
  10917. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  10918. func (s *HeadObjectInput) SetSSECustomerAlgorithm(v string) *HeadObjectInput {
  10919. s.SSECustomerAlgorithm = &v
  10920. return s
  10921. }
  10922. // SetSSECustomerKey sets the SSECustomerKey field's value.
  10923. func (s *HeadObjectInput) SetSSECustomerKey(v string) *HeadObjectInput {
  10924. s.SSECustomerKey = &v
  10925. return s
  10926. }
  10927. func (s *HeadObjectInput) getSSECustomerKey() (v string) {
  10928. if s.SSECustomerKey == nil {
  10929. return v
  10930. }
  10931. return *s.SSECustomerKey
  10932. }
  10933. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  10934. func (s *HeadObjectInput) SetSSECustomerKeyMD5(v string) *HeadObjectInput {
  10935. s.SSECustomerKeyMD5 = &v
  10936. return s
  10937. }
  10938. // SetVersionId sets the VersionId field's value.
  10939. func (s *HeadObjectInput) SetVersionId(v string) *HeadObjectInput {
  10940. s.VersionId = &v
  10941. return s
  10942. }
  10943. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/HeadObjectOutput
  10944. type HeadObjectOutput struct {
  10945. _ struct{} `type:"structure"`
  10946. AcceptRanges *string `location:"header" locationName:"accept-ranges" type:"string"`
  10947. // Specifies caching behavior along the request/reply chain.
  10948. CacheControl *string `location:"header" locationName:"Cache-Control" type:"string"`
  10949. // Specifies presentational information for the object.
  10950. ContentDisposition *string `location:"header" locationName:"Content-Disposition" type:"string"`
  10951. // Specifies what content encodings have been applied to the object and thus
  10952. // what decoding mechanisms must be applied to obtain the media-type referenced
  10953. // by the Content-Type header field.
  10954. ContentEncoding *string `location:"header" locationName:"Content-Encoding" type:"string"`
  10955. // The language the content is in.
  10956. ContentLanguage *string `location:"header" locationName:"Content-Language" type:"string"`
  10957. // Size of the body in bytes.
  10958. ContentLength *int64 `location:"header" locationName:"Content-Length" type:"long"`
  10959. // A standard MIME type describing the format of the object data.
  10960. ContentType *string `location:"header" locationName:"Content-Type" type:"string"`
  10961. // Specifies whether the object retrieved was (true) or was not (false) a Delete
  10962. // Marker. If false, this response header does not appear in the response.
  10963. DeleteMarker *bool `location:"header" locationName:"x-amz-delete-marker" type:"boolean"`
  10964. // An ETag is an opaque identifier assigned by a web server to a specific version
  10965. // of a resource found at a URL
  10966. ETag *string `location:"header" locationName:"ETag" type:"string"`
  10967. // If the object expiration is configured (see PUT Bucket lifecycle), the response
  10968. // includes this header. It includes the expiry-date and rule-id key value pairs
  10969. // providing object expiration information. The value of the rule-id is URL
  10970. // encoded.
  10971. Expiration *string `location:"header" locationName:"x-amz-expiration" type:"string"`
  10972. // The date and time at which the object is no longer cacheable.
  10973. Expires *string `location:"header" locationName:"Expires" type:"string"`
  10974. // Last modified date of the object
  10975. LastModified *time.Time `location:"header" locationName:"Last-Modified" type:"timestamp" timestampFormat:"rfc822"`
  10976. // A map of metadata to store with the object in S3.
  10977. Metadata map[string]*string `location:"headers" locationName:"x-amz-meta-" type:"map"`
  10978. // This is set to the number of metadata entries not returned in x-amz-meta
  10979. // headers. This can happen if you create metadata using an API like SOAP that
  10980. // supports more flexible metadata than the REST API. For example, using SOAP,
  10981. // you can create metadata whose values are not legal HTTP headers.
  10982. MissingMeta *int64 `location:"header" locationName:"x-amz-missing-meta" type:"integer"`
  10983. // The count of parts this object has.
  10984. PartsCount *int64 `location:"header" locationName:"x-amz-mp-parts-count" type:"integer"`
  10985. ReplicationStatus *string `location:"header" locationName:"x-amz-replication-status" type:"string" enum:"ReplicationStatus"`
  10986. // If present, indicates that the requester was successfully charged for the
  10987. // request.
  10988. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  10989. // Provides information about object restoration operation and expiration time
  10990. // of the restored object copy.
  10991. Restore *string `location:"header" locationName:"x-amz-restore" type:"string"`
  10992. // If server-side encryption with a customer-provided encryption key was requested,
  10993. // the response will include this header confirming the encryption algorithm
  10994. // used.
  10995. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  10996. // If server-side encryption with a customer-provided encryption key was requested,
  10997. // the response will include this header to provide round trip message integrity
  10998. // verification of the customer-provided encryption key.
  10999. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  11000. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  11001. // encryption key that was used for the object.
  11002. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  11003. // The Server-side encryption algorithm used when storing this object in S3
  11004. // (e.g., AES256, aws:kms).
  11005. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  11006. StorageClass *string `location:"header" locationName:"x-amz-storage-class" type:"string" enum:"StorageClass"`
  11007. // Version of the object.
  11008. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  11009. // If the bucket is configured as a website, redirects requests for this object
  11010. // to another object in the same bucket or to an external URL. Amazon S3 stores
  11011. // the value of this header in the object metadata.
  11012. WebsiteRedirectLocation *string `location:"header" locationName:"x-amz-website-redirect-location" type:"string"`
  11013. }
  11014. // String returns the string representation
  11015. func (s HeadObjectOutput) String() string {
  11016. return awsutil.Prettify(s)
  11017. }
  11018. // GoString returns the string representation
  11019. func (s HeadObjectOutput) GoString() string {
  11020. return s.String()
  11021. }
  11022. // SetAcceptRanges sets the AcceptRanges field's value.
  11023. func (s *HeadObjectOutput) SetAcceptRanges(v string) *HeadObjectOutput {
  11024. s.AcceptRanges = &v
  11025. return s
  11026. }
  11027. // SetCacheControl sets the CacheControl field's value.
  11028. func (s *HeadObjectOutput) SetCacheControl(v string) *HeadObjectOutput {
  11029. s.CacheControl = &v
  11030. return s
  11031. }
  11032. // SetContentDisposition sets the ContentDisposition field's value.
  11033. func (s *HeadObjectOutput) SetContentDisposition(v string) *HeadObjectOutput {
  11034. s.ContentDisposition = &v
  11035. return s
  11036. }
  11037. // SetContentEncoding sets the ContentEncoding field's value.
  11038. func (s *HeadObjectOutput) SetContentEncoding(v string) *HeadObjectOutput {
  11039. s.ContentEncoding = &v
  11040. return s
  11041. }
  11042. // SetContentLanguage sets the ContentLanguage field's value.
  11043. func (s *HeadObjectOutput) SetContentLanguage(v string) *HeadObjectOutput {
  11044. s.ContentLanguage = &v
  11045. return s
  11046. }
  11047. // SetContentLength sets the ContentLength field's value.
  11048. func (s *HeadObjectOutput) SetContentLength(v int64) *HeadObjectOutput {
  11049. s.ContentLength = &v
  11050. return s
  11051. }
  11052. // SetContentType sets the ContentType field's value.
  11053. func (s *HeadObjectOutput) SetContentType(v string) *HeadObjectOutput {
  11054. s.ContentType = &v
  11055. return s
  11056. }
  11057. // SetDeleteMarker sets the DeleteMarker field's value.
  11058. func (s *HeadObjectOutput) SetDeleteMarker(v bool) *HeadObjectOutput {
  11059. s.DeleteMarker = &v
  11060. return s
  11061. }
  11062. // SetETag sets the ETag field's value.
  11063. func (s *HeadObjectOutput) SetETag(v string) *HeadObjectOutput {
  11064. s.ETag = &v
  11065. return s
  11066. }
  11067. // SetExpiration sets the Expiration field's value.
  11068. func (s *HeadObjectOutput) SetExpiration(v string) *HeadObjectOutput {
  11069. s.Expiration = &v
  11070. return s
  11071. }
  11072. // SetExpires sets the Expires field's value.
  11073. func (s *HeadObjectOutput) SetExpires(v string) *HeadObjectOutput {
  11074. s.Expires = &v
  11075. return s
  11076. }
  11077. // SetLastModified sets the LastModified field's value.
  11078. func (s *HeadObjectOutput) SetLastModified(v time.Time) *HeadObjectOutput {
  11079. s.LastModified = &v
  11080. return s
  11081. }
  11082. // SetMetadata sets the Metadata field's value.
  11083. func (s *HeadObjectOutput) SetMetadata(v map[string]*string) *HeadObjectOutput {
  11084. s.Metadata = v
  11085. return s
  11086. }
  11087. // SetMissingMeta sets the MissingMeta field's value.
  11088. func (s *HeadObjectOutput) SetMissingMeta(v int64) *HeadObjectOutput {
  11089. s.MissingMeta = &v
  11090. return s
  11091. }
  11092. // SetPartsCount sets the PartsCount field's value.
  11093. func (s *HeadObjectOutput) SetPartsCount(v int64) *HeadObjectOutput {
  11094. s.PartsCount = &v
  11095. return s
  11096. }
  11097. // SetReplicationStatus sets the ReplicationStatus field's value.
  11098. func (s *HeadObjectOutput) SetReplicationStatus(v string) *HeadObjectOutput {
  11099. s.ReplicationStatus = &v
  11100. return s
  11101. }
  11102. // SetRequestCharged sets the RequestCharged field's value.
  11103. func (s *HeadObjectOutput) SetRequestCharged(v string) *HeadObjectOutput {
  11104. s.RequestCharged = &v
  11105. return s
  11106. }
  11107. // SetRestore sets the Restore field's value.
  11108. func (s *HeadObjectOutput) SetRestore(v string) *HeadObjectOutput {
  11109. s.Restore = &v
  11110. return s
  11111. }
  11112. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  11113. func (s *HeadObjectOutput) SetSSECustomerAlgorithm(v string) *HeadObjectOutput {
  11114. s.SSECustomerAlgorithm = &v
  11115. return s
  11116. }
  11117. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  11118. func (s *HeadObjectOutput) SetSSECustomerKeyMD5(v string) *HeadObjectOutput {
  11119. s.SSECustomerKeyMD5 = &v
  11120. return s
  11121. }
  11122. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  11123. func (s *HeadObjectOutput) SetSSEKMSKeyId(v string) *HeadObjectOutput {
  11124. s.SSEKMSKeyId = &v
  11125. return s
  11126. }
  11127. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  11128. func (s *HeadObjectOutput) SetServerSideEncryption(v string) *HeadObjectOutput {
  11129. s.ServerSideEncryption = &v
  11130. return s
  11131. }
  11132. // SetStorageClass sets the StorageClass field's value.
  11133. func (s *HeadObjectOutput) SetStorageClass(v string) *HeadObjectOutput {
  11134. s.StorageClass = &v
  11135. return s
  11136. }
  11137. // SetVersionId sets the VersionId field's value.
  11138. func (s *HeadObjectOutput) SetVersionId(v string) *HeadObjectOutput {
  11139. s.VersionId = &v
  11140. return s
  11141. }
  11142. // SetWebsiteRedirectLocation sets the WebsiteRedirectLocation field's value.
  11143. func (s *HeadObjectOutput) SetWebsiteRedirectLocation(v string) *HeadObjectOutput {
  11144. s.WebsiteRedirectLocation = &v
  11145. return s
  11146. }
  11147. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/IndexDocument
  11148. type IndexDocument struct {
  11149. _ struct{} `type:"structure"`
  11150. // A suffix that is appended to a request that is for a directory on the website
  11151. // endpoint (e.g. if the suffix is index.html and you make a request to samplebucket/images/
  11152. // the data that is returned will be for the object with the key name images/index.html)
  11153. // The suffix must not be empty and must not include a slash character.
  11154. //
  11155. // Suffix is a required field
  11156. Suffix *string `type:"string" required:"true"`
  11157. }
  11158. // String returns the string representation
  11159. func (s IndexDocument) String() string {
  11160. return awsutil.Prettify(s)
  11161. }
  11162. // GoString returns the string representation
  11163. func (s IndexDocument) GoString() string {
  11164. return s.String()
  11165. }
  11166. // Validate inspects the fields of the type to determine if they are valid.
  11167. func (s *IndexDocument) Validate() error {
  11168. invalidParams := request.ErrInvalidParams{Context: "IndexDocument"}
  11169. if s.Suffix == nil {
  11170. invalidParams.Add(request.NewErrParamRequired("Suffix"))
  11171. }
  11172. if invalidParams.Len() > 0 {
  11173. return invalidParams
  11174. }
  11175. return nil
  11176. }
  11177. // SetSuffix sets the Suffix field's value.
  11178. func (s *IndexDocument) SetSuffix(v string) *IndexDocument {
  11179. s.Suffix = &v
  11180. return s
  11181. }
  11182. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Initiator
  11183. type Initiator struct {
  11184. _ struct{} `type:"structure"`
  11185. // Name of the Principal.
  11186. DisplayName *string `type:"string"`
  11187. // If the principal is an AWS account, it provides the Canonical User ID. If
  11188. // the principal is an IAM User, it provides a user ARN value.
  11189. ID *string `type:"string"`
  11190. }
  11191. // String returns the string representation
  11192. func (s Initiator) String() string {
  11193. return awsutil.Prettify(s)
  11194. }
  11195. // GoString returns the string representation
  11196. func (s Initiator) GoString() string {
  11197. return s.String()
  11198. }
  11199. // SetDisplayName sets the DisplayName field's value.
  11200. func (s *Initiator) SetDisplayName(v string) *Initiator {
  11201. s.DisplayName = &v
  11202. return s
  11203. }
  11204. // SetID sets the ID field's value.
  11205. func (s *Initiator) SetID(v string) *Initiator {
  11206. s.ID = &v
  11207. return s
  11208. }
  11209. // Describes the serialization format of the object.
  11210. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InputSerialization
  11211. type InputSerialization struct {
  11212. _ struct{} `type:"structure"`
  11213. // Describes the serialization of a CSV-encoded object.
  11214. CSV *CSVInput `type:"structure"`
  11215. }
  11216. // String returns the string representation
  11217. func (s InputSerialization) String() string {
  11218. return awsutil.Prettify(s)
  11219. }
  11220. // GoString returns the string representation
  11221. func (s InputSerialization) GoString() string {
  11222. return s.String()
  11223. }
  11224. // SetCSV sets the CSV field's value.
  11225. func (s *InputSerialization) SetCSV(v *CSVInput) *InputSerialization {
  11226. s.CSV = v
  11227. return s
  11228. }
  11229. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryConfiguration
  11230. type InventoryConfiguration struct {
  11231. _ struct{} `type:"structure"`
  11232. // Contains information about where to publish the inventory results.
  11233. //
  11234. // Destination is a required field
  11235. Destination *InventoryDestination `type:"structure" required:"true"`
  11236. // Specifies an inventory filter. The inventory only includes objects that meet
  11237. // the filter's criteria.
  11238. Filter *InventoryFilter `type:"structure"`
  11239. // The ID used to identify the inventory configuration.
  11240. //
  11241. // Id is a required field
  11242. Id *string `type:"string" required:"true"`
  11243. // Specifies which object version(s) to included in the inventory results.
  11244. //
  11245. // IncludedObjectVersions is a required field
  11246. IncludedObjectVersions *string `type:"string" required:"true" enum:"InventoryIncludedObjectVersions"`
  11247. // Specifies whether the inventory is enabled or disabled.
  11248. //
  11249. // IsEnabled is a required field
  11250. IsEnabled *bool `type:"boolean" required:"true"`
  11251. // Contains the optional fields that are included in the inventory results.
  11252. OptionalFields []*string `locationNameList:"Field" type:"list"`
  11253. // Specifies the schedule for generating inventory results.
  11254. //
  11255. // Schedule is a required field
  11256. Schedule *InventorySchedule `type:"structure" required:"true"`
  11257. }
  11258. // String returns the string representation
  11259. func (s InventoryConfiguration) String() string {
  11260. return awsutil.Prettify(s)
  11261. }
  11262. // GoString returns the string representation
  11263. func (s InventoryConfiguration) GoString() string {
  11264. return s.String()
  11265. }
  11266. // Validate inspects the fields of the type to determine if they are valid.
  11267. func (s *InventoryConfiguration) Validate() error {
  11268. invalidParams := request.ErrInvalidParams{Context: "InventoryConfiguration"}
  11269. if s.Destination == nil {
  11270. invalidParams.Add(request.NewErrParamRequired("Destination"))
  11271. }
  11272. if s.Id == nil {
  11273. invalidParams.Add(request.NewErrParamRequired("Id"))
  11274. }
  11275. if s.IncludedObjectVersions == nil {
  11276. invalidParams.Add(request.NewErrParamRequired("IncludedObjectVersions"))
  11277. }
  11278. if s.IsEnabled == nil {
  11279. invalidParams.Add(request.NewErrParamRequired("IsEnabled"))
  11280. }
  11281. if s.Schedule == nil {
  11282. invalidParams.Add(request.NewErrParamRequired("Schedule"))
  11283. }
  11284. if s.Destination != nil {
  11285. if err := s.Destination.Validate(); err != nil {
  11286. invalidParams.AddNested("Destination", err.(request.ErrInvalidParams))
  11287. }
  11288. }
  11289. if s.Filter != nil {
  11290. if err := s.Filter.Validate(); err != nil {
  11291. invalidParams.AddNested("Filter", err.(request.ErrInvalidParams))
  11292. }
  11293. }
  11294. if s.Schedule != nil {
  11295. if err := s.Schedule.Validate(); err != nil {
  11296. invalidParams.AddNested("Schedule", err.(request.ErrInvalidParams))
  11297. }
  11298. }
  11299. if invalidParams.Len() > 0 {
  11300. return invalidParams
  11301. }
  11302. return nil
  11303. }
  11304. // SetDestination sets the Destination field's value.
  11305. func (s *InventoryConfiguration) SetDestination(v *InventoryDestination) *InventoryConfiguration {
  11306. s.Destination = v
  11307. return s
  11308. }
  11309. // SetFilter sets the Filter field's value.
  11310. func (s *InventoryConfiguration) SetFilter(v *InventoryFilter) *InventoryConfiguration {
  11311. s.Filter = v
  11312. return s
  11313. }
  11314. // SetId sets the Id field's value.
  11315. func (s *InventoryConfiguration) SetId(v string) *InventoryConfiguration {
  11316. s.Id = &v
  11317. return s
  11318. }
  11319. // SetIncludedObjectVersions sets the IncludedObjectVersions field's value.
  11320. func (s *InventoryConfiguration) SetIncludedObjectVersions(v string) *InventoryConfiguration {
  11321. s.IncludedObjectVersions = &v
  11322. return s
  11323. }
  11324. // SetIsEnabled sets the IsEnabled field's value.
  11325. func (s *InventoryConfiguration) SetIsEnabled(v bool) *InventoryConfiguration {
  11326. s.IsEnabled = &v
  11327. return s
  11328. }
  11329. // SetOptionalFields sets the OptionalFields field's value.
  11330. func (s *InventoryConfiguration) SetOptionalFields(v []*string) *InventoryConfiguration {
  11331. s.OptionalFields = v
  11332. return s
  11333. }
  11334. // SetSchedule sets the Schedule field's value.
  11335. func (s *InventoryConfiguration) SetSchedule(v *InventorySchedule) *InventoryConfiguration {
  11336. s.Schedule = v
  11337. return s
  11338. }
  11339. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryDestination
  11340. type InventoryDestination struct {
  11341. _ struct{} `type:"structure"`
  11342. // Contains the bucket name, file format, bucket owner (optional), and prefix
  11343. // (optional) where inventory results are published.
  11344. //
  11345. // S3BucketDestination is a required field
  11346. S3BucketDestination *InventoryS3BucketDestination `type:"structure" required:"true"`
  11347. }
  11348. // String returns the string representation
  11349. func (s InventoryDestination) String() string {
  11350. return awsutil.Prettify(s)
  11351. }
  11352. // GoString returns the string representation
  11353. func (s InventoryDestination) GoString() string {
  11354. return s.String()
  11355. }
  11356. // Validate inspects the fields of the type to determine if they are valid.
  11357. func (s *InventoryDestination) Validate() error {
  11358. invalidParams := request.ErrInvalidParams{Context: "InventoryDestination"}
  11359. if s.S3BucketDestination == nil {
  11360. invalidParams.Add(request.NewErrParamRequired("S3BucketDestination"))
  11361. }
  11362. if s.S3BucketDestination != nil {
  11363. if err := s.S3BucketDestination.Validate(); err != nil {
  11364. invalidParams.AddNested("S3BucketDestination", err.(request.ErrInvalidParams))
  11365. }
  11366. }
  11367. if invalidParams.Len() > 0 {
  11368. return invalidParams
  11369. }
  11370. return nil
  11371. }
  11372. // SetS3BucketDestination sets the S3BucketDestination field's value.
  11373. func (s *InventoryDestination) SetS3BucketDestination(v *InventoryS3BucketDestination) *InventoryDestination {
  11374. s.S3BucketDestination = v
  11375. return s
  11376. }
  11377. // Contains the type of server-side encryption used to encrypt the inventory
  11378. // results.
  11379. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryEncryption
  11380. type InventoryEncryption struct {
  11381. _ struct{} `type:"structure"`
  11382. // Specifies the use of SSE-KMS to encrypt delievered Inventory reports.
  11383. SSEKMS *SSEKMS `locationName:"SSE-KMS" type:"structure"`
  11384. // Specifies the use of SSE-S3 to encrypt delievered Inventory reports.
  11385. SSES3 *SSES3 `locationName:"SSE-S3" type:"structure"`
  11386. }
  11387. // String returns the string representation
  11388. func (s InventoryEncryption) String() string {
  11389. return awsutil.Prettify(s)
  11390. }
  11391. // GoString returns the string representation
  11392. func (s InventoryEncryption) GoString() string {
  11393. return s.String()
  11394. }
  11395. // Validate inspects the fields of the type to determine if they are valid.
  11396. func (s *InventoryEncryption) Validate() error {
  11397. invalidParams := request.ErrInvalidParams{Context: "InventoryEncryption"}
  11398. if s.SSEKMS != nil {
  11399. if err := s.SSEKMS.Validate(); err != nil {
  11400. invalidParams.AddNested("SSEKMS", err.(request.ErrInvalidParams))
  11401. }
  11402. }
  11403. if invalidParams.Len() > 0 {
  11404. return invalidParams
  11405. }
  11406. return nil
  11407. }
  11408. // SetSSEKMS sets the SSEKMS field's value.
  11409. func (s *InventoryEncryption) SetSSEKMS(v *SSEKMS) *InventoryEncryption {
  11410. s.SSEKMS = v
  11411. return s
  11412. }
  11413. // SetSSES3 sets the SSES3 field's value.
  11414. func (s *InventoryEncryption) SetSSES3(v *SSES3) *InventoryEncryption {
  11415. s.SSES3 = v
  11416. return s
  11417. }
  11418. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryFilter
  11419. type InventoryFilter struct {
  11420. _ struct{} `type:"structure"`
  11421. // The prefix that an object must have to be included in the inventory results.
  11422. //
  11423. // Prefix is a required field
  11424. Prefix *string `type:"string" required:"true"`
  11425. }
  11426. // String returns the string representation
  11427. func (s InventoryFilter) String() string {
  11428. return awsutil.Prettify(s)
  11429. }
  11430. // GoString returns the string representation
  11431. func (s InventoryFilter) GoString() string {
  11432. return s.String()
  11433. }
  11434. // Validate inspects the fields of the type to determine if they are valid.
  11435. func (s *InventoryFilter) Validate() error {
  11436. invalidParams := request.ErrInvalidParams{Context: "InventoryFilter"}
  11437. if s.Prefix == nil {
  11438. invalidParams.Add(request.NewErrParamRequired("Prefix"))
  11439. }
  11440. if invalidParams.Len() > 0 {
  11441. return invalidParams
  11442. }
  11443. return nil
  11444. }
  11445. // SetPrefix sets the Prefix field's value.
  11446. func (s *InventoryFilter) SetPrefix(v string) *InventoryFilter {
  11447. s.Prefix = &v
  11448. return s
  11449. }
  11450. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventoryS3BucketDestination
  11451. type InventoryS3BucketDestination struct {
  11452. _ struct{} `type:"structure"`
  11453. // The ID of the account that owns the destination bucket.
  11454. AccountId *string `type:"string"`
  11455. // The Amazon resource name (ARN) of the bucket where inventory results will
  11456. // be published.
  11457. //
  11458. // Bucket is a required field
  11459. Bucket *string `type:"string" required:"true"`
  11460. // Contains the type of server-side encryption used to encrypt the inventory
  11461. // results.
  11462. Encryption *InventoryEncryption `type:"structure"`
  11463. // Specifies the output format of the inventory results.
  11464. //
  11465. // Format is a required field
  11466. Format *string `type:"string" required:"true" enum:"InventoryFormat"`
  11467. // The prefix that is prepended to all inventory results.
  11468. Prefix *string `type:"string"`
  11469. }
  11470. // String returns the string representation
  11471. func (s InventoryS3BucketDestination) String() string {
  11472. return awsutil.Prettify(s)
  11473. }
  11474. // GoString returns the string representation
  11475. func (s InventoryS3BucketDestination) GoString() string {
  11476. return s.String()
  11477. }
  11478. // Validate inspects the fields of the type to determine if they are valid.
  11479. func (s *InventoryS3BucketDestination) Validate() error {
  11480. invalidParams := request.ErrInvalidParams{Context: "InventoryS3BucketDestination"}
  11481. if s.Bucket == nil {
  11482. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  11483. }
  11484. if s.Format == nil {
  11485. invalidParams.Add(request.NewErrParamRequired("Format"))
  11486. }
  11487. if s.Encryption != nil {
  11488. if err := s.Encryption.Validate(); err != nil {
  11489. invalidParams.AddNested("Encryption", err.(request.ErrInvalidParams))
  11490. }
  11491. }
  11492. if invalidParams.Len() > 0 {
  11493. return invalidParams
  11494. }
  11495. return nil
  11496. }
  11497. // SetAccountId sets the AccountId field's value.
  11498. func (s *InventoryS3BucketDestination) SetAccountId(v string) *InventoryS3BucketDestination {
  11499. s.AccountId = &v
  11500. return s
  11501. }
  11502. // SetBucket sets the Bucket field's value.
  11503. func (s *InventoryS3BucketDestination) SetBucket(v string) *InventoryS3BucketDestination {
  11504. s.Bucket = &v
  11505. return s
  11506. }
  11507. func (s *InventoryS3BucketDestination) getBucket() (v string) {
  11508. if s.Bucket == nil {
  11509. return v
  11510. }
  11511. return *s.Bucket
  11512. }
  11513. // SetEncryption sets the Encryption field's value.
  11514. func (s *InventoryS3BucketDestination) SetEncryption(v *InventoryEncryption) *InventoryS3BucketDestination {
  11515. s.Encryption = v
  11516. return s
  11517. }
  11518. // SetFormat sets the Format field's value.
  11519. func (s *InventoryS3BucketDestination) SetFormat(v string) *InventoryS3BucketDestination {
  11520. s.Format = &v
  11521. return s
  11522. }
  11523. // SetPrefix sets the Prefix field's value.
  11524. func (s *InventoryS3BucketDestination) SetPrefix(v string) *InventoryS3BucketDestination {
  11525. s.Prefix = &v
  11526. return s
  11527. }
  11528. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/InventorySchedule
  11529. type InventorySchedule struct {
  11530. _ struct{} `type:"structure"`
  11531. // Specifies how frequently inventory results are produced.
  11532. //
  11533. // Frequency is a required field
  11534. Frequency *string `type:"string" required:"true" enum:"InventoryFrequency"`
  11535. }
  11536. // String returns the string representation
  11537. func (s InventorySchedule) String() string {
  11538. return awsutil.Prettify(s)
  11539. }
  11540. // GoString returns the string representation
  11541. func (s InventorySchedule) GoString() string {
  11542. return s.String()
  11543. }
  11544. // Validate inspects the fields of the type to determine if they are valid.
  11545. func (s *InventorySchedule) Validate() error {
  11546. invalidParams := request.ErrInvalidParams{Context: "InventorySchedule"}
  11547. if s.Frequency == nil {
  11548. invalidParams.Add(request.NewErrParamRequired("Frequency"))
  11549. }
  11550. if invalidParams.Len() > 0 {
  11551. return invalidParams
  11552. }
  11553. return nil
  11554. }
  11555. // SetFrequency sets the Frequency field's value.
  11556. func (s *InventorySchedule) SetFrequency(v string) *InventorySchedule {
  11557. s.Frequency = &v
  11558. return s
  11559. }
  11560. // Container for object key name prefix and suffix filtering rules.
  11561. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/S3KeyFilter
  11562. type KeyFilter struct {
  11563. _ struct{} `type:"structure"`
  11564. // A list of containers for key value pair that defines the criteria for the
  11565. // filter rule.
  11566. FilterRules []*FilterRule `locationName:"FilterRule" type:"list" flattened:"true"`
  11567. }
  11568. // String returns the string representation
  11569. func (s KeyFilter) String() string {
  11570. return awsutil.Prettify(s)
  11571. }
  11572. // GoString returns the string representation
  11573. func (s KeyFilter) GoString() string {
  11574. return s.String()
  11575. }
  11576. // SetFilterRules sets the FilterRules field's value.
  11577. func (s *KeyFilter) SetFilterRules(v []*FilterRule) *KeyFilter {
  11578. s.FilterRules = v
  11579. return s
  11580. }
  11581. // Container for specifying the AWS Lambda notification configuration.
  11582. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LambdaFunctionConfiguration
  11583. type LambdaFunctionConfiguration struct {
  11584. _ struct{} `type:"structure"`
  11585. // Events is a required field
  11586. Events []*string `locationName:"Event" type:"list" flattened:"true" required:"true"`
  11587. // Container for object key name filtering rules. For information about key
  11588. // name filtering, go to Configuring Event Notifications (http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  11589. Filter *NotificationConfigurationFilter `type:"structure"`
  11590. // Optional unique identifier for configurations in a notification configuration.
  11591. // If you don't provide one, Amazon S3 will assign an ID.
  11592. Id *string `type:"string"`
  11593. // Lambda cloud function ARN that Amazon S3 can invoke when it detects events
  11594. // of the specified type.
  11595. //
  11596. // LambdaFunctionArn is a required field
  11597. LambdaFunctionArn *string `locationName:"CloudFunction" type:"string" required:"true"`
  11598. }
  11599. // String returns the string representation
  11600. func (s LambdaFunctionConfiguration) String() string {
  11601. return awsutil.Prettify(s)
  11602. }
  11603. // GoString returns the string representation
  11604. func (s LambdaFunctionConfiguration) GoString() string {
  11605. return s.String()
  11606. }
  11607. // Validate inspects the fields of the type to determine if they are valid.
  11608. func (s *LambdaFunctionConfiguration) Validate() error {
  11609. invalidParams := request.ErrInvalidParams{Context: "LambdaFunctionConfiguration"}
  11610. if s.Events == nil {
  11611. invalidParams.Add(request.NewErrParamRequired("Events"))
  11612. }
  11613. if s.LambdaFunctionArn == nil {
  11614. invalidParams.Add(request.NewErrParamRequired("LambdaFunctionArn"))
  11615. }
  11616. if invalidParams.Len() > 0 {
  11617. return invalidParams
  11618. }
  11619. return nil
  11620. }
  11621. // SetEvents sets the Events field's value.
  11622. func (s *LambdaFunctionConfiguration) SetEvents(v []*string) *LambdaFunctionConfiguration {
  11623. s.Events = v
  11624. return s
  11625. }
  11626. // SetFilter sets the Filter field's value.
  11627. func (s *LambdaFunctionConfiguration) SetFilter(v *NotificationConfigurationFilter) *LambdaFunctionConfiguration {
  11628. s.Filter = v
  11629. return s
  11630. }
  11631. // SetId sets the Id field's value.
  11632. func (s *LambdaFunctionConfiguration) SetId(v string) *LambdaFunctionConfiguration {
  11633. s.Id = &v
  11634. return s
  11635. }
  11636. // SetLambdaFunctionArn sets the LambdaFunctionArn field's value.
  11637. func (s *LambdaFunctionConfiguration) SetLambdaFunctionArn(v string) *LambdaFunctionConfiguration {
  11638. s.LambdaFunctionArn = &v
  11639. return s
  11640. }
  11641. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleConfiguration
  11642. type LifecycleConfiguration struct {
  11643. _ struct{} `type:"structure"`
  11644. // Rules is a required field
  11645. Rules []*Rule `locationName:"Rule" type:"list" flattened:"true" required:"true"`
  11646. }
  11647. // String returns the string representation
  11648. func (s LifecycleConfiguration) String() string {
  11649. return awsutil.Prettify(s)
  11650. }
  11651. // GoString returns the string representation
  11652. func (s LifecycleConfiguration) GoString() string {
  11653. return s.String()
  11654. }
  11655. // Validate inspects the fields of the type to determine if they are valid.
  11656. func (s *LifecycleConfiguration) Validate() error {
  11657. invalidParams := request.ErrInvalidParams{Context: "LifecycleConfiguration"}
  11658. if s.Rules == nil {
  11659. invalidParams.Add(request.NewErrParamRequired("Rules"))
  11660. }
  11661. if s.Rules != nil {
  11662. for i, v := range s.Rules {
  11663. if v == nil {
  11664. continue
  11665. }
  11666. if err := v.Validate(); err != nil {
  11667. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams))
  11668. }
  11669. }
  11670. }
  11671. if invalidParams.Len() > 0 {
  11672. return invalidParams
  11673. }
  11674. return nil
  11675. }
  11676. // SetRules sets the Rules field's value.
  11677. func (s *LifecycleConfiguration) SetRules(v []*Rule) *LifecycleConfiguration {
  11678. s.Rules = v
  11679. return s
  11680. }
  11681. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleExpiration
  11682. type LifecycleExpiration struct {
  11683. _ struct{} `type:"structure"`
  11684. // Indicates at what date the object is to be moved or deleted. Should be in
  11685. // GMT ISO 8601 Format.
  11686. Date *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  11687. // Indicates the lifetime, in days, of the objects that are subject to the rule.
  11688. // The value must be a non-zero positive integer.
  11689. Days *int64 `type:"integer"`
  11690. // Indicates whether Amazon S3 will remove a delete marker with no noncurrent
  11691. // versions. If set to true, the delete marker will be expired; if set to false
  11692. // the policy takes no action. This cannot be specified with Days or Date in
  11693. // a Lifecycle Expiration Policy.
  11694. ExpiredObjectDeleteMarker *bool `type:"boolean"`
  11695. }
  11696. // String returns the string representation
  11697. func (s LifecycleExpiration) String() string {
  11698. return awsutil.Prettify(s)
  11699. }
  11700. // GoString returns the string representation
  11701. func (s LifecycleExpiration) GoString() string {
  11702. return s.String()
  11703. }
  11704. // SetDate sets the Date field's value.
  11705. func (s *LifecycleExpiration) SetDate(v time.Time) *LifecycleExpiration {
  11706. s.Date = &v
  11707. return s
  11708. }
  11709. // SetDays sets the Days field's value.
  11710. func (s *LifecycleExpiration) SetDays(v int64) *LifecycleExpiration {
  11711. s.Days = &v
  11712. return s
  11713. }
  11714. // SetExpiredObjectDeleteMarker sets the ExpiredObjectDeleteMarker field's value.
  11715. func (s *LifecycleExpiration) SetExpiredObjectDeleteMarker(v bool) *LifecycleExpiration {
  11716. s.ExpiredObjectDeleteMarker = &v
  11717. return s
  11718. }
  11719. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRule
  11720. type LifecycleRule struct {
  11721. _ struct{} `type:"structure"`
  11722. // Specifies the days since the initiation of an Incomplete Multipart Upload
  11723. // that Lifecycle will wait before permanently removing all parts of the upload.
  11724. AbortIncompleteMultipartUpload *AbortIncompleteMultipartUpload `type:"structure"`
  11725. Expiration *LifecycleExpiration `type:"structure"`
  11726. // The Filter is used to identify objects that a Lifecycle Rule applies to.
  11727. // A Filter must have exactly one of Prefix, Tag, or And specified.
  11728. Filter *LifecycleRuleFilter `type:"structure"`
  11729. // Unique identifier for the rule. The value cannot be longer than 255 characters.
  11730. ID *string `type:"string"`
  11731. // Specifies when noncurrent object versions expire. Upon expiration, Amazon
  11732. // S3 permanently deletes the noncurrent object versions. You set this lifecycle
  11733. // configuration action on a bucket that has versioning enabled (or suspended)
  11734. // to request that Amazon S3 delete noncurrent object versions at a specific
  11735. // period in the object's lifetime.
  11736. NoncurrentVersionExpiration *NoncurrentVersionExpiration `type:"structure"`
  11737. NoncurrentVersionTransitions []*NoncurrentVersionTransition `locationName:"NoncurrentVersionTransition" type:"list" flattened:"true"`
  11738. // Prefix identifying one or more objects to which the rule applies. This is
  11739. // deprecated; use Filter instead.
  11740. Prefix *string `deprecated:"true" type:"string"`
  11741. // If 'Enabled', the rule is currently being applied. If 'Disabled', the rule
  11742. // is not currently being applied.
  11743. //
  11744. // Status is a required field
  11745. Status *string `type:"string" required:"true" enum:"ExpirationStatus"`
  11746. Transitions []*Transition `locationName:"Transition" type:"list" flattened:"true"`
  11747. }
  11748. // String returns the string representation
  11749. func (s LifecycleRule) String() string {
  11750. return awsutil.Prettify(s)
  11751. }
  11752. // GoString returns the string representation
  11753. func (s LifecycleRule) GoString() string {
  11754. return s.String()
  11755. }
  11756. // Validate inspects the fields of the type to determine if they are valid.
  11757. func (s *LifecycleRule) Validate() error {
  11758. invalidParams := request.ErrInvalidParams{Context: "LifecycleRule"}
  11759. if s.Status == nil {
  11760. invalidParams.Add(request.NewErrParamRequired("Status"))
  11761. }
  11762. if s.Filter != nil {
  11763. if err := s.Filter.Validate(); err != nil {
  11764. invalidParams.AddNested("Filter", err.(request.ErrInvalidParams))
  11765. }
  11766. }
  11767. if invalidParams.Len() > 0 {
  11768. return invalidParams
  11769. }
  11770. return nil
  11771. }
  11772. // SetAbortIncompleteMultipartUpload sets the AbortIncompleteMultipartUpload field's value.
  11773. func (s *LifecycleRule) SetAbortIncompleteMultipartUpload(v *AbortIncompleteMultipartUpload) *LifecycleRule {
  11774. s.AbortIncompleteMultipartUpload = v
  11775. return s
  11776. }
  11777. // SetExpiration sets the Expiration field's value.
  11778. func (s *LifecycleRule) SetExpiration(v *LifecycleExpiration) *LifecycleRule {
  11779. s.Expiration = v
  11780. return s
  11781. }
  11782. // SetFilter sets the Filter field's value.
  11783. func (s *LifecycleRule) SetFilter(v *LifecycleRuleFilter) *LifecycleRule {
  11784. s.Filter = v
  11785. return s
  11786. }
  11787. // SetID sets the ID field's value.
  11788. func (s *LifecycleRule) SetID(v string) *LifecycleRule {
  11789. s.ID = &v
  11790. return s
  11791. }
  11792. // SetNoncurrentVersionExpiration sets the NoncurrentVersionExpiration field's value.
  11793. func (s *LifecycleRule) SetNoncurrentVersionExpiration(v *NoncurrentVersionExpiration) *LifecycleRule {
  11794. s.NoncurrentVersionExpiration = v
  11795. return s
  11796. }
  11797. // SetNoncurrentVersionTransitions sets the NoncurrentVersionTransitions field's value.
  11798. func (s *LifecycleRule) SetNoncurrentVersionTransitions(v []*NoncurrentVersionTransition) *LifecycleRule {
  11799. s.NoncurrentVersionTransitions = v
  11800. return s
  11801. }
  11802. // SetPrefix sets the Prefix field's value.
  11803. func (s *LifecycleRule) SetPrefix(v string) *LifecycleRule {
  11804. s.Prefix = &v
  11805. return s
  11806. }
  11807. // SetStatus sets the Status field's value.
  11808. func (s *LifecycleRule) SetStatus(v string) *LifecycleRule {
  11809. s.Status = &v
  11810. return s
  11811. }
  11812. // SetTransitions sets the Transitions field's value.
  11813. func (s *LifecycleRule) SetTransitions(v []*Transition) *LifecycleRule {
  11814. s.Transitions = v
  11815. return s
  11816. }
  11817. // This is used in a Lifecycle Rule Filter to apply a logical AND to two or
  11818. // more predicates. The Lifecycle Rule will apply to any object matching all
  11819. // of the predicates configured inside the And operator.
  11820. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRuleAndOperator
  11821. type LifecycleRuleAndOperator struct {
  11822. _ struct{} `type:"structure"`
  11823. Prefix *string `type:"string"`
  11824. // All of these tags must exist in the object's tag set in order for the rule
  11825. // to apply.
  11826. Tags []*Tag `locationName:"Tag" locationNameList:"Tag" type:"list" flattened:"true"`
  11827. }
  11828. // String returns the string representation
  11829. func (s LifecycleRuleAndOperator) String() string {
  11830. return awsutil.Prettify(s)
  11831. }
  11832. // GoString returns the string representation
  11833. func (s LifecycleRuleAndOperator) GoString() string {
  11834. return s.String()
  11835. }
  11836. // Validate inspects the fields of the type to determine if they are valid.
  11837. func (s *LifecycleRuleAndOperator) Validate() error {
  11838. invalidParams := request.ErrInvalidParams{Context: "LifecycleRuleAndOperator"}
  11839. if s.Tags != nil {
  11840. for i, v := range s.Tags {
  11841. if v == nil {
  11842. continue
  11843. }
  11844. if err := v.Validate(); err != nil {
  11845. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
  11846. }
  11847. }
  11848. }
  11849. if invalidParams.Len() > 0 {
  11850. return invalidParams
  11851. }
  11852. return nil
  11853. }
  11854. // SetPrefix sets the Prefix field's value.
  11855. func (s *LifecycleRuleAndOperator) SetPrefix(v string) *LifecycleRuleAndOperator {
  11856. s.Prefix = &v
  11857. return s
  11858. }
  11859. // SetTags sets the Tags field's value.
  11860. func (s *LifecycleRuleAndOperator) SetTags(v []*Tag) *LifecycleRuleAndOperator {
  11861. s.Tags = v
  11862. return s
  11863. }
  11864. // The Filter is used to identify objects that a Lifecycle Rule applies to.
  11865. // A Filter must have exactly one of Prefix, Tag, or And specified.
  11866. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LifecycleRuleFilter
  11867. type LifecycleRuleFilter struct {
  11868. _ struct{} `type:"structure"`
  11869. // This is used in a Lifecycle Rule Filter to apply a logical AND to two or
  11870. // more predicates. The Lifecycle Rule will apply to any object matching all
  11871. // of the predicates configured inside the And operator.
  11872. And *LifecycleRuleAndOperator `type:"structure"`
  11873. // Prefix identifying one or more objects to which the rule applies.
  11874. Prefix *string `type:"string"`
  11875. // This tag must exist in the object's tag set in order for the rule to apply.
  11876. Tag *Tag `type:"structure"`
  11877. }
  11878. // String returns the string representation
  11879. func (s LifecycleRuleFilter) String() string {
  11880. return awsutil.Prettify(s)
  11881. }
  11882. // GoString returns the string representation
  11883. func (s LifecycleRuleFilter) GoString() string {
  11884. return s.String()
  11885. }
  11886. // Validate inspects the fields of the type to determine if they are valid.
  11887. func (s *LifecycleRuleFilter) Validate() error {
  11888. invalidParams := request.ErrInvalidParams{Context: "LifecycleRuleFilter"}
  11889. if s.And != nil {
  11890. if err := s.And.Validate(); err != nil {
  11891. invalidParams.AddNested("And", err.(request.ErrInvalidParams))
  11892. }
  11893. }
  11894. if s.Tag != nil {
  11895. if err := s.Tag.Validate(); err != nil {
  11896. invalidParams.AddNested("Tag", err.(request.ErrInvalidParams))
  11897. }
  11898. }
  11899. if invalidParams.Len() > 0 {
  11900. return invalidParams
  11901. }
  11902. return nil
  11903. }
  11904. // SetAnd sets the And field's value.
  11905. func (s *LifecycleRuleFilter) SetAnd(v *LifecycleRuleAndOperator) *LifecycleRuleFilter {
  11906. s.And = v
  11907. return s
  11908. }
  11909. // SetPrefix sets the Prefix field's value.
  11910. func (s *LifecycleRuleFilter) SetPrefix(v string) *LifecycleRuleFilter {
  11911. s.Prefix = &v
  11912. return s
  11913. }
  11914. // SetTag sets the Tag field's value.
  11915. func (s *LifecycleRuleFilter) SetTag(v *Tag) *LifecycleRuleFilter {
  11916. s.Tag = v
  11917. return s
  11918. }
  11919. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurationsRequest
  11920. type ListBucketAnalyticsConfigurationsInput struct {
  11921. _ struct{} `type:"structure"`
  11922. // The name of the bucket from which analytics configurations are retrieved.
  11923. //
  11924. // Bucket is a required field
  11925. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  11926. // The ContinuationToken that represents a placeholder from where this request
  11927. // should begin.
  11928. ContinuationToken *string `location:"querystring" locationName:"continuation-token" type:"string"`
  11929. }
  11930. // String returns the string representation
  11931. func (s ListBucketAnalyticsConfigurationsInput) String() string {
  11932. return awsutil.Prettify(s)
  11933. }
  11934. // GoString returns the string representation
  11935. func (s ListBucketAnalyticsConfigurationsInput) GoString() string {
  11936. return s.String()
  11937. }
  11938. // Validate inspects the fields of the type to determine if they are valid.
  11939. func (s *ListBucketAnalyticsConfigurationsInput) Validate() error {
  11940. invalidParams := request.ErrInvalidParams{Context: "ListBucketAnalyticsConfigurationsInput"}
  11941. if s.Bucket == nil {
  11942. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  11943. }
  11944. if invalidParams.Len() > 0 {
  11945. return invalidParams
  11946. }
  11947. return nil
  11948. }
  11949. // SetBucket sets the Bucket field's value.
  11950. func (s *ListBucketAnalyticsConfigurationsInput) SetBucket(v string) *ListBucketAnalyticsConfigurationsInput {
  11951. s.Bucket = &v
  11952. return s
  11953. }
  11954. func (s *ListBucketAnalyticsConfigurationsInput) getBucket() (v string) {
  11955. if s.Bucket == nil {
  11956. return v
  11957. }
  11958. return *s.Bucket
  11959. }
  11960. // SetContinuationToken sets the ContinuationToken field's value.
  11961. func (s *ListBucketAnalyticsConfigurationsInput) SetContinuationToken(v string) *ListBucketAnalyticsConfigurationsInput {
  11962. s.ContinuationToken = &v
  11963. return s
  11964. }
  11965. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketAnalyticsConfigurationsOutput
  11966. type ListBucketAnalyticsConfigurationsOutput struct {
  11967. _ struct{} `type:"structure"`
  11968. // The list of analytics configurations for a bucket.
  11969. AnalyticsConfigurationList []*AnalyticsConfiguration `locationName:"AnalyticsConfiguration" type:"list" flattened:"true"`
  11970. // The ContinuationToken that represents where this request began.
  11971. ContinuationToken *string `type:"string"`
  11972. // Indicates whether the returned list of analytics configurations is complete.
  11973. // A value of true indicates that the list is not complete and the NextContinuationToken
  11974. // will be provided for a subsequent request.
  11975. IsTruncated *bool `type:"boolean"`
  11976. // NextContinuationToken is sent when isTruncated is true, which indicates that
  11977. // there are more analytics configurations to list. The next request must include
  11978. // this NextContinuationToken. The token is obfuscated and is not a usable value.
  11979. NextContinuationToken *string `type:"string"`
  11980. }
  11981. // String returns the string representation
  11982. func (s ListBucketAnalyticsConfigurationsOutput) String() string {
  11983. return awsutil.Prettify(s)
  11984. }
  11985. // GoString returns the string representation
  11986. func (s ListBucketAnalyticsConfigurationsOutput) GoString() string {
  11987. return s.String()
  11988. }
  11989. // SetAnalyticsConfigurationList sets the AnalyticsConfigurationList field's value.
  11990. func (s *ListBucketAnalyticsConfigurationsOutput) SetAnalyticsConfigurationList(v []*AnalyticsConfiguration) *ListBucketAnalyticsConfigurationsOutput {
  11991. s.AnalyticsConfigurationList = v
  11992. return s
  11993. }
  11994. // SetContinuationToken sets the ContinuationToken field's value.
  11995. func (s *ListBucketAnalyticsConfigurationsOutput) SetContinuationToken(v string) *ListBucketAnalyticsConfigurationsOutput {
  11996. s.ContinuationToken = &v
  11997. return s
  11998. }
  11999. // SetIsTruncated sets the IsTruncated field's value.
  12000. func (s *ListBucketAnalyticsConfigurationsOutput) SetIsTruncated(v bool) *ListBucketAnalyticsConfigurationsOutput {
  12001. s.IsTruncated = &v
  12002. return s
  12003. }
  12004. // SetNextContinuationToken sets the NextContinuationToken field's value.
  12005. func (s *ListBucketAnalyticsConfigurationsOutput) SetNextContinuationToken(v string) *ListBucketAnalyticsConfigurationsOutput {
  12006. s.NextContinuationToken = &v
  12007. return s
  12008. }
  12009. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurationsRequest
  12010. type ListBucketInventoryConfigurationsInput struct {
  12011. _ struct{} `type:"structure"`
  12012. // The name of the bucket containing the inventory configurations to retrieve.
  12013. //
  12014. // Bucket is a required field
  12015. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12016. // The marker used to continue an inventory configuration listing that has been
  12017. // truncated. Use the NextContinuationToken from a previously truncated list
  12018. // response to continue the listing. The continuation token is an opaque value
  12019. // that Amazon S3 understands.
  12020. ContinuationToken *string `location:"querystring" locationName:"continuation-token" type:"string"`
  12021. }
  12022. // String returns the string representation
  12023. func (s ListBucketInventoryConfigurationsInput) String() string {
  12024. return awsutil.Prettify(s)
  12025. }
  12026. // GoString returns the string representation
  12027. func (s ListBucketInventoryConfigurationsInput) GoString() string {
  12028. return s.String()
  12029. }
  12030. // Validate inspects the fields of the type to determine if they are valid.
  12031. func (s *ListBucketInventoryConfigurationsInput) Validate() error {
  12032. invalidParams := request.ErrInvalidParams{Context: "ListBucketInventoryConfigurationsInput"}
  12033. if s.Bucket == nil {
  12034. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12035. }
  12036. if invalidParams.Len() > 0 {
  12037. return invalidParams
  12038. }
  12039. return nil
  12040. }
  12041. // SetBucket sets the Bucket field's value.
  12042. func (s *ListBucketInventoryConfigurationsInput) SetBucket(v string) *ListBucketInventoryConfigurationsInput {
  12043. s.Bucket = &v
  12044. return s
  12045. }
  12046. func (s *ListBucketInventoryConfigurationsInput) getBucket() (v string) {
  12047. if s.Bucket == nil {
  12048. return v
  12049. }
  12050. return *s.Bucket
  12051. }
  12052. // SetContinuationToken sets the ContinuationToken field's value.
  12053. func (s *ListBucketInventoryConfigurationsInput) SetContinuationToken(v string) *ListBucketInventoryConfigurationsInput {
  12054. s.ContinuationToken = &v
  12055. return s
  12056. }
  12057. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketInventoryConfigurationsOutput
  12058. type ListBucketInventoryConfigurationsOutput struct {
  12059. _ struct{} `type:"structure"`
  12060. // If sent in the request, the marker that is used as a starting point for this
  12061. // inventory configuration list response.
  12062. ContinuationToken *string `type:"string"`
  12063. // The list of inventory configurations for a bucket.
  12064. InventoryConfigurationList []*InventoryConfiguration `locationName:"InventoryConfiguration" type:"list" flattened:"true"`
  12065. // Indicates whether the returned list of inventory configurations is truncated
  12066. // in this response. A value of true indicates that the list is truncated.
  12067. IsTruncated *bool `type:"boolean"`
  12068. // The marker used to continue this inventory configuration listing. Use the
  12069. // NextContinuationToken from this response to continue the listing in a subsequent
  12070. // request. The continuation token is an opaque value that Amazon S3 understands.
  12071. NextContinuationToken *string `type:"string"`
  12072. }
  12073. // String returns the string representation
  12074. func (s ListBucketInventoryConfigurationsOutput) String() string {
  12075. return awsutil.Prettify(s)
  12076. }
  12077. // GoString returns the string representation
  12078. func (s ListBucketInventoryConfigurationsOutput) GoString() string {
  12079. return s.String()
  12080. }
  12081. // SetContinuationToken sets the ContinuationToken field's value.
  12082. func (s *ListBucketInventoryConfigurationsOutput) SetContinuationToken(v string) *ListBucketInventoryConfigurationsOutput {
  12083. s.ContinuationToken = &v
  12084. return s
  12085. }
  12086. // SetInventoryConfigurationList sets the InventoryConfigurationList field's value.
  12087. func (s *ListBucketInventoryConfigurationsOutput) SetInventoryConfigurationList(v []*InventoryConfiguration) *ListBucketInventoryConfigurationsOutput {
  12088. s.InventoryConfigurationList = v
  12089. return s
  12090. }
  12091. // SetIsTruncated sets the IsTruncated field's value.
  12092. func (s *ListBucketInventoryConfigurationsOutput) SetIsTruncated(v bool) *ListBucketInventoryConfigurationsOutput {
  12093. s.IsTruncated = &v
  12094. return s
  12095. }
  12096. // SetNextContinuationToken sets the NextContinuationToken field's value.
  12097. func (s *ListBucketInventoryConfigurationsOutput) SetNextContinuationToken(v string) *ListBucketInventoryConfigurationsOutput {
  12098. s.NextContinuationToken = &v
  12099. return s
  12100. }
  12101. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurationsRequest
  12102. type ListBucketMetricsConfigurationsInput struct {
  12103. _ struct{} `type:"structure"`
  12104. // The name of the bucket containing the metrics configurations to retrieve.
  12105. //
  12106. // Bucket is a required field
  12107. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12108. // The marker that is used to continue a metrics configuration listing that
  12109. // has been truncated. Use the NextContinuationToken from a previously truncated
  12110. // list response to continue the listing. The continuation token is an opaque
  12111. // value that Amazon S3 understands.
  12112. ContinuationToken *string `location:"querystring" locationName:"continuation-token" type:"string"`
  12113. }
  12114. // String returns the string representation
  12115. func (s ListBucketMetricsConfigurationsInput) String() string {
  12116. return awsutil.Prettify(s)
  12117. }
  12118. // GoString returns the string representation
  12119. func (s ListBucketMetricsConfigurationsInput) GoString() string {
  12120. return s.String()
  12121. }
  12122. // Validate inspects the fields of the type to determine if they are valid.
  12123. func (s *ListBucketMetricsConfigurationsInput) Validate() error {
  12124. invalidParams := request.ErrInvalidParams{Context: "ListBucketMetricsConfigurationsInput"}
  12125. if s.Bucket == nil {
  12126. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12127. }
  12128. if invalidParams.Len() > 0 {
  12129. return invalidParams
  12130. }
  12131. return nil
  12132. }
  12133. // SetBucket sets the Bucket field's value.
  12134. func (s *ListBucketMetricsConfigurationsInput) SetBucket(v string) *ListBucketMetricsConfigurationsInput {
  12135. s.Bucket = &v
  12136. return s
  12137. }
  12138. func (s *ListBucketMetricsConfigurationsInput) getBucket() (v string) {
  12139. if s.Bucket == nil {
  12140. return v
  12141. }
  12142. return *s.Bucket
  12143. }
  12144. // SetContinuationToken sets the ContinuationToken field's value.
  12145. func (s *ListBucketMetricsConfigurationsInput) SetContinuationToken(v string) *ListBucketMetricsConfigurationsInput {
  12146. s.ContinuationToken = &v
  12147. return s
  12148. }
  12149. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketMetricsConfigurationsOutput
  12150. type ListBucketMetricsConfigurationsOutput struct {
  12151. _ struct{} `type:"structure"`
  12152. // The marker that is used as a starting point for this metrics configuration
  12153. // list response. This value is present if it was sent in the request.
  12154. ContinuationToken *string `type:"string"`
  12155. // Indicates whether the returned list of metrics configurations is complete.
  12156. // A value of true indicates that the list is not complete and the NextContinuationToken
  12157. // will be provided for a subsequent request.
  12158. IsTruncated *bool `type:"boolean"`
  12159. // The list of metrics configurations for a bucket.
  12160. MetricsConfigurationList []*MetricsConfiguration `locationName:"MetricsConfiguration" type:"list" flattened:"true"`
  12161. // The marker used to continue a metrics configuration listing that has been
  12162. // truncated. Use the NextContinuationToken from a previously truncated list
  12163. // response to continue the listing. The continuation token is an opaque value
  12164. // that Amazon S3 understands.
  12165. NextContinuationToken *string `type:"string"`
  12166. }
  12167. // String returns the string representation
  12168. func (s ListBucketMetricsConfigurationsOutput) String() string {
  12169. return awsutil.Prettify(s)
  12170. }
  12171. // GoString returns the string representation
  12172. func (s ListBucketMetricsConfigurationsOutput) GoString() string {
  12173. return s.String()
  12174. }
  12175. // SetContinuationToken sets the ContinuationToken field's value.
  12176. func (s *ListBucketMetricsConfigurationsOutput) SetContinuationToken(v string) *ListBucketMetricsConfigurationsOutput {
  12177. s.ContinuationToken = &v
  12178. return s
  12179. }
  12180. // SetIsTruncated sets the IsTruncated field's value.
  12181. func (s *ListBucketMetricsConfigurationsOutput) SetIsTruncated(v bool) *ListBucketMetricsConfigurationsOutput {
  12182. s.IsTruncated = &v
  12183. return s
  12184. }
  12185. // SetMetricsConfigurationList sets the MetricsConfigurationList field's value.
  12186. func (s *ListBucketMetricsConfigurationsOutput) SetMetricsConfigurationList(v []*MetricsConfiguration) *ListBucketMetricsConfigurationsOutput {
  12187. s.MetricsConfigurationList = v
  12188. return s
  12189. }
  12190. // SetNextContinuationToken sets the NextContinuationToken field's value.
  12191. func (s *ListBucketMetricsConfigurationsOutput) SetNextContinuationToken(v string) *ListBucketMetricsConfigurationsOutput {
  12192. s.NextContinuationToken = &v
  12193. return s
  12194. }
  12195. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketsInput
  12196. type ListBucketsInput struct {
  12197. _ struct{} `type:"structure"`
  12198. }
  12199. // String returns the string representation
  12200. func (s ListBucketsInput) String() string {
  12201. return awsutil.Prettify(s)
  12202. }
  12203. // GoString returns the string representation
  12204. func (s ListBucketsInput) GoString() string {
  12205. return s.String()
  12206. }
  12207. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListBucketsOutput
  12208. type ListBucketsOutput struct {
  12209. _ struct{} `type:"structure"`
  12210. Buckets []*Bucket `locationNameList:"Bucket" type:"list"`
  12211. Owner *Owner `type:"structure"`
  12212. }
  12213. // String returns the string representation
  12214. func (s ListBucketsOutput) String() string {
  12215. return awsutil.Prettify(s)
  12216. }
  12217. // GoString returns the string representation
  12218. func (s ListBucketsOutput) GoString() string {
  12219. return s.String()
  12220. }
  12221. // SetBuckets sets the Buckets field's value.
  12222. func (s *ListBucketsOutput) SetBuckets(v []*Bucket) *ListBucketsOutput {
  12223. s.Buckets = v
  12224. return s
  12225. }
  12226. // SetOwner sets the Owner field's value.
  12227. func (s *ListBucketsOutput) SetOwner(v *Owner) *ListBucketsOutput {
  12228. s.Owner = v
  12229. return s
  12230. }
  12231. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploadsRequest
  12232. type ListMultipartUploadsInput struct {
  12233. _ struct{} `type:"structure"`
  12234. // Bucket is a required field
  12235. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12236. // Character you use to group keys.
  12237. Delimiter *string `location:"querystring" locationName:"delimiter" type:"string"`
  12238. // Requests Amazon S3 to encode the object keys in the response and specifies
  12239. // the encoding method to use. An object key may contain any Unicode character;
  12240. // however, XML 1.0 parser cannot parse some characters, such as characters
  12241. // with an ASCII value from 0 to 10. For characters that are not supported in
  12242. // XML 1.0, you can add this parameter to request that Amazon S3 encode the
  12243. // keys in the response.
  12244. EncodingType *string `location:"querystring" locationName:"encoding-type" type:"string" enum:"EncodingType"`
  12245. // Together with upload-id-marker, this parameter specifies the multipart upload
  12246. // after which listing should begin.
  12247. KeyMarker *string `location:"querystring" locationName:"key-marker" type:"string"`
  12248. // Sets the maximum number of multipart uploads, from 1 to 1,000, to return
  12249. // in the response body. 1,000 is the maximum number of uploads that can be
  12250. // returned in a response.
  12251. MaxUploads *int64 `location:"querystring" locationName:"max-uploads" type:"integer"`
  12252. // Lists in-progress uploads only for those keys that begin with the specified
  12253. // prefix.
  12254. Prefix *string `location:"querystring" locationName:"prefix" type:"string"`
  12255. // Together with key-marker, specifies the multipart upload after which listing
  12256. // should begin. If key-marker is not specified, the upload-id-marker parameter
  12257. // is ignored.
  12258. UploadIdMarker *string `location:"querystring" locationName:"upload-id-marker" type:"string"`
  12259. }
  12260. // String returns the string representation
  12261. func (s ListMultipartUploadsInput) String() string {
  12262. return awsutil.Prettify(s)
  12263. }
  12264. // GoString returns the string representation
  12265. func (s ListMultipartUploadsInput) GoString() string {
  12266. return s.String()
  12267. }
  12268. // Validate inspects the fields of the type to determine if they are valid.
  12269. func (s *ListMultipartUploadsInput) Validate() error {
  12270. invalidParams := request.ErrInvalidParams{Context: "ListMultipartUploadsInput"}
  12271. if s.Bucket == nil {
  12272. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12273. }
  12274. if invalidParams.Len() > 0 {
  12275. return invalidParams
  12276. }
  12277. return nil
  12278. }
  12279. // SetBucket sets the Bucket field's value.
  12280. func (s *ListMultipartUploadsInput) SetBucket(v string) *ListMultipartUploadsInput {
  12281. s.Bucket = &v
  12282. return s
  12283. }
  12284. func (s *ListMultipartUploadsInput) getBucket() (v string) {
  12285. if s.Bucket == nil {
  12286. return v
  12287. }
  12288. return *s.Bucket
  12289. }
  12290. // SetDelimiter sets the Delimiter field's value.
  12291. func (s *ListMultipartUploadsInput) SetDelimiter(v string) *ListMultipartUploadsInput {
  12292. s.Delimiter = &v
  12293. return s
  12294. }
  12295. // SetEncodingType sets the EncodingType field's value.
  12296. func (s *ListMultipartUploadsInput) SetEncodingType(v string) *ListMultipartUploadsInput {
  12297. s.EncodingType = &v
  12298. return s
  12299. }
  12300. // SetKeyMarker sets the KeyMarker field's value.
  12301. func (s *ListMultipartUploadsInput) SetKeyMarker(v string) *ListMultipartUploadsInput {
  12302. s.KeyMarker = &v
  12303. return s
  12304. }
  12305. // SetMaxUploads sets the MaxUploads field's value.
  12306. func (s *ListMultipartUploadsInput) SetMaxUploads(v int64) *ListMultipartUploadsInput {
  12307. s.MaxUploads = &v
  12308. return s
  12309. }
  12310. // SetPrefix sets the Prefix field's value.
  12311. func (s *ListMultipartUploadsInput) SetPrefix(v string) *ListMultipartUploadsInput {
  12312. s.Prefix = &v
  12313. return s
  12314. }
  12315. // SetUploadIdMarker sets the UploadIdMarker field's value.
  12316. func (s *ListMultipartUploadsInput) SetUploadIdMarker(v string) *ListMultipartUploadsInput {
  12317. s.UploadIdMarker = &v
  12318. return s
  12319. }
  12320. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListMultipartUploadsOutput
  12321. type ListMultipartUploadsOutput struct {
  12322. _ struct{} `type:"structure"`
  12323. // Name of the bucket to which the multipart upload was initiated.
  12324. Bucket *string `type:"string"`
  12325. CommonPrefixes []*CommonPrefix `type:"list" flattened:"true"`
  12326. Delimiter *string `type:"string"`
  12327. // Encoding type used by Amazon S3 to encode object keys in the response.
  12328. EncodingType *string `type:"string" enum:"EncodingType"`
  12329. // Indicates whether the returned list of multipart uploads is truncated. A
  12330. // value of true indicates that the list was truncated. The list can be truncated
  12331. // if the number of multipart uploads exceeds the limit allowed or specified
  12332. // by max uploads.
  12333. IsTruncated *bool `type:"boolean"`
  12334. // The key at or after which the listing began.
  12335. KeyMarker *string `type:"string"`
  12336. // Maximum number of multipart uploads that could have been included in the
  12337. // response.
  12338. MaxUploads *int64 `type:"integer"`
  12339. // When a list is truncated, this element specifies the value that should be
  12340. // used for the key-marker request parameter in a subsequent request.
  12341. NextKeyMarker *string `type:"string"`
  12342. // When a list is truncated, this element specifies the value that should be
  12343. // used for the upload-id-marker request parameter in a subsequent request.
  12344. NextUploadIdMarker *string `type:"string"`
  12345. // When a prefix is provided in the request, this field contains the specified
  12346. // prefix. The result contains only keys starting with the specified prefix.
  12347. Prefix *string `type:"string"`
  12348. // Upload ID after which listing began.
  12349. UploadIdMarker *string `type:"string"`
  12350. Uploads []*MultipartUpload `locationName:"Upload" type:"list" flattened:"true"`
  12351. }
  12352. // String returns the string representation
  12353. func (s ListMultipartUploadsOutput) String() string {
  12354. return awsutil.Prettify(s)
  12355. }
  12356. // GoString returns the string representation
  12357. func (s ListMultipartUploadsOutput) GoString() string {
  12358. return s.String()
  12359. }
  12360. // SetBucket sets the Bucket field's value.
  12361. func (s *ListMultipartUploadsOutput) SetBucket(v string) *ListMultipartUploadsOutput {
  12362. s.Bucket = &v
  12363. return s
  12364. }
  12365. func (s *ListMultipartUploadsOutput) getBucket() (v string) {
  12366. if s.Bucket == nil {
  12367. return v
  12368. }
  12369. return *s.Bucket
  12370. }
  12371. // SetCommonPrefixes sets the CommonPrefixes field's value.
  12372. func (s *ListMultipartUploadsOutput) SetCommonPrefixes(v []*CommonPrefix) *ListMultipartUploadsOutput {
  12373. s.CommonPrefixes = v
  12374. return s
  12375. }
  12376. // SetDelimiter sets the Delimiter field's value.
  12377. func (s *ListMultipartUploadsOutput) SetDelimiter(v string) *ListMultipartUploadsOutput {
  12378. s.Delimiter = &v
  12379. return s
  12380. }
  12381. // SetEncodingType sets the EncodingType field's value.
  12382. func (s *ListMultipartUploadsOutput) SetEncodingType(v string) *ListMultipartUploadsOutput {
  12383. s.EncodingType = &v
  12384. return s
  12385. }
  12386. // SetIsTruncated sets the IsTruncated field's value.
  12387. func (s *ListMultipartUploadsOutput) SetIsTruncated(v bool) *ListMultipartUploadsOutput {
  12388. s.IsTruncated = &v
  12389. return s
  12390. }
  12391. // SetKeyMarker sets the KeyMarker field's value.
  12392. func (s *ListMultipartUploadsOutput) SetKeyMarker(v string) *ListMultipartUploadsOutput {
  12393. s.KeyMarker = &v
  12394. return s
  12395. }
  12396. // SetMaxUploads sets the MaxUploads field's value.
  12397. func (s *ListMultipartUploadsOutput) SetMaxUploads(v int64) *ListMultipartUploadsOutput {
  12398. s.MaxUploads = &v
  12399. return s
  12400. }
  12401. // SetNextKeyMarker sets the NextKeyMarker field's value.
  12402. func (s *ListMultipartUploadsOutput) SetNextKeyMarker(v string) *ListMultipartUploadsOutput {
  12403. s.NextKeyMarker = &v
  12404. return s
  12405. }
  12406. // SetNextUploadIdMarker sets the NextUploadIdMarker field's value.
  12407. func (s *ListMultipartUploadsOutput) SetNextUploadIdMarker(v string) *ListMultipartUploadsOutput {
  12408. s.NextUploadIdMarker = &v
  12409. return s
  12410. }
  12411. // SetPrefix sets the Prefix field's value.
  12412. func (s *ListMultipartUploadsOutput) SetPrefix(v string) *ListMultipartUploadsOutput {
  12413. s.Prefix = &v
  12414. return s
  12415. }
  12416. // SetUploadIdMarker sets the UploadIdMarker field's value.
  12417. func (s *ListMultipartUploadsOutput) SetUploadIdMarker(v string) *ListMultipartUploadsOutput {
  12418. s.UploadIdMarker = &v
  12419. return s
  12420. }
  12421. // SetUploads sets the Uploads field's value.
  12422. func (s *ListMultipartUploadsOutput) SetUploads(v []*MultipartUpload) *ListMultipartUploadsOutput {
  12423. s.Uploads = v
  12424. return s
  12425. }
  12426. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersionsRequest
  12427. type ListObjectVersionsInput struct {
  12428. _ struct{} `type:"structure"`
  12429. // Bucket is a required field
  12430. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12431. // A delimiter is a character you use to group keys.
  12432. Delimiter *string `location:"querystring" locationName:"delimiter" type:"string"`
  12433. // Requests Amazon S3 to encode the object keys in the response and specifies
  12434. // the encoding method to use. An object key may contain any Unicode character;
  12435. // however, XML 1.0 parser cannot parse some characters, such as characters
  12436. // with an ASCII value from 0 to 10. For characters that are not supported in
  12437. // XML 1.0, you can add this parameter to request that Amazon S3 encode the
  12438. // keys in the response.
  12439. EncodingType *string `location:"querystring" locationName:"encoding-type" type:"string" enum:"EncodingType"`
  12440. // Specifies the key to start with when listing objects in a bucket.
  12441. KeyMarker *string `location:"querystring" locationName:"key-marker" type:"string"`
  12442. // Sets the maximum number of keys returned in the response. The response might
  12443. // contain fewer keys but will never contain more.
  12444. MaxKeys *int64 `location:"querystring" locationName:"max-keys" type:"integer"`
  12445. // Limits the response to keys that begin with the specified prefix.
  12446. Prefix *string `location:"querystring" locationName:"prefix" type:"string"`
  12447. // Specifies the object version you want to start listing from.
  12448. VersionIdMarker *string `location:"querystring" locationName:"version-id-marker" type:"string"`
  12449. }
  12450. // String returns the string representation
  12451. func (s ListObjectVersionsInput) String() string {
  12452. return awsutil.Prettify(s)
  12453. }
  12454. // GoString returns the string representation
  12455. func (s ListObjectVersionsInput) GoString() string {
  12456. return s.String()
  12457. }
  12458. // Validate inspects the fields of the type to determine if they are valid.
  12459. func (s *ListObjectVersionsInput) Validate() error {
  12460. invalidParams := request.ErrInvalidParams{Context: "ListObjectVersionsInput"}
  12461. if s.Bucket == nil {
  12462. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12463. }
  12464. if invalidParams.Len() > 0 {
  12465. return invalidParams
  12466. }
  12467. return nil
  12468. }
  12469. // SetBucket sets the Bucket field's value.
  12470. func (s *ListObjectVersionsInput) SetBucket(v string) *ListObjectVersionsInput {
  12471. s.Bucket = &v
  12472. return s
  12473. }
  12474. func (s *ListObjectVersionsInput) getBucket() (v string) {
  12475. if s.Bucket == nil {
  12476. return v
  12477. }
  12478. return *s.Bucket
  12479. }
  12480. // SetDelimiter sets the Delimiter field's value.
  12481. func (s *ListObjectVersionsInput) SetDelimiter(v string) *ListObjectVersionsInput {
  12482. s.Delimiter = &v
  12483. return s
  12484. }
  12485. // SetEncodingType sets the EncodingType field's value.
  12486. func (s *ListObjectVersionsInput) SetEncodingType(v string) *ListObjectVersionsInput {
  12487. s.EncodingType = &v
  12488. return s
  12489. }
  12490. // SetKeyMarker sets the KeyMarker field's value.
  12491. func (s *ListObjectVersionsInput) SetKeyMarker(v string) *ListObjectVersionsInput {
  12492. s.KeyMarker = &v
  12493. return s
  12494. }
  12495. // SetMaxKeys sets the MaxKeys field's value.
  12496. func (s *ListObjectVersionsInput) SetMaxKeys(v int64) *ListObjectVersionsInput {
  12497. s.MaxKeys = &v
  12498. return s
  12499. }
  12500. // SetPrefix sets the Prefix field's value.
  12501. func (s *ListObjectVersionsInput) SetPrefix(v string) *ListObjectVersionsInput {
  12502. s.Prefix = &v
  12503. return s
  12504. }
  12505. // SetVersionIdMarker sets the VersionIdMarker field's value.
  12506. func (s *ListObjectVersionsInput) SetVersionIdMarker(v string) *ListObjectVersionsInput {
  12507. s.VersionIdMarker = &v
  12508. return s
  12509. }
  12510. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectVersionsOutput
  12511. type ListObjectVersionsOutput struct {
  12512. _ struct{} `type:"structure"`
  12513. CommonPrefixes []*CommonPrefix `type:"list" flattened:"true"`
  12514. DeleteMarkers []*DeleteMarkerEntry `locationName:"DeleteMarker" type:"list" flattened:"true"`
  12515. Delimiter *string `type:"string"`
  12516. // Encoding type used by Amazon S3 to encode object keys in the response.
  12517. EncodingType *string `type:"string" enum:"EncodingType"`
  12518. // A flag that indicates whether or not Amazon S3 returned all of the results
  12519. // that satisfied the search criteria. If your results were truncated, you can
  12520. // make a follow-up paginated request using the NextKeyMarker and NextVersionIdMarker
  12521. // response parameters as a starting place in another request to return the
  12522. // rest of the results.
  12523. IsTruncated *bool `type:"boolean"`
  12524. // Marks the last Key returned in a truncated response.
  12525. KeyMarker *string `type:"string"`
  12526. MaxKeys *int64 `type:"integer"`
  12527. Name *string `type:"string"`
  12528. // Use this value for the key marker request parameter in a subsequent request.
  12529. NextKeyMarker *string `type:"string"`
  12530. // Use this value for the next version id marker parameter in a subsequent request.
  12531. NextVersionIdMarker *string `type:"string"`
  12532. Prefix *string `type:"string"`
  12533. VersionIdMarker *string `type:"string"`
  12534. Versions []*ObjectVersion `locationName:"Version" type:"list" flattened:"true"`
  12535. }
  12536. // String returns the string representation
  12537. func (s ListObjectVersionsOutput) String() string {
  12538. return awsutil.Prettify(s)
  12539. }
  12540. // GoString returns the string representation
  12541. func (s ListObjectVersionsOutput) GoString() string {
  12542. return s.String()
  12543. }
  12544. // SetCommonPrefixes sets the CommonPrefixes field's value.
  12545. func (s *ListObjectVersionsOutput) SetCommonPrefixes(v []*CommonPrefix) *ListObjectVersionsOutput {
  12546. s.CommonPrefixes = v
  12547. return s
  12548. }
  12549. // SetDeleteMarkers sets the DeleteMarkers field's value.
  12550. func (s *ListObjectVersionsOutput) SetDeleteMarkers(v []*DeleteMarkerEntry) *ListObjectVersionsOutput {
  12551. s.DeleteMarkers = v
  12552. return s
  12553. }
  12554. // SetDelimiter sets the Delimiter field's value.
  12555. func (s *ListObjectVersionsOutput) SetDelimiter(v string) *ListObjectVersionsOutput {
  12556. s.Delimiter = &v
  12557. return s
  12558. }
  12559. // SetEncodingType sets the EncodingType field's value.
  12560. func (s *ListObjectVersionsOutput) SetEncodingType(v string) *ListObjectVersionsOutput {
  12561. s.EncodingType = &v
  12562. return s
  12563. }
  12564. // SetIsTruncated sets the IsTruncated field's value.
  12565. func (s *ListObjectVersionsOutput) SetIsTruncated(v bool) *ListObjectVersionsOutput {
  12566. s.IsTruncated = &v
  12567. return s
  12568. }
  12569. // SetKeyMarker sets the KeyMarker field's value.
  12570. func (s *ListObjectVersionsOutput) SetKeyMarker(v string) *ListObjectVersionsOutput {
  12571. s.KeyMarker = &v
  12572. return s
  12573. }
  12574. // SetMaxKeys sets the MaxKeys field's value.
  12575. func (s *ListObjectVersionsOutput) SetMaxKeys(v int64) *ListObjectVersionsOutput {
  12576. s.MaxKeys = &v
  12577. return s
  12578. }
  12579. // SetName sets the Name field's value.
  12580. func (s *ListObjectVersionsOutput) SetName(v string) *ListObjectVersionsOutput {
  12581. s.Name = &v
  12582. return s
  12583. }
  12584. // SetNextKeyMarker sets the NextKeyMarker field's value.
  12585. func (s *ListObjectVersionsOutput) SetNextKeyMarker(v string) *ListObjectVersionsOutput {
  12586. s.NextKeyMarker = &v
  12587. return s
  12588. }
  12589. // SetNextVersionIdMarker sets the NextVersionIdMarker field's value.
  12590. func (s *ListObjectVersionsOutput) SetNextVersionIdMarker(v string) *ListObjectVersionsOutput {
  12591. s.NextVersionIdMarker = &v
  12592. return s
  12593. }
  12594. // SetPrefix sets the Prefix field's value.
  12595. func (s *ListObjectVersionsOutput) SetPrefix(v string) *ListObjectVersionsOutput {
  12596. s.Prefix = &v
  12597. return s
  12598. }
  12599. // SetVersionIdMarker sets the VersionIdMarker field's value.
  12600. func (s *ListObjectVersionsOutput) SetVersionIdMarker(v string) *ListObjectVersionsOutput {
  12601. s.VersionIdMarker = &v
  12602. return s
  12603. }
  12604. // SetVersions sets the Versions field's value.
  12605. func (s *ListObjectVersionsOutput) SetVersions(v []*ObjectVersion) *ListObjectVersionsOutput {
  12606. s.Versions = v
  12607. return s
  12608. }
  12609. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsRequest
  12610. type ListObjectsInput struct {
  12611. _ struct{} `type:"structure"`
  12612. // Bucket is a required field
  12613. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12614. // A delimiter is a character you use to group keys.
  12615. Delimiter *string `location:"querystring" locationName:"delimiter" type:"string"`
  12616. // Requests Amazon S3 to encode the object keys in the response and specifies
  12617. // the encoding method to use. An object key may contain any Unicode character;
  12618. // however, XML 1.0 parser cannot parse some characters, such as characters
  12619. // with an ASCII value from 0 to 10. For characters that are not supported in
  12620. // XML 1.0, you can add this parameter to request that Amazon S3 encode the
  12621. // keys in the response.
  12622. EncodingType *string `location:"querystring" locationName:"encoding-type" type:"string" enum:"EncodingType"`
  12623. // Specifies the key to start with when listing objects in a bucket.
  12624. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  12625. // Sets the maximum number of keys returned in the response. The response might
  12626. // contain fewer keys but will never contain more.
  12627. MaxKeys *int64 `location:"querystring" locationName:"max-keys" type:"integer"`
  12628. // Limits the response to keys that begin with the specified prefix.
  12629. Prefix *string `location:"querystring" locationName:"prefix" type:"string"`
  12630. // Confirms that the requester knows that she or he will be charged for the
  12631. // list objects request. Bucket owners need not specify this parameter in their
  12632. // requests.
  12633. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  12634. }
  12635. // String returns the string representation
  12636. func (s ListObjectsInput) String() string {
  12637. return awsutil.Prettify(s)
  12638. }
  12639. // GoString returns the string representation
  12640. func (s ListObjectsInput) GoString() string {
  12641. return s.String()
  12642. }
  12643. // Validate inspects the fields of the type to determine if they are valid.
  12644. func (s *ListObjectsInput) Validate() error {
  12645. invalidParams := request.ErrInvalidParams{Context: "ListObjectsInput"}
  12646. if s.Bucket == nil {
  12647. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12648. }
  12649. if invalidParams.Len() > 0 {
  12650. return invalidParams
  12651. }
  12652. return nil
  12653. }
  12654. // SetBucket sets the Bucket field's value.
  12655. func (s *ListObjectsInput) SetBucket(v string) *ListObjectsInput {
  12656. s.Bucket = &v
  12657. return s
  12658. }
  12659. func (s *ListObjectsInput) getBucket() (v string) {
  12660. if s.Bucket == nil {
  12661. return v
  12662. }
  12663. return *s.Bucket
  12664. }
  12665. // SetDelimiter sets the Delimiter field's value.
  12666. func (s *ListObjectsInput) SetDelimiter(v string) *ListObjectsInput {
  12667. s.Delimiter = &v
  12668. return s
  12669. }
  12670. // SetEncodingType sets the EncodingType field's value.
  12671. func (s *ListObjectsInput) SetEncodingType(v string) *ListObjectsInput {
  12672. s.EncodingType = &v
  12673. return s
  12674. }
  12675. // SetMarker sets the Marker field's value.
  12676. func (s *ListObjectsInput) SetMarker(v string) *ListObjectsInput {
  12677. s.Marker = &v
  12678. return s
  12679. }
  12680. // SetMaxKeys sets the MaxKeys field's value.
  12681. func (s *ListObjectsInput) SetMaxKeys(v int64) *ListObjectsInput {
  12682. s.MaxKeys = &v
  12683. return s
  12684. }
  12685. // SetPrefix sets the Prefix field's value.
  12686. func (s *ListObjectsInput) SetPrefix(v string) *ListObjectsInput {
  12687. s.Prefix = &v
  12688. return s
  12689. }
  12690. // SetRequestPayer sets the RequestPayer field's value.
  12691. func (s *ListObjectsInput) SetRequestPayer(v string) *ListObjectsInput {
  12692. s.RequestPayer = &v
  12693. return s
  12694. }
  12695. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsOutput
  12696. type ListObjectsOutput struct {
  12697. _ struct{} `type:"structure"`
  12698. CommonPrefixes []*CommonPrefix `type:"list" flattened:"true"`
  12699. Contents []*Object `type:"list" flattened:"true"`
  12700. Delimiter *string `type:"string"`
  12701. // Encoding type used by Amazon S3 to encode object keys in the response.
  12702. EncodingType *string `type:"string" enum:"EncodingType"`
  12703. // A flag that indicates whether or not Amazon S3 returned all of the results
  12704. // that satisfied the search criteria.
  12705. IsTruncated *bool `type:"boolean"`
  12706. Marker *string `type:"string"`
  12707. MaxKeys *int64 `type:"integer"`
  12708. Name *string `type:"string"`
  12709. // When response is truncated (the IsTruncated element value in the response
  12710. // is true), you can use the key name in this field as marker in the subsequent
  12711. // request to get next set of objects. Amazon S3 lists objects in alphabetical
  12712. // order Note: This element is returned only if you have delimiter request parameter
  12713. // specified. If response does not include the NextMaker and it is truncated,
  12714. // you can use the value of the last Key in the response as the marker in the
  12715. // subsequent request to get the next set of object keys.
  12716. NextMarker *string `type:"string"`
  12717. Prefix *string `type:"string"`
  12718. }
  12719. // String returns the string representation
  12720. func (s ListObjectsOutput) String() string {
  12721. return awsutil.Prettify(s)
  12722. }
  12723. // GoString returns the string representation
  12724. func (s ListObjectsOutput) GoString() string {
  12725. return s.String()
  12726. }
  12727. // SetCommonPrefixes sets the CommonPrefixes field's value.
  12728. func (s *ListObjectsOutput) SetCommonPrefixes(v []*CommonPrefix) *ListObjectsOutput {
  12729. s.CommonPrefixes = v
  12730. return s
  12731. }
  12732. // SetContents sets the Contents field's value.
  12733. func (s *ListObjectsOutput) SetContents(v []*Object) *ListObjectsOutput {
  12734. s.Contents = v
  12735. return s
  12736. }
  12737. // SetDelimiter sets the Delimiter field's value.
  12738. func (s *ListObjectsOutput) SetDelimiter(v string) *ListObjectsOutput {
  12739. s.Delimiter = &v
  12740. return s
  12741. }
  12742. // SetEncodingType sets the EncodingType field's value.
  12743. func (s *ListObjectsOutput) SetEncodingType(v string) *ListObjectsOutput {
  12744. s.EncodingType = &v
  12745. return s
  12746. }
  12747. // SetIsTruncated sets the IsTruncated field's value.
  12748. func (s *ListObjectsOutput) SetIsTruncated(v bool) *ListObjectsOutput {
  12749. s.IsTruncated = &v
  12750. return s
  12751. }
  12752. // SetMarker sets the Marker field's value.
  12753. func (s *ListObjectsOutput) SetMarker(v string) *ListObjectsOutput {
  12754. s.Marker = &v
  12755. return s
  12756. }
  12757. // SetMaxKeys sets the MaxKeys field's value.
  12758. func (s *ListObjectsOutput) SetMaxKeys(v int64) *ListObjectsOutput {
  12759. s.MaxKeys = &v
  12760. return s
  12761. }
  12762. // SetName sets the Name field's value.
  12763. func (s *ListObjectsOutput) SetName(v string) *ListObjectsOutput {
  12764. s.Name = &v
  12765. return s
  12766. }
  12767. // SetNextMarker sets the NextMarker field's value.
  12768. func (s *ListObjectsOutput) SetNextMarker(v string) *ListObjectsOutput {
  12769. s.NextMarker = &v
  12770. return s
  12771. }
  12772. // SetPrefix sets the Prefix field's value.
  12773. func (s *ListObjectsOutput) SetPrefix(v string) *ListObjectsOutput {
  12774. s.Prefix = &v
  12775. return s
  12776. }
  12777. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2Request
  12778. type ListObjectsV2Input struct {
  12779. _ struct{} `type:"structure"`
  12780. // Name of the bucket to list.
  12781. //
  12782. // Bucket is a required field
  12783. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12784. // ContinuationToken indicates Amazon S3 that the list is being continued on
  12785. // this bucket with a token. ContinuationToken is obfuscated and is not a real
  12786. // key
  12787. ContinuationToken *string `location:"querystring" locationName:"continuation-token" type:"string"`
  12788. // A delimiter is a character you use to group keys.
  12789. Delimiter *string `location:"querystring" locationName:"delimiter" type:"string"`
  12790. // Encoding type used by Amazon S3 to encode object keys in the response.
  12791. EncodingType *string `location:"querystring" locationName:"encoding-type" type:"string" enum:"EncodingType"`
  12792. // The owner field is not present in listV2 by default, if you want to return
  12793. // owner field with each key in the result then set the fetch owner field to
  12794. // true
  12795. FetchOwner *bool `location:"querystring" locationName:"fetch-owner" type:"boolean"`
  12796. // Sets the maximum number of keys returned in the response. The response might
  12797. // contain fewer keys but will never contain more.
  12798. MaxKeys *int64 `location:"querystring" locationName:"max-keys" type:"integer"`
  12799. // Limits the response to keys that begin with the specified prefix.
  12800. Prefix *string `location:"querystring" locationName:"prefix" type:"string"`
  12801. // Confirms that the requester knows that she or he will be charged for the
  12802. // list objects request in V2 style. Bucket owners need not specify this parameter
  12803. // in their requests.
  12804. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  12805. // StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts
  12806. // listing after this specified key. StartAfter can be any key in the bucket
  12807. StartAfter *string `location:"querystring" locationName:"start-after" type:"string"`
  12808. }
  12809. // String returns the string representation
  12810. func (s ListObjectsV2Input) String() string {
  12811. return awsutil.Prettify(s)
  12812. }
  12813. // GoString returns the string representation
  12814. func (s ListObjectsV2Input) GoString() string {
  12815. return s.String()
  12816. }
  12817. // Validate inspects the fields of the type to determine if they are valid.
  12818. func (s *ListObjectsV2Input) Validate() error {
  12819. invalidParams := request.ErrInvalidParams{Context: "ListObjectsV2Input"}
  12820. if s.Bucket == nil {
  12821. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  12822. }
  12823. if invalidParams.Len() > 0 {
  12824. return invalidParams
  12825. }
  12826. return nil
  12827. }
  12828. // SetBucket sets the Bucket field's value.
  12829. func (s *ListObjectsV2Input) SetBucket(v string) *ListObjectsV2Input {
  12830. s.Bucket = &v
  12831. return s
  12832. }
  12833. func (s *ListObjectsV2Input) getBucket() (v string) {
  12834. if s.Bucket == nil {
  12835. return v
  12836. }
  12837. return *s.Bucket
  12838. }
  12839. // SetContinuationToken sets the ContinuationToken field's value.
  12840. func (s *ListObjectsV2Input) SetContinuationToken(v string) *ListObjectsV2Input {
  12841. s.ContinuationToken = &v
  12842. return s
  12843. }
  12844. // SetDelimiter sets the Delimiter field's value.
  12845. func (s *ListObjectsV2Input) SetDelimiter(v string) *ListObjectsV2Input {
  12846. s.Delimiter = &v
  12847. return s
  12848. }
  12849. // SetEncodingType sets the EncodingType field's value.
  12850. func (s *ListObjectsV2Input) SetEncodingType(v string) *ListObjectsV2Input {
  12851. s.EncodingType = &v
  12852. return s
  12853. }
  12854. // SetFetchOwner sets the FetchOwner field's value.
  12855. func (s *ListObjectsV2Input) SetFetchOwner(v bool) *ListObjectsV2Input {
  12856. s.FetchOwner = &v
  12857. return s
  12858. }
  12859. // SetMaxKeys sets the MaxKeys field's value.
  12860. func (s *ListObjectsV2Input) SetMaxKeys(v int64) *ListObjectsV2Input {
  12861. s.MaxKeys = &v
  12862. return s
  12863. }
  12864. // SetPrefix sets the Prefix field's value.
  12865. func (s *ListObjectsV2Input) SetPrefix(v string) *ListObjectsV2Input {
  12866. s.Prefix = &v
  12867. return s
  12868. }
  12869. // SetRequestPayer sets the RequestPayer field's value.
  12870. func (s *ListObjectsV2Input) SetRequestPayer(v string) *ListObjectsV2Input {
  12871. s.RequestPayer = &v
  12872. return s
  12873. }
  12874. // SetStartAfter sets the StartAfter field's value.
  12875. func (s *ListObjectsV2Input) SetStartAfter(v string) *ListObjectsV2Input {
  12876. s.StartAfter = &v
  12877. return s
  12878. }
  12879. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListObjectsV2Output
  12880. type ListObjectsV2Output struct {
  12881. _ struct{} `type:"structure"`
  12882. // CommonPrefixes contains all (if there are any) keys between Prefix and the
  12883. // next occurrence of the string specified by delimiter
  12884. CommonPrefixes []*CommonPrefix `type:"list" flattened:"true"`
  12885. // Metadata about each object returned.
  12886. Contents []*Object `type:"list" flattened:"true"`
  12887. // ContinuationToken indicates Amazon S3 that the list is being continued on
  12888. // this bucket with a token. ContinuationToken is obfuscated and is not a real
  12889. // key
  12890. ContinuationToken *string `type:"string"`
  12891. // A delimiter is a character you use to group keys.
  12892. Delimiter *string `type:"string"`
  12893. // Encoding type used by Amazon S3 to encode object keys in the response.
  12894. EncodingType *string `type:"string" enum:"EncodingType"`
  12895. // A flag that indicates whether or not Amazon S3 returned all of the results
  12896. // that satisfied the search criteria.
  12897. IsTruncated *bool `type:"boolean"`
  12898. // KeyCount is the number of keys returned with this request. KeyCount will
  12899. // always be less than equals to MaxKeys field. Say you ask for 50 keys, your
  12900. // result will include less than equals 50 keys
  12901. KeyCount *int64 `type:"integer"`
  12902. // Sets the maximum number of keys returned in the response. The response might
  12903. // contain fewer keys but will never contain more.
  12904. MaxKeys *int64 `type:"integer"`
  12905. // Name of the bucket to list.
  12906. Name *string `type:"string"`
  12907. // NextContinuationToken is sent when isTruncated is true which means there
  12908. // are more keys in the bucket that can be listed. The next list requests to
  12909. // Amazon S3 can be continued with this NextContinuationToken. NextContinuationToken
  12910. // is obfuscated and is not a real key
  12911. NextContinuationToken *string `type:"string"`
  12912. // Limits the response to keys that begin with the specified prefix.
  12913. Prefix *string `type:"string"`
  12914. // StartAfter is where you want Amazon S3 to start listing from. Amazon S3 starts
  12915. // listing after this specified key. StartAfter can be any key in the bucket
  12916. StartAfter *string `type:"string"`
  12917. }
  12918. // String returns the string representation
  12919. func (s ListObjectsV2Output) String() string {
  12920. return awsutil.Prettify(s)
  12921. }
  12922. // GoString returns the string representation
  12923. func (s ListObjectsV2Output) GoString() string {
  12924. return s.String()
  12925. }
  12926. // SetCommonPrefixes sets the CommonPrefixes field's value.
  12927. func (s *ListObjectsV2Output) SetCommonPrefixes(v []*CommonPrefix) *ListObjectsV2Output {
  12928. s.CommonPrefixes = v
  12929. return s
  12930. }
  12931. // SetContents sets the Contents field's value.
  12932. func (s *ListObjectsV2Output) SetContents(v []*Object) *ListObjectsV2Output {
  12933. s.Contents = v
  12934. return s
  12935. }
  12936. // SetContinuationToken sets the ContinuationToken field's value.
  12937. func (s *ListObjectsV2Output) SetContinuationToken(v string) *ListObjectsV2Output {
  12938. s.ContinuationToken = &v
  12939. return s
  12940. }
  12941. // SetDelimiter sets the Delimiter field's value.
  12942. func (s *ListObjectsV2Output) SetDelimiter(v string) *ListObjectsV2Output {
  12943. s.Delimiter = &v
  12944. return s
  12945. }
  12946. // SetEncodingType sets the EncodingType field's value.
  12947. func (s *ListObjectsV2Output) SetEncodingType(v string) *ListObjectsV2Output {
  12948. s.EncodingType = &v
  12949. return s
  12950. }
  12951. // SetIsTruncated sets the IsTruncated field's value.
  12952. func (s *ListObjectsV2Output) SetIsTruncated(v bool) *ListObjectsV2Output {
  12953. s.IsTruncated = &v
  12954. return s
  12955. }
  12956. // SetKeyCount sets the KeyCount field's value.
  12957. func (s *ListObjectsV2Output) SetKeyCount(v int64) *ListObjectsV2Output {
  12958. s.KeyCount = &v
  12959. return s
  12960. }
  12961. // SetMaxKeys sets the MaxKeys field's value.
  12962. func (s *ListObjectsV2Output) SetMaxKeys(v int64) *ListObjectsV2Output {
  12963. s.MaxKeys = &v
  12964. return s
  12965. }
  12966. // SetName sets the Name field's value.
  12967. func (s *ListObjectsV2Output) SetName(v string) *ListObjectsV2Output {
  12968. s.Name = &v
  12969. return s
  12970. }
  12971. // SetNextContinuationToken sets the NextContinuationToken field's value.
  12972. func (s *ListObjectsV2Output) SetNextContinuationToken(v string) *ListObjectsV2Output {
  12973. s.NextContinuationToken = &v
  12974. return s
  12975. }
  12976. // SetPrefix sets the Prefix field's value.
  12977. func (s *ListObjectsV2Output) SetPrefix(v string) *ListObjectsV2Output {
  12978. s.Prefix = &v
  12979. return s
  12980. }
  12981. // SetStartAfter sets the StartAfter field's value.
  12982. func (s *ListObjectsV2Output) SetStartAfter(v string) *ListObjectsV2Output {
  12983. s.StartAfter = &v
  12984. return s
  12985. }
  12986. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListPartsRequest
  12987. type ListPartsInput struct {
  12988. _ struct{} `type:"structure"`
  12989. // Bucket is a required field
  12990. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  12991. // Key is a required field
  12992. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  12993. // Sets the maximum number of parts to return.
  12994. MaxParts *int64 `location:"querystring" locationName:"max-parts" type:"integer"`
  12995. // Specifies the part after which listing should begin. Only parts with higher
  12996. // part numbers will be listed.
  12997. PartNumberMarker *int64 `location:"querystring" locationName:"part-number-marker" type:"integer"`
  12998. // Confirms that the requester knows that she or he will be charged for the
  12999. // request. Bucket owners need not specify this parameter in their requests.
  13000. // Documentation on downloading objects from requester pays buckets can be found
  13001. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  13002. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  13003. // Upload ID identifying the multipart upload whose parts are being listed.
  13004. //
  13005. // UploadId is a required field
  13006. UploadId *string `location:"querystring" locationName:"uploadId" type:"string" required:"true"`
  13007. }
  13008. // String returns the string representation
  13009. func (s ListPartsInput) String() string {
  13010. return awsutil.Prettify(s)
  13011. }
  13012. // GoString returns the string representation
  13013. func (s ListPartsInput) GoString() string {
  13014. return s.String()
  13015. }
  13016. // Validate inspects the fields of the type to determine if they are valid.
  13017. func (s *ListPartsInput) Validate() error {
  13018. invalidParams := request.ErrInvalidParams{Context: "ListPartsInput"}
  13019. if s.Bucket == nil {
  13020. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  13021. }
  13022. if s.Key == nil {
  13023. invalidParams.Add(request.NewErrParamRequired("Key"))
  13024. }
  13025. if s.Key != nil && len(*s.Key) < 1 {
  13026. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  13027. }
  13028. if s.UploadId == nil {
  13029. invalidParams.Add(request.NewErrParamRequired("UploadId"))
  13030. }
  13031. if invalidParams.Len() > 0 {
  13032. return invalidParams
  13033. }
  13034. return nil
  13035. }
  13036. // SetBucket sets the Bucket field's value.
  13037. func (s *ListPartsInput) SetBucket(v string) *ListPartsInput {
  13038. s.Bucket = &v
  13039. return s
  13040. }
  13041. func (s *ListPartsInput) getBucket() (v string) {
  13042. if s.Bucket == nil {
  13043. return v
  13044. }
  13045. return *s.Bucket
  13046. }
  13047. // SetKey sets the Key field's value.
  13048. func (s *ListPartsInput) SetKey(v string) *ListPartsInput {
  13049. s.Key = &v
  13050. return s
  13051. }
  13052. // SetMaxParts sets the MaxParts field's value.
  13053. func (s *ListPartsInput) SetMaxParts(v int64) *ListPartsInput {
  13054. s.MaxParts = &v
  13055. return s
  13056. }
  13057. // SetPartNumberMarker sets the PartNumberMarker field's value.
  13058. func (s *ListPartsInput) SetPartNumberMarker(v int64) *ListPartsInput {
  13059. s.PartNumberMarker = &v
  13060. return s
  13061. }
  13062. // SetRequestPayer sets the RequestPayer field's value.
  13063. func (s *ListPartsInput) SetRequestPayer(v string) *ListPartsInput {
  13064. s.RequestPayer = &v
  13065. return s
  13066. }
  13067. // SetUploadId sets the UploadId field's value.
  13068. func (s *ListPartsInput) SetUploadId(v string) *ListPartsInput {
  13069. s.UploadId = &v
  13070. return s
  13071. }
  13072. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ListPartsOutput
  13073. type ListPartsOutput struct {
  13074. _ struct{} `type:"structure"`
  13075. // Date when multipart upload will become eligible for abort operation by lifecycle.
  13076. AbortDate *time.Time `location:"header" locationName:"x-amz-abort-date" type:"timestamp" timestampFormat:"rfc822"`
  13077. // Id of the lifecycle rule that makes a multipart upload eligible for abort
  13078. // operation.
  13079. AbortRuleId *string `location:"header" locationName:"x-amz-abort-rule-id" type:"string"`
  13080. // Name of the bucket to which the multipart upload was initiated.
  13081. Bucket *string `type:"string"`
  13082. // Identifies who initiated the multipart upload.
  13083. Initiator *Initiator `type:"structure"`
  13084. // Indicates whether the returned list of parts is truncated.
  13085. IsTruncated *bool `type:"boolean"`
  13086. // Object key for which the multipart upload was initiated.
  13087. Key *string `min:"1" type:"string"`
  13088. // Maximum number of parts that were allowed in the response.
  13089. MaxParts *int64 `type:"integer"`
  13090. // When a list is truncated, this element specifies the last part in the list,
  13091. // as well as the value to use for the part-number-marker request parameter
  13092. // in a subsequent request.
  13093. NextPartNumberMarker *int64 `type:"integer"`
  13094. Owner *Owner `type:"structure"`
  13095. // Part number after which listing begins.
  13096. PartNumberMarker *int64 `type:"integer"`
  13097. Parts []*Part `locationName:"Part" type:"list" flattened:"true"`
  13098. // If present, indicates that the requester was successfully charged for the
  13099. // request.
  13100. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  13101. // The class of storage used to store the object.
  13102. StorageClass *string `type:"string" enum:"StorageClass"`
  13103. // Upload ID identifying the multipart upload whose parts are being listed.
  13104. UploadId *string `type:"string"`
  13105. }
  13106. // String returns the string representation
  13107. func (s ListPartsOutput) String() string {
  13108. return awsutil.Prettify(s)
  13109. }
  13110. // GoString returns the string representation
  13111. func (s ListPartsOutput) GoString() string {
  13112. return s.String()
  13113. }
  13114. // SetAbortDate sets the AbortDate field's value.
  13115. func (s *ListPartsOutput) SetAbortDate(v time.Time) *ListPartsOutput {
  13116. s.AbortDate = &v
  13117. return s
  13118. }
  13119. // SetAbortRuleId sets the AbortRuleId field's value.
  13120. func (s *ListPartsOutput) SetAbortRuleId(v string) *ListPartsOutput {
  13121. s.AbortRuleId = &v
  13122. return s
  13123. }
  13124. // SetBucket sets the Bucket field's value.
  13125. func (s *ListPartsOutput) SetBucket(v string) *ListPartsOutput {
  13126. s.Bucket = &v
  13127. return s
  13128. }
  13129. func (s *ListPartsOutput) getBucket() (v string) {
  13130. if s.Bucket == nil {
  13131. return v
  13132. }
  13133. return *s.Bucket
  13134. }
  13135. // SetInitiator sets the Initiator field's value.
  13136. func (s *ListPartsOutput) SetInitiator(v *Initiator) *ListPartsOutput {
  13137. s.Initiator = v
  13138. return s
  13139. }
  13140. // SetIsTruncated sets the IsTruncated field's value.
  13141. func (s *ListPartsOutput) SetIsTruncated(v bool) *ListPartsOutput {
  13142. s.IsTruncated = &v
  13143. return s
  13144. }
  13145. // SetKey sets the Key field's value.
  13146. func (s *ListPartsOutput) SetKey(v string) *ListPartsOutput {
  13147. s.Key = &v
  13148. return s
  13149. }
  13150. // SetMaxParts sets the MaxParts field's value.
  13151. func (s *ListPartsOutput) SetMaxParts(v int64) *ListPartsOutput {
  13152. s.MaxParts = &v
  13153. return s
  13154. }
  13155. // SetNextPartNumberMarker sets the NextPartNumberMarker field's value.
  13156. func (s *ListPartsOutput) SetNextPartNumberMarker(v int64) *ListPartsOutput {
  13157. s.NextPartNumberMarker = &v
  13158. return s
  13159. }
  13160. // SetOwner sets the Owner field's value.
  13161. func (s *ListPartsOutput) SetOwner(v *Owner) *ListPartsOutput {
  13162. s.Owner = v
  13163. return s
  13164. }
  13165. // SetPartNumberMarker sets the PartNumberMarker field's value.
  13166. func (s *ListPartsOutput) SetPartNumberMarker(v int64) *ListPartsOutput {
  13167. s.PartNumberMarker = &v
  13168. return s
  13169. }
  13170. // SetParts sets the Parts field's value.
  13171. func (s *ListPartsOutput) SetParts(v []*Part) *ListPartsOutput {
  13172. s.Parts = v
  13173. return s
  13174. }
  13175. // SetRequestCharged sets the RequestCharged field's value.
  13176. func (s *ListPartsOutput) SetRequestCharged(v string) *ListPartsOutput {
  13177. s.RequestCharged = &v
  13178. return s
  13179. }
  13180. // SetStorageClass sets the StorageClass field's value.
  13181. func (s *ListPartsOutput) SetStorageClass(v string) *ListPartsOutput {
  13182. s.StorageClass = &v
  13183. return s
  13184. }
  13185. // SetUploadId sets the UploadId field's value.
  13186. func (s *ListPartsOutput) SetUploadId(v string) *ListPartsOutput {
  13187. s.UploadId = &v
  13188. return s
  13189. }
  13190. // Describes an S3 location that will receive the results of the restore request.
  13191. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/S3Location
  13192. type Location struct {
  13193. _ struct{} `type:"structure"`
  13194. // A list of grants that control access to the staged results.
  13195. AccessControlList []*Grant `locationNameList:"Grant" type:"list"`
  13196. // The name of the bucket where the restore results will be placed.
  13197. //
  13198. // BucketName is a required field
  13199. BucketName *string `type:"string" required:"true"`
  13200. // The canned ACL to apply to the restore results.
  13201. CannedACL *string `type:"string" enum:"ObjectCannedACL"`
  13202. // Describes the server-side encryption that will be applied to the restore
  13203. // results.
  13204. Encryption *Encryption `type:"structure"`
  13205. // The prefix that is prepended to the restore results for this request.
  13206. //
  13207. // Prefix is a required field
  13208. Prefix *string `type:"string" required:"true"`
  13209. // The class of storage used to store the restore results.
  13210. StorageClass *string `type:"string" enum:"StorageClass"`
  13211. // The tag-set that is applied to the restore results.
  13212. Tagging *Tagging `type:"structure"`
  13213. // A list of metadata to store with the restore results in S3.
  13214. UserMetadata []*MetadataEntry `locationNameList:"MetadataEntry" type:"list"`
  13215. }
  13216. // String returns the string representation
  13217. func (s Location) String() string {
  13218. return awsutil.Prettify(s)
  13219. }
  13220. // GoString returns the string representation
  13221. func (s Location) GoString() string {
  13222. return s.String()
  13223. }
  13224. // Validate inspects the fields of the type to determine if they are valid.
  13225. func (s *Location) Validate() error {
  13226. invalidParams := request.ErrInvalidParams{Context: "Location"}
  13227. if s.BucketName == nil {
  13228. invalidParams.Add(request.NewErrParamRequired("BucketName"))
  13229. }
  13230. if s.Prefix == nil {
  13231. invalidParams.Add(request.NewErrParamRequired("Prefix"))
  13232. }
  13233. if s.AccessControlList != nil {
  13234. for i, v := range s.AccessControlList {
  13235. if v == nil {
  13236. continue
  13237. }
  13238. if err := v.Validate(); err != nil {
  13239. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "AccessControlList", i), err.(request.ErrInvalidParams))
  13240. }
  13241. }
  13242. }
  13243. if s.Encryption != nil {
  13244. if err := s.Encryption.Validate(); err != nil {
  13245. invalidParams.AddNested("Encryption", err.(request.ErrInvalidParams))
  13246. }
  13247. }
  13248. if s.Tagging != nil {
  13249. if err := s.Tagging.Validate(); err != nil {
  13250. invalidParams.AddNested("Tagging", err.(request.ErrInvalidParams))
  13251. }
  13252. }
  13253. if invalidParams.Len() > 0 {
  13254. return invalidParams
  13255. }
  13256. return nil
  13257. }
  13258. // SetAccessControlList sets the AccessControlList field's value.
  13259. func (s *Location) SetAccessControlList(v []*Grant) *Location {
  13260. s.AccessControlList = v
  13261. return s
  13262. }
  13263. // SetBucketName sets the BucketName field's value.
  13264. func (s *Location) SetBucketName(v string) *Location {
  13265. s.BucketName = &v
  13266. return s
  13267. }
  13268. // SetCannedACL sets the CannedACL field's value.
  13269. func (s *Location) SetCannedACL(v string) *Location {
  13270. s.CannedACL = &v
  13271. return s
  13272. }
  13273. // SetEncryption sets the Encryption field's value.
  13274. func (s *Location) SetEncryption(v *Encryption) *Location {
  13275. s.Encryption = v
  13276. return s
  13277. }
  13278. // SetPrefix sets the Prefix field's value.
  13279. func (s *Location) SetPrefix(v string) *Location {
  13280. s.Prefix = &v
  13281. return s
  13282. }
  13283. // SetStorageClass sets the StorageClass field's value.
  13284. func (s *Location) SetStorageClass(v string) *Location {
  13285. s.StorageClass = &v
  13286. return s
  13287. }
  13288. // SetTagging sets the Tagging field's value.
  13289. func (s *Location) SetTagging(v *Tagging) *Location {
  13290. s.Tagging = v
  13291. return s
  13292. }
  13293. // SetUserMetadata sets the UserMetadata field's value.
  13294. func (s *Location) SetUserMetadata(v []*MetadataEntry) *Location {
  13295. s.UserMetadata = v
  13296. return s
  13297. }
  13298. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/LoggingEnabled
  13299. type LoggingEnabled struct {
  13300. _ struct{} `type:"structure"`
  13301. // Specifies the bucket where you want Amazon S3 to store server access logs.
  13302. // You can have your logs delivered to any bucket that you own, including the
  13303. // same bucket that is being logged. You can also configure multiple buckets
  13304. // to deliver their logs to the same target bucket. In this case you should
  13305. // choose a different TargetPrefix for each source bucket so that the delivered
  13306. // log files can be distinguished by key.
  13307. TargetBucket *string `type:"string"`
  13308. TargetGrants []*TargetGrant `locationNameList:"Grant" type:"list"`
  13309. // This element lets you specify a prefix for the keys that the log files will
  13310. // be stored under.
  13311. TargetPrefix *string `type:"string"`
  13312. }
  13313. // String returns the string representation
  13314. func (s LoggingEnabled) String() string {
  13315. return awsutil.Prettify(s)
  13316. }
  13317. // GoString returns the string representation
  13318. func (s LoggingEnabled) GoString() string {
  13319. return s.String()
  13320. }
  13321. // Validate inspects the fields of the type to determine if they are valid.
  13322. func (s *LoggingEnabled) Validate() error {
  13323. invalidParams := request.ErrInvalidParams{Context: "LoggingEnabled"}
  13324. if s.TargetGrants != nil {
  13325. for i, v := range s.TargetGrants {
  13326. if v == nil {
  13327. continue
  13328. }
  13329. if err := v.Validate(); err != nil {
  13330. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TargetGrants", i), err.(request.ErrInvalidParams))
  13331. }
  13332. }
  13333. }
  13334. if invalidParams.Len() > 0 {
  13335. return invalidParams
  13336. }
  13337. return nil
  13338. }
  13339. // SetTargetBucket sets the TargetBucket field's value.
  13340. func (s *LoggingEnabled) SetTargetBucket(v string) *LoggingEnabled {
  13341. s.TargetBucket = &v
  13342. return s
  13343. }
  13344. // SetTargetGrants sets the TargetGrants field's value.
  13345. func (s *LoggingEnabled) SetTargetGrants(v []*TargetGrant) *LoggingEnabled {
  13346. s.TargetGrants = v
  13347. return s
  13348. }
  13349. // SetTargetPrefix sets the TargetPrefix field's value.
  13350. func (s *LoggingEnabled) SetTargetPrefix(v string) *LoggingEnabled {
  13351. s.TargetPrefix = &v
  13352. return s
  13353. }
  13354. // A metadata key-value pair to store with an object.
  13355. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetadataEntry
  13356. type MetadataEntry struct {
  13357. _ struct{} `type:"structure"`
  13358. Name *string `type:"string"`
  13359. Value *string `type:"string"`
  13360. }
  13361. // String returns the string representation
  13362. func (s MetadataEntry) String() string {
  13363. return awsutil.Prettify(s)
  13364. }
  13365. // GoString returns the string representation
  13366. func (s MetadataEntry) GoString() string {
  13367. return s.String()
  13368. }
  13369. // SetName sets the Name field's value.
  13370. func (s *MetadataEntry) SetName(v string) *MetadataEntry {
  13371. s.Name = &v
  13372. return s
  13373. }
  13374. // SetValue sets the Value field's value.
  13375. func (s *MetadataEntry) SetValue(v string) *MetadataEntry {
  13376. s.Value = &v
  13377. return s
  13378. }
  13379. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsAndOperator
  13380. type MetricsAndOperator struct {
  13381. _ struct{} `type:"structure"`
  13382. // The prefix used when evaluating an AND predicate.
  13383. Prefix *string `type:"string"`
  13384. // The list of tags used when evaluating an AND predicate.
  13385. Tags []*Tag `locationName:"Tag" locationNameList:"Tag" type:"list" flattened:"true"`
  13386. }
  13387. // String returns the string representation
  13388. func (s MetricsAndOperator) String() string {
  13389. return awsutil.Prettify(s)
  13390. }
  13391. // GoString returns the string representation
  13392. func (s MetricsAndOperator) GoString() string {
  13393. return s.String()
  13394. }
  13395. // Validate inspects the fields of the type to determine if they are valid.
  13396. func (s *MetricsAndOperator) Validate() error {
  13397. invalidParams := request.ErrInvalidParams{Context: "MetricsAndOperator"}
  13398. if s.Tags != nil {
  13399. for i, v := range s.Tags {
  13400. if v == nil {
  13401. continue
  13402. }
  13403. if err := v.Validate(); err != nil {
  13404. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams))
  13405. }
  13406. }
  13407. }
  13408. if invalidParams.Len() > 0 {
  13409. return invalidParams
  13410. }
  13411. return nil
  13412. }
  13413. // SetPrefix sets the Prefix field's value.
  13414. func (s *MetricsAndOperator) SetPrefix(v string) *MetricsAndOperator {
  13415. s.Prefix = &v
  13416. return s
  13417. }
  13418. // SetTags sets the Tags field's value.
  13419. func (s *MetricsAndOperator) SetTags(v []*Tag) *MetricsAndOperator {
  13420. s.Tags = v
  13421. return s
  13422. }
  13423. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsConfiguration
  13424. type MetricsConfiguration struct {
  13425. _ struct{} `type:"structure"`
  13426. // Specifies a metrics configuration filter. The metrics configuration will
  13427. // only include objects that meet the filter's criteria. A filter must be a
  13428. // prefix, a tag, or a conjunction (MetricsAndOperator).
  13429. Filter *MetricsFilter `type:"structure"`
  13430. // The ID used to identify the metrics configuration.
  13431. //
  13432. // Id is a required field
  13433. Id *string `type:"string" required:"true"`
  13434. }
  13435. // String returns the string representation
  13436. func (s MetricsConfiguration) String() string {
  13437. return awsutil.Prettify(s)
  13438. }
  13439. // GoString returns the string representation
  13440. func (s MetricsConfiguration) GoString() string {
  13441. return s.String()
  13442. }
  13443. // Validate inspects the fields of the type to determine if they are valid.
  13444. func (s *MetricsConfiguration) Validate() error {
  13445. invalidParams := request.ErrInvalidParams{Context: "MetricsConfiguration"}
  13446. if s.Id == nil {
  13447. invalidParams.Add(request.NewErrParamRequired("Id"))
  13448. }
  13449. if s.Filter != nil {
  13450. if err := s.Filter.Validate(); err != nil {
  13451. invalidParams.AddNested("Filter", err.(request.ErrInvalidParams))
  13452. }
  13453. }
  13454. if invalidParams.Len() > 0 {
  13455. return invalidParams
  13456. }
  13457. return nil
  13458. }
  13459. // SetFilter sets the Filter field's value.
  13460. func (s *MetricsConfiguration) SetFilter(v *MetricsFilter) *MetricsConfiguration {
  13461. s.Filter = v
  13462. return s
  13463. }
  13464. // SetId sets the Id field's value.
  13465. func (s *MetricsConfiguration) SetId(v string) *MetricsConfiguration {
  13466. s.Id = &v
  13467. return s
  13468. }
  13469. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MetricsFilter
  13470. type MetricsFilter struct {
  13471. _ struct{} `type:"structure"`
  13472. // A conjunction (logical AND) of predicates, which is used in evaluating a
  13473. // metrics filter. The operator must have at least two predicates, and an object
  13474. // must match all of the predicates in order for the filter to apply.
  13475. And *MetricsAndOperator `type:"structure"`
  13476. // The prefix used when evaluating a metrics filter.
  13477. Prefix *string `type:"string"`
  13478. // The tag used when evaluating a metrics filter.
  13479. Tag *Tag `type:"structure"`
  13480. }
  13481. // String returns the string representation
  13482. func (s MetricsFilter) String() string {
  13483. return awsutil.Prettify(s)
  13484. }
  13485. // GoString returns the string representation
  13486. func (s MetricsFilter) GoString() string {
  13487. return s.String()
  13488. }
  13489. // Validate inspects the fields of the type to determine if they are valid.
  13490. func (s *MetricsFilter) Validate() error {
  13491. invalidParams := request.ErrInvalidParams{Context: "MetricsFilter"}
  13492. if s.And != nil {
  13493. if err := s.And.Validate(); err != nil {
  13494. invalidParams.AddNested("And", err.(request.ErrInvalidParams))
  13495. }
  13496. }
  13497. if s.Tag != nil {
  13498. if err := s.Tag.Validate(); err != nil {
  13499. invalidParams.AddNested("Tag", err.(request.ErrInvalidParams))
  13500. }
  13501. }
  13502. if invalidParams.Len() > 0 {
  13503. return invalidParams
  13504. }
  13505. return nil
  13506. }
  13507. // SetAnd sets the And field's value.
  13508. func (s *MetricsFilter) SetAnd(v *MetricsAndOperator) *MetricsFilter {
  13509. s.And = v
  13510. return s
  13511. }
  13512. // SetPrefix sets the Prefix field's value.
  13513. func (s *MetricsFilter) SetPrefix(v string) *MetricsFilter {
  13514. s.Prefix = &v
  13515. return s
  13516. }
  13517. // SetTag sets the Tag field's value.
  13518. func (s *MetricsFilter) SetTag(v *Tag) *MetricsFilter {
  13519. s.Tag = v
  13520. return s
  13521. }
  13522. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/MultipartUpload
  13523. type MultipartUpload struct {
  13524. _ struct{} `type:"structure"`
  13525. // Date and time at which the multipart upload was initiated.
  13526. Initiated *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  13527. // Identifies who initiated the multipart upload.
  13528. Initiator *Initiator `type:"structure"`
  13529. // Key of the object for which the multipart upload was initiated.
  13530. Key *string `min:"1" type:"string"`
  13531. Owner *Owner `type:"structure"`
  13532. // The class of storage used to store the object.
  13533. StorageClass *string `type:"string" enum:"StorageClass"`
  13534. // Upload ID that identifies the multipart upload.
  13535. UploadId *string `type:"string"`
  13536. }
  13537. // String returns the string representation
  13538. func (s MultipartUpload) String() string {
  13539. return awsutil.Prettify(s)
  13540. }
  13541. // GoString returns the string representation
  13542. func (s MultipartUpload) GoString() string {
  13543. return s.String()
  13544. }
  13545. // SetInitiated sets the Initiated field's value.
  13546. func (s *MultipartUpload) SetInitiated(v time.Time) *MultipartUpload {
  13547. s.Initiated = &v
  13548. return s
  13549. }
  13550. // SetInitiator sets the Initiator field's value.
  13551. func (s *MultipartUpload) SetInitiator(v *Initiator) *MultipartUpload {
  13552. s.Initiator = v
  13553. return s
  13554. }
  13555. // SetKey sets the Key field's value.
  13556. func (s *MultipartUpload) SetKey(v string) *MultipartUpload {
  13557. s.Key = &v
  13558. return s
  13559. }
  13560. // SetOwner sets the Owner field's value.
  13561. func (s *MultipartUpload) SetOwner(v *Owner) *MultipartUpload {
  13562. s.Owner = v
  13563. return s
  13564. }
  13565. // SetStorageClass sets the StorageClass field's value.
  13566. func (s *MultipartUpload) SetStorageClass(v string) *MultipartUpload {
  13567. s.StorageClass = &v
  13568. return s
  13569. }
  13570. // SetUploadId sets the UploadId field's value.
  13571. func (s *MultipartUpload) SetUploadId(v string) *MultipartUpload {
  13572. s.UploadId = &v
  13573. return s
  13574. }
  13575. // Specifies when noncurrent object versions expire. Upon expiration, Amazon
  13576. // S3 permanently deletes the noncurrent object versions. You set this lifecycle
  13577. // configuration action on a bucket that has versioning enabled (or suspended)
  13578. // to request that Amazon S3 delete noncurrent object versions at a specific
  13579. // period in the object's lifetime.
  13580. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoncurrentVersionExpiration
  13581. type NoncurrentVersionExpiration struct {
  13582. _ struct{} `type:"structure"`
  13583. // Specifies the number of days an object is noncurrent before Amazon S3 can
  13584. // perform the associated action. For information about the noncurrent days
  13585. // calculations, see How Amazon S3 Calculates When an Object Became Noncurrent
  13586. // (http://docs.aws.amazon.com/AmazonS3/latest/dev/s3-access-control.html)
  13587. NoncurrentDays *int64 `type:"integer"`
  13588. }
  13589. // String returns the string representation
  13590. func (s NoncurrentVersionExpiration) String() string {
  13591. return awsutil.Prettify(s)
  13592. }
  13593. // GoString returns the string representation
  13594. func (s NoncurrentVersionExpiration) GoString() string {
  13595. return s.String()
  13596. }
  13597. // SetNoncurrentDays sets the NoncurrentDays field's value.
  13598. func (s *NoncurrentVersionExpiration) SetNoncurrentDays(v int64) *NoncurrentVersionExpiration {
  13599. s.NoncurrentDays = &v
  13600. return s
  13601. }
  13602. // Container for the transition rule that describes when noncurrent objects
  13603. // transition to the STANDARD_IA or GLACIER storage class. If your bucket is
  13604. // versioning-enabled (or versioning is suspended), you can set this action
  13605. // to request that Amazon S3 transition noncurrent object versions to the STANDARD_IA
  13606. // or GLACIER storage class at a specific period in the object's lifetime.
  13607. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NoncurrentVersionTransition
  13608. type NoncurrentVersionTransition struct {
  13609. _ struct{} `type:"structure"`
  13610. // Specifies the number of days an object is noncurrent before Amazon S3 can
  13611. // perform the associated action. For information about the noncurrent days
  13612. // calculations, see How Amazon S3 Calculates When an Object Became Noncurrent
  13613. // (http://docs.aws.amazon.com/AmazonS3/latest/dev/s3-access-control.html)
  13614. NoncurrentDays *int64 `type:"integer"`
  13615. // The class of storage used to store the object.
  13616. StorageClass *string `type:"string" enum:"TransitionStorageClass"`
  13617. }
  13618. // String returns the string representation
  13619. func (s NoncurrentVersionTransition) String() string {
  13620. return awsutil.Prettify(s)
  13621. }
  13622. // GoString returns the string representation
  13623. func (s NoncurrentVersionTransition) GoString() string {
  13624. return s.String()
  13625. }
  13626. // SetNoncurrentDays sets the NoncurrentDays field's value.
  13627. func (s *NoncurrentVersionTransition) SetNoncurrentDays(v int64) *NoncurrentVersionTransition {
  13628. s.NoncurrentDays = &v
  13629. return s
  13630. }
  13631. // SetStorageClass sets the StorageClass field's value.
  13632. func (s *NoncurrentVersionTransition) SetStorageClass(v string) *NoncurrentVersionTransition {
  13633. s.StorageClass = &v
  13634. return s
  13635. }
  13636. // Container for specifying the notification configuration of the bucket. If
  13637. // this element is empty, notifications are turned off on the bucket.
  13638. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfiguration
  13639. type NotificationConfiguration struct {
  13640. _ struct{} `type:"structure"`
  13641. LambdaFunctionConfigurations []*LambdaFunctionConfiguration `locationName:"CloudFunctionConfiguration" type:"list" flattened:"true"`
  13642. QueueConfigurations []*QueueConfiguration `locationName:"QueueConfiguration" type:"list" flattened:"true"`
  13643. TopicConfigurations []*TopicConfiguration `locationName:"TopicConfiguration" type:"list" flattened:"true"`
  13644. }
  13645. // String returns the string representation
  13646. func (s NotificationConfiguration) String() string {
  13647. return awsutil.Prettify(s)
  13648. }
  13649. // GoString returns the string representation
  13650. func (s NotificationConfiguration) GoString() string {
  13651. return s.String()
  13652. }
  13653. // Validate inspects the fields of the type to determine if they are valid.
  13654. func (s *NotificationConfiguration) Validate() error {
  13655. invalidParams := request.ErrInvalidParams{Context: "NotificationConfiguration"}
  13656. if s.LambdaFunctionConfigurations != nil {
  13657. for i, v := range s.LambdaFunctionConfigurations {
  13658. if v == nil {
  13659. continue
  13660. }
  13661. if err := v.Validate(); err != nil {
  13662. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "LambdaFunctionConfigurations", i), err.(request.ErrInvalidParams))
  13663. }
  13664. }
  13665. }
  13666. if s.QueueConfigurations != nil {
  13667. for i, v := range s.QueueConfigurations {
  13668. if v == nil {
  13669. continue
  13670. }
  13671. if err := v.Validate(); err != nil {
  13672. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "QueueConfigurations", i), err.(request.ErrInvalidParams))
  13673. }
  13674. }
  13675. }
  13676. if s.TopicConfigurations != nil {
  13677. for i, v := range s.TopicConfigurations {
  13678. if v == nil {
  13679. continue
  13680. }
  13681. if err := v.Validate(); err != nil {
  13682. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TopicConfigurations", i), err.(request.ErrInvalidParams))
  13683. }
  13684. }
  13685. }
  13686. if invalidParams.Len() > 0 {
  13687. return invalidParams
  13688. }
  13689. return nil
  13690. }
  13691. // SetLambdaFunctionConfigurations sets the LambdaFunctionConfigurations field's value.
  13692. func (s *NotificationConfiguration) SetLambdaFunctionConfigurations(v []*LambdaFunctionConfiguration) *NotificationConfiguration {
  13693. s.LambdaFunctionConfigurations = v
  13694. return s
  13695. }
  13696. // SetQueueConfigurations sets the QueueConfigurations field's value.
  13697. func (s *NotificationConfiguration) SetQueueConfigurations(v []*QueueConfiguration) *NotificationConfiguration {
  13698. s.QueueConfigurations = v
  13699. return s
  13700. }
  13701. // SetTopicConfigurations sets the TopicConfigurations field's value.
  13702. func (s *NotificationConfiguration) SetTopicConfigurations(v []*TopicConfiguration) *NotificationConfiguration {
  13703. s.TopicConfigurations = v
  13704. return s
  13705. }
  13706. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfigurationDeprecated
  13707. type NotificationConfigurationDeprecated struct {
  13708. _ struct{} `type:"structure"`
  13709. CloudFunctionConfiguration *CloudFunctionConfiguration `type:"structure"`
  13710. QueueConfiguration *QueueConfigurationDeprecated `type:"structure"`
  13711. TopicConfiguration *TopicConfigurationDeprecated `type:"structure"`
  13712. }
  13713. // String returns the string representation
  13714. func (s NotificationConfigurationDeprecated) String() string {
  13715. return awsutil.Prettify(s)
  13716. }
  13717. // GoString returns the string representation
  13718. func (s NotificationConfigurationDeprecated) GoString() string {
  13719. return s.String()
  13720. }
  13721. // SetCloudFunctionConfiguration sets the CloudFunctionConfiguration field's value.
  13722. func (s *NotificationConfigurationDeprecated) SetCloudFunctionConfiguration(v *CloudFunctionConfiguration) *NotificationConfigurationDeprecated {
  13723. s.CloudFunctionConfiguration = v
  13724. return s
  13725. }
  13726. // SetQueueConfiguration sets the QueueConfiguration field's value.
  13727. func (s *NotificationConfigurationDeprecated) SetQueueConfiguration(v *QueueConfigurationDeprecated) *NotificationConfigurationDeprecated {
  13728. s.QueueConfiguration = v
  13729. return s
  13730. }
  13731. // SetTopicConfiguration sets the TopicConfiguration field's value.
  13732. func (s *NotificationConfigurationDeprecated) SetTopicConfiguration(v *TopicConfigurationDeprecated) *NotificationConfigurationDeprecated {
  13733. s.TopicConfiguration = v
  13734. return s
  13735. }
  13736. // Container for object key name filtering rules. For information about key
  13737. // name filtering, go to Configuring Event Notifications (http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  13738. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/NotificationConfigurationFilter
  13739. type NotificationConfigurationFilter struct {
  13740. _ struct{} `type:"structure"`
  13741. // Container for object key name prefix and suffix filtering rules.
  13742. Key *KeyFilter `locationName:"S3Key" type:"structure"`
  13743. }
  13744. // String returns the string representation
  13745. func (s NotificationConfigurationFilter) String() string {
  13746. return awsutil.Prettify(s)
  13747. }
  13748. // GoString returns the string representation
  13749. func (s NotificationConfigurationFilter) GoString() string {
  13750. return s.String()
  13751. }
  13752. // SetKey sets the Key field's value.
  13753. func (s *NotificationConfigurationFilter) SetKey(v *KeyFilter) *NotificationConfigurationFilter {
  13754. s.Key = v
  13755. return s
  13756. }
  13757. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Object
  13758. type Object struct {
  13759. _ struct{} `type:"structure"`
  13760. ETag *string `type:"string"`
  13761. Key *string `min:"1" type:"string"`
  13762. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  13763. Owner *Owner `type:"structure"`
  13764. Size *int64 `type:"integer"`
  13765. // The class of storage used to store the object.
  13766. StorageClass *string `type:"string" enum:"ObjectStorageClass"`
  13767. }
  13768. // String returns the string representation
  13769. func (s Object) String() string {
  13770. return awsutil.Prettify(s)
  13771. }
  13772. // GoString returns the string representation
  13773. func (s Object) GoString() string {
  13774. return s.String()
  13775. }
  13776. // SetETag sets the ETag field's value.
  13777. func (s *Object) SetETag(v string) *Object {
  13778. s.ETag = &v
  13779. return s
  13780. }
  13781. // SetKey sets the Key field's value.
  13782. func (s *Object) SetKey(v string) *Object {
  13783. s.Key = &v
  13784. return s
  13785. }
  13786. // SetLastModified sets the LastModified field's value.
  13787. func (s *Object) SetLastModified(v time.Time) *Object {
  13788. s.LastModified = &v
  13789. return s
  13790. }
  13791. // SetOwner sets the Owner field's value.
  13792. func (s *Object) SetOwner(v *Owner) *Object {
  13793. s.Owner = v
  13794. return s
  13795. }
  13796. // SetSize sets the Size field's value.
  13797. func (s *Object) SetSize(v int64) *Object {
  13798. s.Size = &v
  13799. return s
  13800. }
  13801. // SetStorageClass sets the StorageClass field's value.
  13802. func (s *Object) SetStorageClass(v string) *Object {
  13803. s.StorageClass = &v
  13804. return s
  13805. }
  13806. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectIdentifier
  13807. type ObjectIdentifier struct {
  13808. _ struct{} `type:"structure"`
  13809. // Key name of the object to delete.
  13810. //
  13811. // Key is a required field
  13812. Key *string `min:"1" type:"string" required:"true"`
  13813. // VersionId for the specific version of the object to delete.
  13814. VersionId *string `type:"string"`
  13815. }
  13816. // String returns the string representation
  13817. func (s ObjectIdentifier) String() string {
  13818. return awsutil.Prettify(s)
  13819. }
  13820. // GoString returns the string representation
  13821. func (s ObjectIdentifier) GoString() string {
  13822. return s.String()
  13823. }
  13824. // Validate inspects the fields of the type to determine if they are valid.
  13825. func (s *ObjectIdentifier) Validate() error {
  13826. invalidParams := request.ErrInvalidParams{Context: "ObjectIdentifier"}
  13827. if s.Key == nil {
  13828. invalidParams.Add(request.NewErrParamRequired("Key"))
  13829. }
  13830. if s.Key != nil && len(*s.Key) < 1 {
  13831. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  13832. }
  13833. if invalidParams.Len() > 0 {
  13834. return invalidParams
  13835. }
  13836. return nil
  13837. }
  13838. // SetKey sets the Key field's value.
  13839. func (s *ObjectIdentifier) SetKey(v string) *ObjectIdentifier {
  13840. s.Key = &v
  13841. return s
  13842. }
  13843. // SetVersionId sets the VersionId field's value.
  13844. func (s *ObjectIdentifier) SetVersionId(v string) *ObjectIdentifier {
  13845. s.VersionId = &v
  13846. return s
  13847. }
  13848. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ObjectVersion
  13849. type ObjectVersion struct {
  13850. _ struct{} `type:"structure"`
  13851. ETag *string `type:"string"`
  13852. // Specifies whether the object is (true) or is not (false) the latest version
  13853. // of an object.
  13854. IsLatest *bool `type:"boolean"`
  13855. // The object key.
  13856. Key *string `min:"1" type:"string"`
  13857. // Date and time the object was last modified.
  13858. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  13859. Owner *Owner `type:"structure"`
  13860. // Size in bytes of the object.
  13861. Size *int64 `type:"integer"`
  13862. // The class of storage used to store the object.
  13863. StorageClass *string `type:"string" enum:"ObjectVersionStorageClass"`
  13864. // Version ID of an object.
  13865. VersionId *string `type:"string"`
  13866. }
  13867. // String returns the string representation
  13868. func (s ObjectVersion) String() string {
  13869. return awsutil.Prettify(s)
  13870. }
  13871. // GoString returns the string representation
  13872. func (s ObjectVersion) GoString() string {
  13873. return s.String()
  13874. }
  13875. // SetETag sets the ETag field's value.
  13876. func (s *ObjectVersion) SetETag(v string) *ObjectVersion {
  13877. s.ETag = &v
  13878. return s
  13879. }
  13880. // SetIsLatest sets the IsLatest field's value.
  13881. func (s *ObjectVersion) SetIsLatest(v bool) *ObjectVersion {
  13882. s.IsLatest = &v
  13883. return s
  13884. }
  13885. // SetKey sets the Key field's value.
  13886. func (s *ObjectVersion) SetKey(v string) *ObjectVersion {
  13887. s.Key = &v
  13888. return s
  13889. }
  13890. // SetLastModified sets the LastModified field's value.
  13891. func (s *ObjectVersion) SetLastModified(v time.Time) *ObjectVersion {
  13892. s.LastModified = &v
  13893. return s
  13894. }
  13895. // SetOwner sets the Owner field's value.
  13896. func (s *ObjectVersion) SetOwner(v *Owner) *ObjectVersion {
  13897. s.Owner = v
  13898. return s
  13899. }
  13900. // SetSize sets the Size field's value.
  13901. func (s *ObjectVersion) SetSize(v int64) *ObjectVersion {
  13902. s.Size = &v
  13903. return s
  13904. }
  13905. // SetStorageClass sets the StorageClass field's value.
  13906. func (s *ObjectVersion) SetStorageClass(v string) *ObjectVersion {
  13907. s.StorageClass = &v
  13908. return s
  13909. }
  13910. // SetVersionId sets the VersionId field's value.
  13911. func (s *ObjectVersion) SetVersionId(v string) *ObjectVersion {
  13912. s.VersionId = &v
  13913. return s
  13914. }
  13915. // Describes the location where the restore job's output is stored.
  13916. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OutputLocation
  13917. type OutputLocation struct {
  13918. _ struct{} `type:"structure"`
  13919. // Describes an S3 location that will receive the results of the restore request.
  13920. S3 *Location `type:"structure"`
  13921. }
  13922. // String returns the string representation
  13923. func (s OutputLocation) String() string {
  13924. return awsutil.Prettify(s)
  13925. }
  13926. // GoString returns the string representation
  13927. func (s OutputLocation) GoString() string {
  13928. return s.String()
  13929. }
  13930. // Validate inspects the fields of the type to determine if they are valid.
  13931. func (s *OutputLocation) Validate() error {
  13932. invalidParams := request.ErrInvalidParams{Context: "OutputLocation"}
  13933. if s.S3 != nil {
  13934. if err := s.S3.Validate(); err != nil {
  13935. invalidParams.AddNested("S3", err.(request.ErrInvalidParams))
  13936. }
  13937. }
  13938. if invalidParams.Len() > 0 {
  13939. return invalidParams
  13940. }
  13941. return nil
  13942. }
  13943. // SetS3 sets the S3 field's value.
  13944. func (s *OutputLocation) SetS3(v *Location) *OutputLocation {
  13945. s.S3 = v
  13946. return s
  13947. }
  13948. // Describes how results of the Select job are serialized.
  13949. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/OutputSerialization
  13950. type OutputSerialization struct {
  13951. _ struct{} `type:"structure"`
  13952. // Describes the serialization of CSV-encoded Select results.
  13953. CSV *CSVOutput `type:"structure"`
  13954. }
  13955. // String returns the string representation
  13956. func (s OutputSerialization) String() string {
  13957. return awsutil.Prettify(s)
  13958. }
  13959. // GoString returns the string representation
  13960. func (s OutputSerialization) GoString() string {
  13961. return s.String()
  13962. }
  13963. // SetCSV sets the CSV field's value.
  13964. func (s *OutputSerialization) SetCSV(v *CSVOutput) *OutputSerialization {
  13965. s.CSV = v
  13966. return s
  13967. }
  13968. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Owner
  13969. type Owner struct {
  13970. _ struct{} `type:"structure"`
  13971. DisplayName *string `type:"string"`
  13972. ID *string `type:"string"`
  13973. }
  13974. // String returns the string representation
  13975. func (s Owner) String() string {
  13976. return awsutil.Prettify(s)
  13977. }
  13978. // GoString returns the string representation
  13979. func (s Owner) GoString() string {
  13980. return s.String()
  13981. }
  13982. // SetDisplayName sets the DisplayName field's value.
  13983. func (s *Owner) SetDisplayName(v string) *Owner {
  13984. s.DisplayName = &v
  13985. return s
  13986. }
  13987. // SetID sets the ID field's value.
  13988. func (s *Owner) SetID(v string) *Owner {
  13989. s.ID = &v
  13990. return s
  13991. }
  13992. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Part
  13993. type Part struct {
  13994. _ struct{} `type:"structure"`
  13995. // Entity tag returned when the part was uploaded.
  13996. ETag *string `type:"string"`
  13997. // Date and time at which the part was uploaded.
  13998. LastModified *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  13999. // Part number identifying the part. This is a positive integer between 1 and
  14000. // 10,000.
  14001. PartNumber *int64 `type:"integer"`
  14002. // Size of the uploaded part data.
  14003. Size *int64 `type:"integer"`
  14004. }
  14005. // String returns the string representation
  14006. func (s Part) String() string {
  14007. return awsutil.Prettify(s)
  14008. }
  14009. // GoString returns the string representation
  14010. func (s Part) GoString() string {
  14011. return s.String()
  14012. }
  14013. // SetETag sets the ETag field's value.
  14014. func (s *Part) SetETag(v string) *Part {
  14015. s.ETag = &v
  14016. return s
  14017. }
  14018. // SetLastModified sets the LastModified field's value.
  14019. func (s *Part) SetLastModified(v time.Time) *Part {
  14020. s.LastModified = &v
  14021. return s
  14022. }
  14023. // SetPartNumber sets the PartNumber field's value.
  14024. func (s *Part) SetPartNumber(v int64) *Part {
  14025. s.PartNumber = &v
  14026. return s
  14027. }
  14028. // SetSize sets the Size field's value.
  14029. func (s *Part) SetSize(v int64) *Part {
  14030. s.Size = &v
  14031. return s
  14032. }
  14033. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfigurationRequest
  14034. type PutBucketAccelerateConfigurationInput struct {
  14035. _ struct{} `type:"structure" payload:"AccelerateConfiguration"`
  14036. // Specifies the Accelerate Configuration you want to set for the bucket.
  14037. //
  14038. // AccelerateConfiguration is a required field
  14039. AccelerateConfiguration *AccelerateConfiguration `locationName:"AccelerateConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14040. // Name of the bucket for which the accelerate configuration is set.
  14041. //
  14042. // Bucket is a required field
  14043. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14044. }
  14045. // String returns the string representation
  14046. func (s PutBucketAccelerateConfigurationInput) String() string {
  14047. return awsutil.Prettify(s)
  14048. }
  14049. // GoString returns the string representation
  14050. func (s PutBucketAccelerateConfigurationInput) GoString() string {
  14051. return s.String()
  14052. }
  14053. // Validate inspects the fields of the type to determine if they are valid.
  14054. func (s *PutBucketAccelerateConfigurationInput) Validate() error {
  14055. invalidParams := request.ErrInvalidParams{Context: "PutBucketAccelerateConfigurationInput"}
  14056. if s.AccelerateConfiguration == nil {
  14057. invalidParams.Add(request.NewErrParamRequired("AccelerateConfiguration"))
  14058. }
  14059. if s.Bucket == nil {
  14060. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14061. }
  14062. if invalidParams.Len() > 0 {
  14063. return invalidParams
  14064. }
  14065. return nil
  14066. }
  14067. // SetAccelerateConfiguration sets the AccelerateConfiguration field's value.
  14068. func (s *PutBucketAccelerateConfigurationInput) SetAccelerateConfiguration(v *AccelerateConfiguration) *PutBucketAccelerateConfigurationInput {
  14069. s.AccelerateConfiguration = v
  14070. return s
  14071. }
  14072. // SetBucket sets the Bucket field's value.
  14073. func (s *PutBucketAccelerateConfigurationInput) SetBucket(v string) *PutBucketAccelerateConfigurationInput {
  14074. s.Bucket = &v
  14075. return s
  14076. }
  14077. func (s *PutBucketAccelerateConfigurationInput) getBucket() (v string) {
  14078. if s.Bucket == nil {
  14079. return v
  14080. }
  14081. return *s.Bucket
  14082. }
  14083. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAccelerateConfigurationOutput
  14084. type PutBucketAccelerateConfigurationOutput struct {
  14085. _ struct{} `type:"structure"`
  14086. }
  14087. // String returns the string representation
  14088. func (s PutBucketAccelerateConfigurationOutput) String() string {
  14089. return awsutil.Prettify(s)
  14090. }
  14091. // GoString returns the string representation
  14092. func (s PutBucketAccelerateConfigurationOutput) GoString() string {
  14093. return s.String()
  14094. }
  14095. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAclRequest
  14096. type PutBucketAclInput struct {
  14097. _ struct{} `type:"structure" payload:"AccessControlPolicy"`
  14098. // The canned ACL to apply to the bucket.
  14099. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"BucketCannedACL"`
  14100. AccessControlPolicy *AccessControlPolicy `locationName:"AccessControlPolicy" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14101. // Bucket is a required field
  14102. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14103. // Allows grantee the read, write, read ACP, and write ACP permissions on the
  14104. // bucket.
  14105. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  14106. // Allows grantee to list the objects in the bucket.
  14107. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  14108. // Allows grantee to read the bucket ACL.
  14109. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  14110. // Allows grantee to create, overwrite, and delete any object in the bucket.
  14111. GrantWrite *string `location:"header" locationName:"x-amz-grant-write" type:"string"`
  14112. // Allows grantee to write the ACL for the applicable bucket.
  14113. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  14114. }
  14115. // String returns the string representation
  14116. func (s PutBucketAclInput) String() string {
  14117. return awsutil.Prettify(s)
  14118. }
  14119. // GoString returns the string representation
  14120. func (s PutBucketAclInput) GoString() string {
  14121. return s.String()
  14122. }
  14123. // Validate inspects the fields of the type to determine if they are valid.
  14124. func (s *PutBucketAclInput) Validate() error {
  14125. invalidParams := request.ErrInvalidParams{Context: "PutBucketAclInput"}
  14126. if s.Bucket == nil {
  14127. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14128. }
  14129. if s.AccessControlPolicy != nil {
  14130. if err := s.AccessControlPolicy.Validate(); err != nil {
  14131. invalidParams.AddNested("AccessControlPolicy", err.(request.ErrInvalidParams))
  14132. }
  14133. }
  14134. if invalidParams.Len() > 0 {
  14135. return invalidParams
  14136. }
  14137. return nil
  14138. }
  14139. // SetACL sets the ACL field's value.
  14140. func (s *PutBucketAclInput) SetACL(v string) *PutBucketAclInput {
  14141. s.ACL = &v
  14142. return s
  14143. }
  14144. // SetAccessControlPolicy sets the AccessControlPolicy field's value.
  14145. func (s *PutBucketAclInput) SetAccessControlPolicy(v *AccessControlPolicy) *PutBucketAclInput {
  14146. s.AccessControlPolicy = v
  14147. return s
  14148. }
  14149. // SetBucket sets the Bucket field's value.
  14150. func (s *PutBucketAclInput) SetBucket(v string) *PutBucketAclInput {
  14151. s.Bucket = &v
  14152. return s
  14153. }
  14154. func (s *PutBucketAclInput) getBucket() (v string) {
  14155. if s.Bucket == nil {
  14156. return v
  14157. }
  14158. return *s.Bucket
  14159. }
  14160. // SetGrantFullControl sets the GrantFullControl field's value.
  14161. func (s *PutBucketAclInput) SetGrantFullControl(v string) *PutBucketAclInput {
  14162. s.GrantFullControl = &v
  14163. return s
  14164. }
  14165. // SetGrantRead sets the GrantRead field's value.
  14166. func (s *PutBucketAclInput) SetGrantRead(v string) *PutBucketAclInput {
  14167. s.GrantRead = &v
  14168. return s
  14169. }
  14170. // SetGrantReadACP sets the GrantReadACP field's value.
  14171. func (s *PutBucketAclInput) SetGrantReadACP(v string) *PutBucketAclInput {
  14172. s.GrantReadACP = &v
  14173. return s
  14174. }
  14175. // SetGrantWrite sets the GrantWrite field's value.
  14176. func (s *PutBucketAclInput) SetGrantWrite(v string) *PutBucketAclInput {
  14177. s.GrantWrite = &v
  14178. return s
  14179. }
  14180. // SetGrantWriteACP sets the GrantWriteACP field's value.
  14181. func (s *PutBucketAclInput) SetGrantWriteACP(v string) *PutBucketAclInput {
  14182. s.GrantWriteACP = &v
  14183. return s
  14184. }
  14185. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAclOutput
  14186. type PutBucketAclOutput struct {
  14187. _ struct{} `type:"structure"`
  14188. }
  14189. // String returns the string representation
  14190. func (s PutBucketAclOutput) String() string {
  14191. return awsutil.Prettify(s)
  14192. }
  14193. // GoString returns the string representation
  14194. func (s PutBucketAclOutput) GoString() string {
  14195. return s.String()
  14196. }
  14197. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfigurationRequest
  14198. type PutBucketAnalyticsConfigurationInput struct {
  14199. _ struct{} `type:"structure" payload:"AnalyticsConfiguration"`
  14200. // The configuration and any analyses for the analytics filter.
  14201. //
  14202. // AnalyticsConfiguration is a required field
  14203. AnalyticsConfiguration *AnalyticsConfiguration `locationName:"AnalyticsConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14204. // The name of the bucket to which an analytics configuration is stored.
  14205. //
  14206. // Bucket is a required field
  14207. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14208. // The identifier used to represent an analytics configuration.
  14209. //
  14210. // Id is a required field
  14211. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  14212. }
  14213. // String returns the string representation
  14214. func (s PutBucketAnalyticsConfigurationInput) String() string {
  14215. return awsutil.Prettify(s)
  14216. }
  14217. // GoString returns the string representation
  14218. func (s PutBucketAnalyticsConfigurationInput) GoString() string {
  14219. return s.String()
  14220. }
  14221. // Validate inspects the fields of the type to determine if they are valid.
  14222. func (s *PutBucketAnalyticsConfigurationInput) Validate() error {
  14223. invalidParams := request.ErrInvalidParams{Context: "PutBucketAnalyticsConfigurationInput"}
  14224. if s.AnalyticsConfiguration == nil {
  14225. invalidParams.Add(request.NewErrParamRequired("AnalyticsConfiguration"))
  14226. }
  14227. if s.Bucket == nil {
  14228. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14229. }
  14230. if s.Id == nil {
  14231. invalidParams.Add(request.NewErrParamRequired("Id"))
  14232. }
  14233. if s.AnalyticsConfiguration != nil {
  14234. if err := s.AnalyticsConfiguration.Validate(); err != nil {
  14235. invalidParams.AddNested("AnalyticsConfiguration", err.(request.ErrInvalidParams))
  14236. }
  14237. }
  14238. if invalidParams.Len() > 0 {
  14239. return invalidParams
  14240. }
  14241. return nil
  14242. }
  14243. // SetAnalyticsConfiguration sets the AnalyticsConfiguration field's value.
  14244. func (s *PutBucketAnalyticsConfigurationInput) SetAnalyticsConfiguration(v *AnalyticsConfiguration) *PutBucketAnalyticsConfigurationInput {
  14245. s.AnalyticsConfiguration = v
  14246. return s
  14247. }
  14248. // SetBucket sets the Bucket field's value.
  14249. func (s *PutBucketAnalyticsConfigurationInput) SetBucket(v string) *PutBucketAnalyticsConfigurationInput {
  14250. s.Bucket = &v
  14251. return s
  14252. }
  14253. func (s *PutBucketAnalyticsConfigurationInput) getBucket() (v string) {
  14254. if s.Bucket == nil {
  14255. return v
  14256. }
  14257. return *s.Bucket
  14258. }
  14259. // SetId sets the Id field's value.
  14260. func (s *PutBucketAnalyticsConfigurationInput) SetId(v string) *PutBucketAnalyticsConfigurationInput {
  14261. s.Id = &v
  14262. return s
  14263. }
  14264. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketAnalyticsConfigurationOutput
  14265. type PutBucketAnalyticsConfigurationOutput struct {
  14266. _ struct{} `type:"structure"`
  14267. }
  14268. // String returns the string representation
  14269. func (s PutBucketAnalyticsConfigurationOutput) String() string {
  14270. return awsutil.Prettify(s)
  14271. }
  14272. // GoString returns the string representation
  14273. func (s PutBucketAnalyticsConfigurationOutput) GoString() string {
  14274. return s.String()
  14275. }
  14276. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCorsRequest
  14277. type PutBucketCorsInput struct {
  14278. _ struct{} `type:"structure" payload:"CORSConfiguration"`
  14279. // Bucket is a required field
  14280. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14281. // CORSConfiguration is a required field
  14282. CORSConfiguration *CORSConfiguration `locationName:"CORSConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14283. }
  14284. // String returns the string representation
  14285. func (s PutBucketCorsInput) String() string {
  14286. return awsutil.Prettify(s)
  14287. }
  14288. // GoString returns the string representation
  14289. func (s PutBucketCorsInput) GoString() string {
  14290. return s.String()
  14291. }
  14292. // Validate inspects the fields of the type to determine if they are valid.
  14293. func (s *PutBucketCorsInput) Validate() error {
  14294. invalidParams := request.ErrInvalidParams{Context: "PutBucketCorsInput"}
  14295. if s.Bucket == nil {
  14296. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14297. }
  14298. if s.CORSConfiguration == nil {
  14299. invalidParams.Add(request.NewErrParamRequired("CORSConfiguration"))
  14300. }
  14301. if s.CORSConfiguration != nil {
  14302. if err := s.CORSConfiguration.Validate(); err != nil {
  14303. invalidParams.AddNested("CORSConfiguration", err.(request.ErrInvalidParams))
  14304. }
  14305. }
  14306. if invalidParams.Len() > 0 {
  14307. return invalidParams
  14308. }
  14309. return nil
  14310. }
  14311. // SetBucket sets the Bucket field's value.
  14312. func (s *PutBucketCorsInput) SetBucket(v string) *PutBucketCorsInput {
  14313. s.Bucket = &v
  14314. return s
  14315. }
  14316. func (s *PutBucketCorsInput) getBucket() (v string) {
  14317. if s.Bucket == nil {
  14318. return v
  14319. }
  14320. return *s.Bucket
  14321. }
  14322. // SetCORSConfiguration sets the CORSConfiguration field's value.
  14323. func (s *PutBucketCorsInput) SetCORSConfiguration(v *CORSConfiguration) *PutBucketCorsInput {
  14324. s.CORSConfiguration = v
  14325. return s
  14326. }
  14327. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketCorsOutput
  14328. type PutBucketCorsOutput struct {
  14329. _ struct{} `type:"structure"`
  14330. }
  14331. // String returns the string representation
  14332. func (s PutBucketCorsOutput) String() string {
  14333. return awsutil.Prettify(s)
  14334. }
  14335. // GoString returns the string representation
  14336. func (s PutBucketCorsOutput) GoString() string {
  14337. return s.String()
  14338. }
  14339. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryptionRequest
  14340. type PutBucketEncryptionInput struct {
  14341. _ struct{} `type:"structure" payload:"ServerSideEncryptionConfiguration"`
  14342. // The name of the bucket for which the server-side encryption configuration
  14343. // is set.
  14344. //
  14345. // Bucket is a required field
  14346. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14347. // Container for server-side encryption configuration rules. Currently S3 supports
  14348. // one rule only.
  14349. //
  14350. // ServerSideEncryptionConfiguration is a required field
  14351. ServerSideEncryptionConfiguration *ServerSideEncryptionConfiguration `locationName:"ServerSideEncryptionConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14352. }
  14353. // String returns the string representation
  14354. func (s PutBucketEncryptionInput) String() string {
  14355. return awsutil.Prettify(s)
  14356. }
  14357. // GoString returns the string representation
  14358. func (s PutBucketEncryptionInput) GoString() string {
  14359. return s.String()
  14360. }
  14361. // Validate inspects the fields of the type to determine if they are valid.
  14362. func (s *PutBucketEncryptionInput) Validate() error {
  14363. invalidParams := request.ErrInvalidParams{Context: "PutBucketEncryptionInput"}
  14364. if s.Bucket == nil {
  14365. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14366. }
  14367. if s.ServerSideEncryptionConfiguration == nil {
  14368. invalidParams.Add(request.NewErrParamRequired("ServerSideEncryptionConfiguration"))
  14369. }
  14370. if s.ServerSideEncryptionConfiguration != nil {
  14371. if err := s.ServerSideEncryptionConfiguration.Validate(); err != nil {
  14372. invalidParams.AddNested("ServerSideEncryptionConfiguration", err.(request.ErrInvalidParams))
  14373. }
  14374. }
  14375. if invalidParams.Len() > 0 {
  14376. return invalidParams
  14377. }
  14378. return nil
  14379. }
  14380. // SetBucket sets the Bucket field's value.
  14381. func (s *PutBucketEncryptionInput) SetBucket(v string) *PutBucketEncryptionInput {
  14382. s.Bucket = &v
  14383. return s
  14384. }
  14385. func (s *PutBucketEncryptionInput) getBucket() (v string) {
  14386. if s.Bucket == nil {
  14387. return v
  14388. }
  14389. return *s.Bucket
  14390. }
  14391. // SetServerSideEncryptionConfiguration sets the ServerSideEncryptionConfiguration field's value.
  14392. func (s *PutBucketEncryptionInput) SetServerSideEncryptionConfiguration(v *ServerSideEncryptionConfiguration) *PutBucketEncryptionInput {
  14393. s.ServerSideEncryptionConfiguration = v
  14394. return s
  14395. }
  14396. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketEncryptionOutput
  14397. type PutBucketEncryptionOutput struct {
  14398. _ struct{} `type:"structure"`
  14399. }
  14400. // String returns the string representation
  14401. func (s PutBucketEncryptionOutput) String() string {
  14402. return awsutil.Prettify(s)
  14403. }
  14404. // GoString returns the string representation
  14405. func (s PutBucketEncryptionOutput) GoString() string {
  14406. return s.String()
  14407. }
  14408. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfigurationRequest
  14409. type PutBucketInventoryConfigurationInput struct {
  14410. _ struct{} `type:"structure" payload:"InventoryConfiguration"`
  14411. // The name of the bucket where the inventory configuration will be stored.
  14412. //
  14413. // Bucket is a required field
  14414. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14415. // The ID used to identify the inventory configuration.
  14416. //
  14417. // Id is a required field
  14418. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  14419. // Specifies the inventory configuration.
  14420. //
  14421. // InventoryConfiguration is a required field
  14422. InventoryConfiguration *InventoryConfiguration `locationName:"InventoryConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14423. }
  14424. // String returns the string representation
  14425. func (s PutBucketInventoryConfigurationInput) String() string {
  14426. return awsutil.Prettify(s)
  14427. }
  14428. // GoString returns the string representation
  14429. func (s PutBucketInventoryConfigurationInput) GoString() string {
  14430. return s.String()
  14431. }
  14432. // Validate inspects the fields of the type to determine if they are valid.
  14433. func (s *PutBucketInventoryConfigurationInput) Validate() error {
  14434. invalidParams := request.ErrInvalidParams{Context: "PutBucketInventoryConfigurationInput"}
  14435. if s.Bucket == nil {
  14436. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14437. }
  14438. if s.Id == nil {
  14439. invalidParams.Add(request.NewErrParamRequired("Id"))
  14440. }
  14441. if s.InventoryConfiguration == nil {
  14442. invalidParams.Add(request.NewErrParamRequired("InventoryConfiguration"))
  14443. }
  14444. if s.InventoryConfiguration != nil {
  14445. if err := s.InventoryConfiguration.Validate(); err != nil {
  14446. invalidParams.AddNested("InventoryConfiguration", err.(request.ErrInvalidParams))
  14447. }
  14448. }
  14449. if invalidParams.Len() > 0 {
  14450. return invalidParams
  14451. }
  14452. return nil
  14453. }
  14454. // SetBucket sets the Bucket field's value.
  14455. func (s *PutBucketInventoryConfigurationInput) SetBucket(v string) *PutBucketInventoryConfigurationInput {
  14456. s.Bucket = &v
  14457. return s
  14458. }
  14459. func (s *PutBucketInventoryConfigurationInput) getBucket() (v string) {
  14460. if s.Bucket == nil {
  14461. return v
  14462. }
  14463. return *s.Bucket
  14464. }
  14465. // SetId sets the Id field's value.
  14466. func (s *PutBucketInventoryConfigurationInput) SetId(v string) *PutBucketInventoryConfigurationInput {
  14467. s.Id = &v
  14468. return s
  14469. }
  14470. // SetInventoryConfiguration sets the InventoryConfiguration field's value.
  14471. func (s *PutBucketInventoryConfigurationInput) SetInventoryConfiguration(v *InventoryConfiguration) *PutBucketInventoryConfigurationInput {
  14472. s.InventoryConfiguration = v
  14473. return s
  14474. }
  14475. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketInventoryConfigurationOutput
  14476. type PutBucketInventoryConfigurationOutput struct {
  14477. _ struct{} `type:"structure"`
  14478. }
  14479. // String returns the string representation
  14480. func (s PutBucketInventoryConfigurationOutput) String() string {
  14481. return awsutil.Prettify(s)
  14482. }
  14483. // GoString returns the string representation
  14484. func (s PutBucketInventoryConfigurationOutput) GoString() string {
  14485. return s.String()
  14486. }
  14487. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfigurationRequest
  14488. type PutBucketLifecycleConfigurationInput struct {
  14489. _ struct{} `type:"structure" payload:"LifecycleConfiguration"`
  14490. // Bucket is a required field
  14491. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14492. LifecycleConfiguration *BucketLifecycleConfiguration `locationName:"LifecycleConfiguration" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14493. }
  14494. // String returns the string representation
  14495. func (s PutBucketLifecycleConfigurationInput) String() string {
  14496. return awsutil.Prettify(s)
  14497. }
  14498. // GoString returns the string representation
  14499. func (s PutBucketLifecycleConfigurationInput) GoString() string {
  14500. return s.String()
  14501. }
  14502. // Validate inspects the fields of the type to determine if they are valid.
  14503. func (s *PutBucketLifecycleConfigurationInput) Validate() error {
  14504. invalidParams := request.ErrInvalidParams{Context: "PutBucketLifecycleConfigurationInput"}
  14505. if s.Bucket == nil {
  14506. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14507. }
  14508. if s.LifecycleConfiguration != nil {
  14509. if err := s.LifecycleConfiguration.Validate(); err != nil {
  14510. invalidParams.AddNested("LifecycleConfiguration", err.(request.ErrInvalidParams))
  14511. }
  14512. }
  14513. if invalidParams.Len() > 0 {
  14514. return invalidParams
  14515. }
  14516. return nil
  14517. }
  14518. // SetBucket sets the Bucket field's value.
  14519. func (s *PutBucketLifecycleConfigurationInput) SetBucket(v string) *PutBucketLifecycleConfigurationInput {
  14520. s.Bucket = &v
  14521. return s
  14522. }
  14523. func (s *PutBucketLifecycleConfigurationInput) getBucket() (v string) {
  14524. if s.Bucket == nil {
  14525. return v
  14526. }
  14527. return *s.Bucket
  14528. }
  14529. // SetLifecycleConfiguration sets the LifecycleConfiguration field's value.
  14530. func (s *PutBucketLifecycleConfigurationInput) SetLifecycleConfiguration(v *BucketLifecycleConfiguration) *PutBucketLifecycleConfigurationInput {
  14531. s.LifecycleConfiguration = v
  14532. return s
  14533. }
  14534. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleConfigurationOutput
  14535. type PutBucketLifecycleConfigurationOutput struct {
  14536. _ struct{} `type:"structure"`
  14537. }
  14538. // String returns the string representation
  14539. func (s PutBucketLifecycleConfigurationOutput) String() string {
  14540. return awsutil.Prettify(s)
  14541. }
  14542. // GoString returns the string representation
  14543. func (s PutBucketLifecycleConfigurationOutput) GoString() string {
  14544. return s.String()
  14545. }
  14546. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleRequest
  14547. type PutBucketLifecycleInput struct {
  14548. _ struct{} `type:"structure" payload:"LifecycleConfiguration"`
  14549. // Bucket is a required field
  14550. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14551. LifecycleConfiguration *LifecycleConfiguration `locationName:"LifecycleConfiguration" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14552. }
  14553. // String returns the string representation
  14554. func (s PutBucketLifecycleInput) String() string {
  14555. return awsutil.Prettify(s)
  14556. }
  14557. // GoString returns the string representation
  14558. func (s PutBucketLifecycleInput) GoString() string {
  14559. return s.String()
  14560. }
  14561. // Validate inspects the fields of the type to determine if they are valid.
  14562. func (s *PutBucketLifecycleInput) Validate() error {
  14563. invalidParams := request.ErrInvalidParams{Context: "PutBucketLifecycleInput"}
  14564. if s.Bucket == nil {
  14565. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14566. }
  14567. if s.LifecycleConfiguration != nil {
  14568. if err := s.LifecycleConfiguration.Validate(); err != nil {
  14569. invalidParams.AddNested("LifecycleConfiguration", err.(request.ErrInvalidParams))
  14570. }
  14571. }
  14572. if invalidParams.Len() > 0 {
  14573. return invalidParams
  14574. }
  14575. return nil
  14576. }
  14577. // SetBucket sets the Bucket field's value.
  14578. func (s *PutBucketLifecycleInput) SetBucket(v string) *PutBucketLifecycleInput {
  14579. s.Bucket = &v
  14580. return s
  14581. }
  14582. func (s *PutBucketLifecycleInput) getBucket() (v string) {
  14583. if s.Bucket == nil {
  14584. return v
  14585. }
  14586. return *s.Bucket
  14587. }
  14588. // SetLifecycleConfiguration sets the LifecycleConfiguration field's value.
  14589. func (s *PutBucketLifecycleInput) SetLifecycleConfiguration(v *LifecycleConfiguration) *PutBucketLifecycleInput {
  14590. s.LifecycleConfiguration = v
  14591. return s
  14592. }
  14593. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLifecycleOutput
  14594. type PutBucketLifecycleOutput struct {
  14595. _ struct{} `type:"structure"`
  14596. }
  14597. // String returns the string representation
  14598. func (s PutBucketLifecycleOutput) String() string {
  14599. return awsutil.Prettify(s)
  14600. }
  14601. // GoString returns the string representation
  14602. func (s PutBucketLifecycleOutput) GoString() string {
  14603. return s.String()
  14604. }
  14605. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLoggingRequest
  14606. type PutBucketLoggingInput struct {
  14607. _ struct{} `type:"structure" payload:"BucketLoggingStatus"`
  14608. // Bucket is a required field
  14609. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14610. // BucketLoggingStatus is a required field
  14611. BucketLoggingStatus *BucketLoggingStatus `locationName:"BucketLoggingStatus" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14612. }
  14613. // String returns the string representation
  14614. func (s PutBucketLoggingInput) String() string {
  14615. return awsutil.Prettify(s)
  14616. }
  14617. // GoString returns the string representation
  14618. func (s PutBucketLoggingInput) GoString() string {
  14619. return s.String()
  14620. }
  14621. // Validate inspects the fields of the type to determine if they are valid.
  14622. func (s *PutBucketLoggingInput) Validate() error {
  14623. invalidParams := request.ErrInvalidParams{Context: "PutBucketLoggingInput"}
  14624. if s.Bucket == nil {
  14625. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14626. }
  14627. if s.BucketLoggingStatus == nil {
  14628. invalidParams.Add(request.NewErrParamRequired("BucketLoggingStatus"))
  14629. }
  14630. if s.BucketLoggingStatus != nil {
  14631. if err := s.BucketLoggingStatus.Validate(); err != nil {
  14632. invalidParams.AddNested("BucketLoggingStatus", err.(request.ErrInvalidParams))
  14633. }
  14634. }
  14635. if invalidParams.Len() > 0 {
  14636. return invalidParams
  14637. }
  14638. return nil
  14639. }
  14640. // SetBucket sets the Bucket field's value.
  14641. func (s *PutBucketLoggingInput) SetBucket(v string) *PutBucketLoggingInput {
  14642. s.Bucket = &v
  14643. return s
  14644. }
  14645. func (s *PutBucketLoggingInput) getBucket() (v string) {
  14646. if s.Bucket == nil {
  14647. return v
  14648. }
  14649. return *s.Bucket
  14650. }
  14651. // SetBucketLoggingStatus sets the BucketLoggingStatus field's value.
  14652. func (s *PutBucketLoggingInput) SetBucketLoggingStatus(v *BucketLoggingStatus) *PutBucketLoggingInput {
  14653. s.BucketLoggingStatus = v
  14654. return s
  14655. }
  14656. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketLoggingOutput
  14657. type PutBucketLoggingOutput struct {
  14658. _ struct{} `type:"structure"`
  14659. }
  14660. // String returns the string representation
  14661. func (s PutBucketLoggingOutput) String() string {
  14662. return awsutil.Prettify(s)
  14663. }
  14664. // GoString returns the string representation
  14665. func (s PutBucketLoggingOutput) GoString() string {
  14666. return s.String()
  14667. }
  14668. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfigurationRequest
  14669. type PutBucketMetricsConfigurationInput struct {
  14670. _ struct{} `type:"structure" payload:"MetricsConfiguration"`
  14671. // The name of the bucket for which the metrics configuration is set.
  14672. //
  14673. // Bucket is a required field
  14674. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14675. // The ID used to identify the metrics configuration.
  14676. //
  14677. // Id is a required field
  14678. Id *string `location:"querystring" locationName:"id" type:"string" required:"true"`
  14679. // Specifies the metrics configuration.
  14680. //
  14681. // MetricsConfiguration is a required field
  14682. MetricsConfiguration *MetricsConfiguration `locationName:"MetricsConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14683. }
  14684. // String returns the string representation
  14685. func (s PutBucketMetricsConfigurationInput) String() string {
  14686. return awsutil.Prettify(s)
  14687. }
  14688. // GoString returns the string representation
  14689. func (s PutBucketMetricsConfigurationInput) GoString() string {
  14690. return s.String()
  14691. }
  14692. // Validate inspects the fields of the type to determine if they are valid.
  14693. func (s *PutBucketMetricsConfigurationInput) Validate() error {
  14694. invalidParams := request.ErrInvalidParams{Context: "PutBucketMetricsConfigurationInput"}
  14695. if s.Bucket == nil {
  14696. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14697. }
  14698. if s.Id == nil {
  14699. invalidParams.Add(request.NewErrParamRequired("Id"))
  14700. }
  14701. if s.MetricsConfiguration == nil {
  14702. invalidParams.Add(request.NewErrParamRequired("MetricsConfiguration"))
  14703. }
  14704. if s.MetricsConfiguration != nil {
  14705. if err := s.MetricsConfiguration.Validate(); err != nil {
  14706. invalidParams.AddNested("MetricsConfiguration", err.(request.ErrInvalidParams))
  14707. }
  14708. }
  14709. if invalidParams.Len() > 0 {
  14710. return invalidParams
  14711. }
  14712. return nil
  14713. }
  14714. // SetBucket sets the Bucket field's value.
  14715. func (s *PutBucketMetricsConfigurationInput) SetBucket(v string) *PutBucketMetricsConfigurationInput {
  14716. s.Bucket = &v
  14717. return s
  14718. }
  14719. func (s *PutBucketMetricsConfigurationInput) getBucket() (v string) {
  14720. if s.Bucket == nil {
  14721. return v
  14722. }
  14723. return *s.Bucket
  14724. }
  14725. // SetId sets the Id field's value.
  14726. func (s *PutBucketMetricsConfigurationInput) SetId(v string) *PutBucketMetricsConfigurationInput {
  14727. s.Id = &v
  14728. return s
  14729. }
  14730. // SetMetricsConfiguration sets the MetricsConfiguration field's value.
  14731. func (s *PutBucketMetricsConfigurationInput) SetMetricsConfiguration(v *MetricsConfiguration) *PutBucketMetricsConfigurationInput {
  14732. s.MetricsConfiguration = v
  14733. return s
  14734. }
  14735. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketMetricsConfigurationOutput
  14736. type PutBucketMetricsConfigurationOutput struct {
  14737. _ struct{} `type:"structure"`
  14738. }
  14739. // String returns the string representation
  14740. func (s PutBucketMetricsConfigurationOutput) String() string {
  14741. return awsutil.Prettify(s)
  14742. }
  14743. // GoString returns the string representation
  14744. func (s PutBucketMetricsConfigurationOutput) GoString() string {
  14745. return s.String()
  14746. }
  14747. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfigurationRequest
  14748. type PutBucketNotificationConfigurationInput struct {
  14749. _ struct{} `type:"structure" payload:"NotificationConfiguration"`
  14750. // Bucket is a required field
  14751. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14752. // Container for specifying the notification configuration of the bucket. If
  14753. // this element is empty, notifications are turned off on the bucket.
  14754. //
  14755. // NotificationConfiguration is a required field
  14756. NotificationConfiguration *NotificationConfiguration `locationName:"NotificationConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14757. }
  14758. // String returns the string representation
  14759. func (s PutBucketNotificationConfigurationInput) String() string {
  14760. return awsutil.Prettify(s)
  14761. }
  14762. // GoString returns the string representation
  14763. func (s PutBucketNotificationConfigurationInput) GoString() string {
  14764. return s.String()
  14765. }
  14766. // Validate inspects the fields of the type to determine if they are valid.
  14767. func (s *PutBucketNotificationConfigurationInput) Validate() error {
  14768. invalidParams := request.ErrInvalidParams{Context: "PutBucketNotificationConfigurationInput"}
  14769. if s.Bucket == nil {
  14770. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14771. }
  14772. if s.NotificationConfiguration == nil {
  14773. invalidParams.Add(request.NewErrParamRequired("NotificationConfiguration"))
  14774. }
  14775. if s.NotificationConfiguration != nil {
  14776. if err := s.NotificationConfiguration.Validate(); err != nil {
  14777. invalidParams.AddNested("NotificationConfiguration", err.(request.ErrInvalidParams))
  14778. }
  14779. }
  14780. if invalidParams.Len() > 0 {
  14781. return invalidParams
  14782. }
  14783. return nil
  14784. }
  14785. // SetBucket sets the Bucket field's value.
  14786. func (s *PutBucketNotificationConfigurationInput) SetBucket(v string) *PutBucketNotificationConfigurationInput {
  14787. s.Bucket = &v
  14788. return s
  14789. }
  14790. func (s *PutBucketNotificationConfigurationInput) getBucket() (v string) {
  14791. if s.Bucket == nil {
  14792. return v
  14793. }
  14794. return *s.Bucket
  14795. }
  14796. // SetNotificationConfiguration sets the NotificationConfiguration field's value.
  14797. func (s *PutBucketNotificationConfigurationInput) SetNotificationConfiguration(v *NotificationConfiguration) *PutBucketNotificationConfigurationInput {
  14798. s.NotificationConfiguration = v
  14799. return s
  14800. }
  14801. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationConfigurationOutput
  14802. type PutBucketNotificationConfigurationOutput struct {
  14803. _ struct{} `type:"structure"`
  14804. }
  14805. // String returns the string representation
  14806. func (s PutBucketNotificationConfigurationOutput) String() string {
  14807. return awsutil.Prettify(s)
  14808. }
  14809. // GoString returns the string representation
  14810. func (s PutBucketNotificationConfigurationOutput) GoString() string {
  14811. return s.String()
  14812. }
  14813. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationRequest
  14814. type PutBucketNotificationInput struct {
  14815. _ struct{} `type:"structure" payload:"NotificationConfiguration"`
  14816. // Bucket is a required field
  14817. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14818. // NotificationConfiguration is a required field
  14819. NotificationConfiguration *NotificationConfigurationDeprecated `locationName:"NotificationConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14820. }
  14821. // String returns the string representation
  14822. func (s PutBucketNotificationInput) String() string {
  14823. return awsutil.Prettify(s)
  14824. }
  14825. // GoString returns the string representation
  14826. func (s PutBucketNotificationInput) GoString() string {
  14827. return s.String()
  14828. }
  14829. // Validate inspects the fields of the type to determine if they are valid.
  14830. func (s *PutBucketNotificationInput) Validate() error {
  14831. invalidParams := request.ErrInvalidParams{Context: "PutBucketNotificationInput"}
  14832. if s.Bucket == nil {
  14833. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14834. }
  14835. if s.NotificationConfiguration == nil {
  14836. invalidParams.Add(request.NewErrParamRequired("NotificationConfiguration"))
  14837. }
  14838. if invalidParams.Len() > 0 {
  14839. return invalidParams
  14840. }
  14841. return nil
  14842. }
  14843. // SetBucket sets the Bucket field's value.
  14844. func (s *PutBucketNotificationInput) SetBucket(v string) *PutBucketNotificationInput {
  14845. s.Bucket = &v
  14846. return s
  14847. }
  14848. func (s *PutBucketNotificationInput) getBucket() (v string) {
  14849. if s.Bucket == nil {
  14850. return v
  14851. }
  14852. return *s.Bucket
  14853. }
  14854. // SetNotificationConfiguration sets the NotificationConfiguration field's value.
  14855. func (s *PutBucketNotificationInput) SetNotificationConfiguration(v *NotificationConfigurationDeprecated) *PutBucketNotificationInput {
  14856. s.NotificationConfiguration = v
  14857. return s
  14858. }
  14859. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketNotificationOutput
  14860. type PutBucketNotificationOutput struct {
  14861. _ struct{} `type:"structure"`
  14862. }
  14863. // String returns the string representation
  14864. func (s PutBucketNotificationOutput) String() string {
  14865. return awsutil.Prettify(s)
  14866. }
  14867. // GoString returns the string representation
  14868. func (s PutBucketNotificationOutput) GoString() string {
  14869. return s.String()
  14870. }
  14871. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicyRequest
  14872. type PutBucketPolicyInput struct {
  14873. _ struct{} `type:"structure" payload:"Policy"`
  14874. // Bucket is a required field
  14875. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14876. // Set this parameter to true to confirm that you want to remove your permissions
  14877. // to change this bucket policy in the future.
  14878. ConfirmRemoveSelfBucketAccess *bool `location:"header" locationName:"x-amz-confirm-remove-self-bucket-access" type:"boolean"`
  14879. // The bucket policy as a JSON document.
  14880. //
  14881. // Policy is a required field
  14882. Policy *string `type:"string" required:"true"`
  14883. }
  14884. // String returns the string representation
  14885. func (s PutBucketPolicyInput) String() string {
  14886. return awsutil.Prettify(s)
  14887. }
  14888. // GoString returns the string representation
  14889. func (s PutBucketPolicyInput) GoString() string {
  14890. return s.String()
  14891. }
  14892. // Validate inspects the fields of the type to determine if they are valid.
  14893. func (s *PutBucketPolicyInput) Validate() error {
  14894. invalidParams := request.ErrInvalidParams{Context: "PutBucketPolicyInput"}
  14895. if s.Bucket == nil {
  14896. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14897. }
  14898. if s.Policy == nil {
  14899. invalidParams.Add(request.NewErrParamRequired("Policy"))
  14900. }
  14901. if invalidParams.Len() > 0 {
  14902. return invalidParams
  14903. }
  14904. return nil
  14905. }
  14906. // SetBucket sets the Bucket field's value.
  14907. func (s *PutBucketPolicyInput) SetBucket(v string) *PutBucketPolicyInput {
  14908. s.Bucket = &v
  14909. return s
  14910. }
  14911. func (s *PutBucketPolicyInput) getBucket() (v string) {
  14912. if s.Bucket == nil {
  14913. return v
  14914. }
  14915. return *s.Bucket
  14916. }
  14917. // SetConfirmRemoveSelfBucketAccess sets the ConfirmRemoveSelfBucketAccess field's value.
  14918. func (s *PutBucketPolicyInput) SetConfirmRemoveSelfBucketAccess(v bool) *PutBucketPolicyInput {
  14919. s.ConfirmRemoveSelfBucketAccess = &v
  14920. return s
  14921. }
  14922. // SetPolicy sets the Policy field's value.
  14923. func (s *PutBucketPolicyInput) SetPolicy(v string) *PutBucketPolicyInput {
  14924. s.Policy = &v
  14925. return s
  14926. }
  14927. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketPolicyOutput
  14928. type PutBucketPolicyOutput struct {
  14929. _ struct{} `type:"structure"`
  14930. }
  14931. // String returns the string representation
  14932. func (s PutBucketPolicyOutput) String() string {
  14933. return awsutil.Prettify(s)
  14934. }
  14935. // GoString returns the string representation
  14936. func (s PutBucketPolicyOutput) GoString() string {
  14937. return s.String()
  14938. }
  14939. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplicationRequest
  14940. type PutBucketReplicationInput struct {
  14941. _ struct{} `type:"structure" payload:"ReplicationConfiguration"`
  14942. // Bucket is a required field
  14943. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  14944. // Container for replication rules. You can add as many as 1,000 rules. Total
  14945. // replication configuration size can be up to 2 MB.
  14946. //
  14947. // ReplicationConfiguration is a required field
  14948. ReplicationConfiguration *ReplicationConfiguration `locationName:"ReplicationConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  14949. }
  14950. // String returns the string representation
  14951. func (s PutBucketReplicationInput) String() string {
  14952. return awsutil.Prettify(s)
  14953. }
  14954. // GoString returns the string representation
  14955. func (s PutBucketReplicationInput) GoString() string {
  14956. return s.String()
  14957. }
  14958. // Validate inspects the fields of the type to determine if they are valid.
  14959. func (s *PutBucketReplicationInput) Validate() error {
  14960. invalidParams := request.ErrInvalidParams{Context: "PutBucketReplicationInput"}
  14961. if s.Bucket == nil {
  14962. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  14963. }
  14964. if s.ReplicationConfiguration == nil {
  14965. invalidParams.Add(request.NewErrParamRequired("ReplicationConfiguration"))
  14966. }
  14967. if s.ReplicationConfiguration != nil {
  14968. if err := s.ReplicationConfiguration.Validate(); err != nil {
  14969. invalidParams.AddNested("ReplicationConfiguration", err.(request.ErrInvalidParams))
  14970. }
  14971. }
  14972. if invalidParams.Len() > 0 {
  14973. return invalidParams
  14974. }
  14975. return nil
  14976. }
  14977. // SetBucket sets the Bucket field's value.
  14978. func (s *PutBucketReplicationInput) SetBucket(v string) *PutBucketReplicationInput {
  14979. s.Bucket = &v
  14980. return s
  14981. }
  14982. func (s *PutBucketReplicationInput) getBucket() (v string) {
  14983. if s.Bucket == nil {
  14984. return v
  14985. }
  14986. return *s.Bucket
  14987. }
  14988. // SetReplicationConfiguration sets the ReplicationConfiguration field's value.
  14989. func (s *PutBucketReplicationInput) SetReplicationConfiguration(v *ReplicationConfiguration) *PutBucketReplicationInput {
  14990. s.ReplicationConfiguration = v
  14991. return s
  14992. }
  14993. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketReplicationOutput
  14994. type PutBucketReplicationOutput struct {
  14995. _ struct{} `type:"structure"`
  14996. }
  14997. // String returns the string representation
  14998. func (s PutBucketReplicationOutput) String() string {
  14999. return awsutil.Prettify(s)
  15000. }
  15001. // GoString returns the string representation
  15002. func (s PutBucketReplicationOutput) GoString() string {
  15003. return s.String()
  15004. }
  15005. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPaymentRequest
  15006. type PutBucketRequestPaymentInput struct {
  15007. _ struct{} `type:"structure" payload:"RequestPaymentConfiguration"`
  15008. // Bucket is a required field
  15009. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15010. // RequestPaymentConfiguration is a required field
  15011. RequestPaymentConfiguration *RequestPaymentConfiguration `locationName:"RequestPaymentConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15012. }
  15013. // String returns the string representation
  15014. func (s PutBucketRequestPaymentInput) String() string {
  15015. return awsutil.Prettify(s)
  15016. }
  15017. // GoString returns the string representation
  15018. func (s PutBucketRequestPaymentInput) GoString() string {
  15019. return s.String()
  15020. }
  15021. // Validate inspects the fields of the type to determine if they are valid.
  15022. func (s *PutBucketRequestPaymentInput) Validate() error {
  15023. invalidParams := request.ErrInvalidParams{Context: "PutBucketRequestPaymentInput"}
  15024. if s.Bucket == nil {
  15025. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15026. }
  15027. if s.RequestPaymentConfiguration == nil {
  15028. invalidParams.Add(request.NewErrParamRequired("RequestPaymentConfiguration"))
  15029. }
  15030. if s.RequestPaymentConfiguration != nil {
  15031. if err := s.RequestPaymentConfiguration.Validate(); err != nil {
  15032. invalidParams.AddNested("RequestPaymentConfiguration", err.(request.ErrInvalidParams))
  15033. }
  15034. }
  15035. if invalidParams.Len() > 0 {
  15036. return invalidParams
  15037. }
  15038. return nil
  15039. }
  15040. // SetBucket sets the Bucket field's value.
  15041. func (s *PutBucketRequestPaymentInput) SetBucket(v string) *PutBucketRequestPaymentInput {
  15042. s.Bucket = &v
  15043. return s
  15044. }
  15045. func (s *PutBucketRequestPaymentInput) getBucket() (v string) {
  15046. if s.Bucket == nil {
  15047. return v
  15048. }
  15049. return *s.Bucket
  15050. }
  15051. // SetRequestPaymentConfiguration sets the RequestPaymentConfiguration field's value.
  15052. func (s *PutBucketRequestPaymentInput) SetRequestPaymentConfiguration(v *RequestPaymentConfiguration) *PutBucketRequestPaymentInput {
  15053. s.RequestPaymentConfiguration = v
  15054. return s
  15055. }
  15056. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketRequestPaymentOutput
  15057. type PutBucketRequestPaymentOutput struct {
  15058. _ struct{} `type:"structure"`
  15059. }
  15060. // String returns the string representation
  15061. func (s PutBucketRequestPaymentOutput) String() string {
  15062. return awsutil.Prettify(s)
  15063. }
  15064. // GoString returns the string representation
  15065. func (s PutBucketRequestPaymentOutput) GoString() string {
  15066. return s.String()
  15067. }
  15068. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTaggingRequest
  15069. type PutBucketTaggingInput struct {
  15070. _ struct{} `type:"structure" payload:"Tagging"`
  15071. // Bucket is a required field
  15072. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15073. // Tagging is a required field
  15074. Tagging *Tagging `locationName:"Tagging" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15075. }
  15076. // String returns the string representation
  15077. func (s PutBucketTaggingInput) String() string {
  15078. return awsutil.Prettify(s)
  15079. }
  15080. // GoString returns the string representation
  15081. func (s PutBucketTaggingInput) GoString() string {
  15082. return s.String()
  15083. }
  15084. // Validate inspects the fields of the type to determine if they are valid.
  15085. func (s *PutBucketTaggingInput) Validate() error {
  15086. invalidParams := request.ErrInvalidParams{Context: "PutBucketTaggingInput"}
  15087. if s.Bucket == nil {
  15088. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15089. }
  15090. if s.Tagging == nil {
  15091. invalidParams.Add(request.NewErrParamRequired("Tagging"))
  15092. }
  15093. if s.Tagging != nil {
  15094. if err := s.Tagging.Validate(); err != nil {
  15095. invalidParams.AddNested("Tagging", err.(request.ErrInvalidParams))
  15096. }
  15097. }
  15098. if invalidParams.Len() > 0 {
  15099. return invalidParams
  15100. }
  15101. return nil
  15102. }
  15103. // SetBucket sets the Bucket field's value.
  15104. func (s *PutBucketTaggingInput) SetBucket(v string) *PutBucketTaggingInput {
  15105. s.Bucket = &v
  15106. return s
  15107. }
  15108. func (s *PutBucketTaggingInput) getBucket() (v string) {
  15109. if s.Bucket == nil {
  15110. return v
  15111. }
  15112. return *s.Bucket
  15113. }
  15114. // SetTagging sets the Tagging field's value.
  15115. func (s *PutBucketTaggingInput) SetTagging(v *Tagging) *PutBucketTaggingInput {
  15116. s.Tagging = v
  15117. return s
  15118. }
  15119. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketTaggingOutput
  15120. type PutBucketTaggingOutput struct {
  15121. _ struct{} `type:"structure"`
  15122. }
  15123. // String returns the string representation
  15124. func (s PutBucketTaggingOutput) String() string {
  15125. return awsutil.Prettify(s)
  15126. }
  15127. // GoString returns the string representation
  15128. func (s PutBucketTaggingOutput) GoString() string {
  15129. return s.String()
  15130. }
  15131. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioningRequest
  15132. type PutBucketVersioningInput struct {
  15133. _ struct{} `type:"structure" payload:"VersioningConfiguration"`
  15134. // Bucket is a required field
  15135. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15136. // The concatenation of the authentication device's serial number, a space,
  15137. // and the value that is displayed on your authentication device.
  15138. MFA *string `location:"header" locationName:"x-amz-mfa" type:"string"`
  15139. // VersioningConfiguration is a required field
  15140. VersioningConfiguration *VersioningConfiguration `locationName:"VersioningConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15141. }
  15142. // String returns the string representation
  15143. func (s PutBucketVersioningInput) String() string {
  15144. return awsutil.Prettify(s)
  15145. }
  15146. // GoString returns the string representation
  15147. func (s PutBucketVersioningInput) GoString() string {
  15148. return s.String()
  15149. }
  15150. // Validate inspects the fields of the type to determine if they are valid.
  15151. func (s *PutBucketVersioningInput) Validate() error {
  15152. invalidParams := request.ErrInvalidParams{Context: "PutBucketVersioningInput"}
  15153. if s.Bucket == nil {
  15154. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15155. }
  15156. if s.VersioningConfiguration == nil {
  15157. invalidParams.Add(request.NewErrParamRequired("VersioningConfiguration"))
  15158. }
  15159. if invalidParams.Len() > 0 {
  15160. return invalidParams
  15161. }
  15162. return nil
  15163. }
  15164. // SetBucket sets the Bucket field's value.
  15165. func (s *PutBucketVersioningInput) SetBucket(v string) *PutBucketVersioningInput {
  15166. s.Bucket = &v
  15167. return s
  15168. }
  15169. func (s *PutBucketVersioningInput) getBucket() (v string) {
  15170. if s.Bucket == nil {
  15171. return v
  15172. }
  15173. return *s.Bucket
  15174. }
  15175. // SetMFA sets the MFA field's value.
  15176. func (s *PutBucketVersioningInput) SetMFA(v string) *PutBucketVersioningInput {
  15177. s.MFA = &v
  15178. return s
  15179. }
  15180. // SetVersioningConfiguration sets the VersioningConfiguration field's value.
  15181. func (s *PutBucketVersioningInput) SetVersioningConfiguration(v *VersioningConfiguration) *PutBucketVersioningInput {
  15182. s.VersioningConfiguration = v
  15183. return s
  15184. }
  15185. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketVersioningOutput
  15186. type PutBucketVersioningOutput struct {
  15187. _ struct{} `type:"structure"`
  15188. }
  15189. // String returns the string representation
  15190. func (s PutBucketVersioningOutput) String() string {
  15191. return awsutil.Prettify(s)
  15192. }
  15193. // GoString returns the string representation
  15194. func (s PutBucketVersioningOutput) GoString() string {
  15195. return s.String()
  15196. }
  15197. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsiteRequest
  15198. type PutBucketWebsiteInput struct {
  15199. _ struct{} `type:"structure" payload:"WebsiteConfiguration"`
  15200. // Bucket is a required field
  15201. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15202. // WebsiteConfiguration is a required field
  15203. WebsiteConfiguration *WebsiteConfiguration `locationName:"WebsiteConfiguration" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15204. }
  15205. // String returns the string representation
  15206. func (s PutBucketWebsiteInput) String() string {
  15207. return awsutil.Prettify(s)
  15208. }
  15209. // GoString returns the string representation
  15210. func (s PutBucketWebsiteInput) GoString() string {
  15211. return s.String()
  15212. }
  15213. // Validate inspects the fields of the type to determine if they are valid.
  15214. func (s *PutBucketWebsiteInput) Validate() error {
  15215. invalidParams := request.ErrInvalidParams{Context: "PutBucketWebsiteInput"}
  15216. if s.Bucket == nil {
  15217. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15218. }
  15219. if s.WebsiteConfiguration == nil {
  15220. invalidParams.Add(request.NewErrParamRequired("WebsiteConfiguration"))
  15221. }
  15222. if s.WebsiteConfiguration != nil {
  15223. if err := s.WebsiteConfiguration.Validate(); err != nil {
  15224. invalidParams.AddNested("WebsiteConfiguration", err.(request.ErrInvalidParams))
  15225. }
  15226. }
  15227. if invalidParams.Len() > 0 {
  15228. return invalidParams
  15229. }
  15230. return nil
  15231. }
  15232. // SetBucket sets the Bucket field's value.
  15233. func (s *PutBucketWebsiteInput) SetBucket(v string) *PutBucketWebsiteInput {
  15234. s.Bucket = &v
  15235. return s
  15236. }
  15237. func (s *PutBucketWebsiteInput) getBucket() (v string) {
  15238. if s.Bucket == nil {
  15239. return v
  15240. }
  15241. return *s.Bucket
  15242. }
  15243. // SetWebsiteConfiguration sets the WebsiteConfiguration field's value.
  15244. func (s *PutBucketWebsiteInput) SetWebsiteConfiguration(v *WebsiteConfiguration) *PutBucketWebsiteInput {
  15245. s.WebsiteConfiguration = v
  15246. return s
  15247. }
  15248. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutBucketWebsiteOutput
  15249. type PutBucketWebsiteOutput struct {
  15250. _ struct{} `type:"structure"`
  15251. }
  15252. // String returns the string representation
  15253. func (s PutBucketWebsiteOutput) String() string {
  15254. return awsutil.Prettify(s)
  15255. }
  15256. // GoString returns the string representation
  15257. func (s PutBucketWebsiteOutput) GoString() string {
  15258. return s.String()
  15259. }
  15260. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAclRequest
  15261. type PutObjectAclInput struct {
  15262. _ struct{} `type:"structure" payload:"AccessControlPolicy"`
  15263. // The canned ACL to apply to the object.
  15264. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"ObjectCannedACL"`
  15265. AccessControlPolicy *AccessControlPolicy `locationName:"AccessControlPolicy" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15266. // Bucket is a required field
  15267. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15268. // Allows grantee the read, write, read ACP, and write ACP permissions on the
  15269. // bucket.
  15270. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  15271. // Allows grantee to list the objects in the bucket.
  15272. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  15273. // Allows grantee to read the bucket ACL.
  15274. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  15275. // Allows grantee to create, overwrite, and delete any object in the bucket.
  15276. GrantWrite *string `location:"header" locationName:"x-amz-grant-write" type:"string"`
  15277. // Allows grantee to write the ACL for the applicable bucket.
  15278. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  15279. // Key is a required field
  15280. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  15281. // Confirms that the requester knows that she or he will be charged for the
  15282. // request. Bucket owners need not specify this parameter in their requests.
  15283. // Documentation on downloading objects from requester pays buckets can be found
  15284. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  15285. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  15286. // VersionId used to reference a specific version of the object.
  15287. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  15288. }
  15289. // String returns the string representation
  15290. func (s PutObjectAclInput) String() string {
  15291. return awsutil.Prettify(s)
  15292. }
  15293. // GoString returns the string representation
  15294. func (s PutObjectAclInput) GoString() string {
  15295. return s.String()
  15296. }
  15297. // Validate inspects the fields of the type to determine if they are valid.
  15298. func (s *PutObjectAclInput) Validate() error {
  15299. invalidParams := request.ErrInvalidParams{Context: "PutObjectAclInput"}
  15300. if s.Bucket == nil {
  15301. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15302. }
  15303. if s.Key == nil {
  15304. invalidParams.Add(request.NewErrParamRequired("Key"))
  15305. }
  15306. if s.Key != nil && len(*s.Key) < 1 {
  15307. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  15308. }
  15309. if s.AccessControlPolicy != nil {
  15310. if err := s.AccessControlPolicy.Validate(); err != nil {
  15311. invalidParams.AddNested("AccessControlPolicy", err.(request.ErrInvalidParams))
  15312. }
  15313. }
  15314. if invalidParams.Len() > 0 {
  15315. return invalidParams
  15316. }
  15317. return nil
  15318. }
  15319. // SetACL sets the ACL field's value.
  15320. func (s *PutObjectAclInput) SetACL(v string) *PutObjectAclInput {
  15321. s.ACL = &v
  15322. return s
  15323. }
  15324. // SetAccessControlPolicy sets the AccessControlPolicy field's value.
  15325. func (s *PutObjectAclInput) SetAccessControlPolicy(v *AccessControlPolicy) *PutObjectAclInput {
  15326. s.AccessControlPolicy = v
  15327. return s
  15328. }
  15329. // SetBucket sets the Bucket field's value.
  15330. func (s *PutObjectAclInput) SetBucket(v string) *PutObjectAclInput {
  15331. s.Bucket = &v
  15332. return s
  15333. }
  15334. func (s *PutObjectAclInput) getBucket() (v string) {
  15335. if s.Bucket == nil {
  15336. return v
  15337. }
  15338. return *s.Bucket
  15339. }
  15340. // SetGrantFullControl sets the GrantFullControl field's value.
  15341. func (s *PutObjectAclInput) SetGrantFullControl(v string) *PutObjectAclInput {
  15342. s.GrantFullControl = &v
  15343. return s
  15344. }
  15345. // SetGrantRead sets the GrantRead field's value.
  15346. func (s *PutObjectAclInput) SetGrantRead(v string) *PutObjectAclInput {
  15347. s.GrantRead = &v
  15348. return s
  15349. }
  15350. // SetGrantReadACP sets the GrantReadACP field's value.
  15351. func (s *PutObjectAclInput) SetGrantReadACP(v string) *PutObjectAclInput {
  15352. s.GrantReadACP = &v
  15353. return s
  15354. }
  15355. // SetGrantWrite sets the GrantWrite field's value.
  15356. func (s *PutObjectAclInput) SetGrantWrite(v string) *PutObjectAclInput {
  15357. s.GrantWrite = &v
  15358. return s
  15359. }
  15360. // SetGrantWriteACP sets the GrantWriteACP field's value.
  15361. func (s *PutObjectAclInput) SetGrantWriteACP(v string) *PutObjectAclInput {
  15362. s.GrantWriteACP = &v
  15363. return s
  15364. }
  15365. // SetKey sets the Key field's value.
  15366. func (s *PutObjectAclInput) SetKey(v string) *PutObjectAclInput {
  15367. s.Key = &v
  15368. return s
  15369. }
  15370. // SetRequestPayer sets the RequestPayer field's value.
  15371. func (s *PutObjectAclInput) SetRequestPayer(v string) *PutObjectAclInput {
  15372. s.RequestPayer = &v
  15373. return s
  15374. }
  15375. // SetVersionId sets the VersionId field's value.
  15376. func (s *PutObjectAclInput) SetVersionId(v string) *PutObjectAclInput {
  15377. s.VersionId = &v
  15378. return s
  15379. }
  15380. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectAclOutput
  15381. type PutObjectAclOutput struct {
  15382. _ struct{} `type:"structure"`
  15383. // If present, indicates that the requester was successfully charged for the
  15384. // request.
  15385. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  15386. }
  15387. // String returns the string representation
  15388. func (s PutObjectAclOutput) String() string {
  15389. return awsutil.Prettify(s)
  15390. }
  15391. // GoString returns the string representation
  15392. func (s PutObjectAclOutput) GoString() string {
  15393. return s.String()
  15394. }
  15395. // SetRequestCharged sets the RequestCharged field's value.
  15396. func (s *PutObjectAclOutput) SetRequestCharged(v string) *PutObjectAclOutput {
  15397. s.RequestCharged = &v
  15398. return s
  15399. }
  15400. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectRequest
  15401. type PutObjectInput struct {
  15402. _ struct{} `type:"structure" payload:"Body"`
  15403. // The canned ACL to apply to the object.
  15404. ACL *string `location:"header" locationName:"x-amz-acl" type:"string" enum:"ObjectCannedACL"`
  15405. // Object data.
  15406. Body io.ReadSeeker `type:"blob"`
  15407. // Name of the bucket to which the PUT operation was initiated.
  15408. //
  15409. // Bucket is a required field
  15410. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15411. // Specifies caching behavior along the request/reply chain.
  15412. CacheControl *string `location:"header" locationName:"Cache-Control" type:"string"`
  15413. // Specifies presentational information for the object.
  15414. ContentDisposition *string `location:"header" locationName:"Content-Disposition" type:"string"`
  15415. // Specifies what content encodings have been applied to the object and thus
  15416. // what decoding mechanisms must be applied to obtain the media-type referenced
  15417. // by the Content-Type header field.
  15418. ContentEncoding *string `location:"header" locationName:"Content-Encoding" type:"string"`
  15419. // The language the content is in.
  15420. ContentLanguage *string `location:"header" locationName:"Content-Language" type:"string"`
  15421. // Size of the body in bytes. This parameter is useful when the size of the
  15422. // body cannot be determined automatically.
  15423. ContentLength *int64 `location:"header" locationName:"Content-Length" type:"long"`
  15424. // The base64-encoded 128-bit MD5 digest of the part data.
  15425. ContentMD5 *string `location:"header" locationName:"Content-MD5" type:"string"`
  15426. // A standard MIME type describing the format of the object data.
  15427. ContentType *string `location:"header" locationName:"Content-Type" type:"string"`
  15428. // The date and time at which the object is no longer cacheable.
  15429. Expires *time.Time `location:"header" locationName:"Expires" type:"timestamp" timestampFormat:"rfc822"`
  15430. // Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.
  15431. GrantFullControl *string `location:"header" locationName:"x-amz-grant-full-control" type:"string"`
  15432. // Allows grantee to read the object data and its metadata.
  15433. GrantRead *string `location:"header" locationName:"x-amz-grant-read" type:"string"`
  15434. // Allows grantee to read the object ACL.
  15435. GrantReadACP *string `location:"header" locationName:"x-amz-grant-read-acp" type:"string"`
  15436. // Allows grantee to write the ACL for the applicable object.
  15437. GrantWriteACP *string `location:"header" locationName:"x-amz-grant-write-acp" type:"string"`
  15438. // Object key for which the PUT operation was initiated.
  15439. //
  15440. // Key is a required field
  15441. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  15442. // A map of metadata to store with the object in S3.
  15443. Metadata map[string]*string `location:"headers" locationName:"x-amz-meta-" type:"map"`
  15444. // Confirms that the requester knows that she or he will be charged for the
  15445. // request. Bucket owners need not specify this parameter in their requests.
  15446. // Documentation on downloading objects from requester pays buckets can be found
  15447. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  15448. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  15449. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  15450. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  15451. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  15452. // data. This value is used to store the object and then it is discarded; Amazon
  15453. // does not store the encryption key. The key must be appropriate for use with
  15454. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  15455. // header.
  15456. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  15457. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  15458. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  15459. // key was transmitted without error.
  15460. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  15461. // Specifies the AWS KMS key ID to use for object encryption. All GET and PUT
  15462. // requests for an object protected by AWS KMS will fail if not made via SSL
  15463. // or using SigV4. Documentation on configuring any of the officially supported
  15464. // AWS SDKs and CLI can be found at http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
  15465. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  15466. // The Server-side encryption algorithm used when storing this object in S3
  15467. // (e.g., AES256, aws:kms).
  15468. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  15469. // The type of storage to use for the object. Defaults to 'STANDARD'.
  15470. StorageClass *string `location:"header" locationName:"x-amz-storage-class" type:"string" enum:"StorageClass"`
  15471. // The tag-set for the object. The tag-set must be encoded as URL Query parameters
  15472. Tagging *string `location:"header" locationName:"x-amz-tagging" type:"string"`
  15473. // If the bucket is configured as a website, redirects requests for this object
  15474. // to another object in the same bucket or to an external URL. Amazon S3 stores
  15475. // the value of this header in the object metadata.
  15476. WebsiteRedirectLocation *string `location:"header" locationName:"x-amz-website-redirect-location" type:"string"`
  15477. }
  15478. // String returns the string representation
  15479. func (s PutObjectInput) String() string {
  15480. return awsutil.Prettify(s)
  15481. }
  15482. // GoString returns the string representation
  15483. func (s PutObjectInput) GoString() string {
  15484. return s.String()
  15485. }
  15486. // Validate inspects the fields of the type to determine if they are valid.
  15487. func (s *PutObjectInput) Validate() error {
  15488. invalidParams := request.ErrInvalidParams{Context: "PutObjectInput"}
  15489. if s.Bucket == nil {
  15490. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15491. }
  15492. if s.Key == nil {
  15493. invalidParams.Add(request.NewErrParamRequired("Key"))
  15494. }
  15495. if s.Key != nil && len(*s.Key) < 1 {
  15496. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  15497. }
  15498. if invalidParams.Len() > 0 {
  15499. return invalidParams
  15500. }
  15501. return nil
  15502. }
  15503. // SetACL sets the ACL field's value.
  15504. func (s *PutObjectInput) SetACL(v string) *PutObjectInput {
  15505. s.ACL = &v
  15506. return s
  15507. }
  15508. // SetBody sets the Body field's value.
  15509. func (s *PutObjectInput) SetBody(v io.ReadSeeker) *PutObjectInput {
  15510. s.Body = v
  15511. return s
  15512. }
  15513. // SetBucket sets the Bucket field's value.
  15514. func (s *PutObjectInput) SetBucket(v string) *PutObjectInput {
  15515. s.Bucket = &v
  15516. return s
  15517. }
  15518. func (s *PutObjectInput) getBucket() (v string) {
  15519. if s.Bucket == nil {
  15520. return v
  15521. }
  15522. return *s.Bucket
  15523. }
  15524. // SetCacheControl sets the CacheControl field's value.
  15525. func (s *PutObjectInput) SetCacheControl(v string) *PutObjectInput {
  15526. s.CacheControl = &v
  15527. return s
  15528. }
  15529. // SetContentDisposition sets the ContentDisposition field's value.
  15530. func (s *PutObjectInput) SetContentDisposition(v string) *PutObjectInput {
  15531. s.ContentDisposition = &v
  15532. return s
  15533. }
  15534. // SetContentEncoding sets the ContentEncoding field's value.
  15535. func (s *PutObjectInput) SetContentEncoding(v string) *PutObjectInput {
  15536. s.ContentEncoding = &v
  15537. return s
  15538. }
  15539. // SetContentLanguage sets the ContentLanguage field's value.
  15540. func (s *PutObjectInput) SetContentLanguage(v string) *PutObjectInput {
  15541. s.ContentLanguage = &v
  15542. return s
  15543. }
  15544. // SetContentLength sets the ContentLength field's value.
  15545. func (s *PutObjectInput) SetContentLength(v int64) *PutObjectInput {
  15546. s.ContentLength = &v
  15547. return s
  15548. }
  15549. // SetContentMD5 sets the ContentMD5 field's value.
  15550. func (s *PutObjectInput) SetContentMD5(v string) *PutObjectInput {
  15551. s.ContentMD5 = &v
  15552. return s
  15553. }
  15554. // SetContentType sets the ContentType field's value.
  15555. func (s *PutObjectInput) SetContentType(v string) *PutObjectInput {
  15556. s.ContentType = &v
  15557. return s
  15558. }
  15559. // SetExpires sets the Expires field's value.
  15560. func (s *PutObjectInput) SetExpires(v time.Time) *PutObjectInput {
  15561. s.Expires = &v
  15562. return s
  15563. }
  15564. // SetGrantFullControl sets the GrantFullControl field's value.
  15565. func (s *PutObjectInput) SetGrantFullControl(v string) *PutObjectInput {
  15566. s.GrantFullControl = &v
  15567. return s
  15568. }
  15569. // SetGrantRead sets the GrantRead field's value.
  15570. func (s *PutObjectInput) SetGrantRead(v string) *PutObjectInput {
  15571. s.GrantRead = &v
  15572. return s
  15573. }
  15574. // SetGrantReadACP sets the GrantReadACP field's value.
  15575. func (s *PutObjectInput) SetGrantReadACP(v string) *PutObjectInput {
  15576. s.GrantReadACP = &v
  15577. return s
  15578. }
  15579. // SetGrantWriteACP sets the GrantWriteACP field's value.
  15580. func (s *PutObjectInput) SetGrantWriteACP(v string) *PutObjectInput {
  15581. s.GrantWriteACP = &v
  15582. return s
  15583. }
  15584. // SetKey sets the Key field's value.
  15585. func (s *PutObjectInput) SetKey(v string) *PutObjectInput {
  15586. s.Key = &v
  15587. return s
  15588. }
  15589. // SetMetadata sets the Metadata field's value.
  15590. func (s *PutObjectInput) SetMetadata(v map[string]*string) *PutObjectInput {
  15591. s.Metadata = v
  15592. return s
  15593. }
  15594. // SetRequestPayer sets the RequestPayer field's value.
  15595. func (s *PutObjectInput) SetRequestPayer(v string) *PutObjectInput {
  15596. s.RequestPayer = &v
  15597. return s
  15598. }
  15599. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  15600. func (s *PutObjectInput) SetSSECustomerAlgorithm(v string) *PutObjectInput {
  15601. s.SSECustomerAlgorithm = &v
  15602. return s
  15603. }
  15604. // SetSSECustomerKey sets the SSECustomerKey field's value.
  15605. func (s *PutObjectInput) SetSSECustomerKey(v string) *PutObjectInput {
  15606. s.SSECustomerKey = &v
  15607. return s
  15608. }
  15609. func (s *PutObjectInput) getSSECustomerKey() (v string) {
  15610. if s.SSECustomerKey == nil {
  15611. return v
  15612. }
  15613. return *s.SSECustomerKey
  15614. }
  15615. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  15616. func (s *PutObjectInput) SetSSECustomerKeyMD5(v string) *PutObjectInput {
  15617. s.SSECustomerKeyMD5 = &v
  15618. return s
  15619. }
  15620. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  15621. func (s *PutObjectInput) SetSSEKMSKeyId(v string) *PutObjectInput {
  15622. s.SSEKMSKeyId = &v
  15623. return s
  15624. }
  15625. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  15626. func (s *PutObjectInput) SetServerSideEncryption(v string) *PutObjectInput {
  15627. s.ServerSideEncryption = &v
  15628. return s
  15629. }
  15630. // SetStorageClass sets the StorageClass field's value.
  15631. func (s *PutObjectInput) SetStorageClass(v string) *PutObjectInput {
  15632. s.StorageClass = &v
  15633. return s
  15634. }
  15635. // SetTagging sets the Tagging field's value.
  15636. func (s *PutObjectInput) SetTagging(v string) *PutObjectInput {
  15637. s.Tagging = &v
  15638. return s
  15639. }
  15640. // SetWebsiteRedirectLocation sets the WebsiteRedirectLocation field's value.
  15641. func (s *PutObjectInput) SetWebsiteRedirectLocation(v string) *PutObjectInput {
  15642. s.WebsiteRedirectLocation = &v
  15643. return s
  15644. }
  15645. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectOutput
  15646. type PutObjectOutput struct {
  15647. _ struct{} `type:"structure"`
  15648. // Entity tag for the uploaded object.
  15649. ETag *string `location:"header" locationName:"ETag" type:"string"`
  15650. // If the object expiration is configured, this will contain the expiration
  15651. // date (expiry-date) and rule ID (rule-id). The value of rule-id is URL encoded.
  15652. Expiration *string `location:"header" locationName:"x-amz-expiration" type:"string"`
  15653. // If present, indicates that the requester was successfully charged for the
  15654. // request.
  15655. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  15656. // If server-side encryption with a customer-provided encryption key was requested,
  15657. // the response will include this header confirming the encryption algorithm
  15658. // used.
  15659. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  15660. // If server-side encryption with a customer-provided encryption key was requested,
  15661. // the response will include this header to provide round trip message integrity
  15662. // verification of the customer-provided encryption key.
  15663. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  15664. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  15665. // encryption key that was used for the object.
  15666. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  15667. // The Server-side encryption algorithm used when storing this object in S3
  15668. // (e.g., AES256, aws:kms).
  15669. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  15670. // Version of the object.
  15671. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  15672. }
  15673. // String returns the string representation
  15674. func (s PutObjectOutput) String() string {
  15675. return awsutil.Prettify(s)
  15676. }
  15677. // GoString returns the string representation
  15678. func (s PutObjectOutput) GoString() string {
  15679. return s.String()
  15680. }
  15681. // SetETag sets the ETag field's value.
  15682. func (s *PutObjectOutput) SetETag(v string) *PutObjectOutput {
  15683. s.ETag = &v
  15684. return s
  15685. }
  15686. // SetExpiration sets the Expiration field's value.
  15687. func (s *PutObjectOutput) SetExpiration(v string) *PutObjectOutput {
  15688. s.Expiration = &v
  15689. return s
  15690. }
  15691. // SetRequestCharged sets the RequestCharged field's value.
  15692. func (s *PutObjectOutput) SetRequestCharged(v string) *PutObjectOutput {
  15693. s.RequestCharged = &v
  15694. return s
  15695. }
  15696. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  15697. func (s *PutObjectOutput) SetSSECustomerAlgorithm(v string) *PutObjectOutput {
  15698. s.SSECustomerAlgorithm = &v
  15699. return s
  15700. }
  15701. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  15702. func (s *PutObjectOutput) SetSSECustomerKeyMD5(v string) *PutObjectOutput {
  15703. s.SSECustomerKeyMD5 = &v
  15704. return s
  15705. }
  15706. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  15707. func (s *PutObjectOutput) SetSSEKMSKeyId(v string) *PutObjectOutput {
  15708. s.SSEKMSKeyId = &v
  15709. return s
  15710. }
  15711. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  15712. func (s *PutObjectOutput) SetServerSideEncryption(v string) *PutObjectOutput {
  15713. s.ServerSideEncryption = &v
  15714. return s
  15715. }
  15716. // SetVersionId sets the VersionId field's value.
  15717. func (s *PutObjectOutput) SetVersionId(v string) *PutObjectOutput {
  15718. s.VersionId = &v
  15719. return s
  15720. }
  15721. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTaggingRequest
  15722. type PutObjectTaggingInput struct {
  15723. _ struct{} `type:"structure" payload:"Tagging"`
  15724. // Bucket is a required field
  15725. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  15726. // Key is a required field
  15727. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  15728. // Tagging is a required field
  15729. Tagging *Tagging `locationName:"Tagging" type:"structure" required:"true" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  15730. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  15731. }
  15732. // String returns the string representation
  15733. func (s PutObjectTaggingInput) String() string {
  15734. return awsutil.Prettify(s)
  15735. }
  15736. // GoString returns the string representation
  15737. func (s PutObjectTaggingInput) GoString() string {
  15738. return s.String()
  15739. }
  15740. // Validate inspects the fields of the type to determine if they are valid.
  15741. func (s *PutObjectTaggingInput) Validate() error {
  15742. invalidParams := request.ErrInvalidParams{Context: "PutObjectTaggingInput"}
  15743. if s.Bucket == nil {
  15744. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  15745. }
  15746. if s.Key == nil {
  15747. invalidParams.Add(request.NewErrParamRequired("Key"))
  15748. }
  15749. if s.Key != nil && len(*s.Key) < 1 {
  15750. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  15751. }
  15752. if s.Tagging == nil {
  15753. invalidParams.Add(request.NewErrParamRequired("Tagging"))
  15754. }
  15755. if s.Tagging != nil {
  15756. if err := s.Tagging.Validate(); err != nil {
  15757. invalidParams.AddNested("Tagging", err.(request.ErrInvalidParams))
  15758. }
  15759. }
  15760. if invalidParams.Len() > 0 {
  15761. return invalidParams
  15762. }
  15763. return nil
  15764. }
  15765. // SetBucket sets the Bucket field's value.
  15766. func (s *PutObjectTaggingInput) SetBucket(v string) *PutObjectTaggingInput {
  15767. s.Bucket = &v
  15768. return s
  15769. }
  15770. func (s *PutObjectTaggingInput) getBucket() (v string) {
  15771. if s.Bucket == nil {
  15772. return v
  15773. }
  15774. return *s.Bucket
  15775. }
  15776. // SetKey sets the Key field's value.
  15777. func (s *PutObjectTaggingInput) SetKey(v string) *PutObjectTaggingInput {
  15778. s.Key = &v
  15779. return s
  15780. }
  15781. // SetTagging sets the Tagging field's value.
  15782. func (s *PutObjectTaggingInput) SetTagging(v *Tagging) *PutObjectTaggingInput {
  15783. s.Tagging = v
  15784. return s
  15785. }
  15786. // SetVersionId sets the VersionId field's value.
  15787. func (s *PutObjectTaggingInput) SetVersionId(v string) *PutObjectTaggingInput {
  15788. s.VersionId = &v
  15789. return s
  15790. }
  15791. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/PutObjectTaggingOutput
  15792. type PutObjectTaggingOutput struct {
  15793. _ struct{} `type:"structure"`
  15794. VersionId *string `location:"header" locationName:"x-amz-version-id" type:"string"`
  15795. }
  15796. // String returns the string representation
  15797. func (s PutObjectTaggingOutput) String() string {
  15798. return awsutil.Prettify(s)
  15799. }
  15800. // GoString returns the string representation
  15801. func (s PutObjectTaggingOutput) GoString() string {
  15802. return s.String()
  15803. }
  15804. // SetVersionId sets the VersionId field's value.
  15805. func (s *PutObjectTaggingOutput) SetVersionId(v string) *PutObjectTaggingOutput {
  15806. s.VersionId = &v
  15807. return s
  15808. }
  15809. // Container for specifying an configuration when you want Amazon S3 to publish
  15810. // events to an Amazon Simple Queue Service (Amazon SQS) queue.
  15811. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/QueueConfiguration
  15812. type QueueConfiguration struct {
  15813. _ struct{} `type:"structure"`
  15814. // Events is a required field
  15815. Events []*string `locationName:"Event" type:"list" flattened:"true" required:"true"`
  15816. // Container for object key name filtering rules. For information about key
  15817. // name filtering, go to Configuring Event Notifications (http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  15818. Filter *NotificationConfigurationFilter `type:"structure"`
  15819. // Optional unique identifier for configurations in a notification configuration.
  15820. // If you don't provide one, Amazon S3 will assign an ID.
  15821. Id *string `type:"string"`
  15822. // Amazon SQS queue ARN to which Amazon S3 will publish a message when it detects
  15823. // events of specified type.
  15824. //
  15825. // QueueArn is a required field
  15826. QueueArn *string `locationName:"Queue" type:"string" required:"true"`
  15827. }
  15828. // String returns the string representation
  15829. func (s QueueConfiguration) String() string {
  15830. return awsutil.Prettify(s)
  15831. }
  15832. // GoString returns the string representation
  15833. func (s QueueConfiguration) GoString() string {
  15834. return s.String()
  15835. }
  15836. // Validate inspects the fields of the type to determine if they are valid.
  15837. func (s *QueueConfiguration) Validate() error {
  15838. invalidParams := request.ErrInvalidParams{Context: "QueueConfiguration"}
  15839. if s.Events == nil {
  15840. invalidParams.Add(request.NewErrParamRequired("Events"))
  15841. }
  15842. if s.QueueArn == nil {
  15843. invalidParams.Add(request.NewErrParamRequired("QueueArn"))
  15844. }
  15845. if invalidParams.Len() > 0 {
  15846. return invalidParams
  15847. }
  15848. return nil
  15849. }
  15850. // SetEvents sets the Events field's value.
  15851. func (s *QueueConfiguration) SetEvents(v []*string) *QueueConfiguration {
  15852. s.Events = v
  15853. return s
  15854. }
  15855. // SetFilter sets the Filter field's value.
  15856. func (s *QueueConfiguration) SetFilter(v *NotificationConfigurationFilter) *QueueConfiguration {
  15857. s.Filter = v
  15858. return s
  15859. }
  15860. // SetId sets the Id field's value.
  15861. func (s *QueueConfiguration) SetId(v string) *QueueConfiguration {
  15862. s.Id = &v
  15863. return s
  15864. }
  15865. // SetQueueArn sets the QueueArn field's value.
  15866. func (s *QueueConfiguration) SetQueueArn(v string) *QueueConfiguration {
  15867. s.QueueArn = &v
  15868. return s
  15869. }
  15870. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/QueueConfigurationDeprecated
  15871. type QueueConfigurationDeprecated struct {
  15872. _ struct{} `type:"structure"`
  15873. // Bucket event for which to send notifications.
  15874. Event *string `deprecated:"true" type:"string" enum:"Event"`
  15875. Events []*string `locationName:"Event" type:"list" flattened:"true"`
  15876. // Optional unique identifier for configurations in a notification configuration.
  15877. // If you don't provide one, Amazon S3 will assign an ID.
  15878. Id *string `type:"string"`
  15879. Queue *string `type:"string"`
  15880. }
  15881. // String returns the string representation
  15882. func (s QueueConfigurationDeprecated) String() string {
  15883. return awsutil.Prettify(s)
  15884. }
  15885. // GoString returns the string representation
  15886. func (s QueueConfigurationDeprecated) GoString() string {
  15887. return s.String()
  15888. }
  15889. // SetEvent sets the Event field's value.
  15890. func (s *QueueConfigurationDeprecated) SetEvent(v string) *QueueConfigurationDeprecated {
  15891. s.Event = &v
  15892. return s
  15893. }
  15894. // SetEvents sets the Events field's value.
  15895. func (s *QueueConfigurationDeprecated) SetEvents(v []*string) *QueueConfigurationDeprecated {
  15896. s.Events = v
  15897. return s
  15898. }
  15899. // SetId sets the Id field's value.
  15900. func (s *QueueConfigurationDeprecated) SetId(v string) *QueueConfigurationDeprecated {
  15901. s.Id = &v
  15902. return s
  15903. }
  15904. // SetQueue sets the Queue field's value.
  15905. func (s *QueueConfigurationDeprecated) SetQueue(v string) *QueueConfigurationDeprecated {
  15906. s.Queue = &v
  15907. return s
  15908. }
  15909. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Redirect
  15910. type Redirect struct {
  15911. _ struct{} `type:"structure"`
  15912. // The host name to use in the redirect request.
  15913. HostName *string `type:"string"`
  15914. // The HTTP redirect code to use on the response. Not required if one of the
  15915. // siblings is present.
  15916. HttpRedirectCode *string `type:"string"`
  15917. // Protocol to use (http, https) when redirecting requests. The default is the
  15918. // protocol that is used in the original request.
  15919. Protocol *string `type:"string" enum:"Protocol"`
  15920. // The object key prefix to use in the redirect request. For example, to redirect
  15921. // requests for all pages with prefix docs/ (objects in the docs/ folder) to
  15922. // documents/, you can set a condition block with KeyPrefixEquals set to docs/
  15923. // and in the Redirect set ReplaceKeyPrefixWith to /documents. Not required
  15924. // if one of the siblings is present. Can be present only if ReplaceKeyWith
  15925. // is not provided.
  15926. ReplaceKeyPrefixWith *string `type:"string"`
  15927. // The specific object key to use in the redirect request. For example, redirect
  15928. // request to error.html. Not required if one of the sibling is present. Can
  15929. // be present only if ReplaceKeyPrefixWith is not provided.
  15930. ReplaceKeyWith *string `type:"string"`
  15931. }
  15932. // String returns the string representation
  15933. func (s Redirect) String() string {
  15934. return awsutil.Prettify(s)
  15935. }
  15936. // GoString returns the string representation
  15937. func (s Redirect) GoString() string {
  15938. return s.String()
  15939. }
  15940. // SetHostName sets the HostName field's value.
  15941. func (s *Redirect) SetHostName(v string) *Redirect {
  15942. s.HostName = &v
  15943. return s
  15944. }
  15945. // SetHttpRedirectCode sets the HttpRedirectCode field's value.
  15946. func (s *Redirect) SetHttpRedirectCode(v string) *Redirect {
  15947. s.HttpRedirectCode = &v
  15948. return s
  15949. }
  15950. // SetProtocol sets the Protocol field's value.
  15951. func (s *Redirect) SetProtocol(v string) *Redirect {
  15952. s.Protocol = &v
  15953. return s
  15954. }
  15955. // SetReplaceKeyPrefixWith sets the ReplaceKeyPrefixWith field's value.
  15956. func (s *Redirect) SetReplaceKeyPrefixWith(v string) *Redirect {
  15957. s.ReplaceKeyPrefixWith = &v
  15958. return s
  15959. }
  15960. // SetReplaceKeyWith sets the ReplaceKeyWith field's value.
  15961. func (s *Redirect) SetReplaceKeyWith(v string) *Redirect {
  15962. s.ReplaceKeyWith = &v
  15963. return s
  15964. }
  15965. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RedirectAllRequestsTo
  15966. type RedirectAllRequestsTo struct {
  15967. _ struct{} `type:"structure"`
  15968. // Name of the host where requests will be redirected.
  15969. //
  15970. // HostName is a required field
  15971. HostName *string `type:"string" required:"true"`
  15972. // Protocol to use (http, https) when redirecting requests. The default is the
  15973. // protocol that is used in the original request.
  15974. Protocol *string `type:"string" enum:"Protocol"`
  15975. }
  15976. // String returns the string representation
  15977. func (s RedirectAllRequestsTo) String() string {
  15978. return awsutil.Prettify(s)
  15979. }
  15980. // GoString returns the string representation
  15981. func (s RedirectAllRequestsTo) GoString() string {
  15982. return s.String()
  15983. }
  15984. // Validate inspects the fields of the type to determine if they are valid.
  15985. func (s *RedirectAllRequestsTo) Validate() error {
  15986. invalidParams := request.ErrInvalidParams{Context: "RedirectAllRequestsTo"}
  15987. if s.HostName == nil {
  15988. invalidParams.Add(request.NewErrParamRequired("HostName"))
  15989. }
  15990. if invalidParams.Len() > 0 {
  15991. return invalidParams
  15992. }
  15993. return nil
  15994. }
  15995. // SetHostName sets the HostName field's value.
  15996. func (s *RedirectAllRequestsTo) SetHostName(v string) *RedirectAllRequestsTo {
  15997. s.HostName = &v
  15998. return s
  15999. }
  16000. // SetProtocol sets the Protocol field's value.
  16001. func (s *RedirectAllRequestsTo) SetProtocol(v string) *RedirectAllRequestsTo {
  16002. s.Protocol = &v
  16003. return s
  16004. }
  16005. // Container for replication rules. You can add as many as 1,000 rules. Total
  16006. // replication configuration size can be up to 2 MB.
  16007. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationConfiguration
  16008. type ReplicationConfiguration struct {
  16009. _ struct{} `type:"structure"`
  16010. // Amazon Resource Name (ARN) of an IAM role for Amazon S3 to assume when replicating
  16011. // the objects.
  16012. //
  16013. // Role is a required field
  16014. Role *string `type:"string" required:"true"`
  16015. // Container for information about a particular replication rule. Replication
  16016. // configuration must have at least one rule and can contain up to 1,000 rules.
  16017. //
  16018. // Rules is a required field
  16019. Rules []*ReplicationRule `locationName:"Rule" type:"list" flattened:"true" required:"true"`
  16020. }
  16021. // String returns the string representation
  16022. func (s ReplicationConfiguration) String() string {
  16023. return awsutil.Prettify(s)
  16024. }
  16025. // GoString returns the string representation
  16026. func (s ReplicationConfiguration) GoString() string {
  16027. return s.String()
  16028. }
  16029. // Validate inspects the fields of the type to determine if they are valid.
  16030. func (s *ReplicationConfiguration) Validate() error {
  16031. invalidParams := request.ErrInvalidParams{Context: "ReplicationConfiguration"}
  16032. if s.Role == nil {
  16033. invalidParams.Add(request.NewErrParamRequired("Role"))
  16034. }
  16035. if s.Rules == nil {
  16036. invalidParams.Add(request.NewErrParamRequired("Rules"))
  16037. }
  16038. if s.Rules != nil {
  16039. for i, v := range s.Rules {
  16040. if v == nil {
  16041. continue
  16042. }
  16043. if err := v.Validate(); err != nil {
  16044. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams))
  16045. }
  16046. }
  16047. }
  16048. if invalidParams.Len() > 0 {
  16049. return invalidParams
  16050. }
  16051. return nil
  16052. }
  16053. // SetRole sets the Role field's value.
  16054. func (s *ReplicationConfiguration) SetRole(v string) *ReplicationConfiguration {
  16055. s.Role = &v
  16056. return s
  16057. }
  16058. // SetRules sets the Rules field's value.
  16059. func (s *ReplicationConfiguration) SetRules(v []*ReplicationRule) *ReplicationConfiguration {
  16060. s.Rules = v
  16061. return s
  16062. }
  16063. // Container for information about a particular replication rule.
  16064. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ReplicationRule
  16065. type ReplicationRule struct {
  16066. _ struct{} `type:"structure"`
  16067. // Container for replication destination information.
  16068. //
  16069. // Destination is a required field
  16070. Destination *Destination `type:"structure" required:"true"`
  16071. // Unique identifier for the rule. The value cannot be longer than 255 characters.
  16072. ID *string `type:"string"`
  16073. // Object keyname prefix identifying one or more objects to which the rule applies.
  16074. // Maximum prefix length can be up to 1,024 characters. Overlapping prefixes
  16075. // are not supported.
  16076. //
  16077. // Prefix is a required field
  16078. Prefix *string `type:"string" required:"true"`
  16079. // Container for filters that define which source objects should be replicated.
  16080. SourceSelectionCriteria *SourceSelectionCriteria `type:"structure"`
  16081. // The rule is ignored if status is not Enabled.
  16082. //
  16083. // Status is a required field
  16084. Status *string `type:"string" required:"true" enum:"ReplicationRuleStatus"`
  16085. }
  16086. // String returns the string representation
  16087. func (s ReplicationRule) String() string {
  16088. return awsutil.Prettify(s)
  16089. }
  16090. // GoString returns the string representation
  16091. func (s ReplicationRule) GoString() string {
  16092. return s.String()
  16093. }
  16094. // Validate inspects the fields of the type to determine if they are valid.
  16095. func (s *ReplicationRule) Validate() error {
  16096. invalidParams := request.ErrInvalidParams{Context: "ReplicationRule"}
  16097. if s.Destination == nil {
  16098. invalidParams.Add(request.NewErrParamRequired("Destination"))
  16099. }
  16100. if s.Prefix == nil {
  16101. invalidParams.Add(request.NewErrParamRequired("Prefix"))
  16102. }
  16103. if s.Status == nil {
  16104. invalidParams.Add(request.NewErrParamRequired("Status"))
  16105. }
  16106. if s.Destination != nil {
  16107. if err := s.Destination.Validate(); err != nil {
  16108. invalidParams.AddNested("Destination", err.(request.ErrInvalidParams))
  16109. }
  16110. }
  16111. if s.SourceSelectionCriteria != nil {
  16112. if err := s.SourceSelectionCriteria.Validate(); err != nil {
  16113. invalidParams.AddNested("SourceSelectionCriteria", err.(request.ErrInvalidParams))
  16114. }
  16115. }
  16116. if invalidParams.Len() > 0 {
  16117. return invalidParams
  16118. }
  16119. return nil
  16120. }
  16121. // SetDestination sets the Destination field's value.
  16122. func (s *ReplicationRule) SetDestination(v *Destination) *ReplicationRule {
  16123. s.Destination = v
  16124. return s
  16125. }
  16126. // SetID sets the ID field's value.
  16127. func (s *ReplicationRule) SetID(v string) *ReplicationRule {
  16128. s.ID = &v
  16129. return s
  16130. }
  16131. // SetPrefix sets the Prefix field's value.
  16132. func (s *ReplicationRule) SetPrefix(v string) *ReplicationRule {
  16133. s.Prefix = &v
  16134. return s
  16135. }
  16136. // SetSourceSelectionCriteria sets the SourceSelectionCriteria field's value.
  16137. func (s *ReplicationRule) SetSourceSelectionCriteria(v *SourceSelectionCriteria) *ReplicationRule {
  16138. s.SourceSelectionCriteria = v
  16139. return s
  16140. }
  16141. // SetStatus sets the Status field's value.
  16142. func (s *ReplicationRule) SetStatus(v string) *ReplicationRule {
  16143. s.Status = &v
  16144. return s
  16145. }
  16146. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RequestPaymentConfiguration
  16147. type RequestPaymentConfiguration struct {
  16148. _ struct{} `type:"structure"`
  16149. // Specifies who pays for the download and request fees.
  16150. //
  16151. // Payer is a required field
  16152. Payer *string `type:"string" required:"true" enum:"Payer"`
  16153. }
  16154. // String returns the string representation
  16155. func (s RequestPaymentConfiguration) String() string {
  16156. return awsutil.Prettify(s)
  16157. }
  16158. // GoString returns the string representation
  16159. func (s RequestPaymentConfiguration) GoString() string {
  16160. return s.String()
  16161. }
  16162. // Validate inspects the fields of the type to determine if they are valid.
  16163. func (s *RequestPaymentConfiguration) Validate() error {
  16164. invalidParams := request.ErrInvalidParams{Context: "RequestPaymentConfiguration"}
  16165. if s.Payer == nil {
  16166. invalidParams.Add(request.NewErrParamRequired("Payer"))
  16167. }
  16168. if invalidParams.Len() > 0 {
  16169. return invalidParams
  16170. }
  16171. return nil
  16172. }
  16173. // SetPayer sets the Payer field's value.
  16174. func (s *RequestPaymentConfiguration) SetPayer(v string) *RequestPaymentConfiguration {
  16175. s.Payer = &v
  16176. return s
  16177. }
  16178. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObjectRequest
  16179. type RestoreObjectInput struct {
  16180. _ struct{} `type:"structure" payload:"RestoreRequest"`
  16181. // Bucket is a required field
  16182. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  16183. // Key is a required field
  16184. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  16185. // Confirms that the requester knows that she or he will be charged for the
  16186. // request. Bucket owners need not specify this parameter in their requests.
  16187. // Documentation on downloading objects from requester pays buckets can be found
  16188. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  16189. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  16190. // Container for restore job parameters.
  16191. RestoreRequest *RestoreRequest `locationName:"RestoreRequest" type:"structure" xmlURI:"http://s3.amazonaws.com/doc/2006-03-01/"`
  16192. VersionId *string `location:"querystring" locationName:"versionId" type:"string"`
  16193. }
  16194. // String returns the string representation
  16195. func (s RestoreObjectInput) String() string {
  16196. return awsutil.Prettify(s)
  16197. }
  16198. // GoString returns the string representation
  16199. func (s RestoreObjectInput) GoString() string {
  16200. return s.String()
  16201. }
  16202. // Validate inspects the fields of the type to determine if they are valid.
  16203. func (s *RestoreObjectInput) Validate() error {
  16204. invalidParams := request.ErrInvalidParams{Context: "RestoreObjectInput"}
  16205. if s.Bucket == nil {
  16206. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  16207. }
  16208. if s.Key == nil {
  16209. invalidParams.Add(request.NewErrParamRequired("Key"))
  16210. }
  16211. if s.Key != nil && len(*s.Key) < 1 {
  16212. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  16213. }
  16214. if s.RestoreRequest != nil {
  16215. if err := s.RestoreRequest.Validate(); err != nil {
  16216. invalidParams.AddNested("RestoreRequest", err.(request.ErrInvalidParams))
  16217. }
  16218. }
  16219. if invalidParams.Len() > 0 {
  16220. return invalidParams
  16221. }
  16222. return nil
  16223. }
  16224. // SetBucket sets the Bucket field's value.
  16225. func (s *RestoreObjectInput) SetBucket(v string) *RestoreObjectInput {
  16226. s.Bucket = &v
  16227. return s
  16228. }
  16229. func (s *RestoreObjectInput) getBucket() (v string) {
  16230. if s.Bucket == nil {
  16231. return v
  16232. }
  16233. return *s.Bucket
  16234. }
  16235. // SetKey sets the Key field's value.
  16236. func (s *RestoreObjectInput) SetKey(v string) *RestoreObjectInput {
  16237. s.Key = &v
  16238. return s
  16239. }
  16240. // SetRequestPayer sets the RequestPayer field's value.
  16241. func (s *RestoreObjectInput) SetRequestPayer(v string) *RestoreObjectInput {
  16242. s.RequestPayer = &v
  16243. return s
  16244. }
  16245. // SetRestoreRequest sets the RestoreRequest field's value.
  16246. func (s *RestoreObjectInput) SetRestoreRequest(v *RestoreRequest) *RestoreObjectInput {
  16247. s.RestoreRequest = v
  16248. return s
  16249. }
  16250. // SetVersionId sets the VersionId field's value.
  16251. func (s *RestoreObjectInput) SetVersionId(v string) *RestoreObjectInput {
  16252. s.VersionId = &v
  16253. return s
  16254. }
  16255. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreObjectOutput
  16256. type RestoreObjectOutput struct {
  16257. _ struct{} `type:"structure"`
  16258. // If present, indicates that the requester was successfully charged for the
  16259. // request.
  16260. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  16261. // Indicates the path in the provided S3 output location where Select results
  16262. // will be restored to.
  16263. RestoreOutputPath *string `location:"header" locationName:"x-amz-restore-output-path" type:"string"`
  16264. }
  16265. // String returns the string representation
  16266. func (s RestoreObjectOutput) String() string {
  16267. return awsutil.Prettify(s)
  16268. }
  16269. // GoString returns the string representation
  16270. func (s RestoreObjectOutput) GoString() string {
  16271. return s.String()
  16272. }
  16273. // SetRequestCharged sets the RequestCharged field's value.
  16274. func (s *RestoreObjectOutput) SetRequestCharged(v string) *RestoreObjectOutput {
  16275. s.RequestCharged = &v
  16276. return s
  16277. }
  16278. // SetRestoreOutputPath sets the RestoreOutputPath field's value.
  16279. func (s *RestoreObjectOutput) SetRestoreOutputPath(v string) *RestoreObjectOutput {
  16280. s.RestoreOutputPath = &v
  16281. return s
  16282. }
  16283. // Container for restore job parameters.
  16284. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RestoreRequest
  16285. type RestoreRequest struct {
  16286. _ struct{} `type:"structure"`
  16287. // Lifetime of the active copy in days. Do not use with restores that specify
  16288. // OutputLocation.
  16289. Days *int64 `type:"integer"`
  16290. // The optional description for the job.
  16291. Description *string `type:"string"`
  16292. // Glacier related parameters pertaining to this job. Do not use with restores
  16293. // that specify OutputLocation.
  16294. GlacierJobParameters *GlacierJobParameters `type:"structure"`
  16295. // Describes the location where the restore job's output is stored.
  16296. OutputLocation *OutputLocation `type:"structure"`
  16297. // Describes the parameters for Select job types.
  16298. SelectParameters *SelectParameters `type:"structure"`
  16299. // Glacier retrieval tier at which the restore will be processed.
  16300. Tier *string `type:"string" enum:"Tier"`
  16301. // Type of restore request.
  16302. Type *string `type:"string" enum:"RestoreRequestType"`
  16303. }
  16304. // String returns the string representation
  16305. func (s RestoreRequest) String() string {
  16306. return awsutil.Prettify(s)
  16307. }
  16308. // GoString returns the string representation
  16309. func (s RestoreRequest) GoString() string {
  16310. return s.String()
  16311. }
  16312. // Validate inspects the fields of the type to determine if they are valid.
  16313. func (s *RestoreRequest) Validate() error {
  16314. invalidParams := request.ErrInvalidParams{Context: "RestoreRequest"}
  16315. if s.GlacierJobParameters != nil {
  16316. if err := s.GlacierJobParameters.Validate(); err != nil {
  16317. invalidParams.AddNested("GlacierJobParameters", err.(request.ErrInvalidParams))
  16318. }
  16319. }
  16320. if s.OutputLocation != nil {
  16321. if err := s.OutputLocation.Validate(); err != nil {
  16322. invalidParams.AddNested("OutputLocation", err.(request.ErrInvalidParams))
  16323. }
  16324. }
  16325. if s.SelectParameters != nil {
  16326. if err := s.SelectParameters.Validate(); err != nil {
  16327. invalidParams.AddNested("SelectParameters", err.(request.ErrInvalidParams))
  16328. }
  16329. }
  16330. if invalidParams.Len() > 0 {
  16331. return invalidParams
  16332. }
  16333. return nil
  16334. }
  16335. // SetDays sets the Days field's value.
  16336. func (s *RestoreRequest) SetDays(v int64) *RestoreRequest {
  16337. s.Days = &v
  16338. return s
  16339. }
  16340. // SetDescription sets the Description field's value.
  16341. func (s *RestoreRequest) SetDescription(v string) *RestoreRequest {
  16342. s.Description = &v
  16343. return s
  16344. }
  16345. // SetGlacierJobParameters sets the GlacierJobParameters field's value.
  16346. func (s *RestoreRequest) SetGlacierJobParameters(v *GlacierJobParameters) *RestoreRequest {
  16347. s.GlacierJobParameters = v
  16348. return s
  16349. }
  16350. // SetOutputLocation sets the OutputLocation field's value.
  16351. func (s *RestoreRequest) SetOutputLocation(v *OutputLocation) *RestoreRequest {
  16352. s.OutputLocation = v
  16353. return s
  16354. }
  16355. // SetSelectParameters sets the SelectParameters field's value.
  16356. func (s *RestoreRequest) SetSelectParameters(v *SelectParameters) *RestoreRequest {
  16357. s.SelectParameters = v
  16358. return s
  16359. }
  16360. // SetTier sets the Tier field's value.
  16361. func (s *RestoreRequest) SetTier(v string) *RestoreRequest {
  16362. s.Tier = &v
  16363. return s
  16364. }
  16365. // SetType sets the Type field's value.
  16366. func (s *RestoreRequest) SetType(v string) *RestoreRequest {
  16367. s.Type = &v
  16368. return s
  16369. }
  16370. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/RoutingRule
  16371. type RoutingRule struct {
  16372. _ struct{} `type:"structure"`
  16373. // A container for describing a condition that must be met for the specified
  16374. // redirect to apply. For example, 1. If request is for pages in the /docs folder,
  16375. // redirect to the /documents folder. 2. If request results in HTTP error 4xx,
  16376. // redirect request to another host where you might process the error.
  16377. Condition *Condition `type:"structure"`
  16378. // Container for redirect information. You can redirect requests to another
  16379. // host, to another page, or with another protocol. In the event of an error,
  16380. // you can can specify a different error code to return.
  16381. //
  16382. // Redirect is a required field
  16383. Redirect *Redirect `type:"structure" required:"true"`
  16384. }
  16385. // String returns the string representation
  16386. func (s RoutingRule) String() string {
  16387. return awsutil.Prettify(s)
  16388. }
  16389. // GoString returns the string representation
  16390. func (s RoutingRule) GoString() string {
  16391. return s.String()
  16392. }
  16393. // Validate inspects the fields of the type to determine if they are valid.
  16394. func (s *RoutingRule) Validate() error {
  16395. invalidParams := request.ErrInvalidParams{Context: "RoutingRule"}
  16396. if s.Redirect == nil {
  16397. invalidParams.Add(request.NewErrParamRequired("Redirect"))
  16398. }
  16399. if invalidParams.Len() > 0 {
  16400. return invalidParams
  16401. }
  16402. return nil
  16403. }
  16404. // SetCondition sets the Condition field's value.
  16405. func (s *RoutingRule) SetCondition(v *Condition) *RoutingRule {
  16406. s.Condition = v
  16407. return s
  16408. }
  16409. // SetRedirect sets the Redirect field's value.
  16410. func (s *RoutingRule) SetRedirect(v *Redirect) *RoutingRule {
  16411. s.Redirect = v
  16412. return s
  16413. }
  16414. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Rule
  16415. type Rule struct {
  16416. _ struct{} `type:"structure"`
  16417. // Specifies the days since the initiation of an Incomplete Multipart Upload
  16418. // that Lifecycle will wait before permanently removing all parts of the upload.
  16419. AbortIncompleteMultipartUpload *AbortIncompleteMultipartUpload `type:"structure"`
  16420. Expiration *LifecycleExpiration `type:"structure"`
  16421. // Unique identifier for the rule. The value cannot be longer than 255 characters.
  16422. ID *string `type:"string"`
  16423. // Specifies when noncurrent object versions expire. Upon expiration, Amazon
  16424. // S3 permanently deletes the noncurrent object versions. You set this lifecycle
  16425. // configuration action on a bucket that has versioning enabled (or suspended)
  16426. // to request that Amazon S3 delete noncurrent object versions at a specific
  16427. // period in the object's lifetime.
  16428. NoncurrentVersionExpiration *NoncurrentVersionExpiration `type:"structure"`
  16429. // Container for the transition rule that describes when noncurrent objects
  16430. // transition to the STANDARD_IA or GLACIER storage class. If your bucket is
  16431. // versioning-enabled (or versioning is suspended), you can set this action
  16432. // to request that Amazon S3 transition noncurrent object versions to the STANDARD_IA
  16433. // or GLACIER storage class at a specific period in the object's lifetime.
  16434. NoncurrentVersionTransition *NoncurrentVersionTransition `type:"structure"`
  16435. // Prefix identifying one or more objects to which the rule applies.
  16436. //
  16437. // Prefix is a required field
  16438. Prefix *string `type:"string" required:"true"`
  16439. // If 'Enabled', the rule is currently being applied. If 'Disabled', the rule
  16440. // is not currently being applied.
  16441. //
  16442. // Status is a required field
  16443. Status *string `type:"string" required:"true" enum:"ExpirationStatus"`
  16444. Transition *Transition `type:"structure"`
  16445. }
  16446. // String returns the string representation
  16447. func (s Rule) String() string {
  16448. return awsutil.Prettify(s)
  16449. }
  16450. // GoString returns the string representation
  16451. func (s Rule) GoString() string {
  16452. return s.String()
  16453. }
  16454. // Validate inspects the fields of the type to determine if they are valid.
  16455. func (s *Rule) Validate() error {
  16456. invalidParams := request.ErrInvalidParams{Context: "Rule"}
  16457. if s.Prefix == nil {
  16458. invalidParams.Add(request.NewErrParamRequired("Prefix"))
  16459. }
  16460. if s.Status == nil {
  16461. invalidParams.Add(request.NewErrParamRequired("Status"))
  16462. }
  16463. if invalidParams.Len() > 0 {
  16464. return invalidParams
  16465. }
  16466. return nil
  16467. }
  16468. // SetAbortIncompleteMultipartUpload sets the AbortIncompleteMultipartUpload field's value.
  16469. func (s *Rule) SetAbortIncompleteMultipartUpload(v *AbortIncompleteMultipartUpload) *Rule {
  16470. s.AbortIncompleteMultipartUpload = v
  16471. return s
  16472. }
  16473. // SetExpiration sets the Expiration field's value.
  16474. func (s *Rule) SetExpiration(v *LifecycleExpiration) *Rule {
  16475. s.Expiration = v
  16476. return s
  16477. }
  16478. // SetID sets the ID field's value.
  16479. func (s *Rule) SetID(v string) *Rule {
  16480. s.ID = &v
  16481. return s
  16482. }
  16483. // SetNoncurrentVersionExpiration sets the NoncurrentVersionExpiration field's value.
  16484. func (s *Rule) SetNoncurrentVersionExpiration(v *NoncurrentVersionExpiration) *Rule {
  16485. s.NoncurrentVersionExpiration = v
  16486. return s
  16487. }
  16488. // SetNoncurrentVersionTransition sets the NoncurrentVersionTransition field's value.
  16489. func (s *Rule) SetNoncurrentVersionTransition(v *NoncurrentVersionTransition) *Rule {
  16490. s.NoncurrentVersionTransition = v
  16491. return s
  16492. }
  16493. // SetPrefix sets the Prefix field's value.
  16494. func (s *Rule) SetPrefix(v string) *Rule {
  16495. s.Prefix = &v
  16496. return s
  16497. }
  16498. // SetStatus sets the Status field's value.
  16499. func (s *Rule) SetStatus(v string) *Rule {
  16500. s.Status = &v
  16501. return s
  16502. }
  16503. // SetTransition sets the Transition field's value.
  16504. func (s *Rule) SetTransition(v *Transition) *Rule {
  16505. s.Transition = v
  16506. return s
  16507. }
  16508. // Specifies the use of SSE-KMS to encrypt delievered Inventory reports.
  16509. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SSEKMS
  16510. type SSEKMS struct {
  16511. _ struct{} `locationName:"SSE-KMS" type:"structure"`
  16512. // Specifies the ID of the AWS Key Management Service (KMS) master encryption
  16513. // key to use for encrypting Inventory reports.
  16514. //
  16515. // KeyId is a required field
  16516. KeyId *string `type:"string" required:"true"`
  16517. }
  16518. // String returns the string representation
  16519. func (s SSEKMS) String() string {
  16520. return awsutil.Prettify(s)
  16521. }
  16522. // GoString returns the string representation
  16523. func (s SSEKMS) GoString() string {
  16524. return s.String()
  16525. }
  16526. // Validate inspects the fields of the type to determine if they are valid.
  16527. func (s *SSEKMS) Validate() error {
  16528. invalidParams := request.ErrInvalidParams{Context: "SSEKMS"}
  16529. if s.KeyId == nil {
  16530. invalidParams.Add(request.NewErrParamRequired("KeyId"))
  16531. }
  16532. if invalidParams.Len() > 0 {
  16533. return invalidParams
  16534. }
  16535. return nil
  16536. }
  16537. // SetKeyId sets the KeyId field's value.
  16538. func (s *SSEKMS) SetKeyId(v string) *SSEKMS {
  16539. s.KeyId = &v
  16540. return s
  16541. }
  16542. // Specifies the use of SSE-S3 to encrypt delievered Inventory reports.
  16543. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SSES3
  16544. type SSES3 struct {
  16545. _ struct{} `locationName:"SSE-S3" type:"structure"`
  16546. }
  16547. // String returns the string representation
  16548. func (s SSES3) String() string {
  16549. return awsutil.Prettify(s)
  16550. }
  16551. // GoString returns the string representation
  16552. func (s SSES3) GoString() string {
  16553. return s.String()
  16554. }
  16555. // Describes the parameters for Select job types.
  16556. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SelectParameters
  16557. type SelectParameters struct {
  16558. _ struct{} `type:"structure"`
  16559. // The expression that is used to query the object.
  16560. //
  16561. // Expression is a required field
  16562. Expression *string `type:"string" required:"true"`
  16563. // The type of the provided expression (e.g., SQL).
  16564. //
  16565. // ExpressionType is a required field
  16566. ExpressionType *string `type:"string" required:"true" enum:"ExpressionType"`
  16567. // Describes the serialization format of the object.
  16568. //
  16569. // InputSerialization is a required field
  16570. InputSerialization *InputSerialization `type:"structure" required:"true"`
  16571. // Describes how the results of the Select job are serialized.
  16572. //
  16573. // OutputSerialization is a required field
  16574. OutputSerialization *OutputSerialization `type:"structure" required:"true"`
  16575. }
  16576. // String returns the string representation
  16577. func (s SelectParameters) String() string {
  16578. return awsutil.Prettify(s)
  16579. }
  16580. // GoString returns the string representation
  16581. func (s SelectParameters) GoString() string {
  16582. return s.String()
  16583. }
  16584. // Validate inspects the fields of the type to determine if they are valid.
  16585. func (s *SelectParameters) Validate() error {
  16586. invalidParams := request.ErrInvalidParams{Context: "SelectParameters"}
  16587. if s.Expression == nil {
  16588. invalidParams.Add(request.NewErrParamRequired("Expression"))
  16589. }
  16590. if s.ExpressionType == nil {
  16591. invalidParams.Add(request.NewErrParamRequired("ExpressionType"))
  16592. }
  16593. if s.InputSerialization == nil {
  16594. invalidParams.Add(request.NewErrParamRequired("InputSerialization"))
  16595. }
  16596. if s.OutputSerialization == nil {
  16597. invalidParams.Add(request.NewErrParamRequired("OutputSerialization"))
  16598. }
  16599. if invalidParams.Len() > 0 {
  16600. return invalidParams
  16601. }
  16602. return nil
  16603. }
  16604. // SetExpression sets the Expression field's value.
  16605. func (s *SelectParameters) SetExpression(v string) *SelectParameters {
  16606. s.Expression = &v
  16607. return s
  16608. }
  16609. // SetExpressionType sets the ExpressionType field's value.
  16610. func (s *SelectParameters) SetExpressionType(v string) *SelectParameters {
  16611. s.ExpressionType = &v
  16612. return s
  16613. }
  16614. // SetInputSerialization sets the InputSerialization field's value.
  16615. func (s *SelectParameters) SetInputSerialization(v *InputSerialization) *SelectParameters {
  16616. s.InputSerialization = v
  16617. return s
  16618. }
  16619. // SetOutputSerialization sets the OutputSerialization field's value.
  16620. func (s *SelectParameters) SetOutputSerialization(v *OutputSerialization) *SelectParameters {
  16621. s.OutputSerialization = v
  16622. return s
  16623. }
  16624. // Describes the default server-side encryption to apply to new objects in the
  16625. // bucket. If Put Object request does not specify any server-side encryption,
  16626. // this default encryption will be applied.
  16627. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionByDefault
  16628. type ServerSideEncryptionByDefault struct {
  16629. _ struct{} `type:"structure"`
  16630. // KMS master key ID to use for the default encryption. This parameter is allowed
  16631. // if SSEAlgorithm is aws:kms.
  16632. KMSMasterKeyID *string `type:"string"`
  16633. // Server-side encryption algorithm to use for the default encryption.
  16634. //
  16635. // SSEAlgorithm is a required field
  16636. SSEAlgorithm *string `type:"string" required:"true" enum:"ServerSideEncryption"`
  16637. }
  16638. // String returns the string representation
  16639. func (s ServerSideEncryptionByDefault) String() string {
  16640. return awsutil.Prettify(s)
  16641. }
  16642. // GoString returns the string representation
  16643. func (s ServerSideEncryptionByDefault) GoString() string {
  16644. return s.String()
  16645. }
  16646. // Validate inspects the fields of the type to determine if they are valid.
  16647. func (s *ServerSideEncryptionByDefault) Validate() error {
  16648. invalidParams := request.ErrInvalidParams{Context: "ServerSideEncryptionByDefault"}
  16649. if s.SSEAlgorithm == nil {
  16650. invalidParams.Add(request.NewErrParamRequired("SSEAlgorithm"))
  16651. }
  16652. if invalidParams.Len() > 0 {
  16653. return invalidParams
  16654. }
  16655. return nil
  16656. }
  16657. // SetKMSMasterKeyID sets the KMSMasterKeyID field's value.
  16658. func (s *ServerSideEncryptionByDefault) SetKMSMasterKeyID(v string) *ServerSideEncryptionByDefault {
  16659. s.KMSMasterKeyID = &v
  16660. return s
  16661. }
  16662. // SetSSEAlgorithm sets the SSEAlgorithm field's value.
  16663. func (s *ServerSideEncryptionByDefault) SetSSEAlgorithm(v string) *ServerSideEncryptionByDefault {
  16664. s.SSEAlgorithm = &v
  16665. return s
  16666. }
  16667. // Container for server-side encryption configuration rules. Currently S3 supports
  16668. // one rule only.
  16669. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionConfiguration
  16670. type ServerSideEncryptionConfiguration struct {
  16671. _ struct{} `type:"structure"`
  16672. // Container for information about a particular server-side encryption configuration
  16673. // rule.
  16674. //
  16675. // Rules is a required field
  16676. Rules []*ServerSideEncryptionRule `locationName:"Rule" type:"list" flattened:"true" required:"true"`
  16677. }
  16678. // String returns the string representation
  16679. func (s ServerSideEncryptionConfiguration) String() string {
  16680. return awsutil.Prettify(s)
  16681. }
  16682. // GoString returns the string representation
  16683. func (s ServerSideEncryptionConfiguration) GoString() string {
  16684. return s.String()
  16685. }
  16686. // Validate inspects the fields of the type to determine if they are valid.
  16687. func (s *ServerSideEncryptionConfiguration) Validate() error {
  16688. invalidParams := request.ErrInvalidParams{Context: "ServerSideEncryptionConfiguration"}
  16689. if s.Rules == nil {
  16690. invalidParams.Add(request.NewErrParamRequired("Rules"))
  16691. }
  16692. if s.Rules != nil {
  16693. for i, v := range s.Rules {
  16694. if v == nil {
  16695. continue
  16696. }
  16697. if err := v.Validate(); err != nil {
  16698. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Rules", i), err.(request.ErrInvalidParams))
  16699. }
  16700. }
  16701. }
  16702. if invalidParams.Len() > 0 {
  16703. return invalidParams
  16704. }
  16705. return nil
  16706. }
  16707. // SetRules sets the Rules field's value.
  16708. func (s *ServerSideEncryptionConfiguration) SetRules(v []*ServerSideEncryptionRule) *ServerSideEncryptionConfiguration {
  16709. s.Rules = v
  16710. return s
  16711. }
  16712. // Container for information about a particular server-side encryption configuration
  16713. // rule.
  16714. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/ServerSideEncryptionRule
  16715. type ServerSideEncryptionRule struct {
  16716. _ struct{} `type:"structure"`
  16717. // Describes the default server-side encryption to apply to new objects in the
  16718. // bucket. If Put Object request does not specify any server-side encryption,
  16719. // this default encryption will be applied.
  16720. ApplyServerSideEncryptionByDefault *ServerSideEncryptionByDefault `type:"structure"`
  16721. }
  16722. // String returns the string representation
  16723. func (s ServerSideEncryptionRule) String() string {
  16724. return awsutil.Prettify(s)
  16725. }
  16726. // GoString returns the string representation
  16727. func (s ServerSideEncryptionRule) GoString() string {
  16728. return s.String()
  16729. }
  16730. // Validate inspects the fields of the type to determine if they are valid.
  16731. func (s *ServerSideEncryptionRule) Validate() error {
  16732. invalidParams := request.ErrInvalidParams{Context: "ServerSideEncryptionRule"}
  16733. if s.ApplyServerSideEncryptionByDefault != nil {
  16734. if err := s.ApplyServerSideEncryptionByDefault.Validate(); err != nil {
  16735. invalidParams.AddNested("ApplyServerSideEncryptionByDefault", err.(request.ErrInvalidParams))
  16736. }
  16737. }
  16738. if invalidParams.Len() > 0 {
  16739. return invalidParams
  16740. }
  16741. return nil
  16742. }
  16743. // SetApplyServerSideEncryptionByDefault sets the ApplyServerSideEncryptionByDefault field's value.
  16744. func (s *ServerSideEncryptionRule) SetApplyServerSideEncryptionByDefault(v *ServerSideEncryptionByDefault) *ServerSideEncryptionRule {
  16745. s.ApplyServerSideEncryptionByDefault = v
  16746. return s
  16747. }
  16748. // Container for filters that define which source objects should be replicated.
  16749. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SourceSelectionCriteria
  16750. type SourceSelectionCriteria struct {
  16751. _ struct{} `type:"structure"`
  16752. // Container for filter information of selection of KMS Encrypted S3 objects.
  16753. SseKmsEncryptedObjects *SseKmsEncryptedObjects `type:"structure"`
  16754. }
  16755. // String returns the string representation
  16756. func (s SourceSelectionCriteria) String() string {
  16757. return awsutil.Prettify(s)
  16758. }
  16759. // GoString returns the string representation
  16760. func (s SourceSelectionCriteria) GoString() string {
  16761. return s.String()
  16762. }
  16763. // Validate inspects the fields of the type to determine if they are valid.
  16764. func (s *SourceSelectionCriteria) Validate() error {
  16765. invalidParams := request.ErrInvalidParams{Context: "SourceSelectionCriteria"}
  16766. if s.SseKmsEncryptedObjects != nil {
  16767. if err := s.SseKmsEncryptedObjects.Validate(); err != nil {
  16768. invalidParams.AddNested("SseKmsEncryptedObjects", err.(request.ErrInvalidParams))
  16769. }
  16770. }
  16771. if invalidParams.Len() > 0 {
  16772. return invalidParams
  16773. }
  16774. return nil
  16775. }
  16776. // SetSseKmsEncryptedObjects sets the SseKmsEncryptedObjects field's value.
  16777. func (s *SourceSelectionCriteria) SetSseKmsEncryptedObjects(v *SseKmsEncryptedObjects) *SourceSelectionCriteria {
  16778. s.SseKmsEncryptedObjects = v
  16779. return s
  16780. }
  16781. // Container for filter information of selection of KMS Encrypted S3 objects.
  16782. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/SseKmsEncryptedObjects
  16783. type SseKmsEncryptedObjects struct {
  16784. _ struct{} `type:"structure"`
  16785. // The replication for KMS encrypted S3 objects is disabled if status is not
  16786. // Enabled.
  16787. //
  16788. // Status is a required field
  16789. Status *string `type:"string" required:"true" enum:"SseKmsEncryptedObjectsStatus"`
  16790. }
  16791. // String returns the string representation
  16792. func (s SseKmsEncryptedObjects) String() string {
  16793. return awsutil.Prettify(s)
  16794. }
  16795. // GoString returns the string representation
  16796. func (s SseKmsEncryptedObjects) GoString() string {
  16797. return s.String()
  16798. }
  16799. // Validate inspects the fields of the type to determine if they are valid.
  16800. func (s *SseKmsEncryptedObjects) Validate() error {
  16801. invalidParams := request.ErrInvalidParams{Context: "SseKmsEncryptedObjects"}
  16802. if s.Status == nil {
  16803. invalidParams.Add(request.NewErrParamRequired("Status"))
  16804. }
  16805. if invalidParams.Len() > 0 {
  16806. return invalidParams
  16807. }
  16808. return nil
  16809. }
  16810. // SetStatus sets the Status field's value.
  16811. func (s *SseKmsEncryptedObjects) SetStatus(v string) *SseKmsEncryptedObjects {
  16812. s.Status = &v
  16813. return s
  16814. }
  16815. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/StorageClassAnalysis
  16816. type StorageClassAnalysis struct {
  16817. _ struct{} `type:"structure"`
  16818. // A container used to describe how data related to the storage class analysis
  16819. // should be exported.
  16820. DataExport *StorageClassAnalysisDataExport `type:"structure"`
  16821. }
  16822. // String returns the string representation
  16823. func (s StorageClassAnalysis) String() string {
  16824. return awsutil.Prettify(s)
  16825. }
  16826. // GoString returns the string representation
  16827. func (s StorageClassAnalysis) GoString() string {
  16828. return s.String()
  16829. }
  16830. // Validate inspects the fields of the type to determine if they are valid.
  16831. func (s *StorageClassAnalysis) Validate() error {
  16832. invalidParams := request.ErrInvalidParams{Context: "StorageClassAnalysis"}
  16833. if s.DataExport != nil {
  16834. if err := s.DataExport.Validate(); err != nil {
  16835. invalidParams.AddNested("DataExport", err.(request.ErrInvalidParams))
  16836. }
  16837. }
  16838. if invalidParams.Len() > 0 {
  16839. return invalidParams
  16840. }
  16841. return nil
  16842. }
  16843. // SetDataExport sets the DataExport field's value.
  16844. func (s *StorageClassAnalysis) SetDataExport(v *StorageClassAnalysisDataExport) *StorageClassAnalysis {
  16845. s.DataExport = v
  16846. return s
  16847. }
  16848. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/StorageClassAnalysisDataExport
  16849. type StorageClassAnalysisDataExport struct {
  16850. _ struct{} `type:"structure"`
  16851. // The place to store the data for an analysis.
  16852. //
  16853. // Destination is a required field
  16854. Destination *AnalyticsExportDestination `type:"structure" required:"true"`
  16855. // The version of the output schema to use when exporting data. Must be V_1.
  16856. //
  16857. // OutputSchemaVersion is a required field
  16858. OutputSchemaVersion *string `type:"string" required:"true" enum:"StorageClassAnalysisSchemaVersion"`
  16859. }
  16860. // String returns the string representation
  16861. func (s StorageClassAnalysisDataExport) String() string {
  16862. return awsutil.Prettify(s)
  16863. }
  16864. // GoString returns the string representation
  16865. func (s StorageClassAnalysisDataExport) GoString() string {
  16866. return s.String()
  16867. }
  16868. // Validate inspects the fields of the type to determine if they are valid.
  16869. func (s *StorageClassAnalysisDataExport) Validate() error {
  16870. invalidParams := request.ErrInvalidParams{Context: "StorageClassAnalysisDataExport"}
  16871. if s.Destination == nil {
  16872. invalidParams.Add(request.NewErrParamRequired("Destination"))
  16873. }
  16874. if s.OutputSchemaVersion == nil {
  16875. invalidParams.Add(request.NewErrParamRequired("OutputSchemaVersion"))
  16876. }
  16877. if s.Destination != nil {
  16878. if err := s.Destination.Validate(); err != nil {
  16879. invalidParams.AddNested("Destination", err.(request.ErrInvalidParams))
  16880. }
  16881. }
  16882. if invalidParams.Len() > 0 {
  16883. return invalidParams
  16884. }
  16885. return nil
  16886. }
  16887. // SetDestination sets the Destination field's value.
  16888. func (s *StorageClassAnalysisDataExport) SetDestination(v *AnalyticsExportDestination) *StorageClassAnalysisDataExport {
  16889. s.Destination = v
  16890. return s
  16891. }
  16892. // SetOutputSchemaVersion sets the OutputSchemaVersion field's value.
  16893. func (s *StorageClassAnalysisDataExport) SetOutputSchemaVersion(v string) *StorageClassAnalysisDataExport {
  16894. s.OutputSchemaVersion = &v
  16895. return s
  16896. }
  16897. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Tag
  16898. type Tag struct {
  16899. _ struct{} `type:"structure"`
  16900. // Name of the tag.
  16901. //
  16902. // Key is a required field
  16903. Key *string `min:"1" type:"string" required:"true"`
  16904. // Value of the tag.
  16905. //
  16906. // Value is a required field
  16907. Value *string `type:"string" required:"true"`
  16908. }
  16909. // String returns the string representation
  16910. func (s Tag) String() string {
  16911. return awsutil.Prettify(s)
  16912. }
  16913. // GoString returns the string representation
  16914. func (s Tag) GoString() string {
  16915. return s.String()
  16916. }
  16917. // Validate inspects the fields of the type to determine if they are valid.
  16918. func (s *Tag) Validate() error {
  16919. invalidParams := request.ErrInvalidParams{Context: "Tag"}
  16920. if s.Key == nil {
  16921. invalidParams.Add(request.NewErrParamRequired("Key"))
  16922. }
  16923. if s.Key != nil && len(*s.Key) < 1 {
  16924. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  16925. }
  16926. if s.Value == nil {
  16927. invalidParams.Add(request.NewErrParamRequired("Value"))
  16928. }
  16929. if invalidParams.Len() > 0 {
  16930. return invalidParams
  16931. }
  16932. return nil
  16933. }
  16934. // SetKey sets the Key field's value.
  16935. func (s *Tag) SetKey(v string) *Tag {
  16936. s.Key = &v
  16937. return s
  16938. }
  16939. // SetValue sets the Value field's value.
  16940. func (s *Tag) SetValue(v string) *Tag {
  16941. s.Value = &v
  16942. return s
  16943. }
  16944. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Tagging
  16945. type Tagging struct {
  16946. _ struct{} `type:"structure"`
  16947. // TagSet is a required field
  16948. TagSet []*Tag `locationNameList:"Tag" type:"list" required:"true"`
  16949. }
  16950. // String returns the string representation
  16951. func (s Tagging) String() string {
  16952. return awsutil.Prettify(s)
  16953. }
  16954. // GoString returns the string representation
  16955. func (s Tagging) GoString() string {
  16956. return s.String()
  16957. }
  16958. // Validate inspects the fields of the type to determine if they are valid.
  16959. func (s *Tagging) Validate() error {
  16960. invalidParams := request.ErrInvalidParams{Context: "Tagging"}
  16961. if s.TagSet == nil {
  16962. invalidParams.Add(request.NewErrParamRequired("TagSet"))
  16963. }
  16964. if s.TagSet != nil {
  16965. for i, v := range s.TagSet {
  16966. if v == nil {
  16967. continue
  16968. }
  16969. if err := v.Validate(); err != nil {
  16970. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TagSet", i), err.(request.ErrInvalidParams))
  16971. }
  16972. }
  16973. }
  16974. if invalidParams.Len() > 0 {
  16975. return invalidParams
  16976. }
  16977. return nil
  16978. }
  16979. // SetTagSet sets the TagSet field's value.
  16980. func (s *Tagging) SetTagSet(v []*Tag) *Tagging {
  16981. s.TagSet = v
  16982. return s
  16983. }
  16984. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TargetGrant
  16985. type TargetGrant struct {
  16986. _ struct{} `type:"structure"`
  16987. Grantee *Grantee `type:"structure" xmlPrefix:"xsi" xmlURI:"http://www.w3.org/2001/XMLSchema-instance"`
  16988. // Logging permissions assigned to the Grantee for the bucket.
  16989. Permission *string `type:"string" enum:"BucketLogsPermission"`
  16990. }
  16991. // String returns the string representation
  16992. func (s TargetGrant) String() string {
  16993. return awsutil.Prettify(s)
  16994. }
  16995. // GoString returns the string representation
  16996. func (s TargetGrant) GoString() string {
  16997. return s.String()
  16998. }
  16999. // Validate inspects the fields of the type to determine if they are valid.
  17000. func (s *TargetGrant) Validate() error {
  17001. invalidParams := request.ErrInvalidParams{Context: "TargetGrant"}
  17002. if s.Grantee != nil {
  17003. if err := s.Grantee.Validate(); err != nil {
  17004. invalidParams.AddNested("Grantee", err.(request.ErrInvalidParams))
  17005. }
  17006. }
  17007. if invalidParams.Len() > 0 {
  17008. return invalidParams
  17009. }
  17010. return nil
  17011. }
  17012. // SetGrantee sets the Grantee field's value.
  17013. func (s *TargetGrant) SetGrantee(v *Grantee) *TargetGrant {
  17014. s.Grantee = v
  17015. return s
  17016. }
  17017. // SetPermission sets the Permission field's value.
  17018. func (s *TargetGrant) SetPermission(v string) *TargetGrant {
  17019. s.Permission = &v
  17020. return s
  17021. }
  17022. // Container for specifying the configuration when you want Amazon S3 to publish
  17023. // events to an Amazon Simple Notification Service (Amazon SNS) topic.
  17024. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TopicConfiguration
  17025. type TopicConfiguration struct {
  17026. _ struct{} `type:"structure"`
  17027. // Events is a required field
  17028. Events []*string `locationName:"Event" type:"list" flattened:"true" required:"true"`
  17029. // Container for object key name filtering rules. For information about key
  17030. // name filtering, go to Configuring Event Notifications (http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  17031. Filter *NotificationConfigurationFilter `type:"structure"`
  17032. // Optional unique identifier for configurations in a notification configuration.
  17033. // If you don't provide one, Amazon S3 will assign an ID.
  17034. Id *string `type:"string"`
  17035. // Amazon SNS topic ARN to which Amazon S3 will publish a message when it detects
  17036. // events of specified type.
  17037. //
  17038. // TopicArn is a required field
  17039. TopicArn *string `locationName:"Topic" type:"string" required:"true"`
  17040. }
  17041. // String returns the string representation
  17042. func (s TopicConfiguration) String() string {
  17043. return awsutil.Prettify(s)
  17044. }
  17045. // GoString returns the string representation
  17046. func (s TopicConfiguration) GoString() string {
  17047. return s.String()
  17048. }
  17049. // Validate inspects the fields of the type to determine if they are valid.
  17050. func (s *TopicConfiguration) Validate() error {
  17051. invalidParams := request.ErrInvalidParams{Context: "TopicConfiguration"}
  17052. if s.Events == nil {
  17053. invalidParams.Add(request.NewErrParamRequired("Events"))
  17054. }
  17055. if s.TopicArn == nil {
  17056. invalidParams.Add(request.NewErrParamRequired("TopicArn"))
  17057. }
  17058. if invalidParams.Len() > 0 {
  17059. return invalidParams
  17060. }
  17061. return nil
  17062. }
  17063. // SetEvents sets the Events field's value.
  17064. func (s *TopicConfiguration) SetEvents(v []*string) *TopicConfiguration {
  17065. s.Events = v
  17066. return s
  17067. }
  17068. // SetFilter sets the Filter field's value.
  17069. func (s *TopicConfiguration) SetFilter(v *NotificationConfigurationFilter) *TopicConfiguration {
  17070. s.Filter = v
  17071. return s
  17072. }
  17073. // SetId sets the Id field's value.
  17074. func (s *TopicConfiguration) SetId(v string) *TopicConfiguration {
  17075. s.Id = &v
  17076. return s
  17077. }
  17078. // SetTopicArn sets the TopicArn field's value.
  17079. func (s *TopicConfiguration) SetTopicArn(v string) *TopicConfiguration {
  17080. s.TopicArn = &v
  17081. return s
  17082. }
  17083. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/TopicConfigurationDeprecated
  17084. type TopicConfigurationDeprecated struct {
  17085. _ struct{} `type:"structure"`
  17086. // Bucket event for which to send notifications.
  17087. Event *string `deprecated:"true" type:"string" enum:"Event"`
  17088. Events []*string `locationName:"Event" type:"list" flattened:"true"`
  17089. // Optional unique identifier for configurations in a notification configuration.
  17090. // If you don't provide one, Amazon S3 will assign an ID.
  17091. Id *string `type:"string"`
  17092. // Amazon SNS topic to which Amazon S3 will publish a message to report the
  17093. // specified events for the bucket.
  17094. Topic *string `type:"string"`
  17095. }
  17096. // String returns the string representation
  17097. func (s TopicConfigurationDeprecated) String() string {
  17098. return awsutil.Prettify(s)
  17099. }
  17100. // GoString returns the string representation
  17101. func (s TopicConfigurationDeprecated) GoString() string {
  17102. return s.String()
  17103. }
  17104. // SetEvent sets the Event field's value.
  17105. func (s *TopicConfigurationDeprecated) SetEvent(v string) *TopicConfigurationDeprecated {
  17106. s.Event = &v
  17107. return s
  17108. }
  17109. // SetEvents sets the Events field's value.
  17110. func (s *TopicConfigurationDeprecated) SetEvents(v []*string) *TopicConfigurationDeprecated {
  17111. s.Events = v
  17112. return s
  17113. }
  17114. // SetId sets the Id field's value.
  17115. func (s *TopicConfigurationDeprecated) SetId(v string) *TopicConfigurationDeprecated {
  17116. s.Id = &v
  17117. return s
  17118. }
  17119. // SetTopic sets the Topic field's value.
  17120. func (s *TopicConfigurationDeprecated) SetTopic(v string) *TopicConfigurationDeprecated {
  17121. s.Topic = &v
  17122. return s
  17123. }
  17124. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/Transition
  17125. type Transition struct {
  17126. _ struct{} `type:"structure"`
  17127. // Indicates at what date the object is to be moved or deleted. Should be in
  17128. // GMT ISO 8601 Format.
  17129. Date *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  17130. // Indicates the lifetime, in days, of the objects that are subject to the rule.
  17131. // The value must be a non-zero positive integer.
  17132. Days *int64 `type:"integer"`
  17133. // The class of storage used to store the object.
  17134. StorageClass *string `type:"string" enum:"TransitionStorageClass"`
  17135. }
  17136. // String returns the string representation
  17137. func (s Transition) String() string {
  17138. return awsutil.Prettify(s)
  17139. }
  17140. // GoString returns the string representation
  17141. func (s Transition) GoString() string {
  17142. return s.String()
  17143. }
  17144. // SetDate sets the Date field's value.
  17145. func (s *Transition) SetDate(v time.Time) *Transition {
  17146. s.Date = &v
  17147. return s
  17148. }
  17149. // SetDays sets the Days field's value.
  17150. func (s *Transition) SetDays(v int64) *Transition {
  17151. s.Days = &v
  17152. return s
  17153. }
  17154. // SetStorageClass sets the StorageClass field's value.
  17155. func (s *Transition) SetStorageClass(v string) *Transition {
  17156. s.StorageClass = &v
  17157. return s
  17158. }
  17159. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopyRequest
  17160. type UploadPartCopyInput struct {
  17161. _ struct{} `type:"structure"`
  17162. // Bucket is a required field
  17163. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  17164. // The name of the source bucket and key name of the source object, separated
  17165. // by a slash (/). Must be URL-encoded.
  17166. //
  17167. // CopySource is a required field
  17168. CopySource *string `location:"header" locationName:"x-amz-copy-source" type:"string" required:"true"`
  17169. // Copies the object if its entity tag (ETag) matches the specified tag.
  17170. CopySourceIfMatch *string `location:"header" locationName:"x-amz-copy-source-if-match" type:"string"`
  17171. // Copies the object if it has been modified since the specified time.
  17172. CopySourceIfModifiedSince *time.Time `location:"header" locationName:"x-amz-copy-source-if-modified-since" type:"timestamp" timestampFormat:"rfc822"`
  17173. // Copies the object if its entity tag (ETag) is different than the specified
  17174. // ETag.
  17175. CopySourceIfNoneMatch *string `location:"header" locationName:"x-amz-copy-source-if-none-match" type:"string"`
  17176. // Copies the object if it hasn't been modified since the specified time.
  17177. CopySourceIfUnmodifiedSince *time.Time `location:"header" locationName:"x-amz-copy-source-if-unmodified-since" type:"timestamp" timestampFormat:"rfc822"`
  17178. // The range of bytes to copy from the source object. The range value must use
  17179. // the form bytes=first-last, where the first and last are the zero-based byte
  17180. // offsets to copy. For example, bytes=0-9 indicates that you want to copy the
  17181. // first ten bytes of the source. You can copy a range only if the source object
  17182. // is greater than 5 GB.
  17183. CopySourceRange *string `location:"header" locationName:"x-amz-copy-source-range" type:"string"`
  17184. // Specifies the algorithm to use when decrypting the source object (e.g., AES256).
  17185. CopySourceSSECustomerAlgorithm *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-algorithm" type:"string"`
  17186. // Specifies the customer-provided encryption key for Amazon S3 to use to decrypt
  17187. // the source object. The encryption key provided in this header must be one
  17188. // that was used when the source object was created.
  17189. CopySourceSSECustomerKey *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-key" type:"string"`
  17190. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  17191. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  17192. // key was transmitted without error.
  17193. CopySourceSSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-copy-source-server-side-encryption-customer-key-MD5" type:"string"`
  17194. // Key is a required field
  17195. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  17196. // Part number of part being copied. This is a positive integer between 1 and
  17197. // 10,000.
  17198. //
  17199. // PartNumber is a required field
  17200. PartNumber *int64 `location:"querystring" locationName:"partNumber" type:"integer" required:"true"`
  17201. // Confirms that the requester knows that she or he will be charged for the
  17202. // request. Bucket owners need not specify this parameter in their requests.
  17203. // Documentation on downloading objects from requester pays buckets can be found
  17204. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  17205. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  17206. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  17207. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  17208. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  17209. // data. This value is used to store the object and then it is discarded; Amazon
  17210. // does not store the encryption key. The key must be appropriate for use with
  17211. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  17212. // header. This must be the same encryption key specified in the initiate multipart
  17213. // upload request.
  17214. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  17215. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  17216. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  17217. // key was transmitted without error.
  17218. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  17219. // Upload ID identifying the multipart upload whose part is being copied.
  17220. //
  17221. // UploadId is a required field
  17222. UploadId *string `location:"querystring" locationName:"uploadId" type:"string" required:"true"`
  17223. }
  17224. // String returns the string representation
  17225. func (s UploadPartCopyInput) String() string {
  17226. return awsutil.Prettify(s)
  17227. }
  17228. // GoString returns the string representation
  17229. func (s UploadPartCopyInput) GoString() string {
  17230. return s.String()
  17231. }
  17232. // Validate inspects the fields of the type to determine if they are valid.
  17233. func (s *UploadPartCopyInput) Validate() error {
  17234. invalidParams := request.ErrInvalidParams{Context: "UploadPartCopyInput"}
  17235. if s.Bucket == nil {
  17236. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  17237. }
  17238. if s.CopySource == nil {
  17239. invalidParams.Add(request.NewErrParamRequired("CopySource"))
  17240. }
  17241. if s.Key == nil {
  17242. invalidParams.Add(request.NewErrParamRequired("Key"))
  17243. }
  17244. if s.Key != nil && len(*s.Key) < 1 {
  17245. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  17246. }
  17247. if s.PartNumber == nil {
  17248. invalidParams.Add(request.NewErrParamRequired("PartNumber"))
  17249. }
  17250. if s.UploadId == nil {
  17251. invalidParams.Add(request.NewErrParamRequired("UploadId"))
  17252. }
  17253. if invalidParams.Len() > 0 {
  17254. return invalidParams
  17255. }
  17256. return nil
  17257. }
  17258. // SetBucket sets the Bucket field's value.
  17259. func (s *UploadPartCopyInput) SetBucket(v string) *UploadPartCopyInput {
  17260. s.Bucket = &v
  17261. return s
  17262. }
  17263. func (s *UploadPartCopyInput) getBucket() (v string) {
  17264. if s.Bucket == nil {
  17265. return v
  17266. }
  17267. return *s.Bucket
  17268. }
  17269. // SetCopySource sets the CopySource field's value.
  17270. func (s *UploadPartCopyInput) SetCopySource(v string) *UploadPartCopyInput {
  17271. s.CopySource = &v
  17272. return s
  17273. }
  17274. // SetCopySourceIfMatch sets the CopySourceIfMatch field's value.
  17275. func (s *UploadPartCopyInput) SetCopySourceIfMatch(v string) *UploadPartCopyInput {
  17276. s.CopySourceIfMatch = &v
  17277. return s
  17278. }
  17279. // SetCopySourceIfModifiedSince sets the CopySourceIfModifiedSince field's value.
  17280. func (s *UploadPartCopyInput) SetCopySourceIfModifiedSince(v time.Time) *UploadPartCopyInput {
  17281. s.CopySourceIfModifiedSince = &v
  17282. return s
  17283. }
  17284. // SetCopySourceIfNoneMatch sets the CopySourceIfNoneMatch field's value.
  17285. func (s *UploadPartCopyInput) SetCopySourceIfNoneMatch(v string) *UploadPartCopyInput {
  17286. s.CopySourceIfNoneMatch = &v
  17287. return s
  17288. }
  17289. // SetCopySourceIfUnmodifiedSince sets the CopySourceIfUnmodifiedSince field's value.
  17290. func (s *UploadPartCopyInput) SetCopySourceIfUnmodifiedSince(v time.Time) *UploadPartCopyInput {
  17291. s.CopySourceIfUnmodifiedSince = &v
  17292. return s
  17293. }
  17294. // SetCopySourceRange sets the CopySourceRange field's value.
  17295. func (s *UploadPartCopyInput) SetCopySourceRange(v string) *UploadPartCopyInput {
  17296. s.CopySourceRange = &v
  17297. return s
  17298. }
  17299. // SetCopySourceSSECustomerAlgorithm sets the CopySourceSSECustomerAlgorithm field's value.
  17300. func (s *UploadPartCopyInput) SetCopySourceSSECustomerAlgorithm(v string) *UploadPartCopyInput {
  17301. s.CopySourceSSECustomerAlgorithm = &v
  17302. return s
  17303. }
  17304. // SetCopySourceSSECustomerKey sets the CopySourceSSECustomerKey field's value.
  17305. func (s *UploadPartCopyInput) SetCopySourceSSECustomerKey(v string) *UploadPartCopyInput {
  17306. s.CopySourceSSECustomerKey = &v
  17307. return s
  17308. }
  17309. func (s *UploadPartCopyInput) getCopySourceSSECustomerKey() (v string) {
  17310. if s.CopySourceSSECustomerKey == nil {
  17311. return v
  17312. }
  17313. return *s.CopySourceSSECustomerKey
  17314. }
  17315. // SetCopySourceSSECustomerKeyMD5 sets the CopySourceSSECustomerKeyMD5 field's value.
  17316. func (s *UploadPartCopyInput) SetCopySourceSSECustomerKeyMD5(v string) *UploadPartCopyInput {
  17317. s.CopySourceSSECustomerKeyMD5 = &v
  17318. return s
  17319. }
  17320. // SetKey sets the Key field's value.
  17321. func (s *UploadPartCopyInput) SetKey(v string) *UploadPartCopyInput {
  17322. s.Key = &v
  17323. return s
  17324. }
  17325. // SetPartNumber sets the PartNumber field's value.
  17326. func (s *UploadPartCopyInput) SetPartNumber(v int64) *UploadPartCopyInput {
  17327. s.PartNumber = &v
  17328. return s
  17329. }
  17330. // SetRequestPayer sets the RequestPayer field's value.
  17331. func (s *UploadPartCopyInput) SetRequestPayer(v string) *UploadPartCopyInput {
  17332. s.RequestPayer = &v
  17333. return s
  17334. }
  17335. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  17336. func (s *UploadPartCopyInput) SetSSECustomerAlgorithm(v string) *UploadPartCopyInput {
  17337. s.SSECustomerAlgorithm = &v
  17338. return s
  17339. }
  17340. // SetSSECustomerKey sets the SSECustomerKey field's value.
  17341. func (s *UploadPartCopyInput) SetSSECustomerKey(v string) *UploadPartCopyInput {
  17342. s.SSECustomerKey = &v
  17343. return s
  17344. }
  17345. func (s *UploadPartCopyInput) getSSECustomerKey() (v string) {
  17346. if s.SSECustomerKey == nil {
  17347. return v
  17348. }
  17349. return *s.SSECustomerKey
  17350. }
  17351. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  17352. func (s *UploadPartCopyInput) SetSSECustomerKeyMD5(v string) *UploadPartCopyInput {
  17353. s.SSECustomerKeyMD5 = &v
  17354. return s
  17355. }
  17356. // SetUploadId sets the UploadId field's value.
  17357. func (s *UploadPartCopyInput) SetUploadId(v string) *UploadPartCopyInput {
  17358. s.UploadId = &v
  17359. return s
  17360. }
  17361. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartCopyOutput
  17362. type UploadPartCopyOutput struct {
  17363. _ struct{} `type:"structure" payload:"CopyPartResult"`
  17364. CopyPartResult *CopyPartResult `type:"structure"`
  17365. // The version of the source object that was copied, if you have enabled versioning
  17366. // on the source bucket.
  17367. CopySourceVersionId *string `location:"header" locationName:"x-amz-copy-source-version-id" type:"string"`
  17368. // If present, indicates that the requester was successfully charged for the
  17369. // request.
  17370. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  17371. // If server-side encryption with a customer-provided encryption key was requested,
  17372. // the response will include this header confirming the encryption algorithm
  17373. // used.
  17374. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  17375. // If server-side encryption with a customer-provided encryption key was requested,
  17376. // the response will include this header to provide round trip message integrity
  17377. // verification of the customer-provided encryption key.
  17378. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  17379. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  17380. // encryption key that was used for the object.
  17381. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  17382. // The Server-side encryption algorithm used when storing this object in S3
  17383. // (e.g., AES256, aws:kms).
  17384. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  17385. }
  17386. // String returns the string representation
  17387. func (s UploadPartCopyOutput) String() string {
  17388. return awsutil.Prettify(s)
  17389. }
  17390. // GoString returns the string representation
  17391. func (s UploadPartCopyOutput) GoString() string {
  17392. return s.String()
  17393. }
  17394. // SetCopyPartResult sets the CopyPartResult field's value.
  17395. func (s *UploadPartCopyOutput) SetCopyPartResult(v *CopyPartResult) *UploadPartCopyOutput {
  17396. s.CopyPartResult = v
  17397. return s
  17398. }
  17399. // SetCopySourceVersionId sets the CopySourceVersionId field's value.
  17400. func (s *UploadPartCopyOutput) SetCopySourceVersionId(v string) *UploadPartCopyOutput {
  17401. s.CopySourceVersionId = &v
  17402. return s
  17403. }
  17404. // SetRequestCharged sets the RequestCharged field's value.
  17405. func (s *UploadPartCopyOutput) SetRequestCharged(v string) *UploadPartCopyOutput {
  17406. s.RequestCharged = &v
  17407. return s
  17408. }
  17409. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  17410. func (s *UploadPartCopyOutput) SetSSECustomerAlgorithm(v string) *UploadPartCopyOutput {
  17411. s.SSECustomerAlgorithm = &v
  17412. return s
  17413. }
  17414. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  17415. func (s *UploadPartCopyOutput) SetSSECustomerKeyMD5(v string) *UploadPartCopyOutput {
  17416. s.SSECustomerKeyMD5 = &v
  17417. return s
  17418. }
  17419. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  17420. func (s *UploadPartCopyOutput) SetSSEKMSKeyId(v string) *UploadPartCopyOutput {
  17421. s.SSEKMSKeyId = &v
  17422. return s
  17423. }
  17424. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  17425. func (s *UploadPartCopyOutput) SetServerSideEncryption(v string) *UploadPartCopyOutput {
  17426. s.ServerSideEncryption = &v
  17427. return s
  17428. }
  17429. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartRequest
  17430. type UploadPartInput struct {
  17431. _ struct{} `type:"structure" payload:"Body"`
  17432. // Object data.
  17433. Body io.ReadSeeker `type:"blob"`
  17434. // Name of the bucket to which the multipart upload was initiated.
  17435. //
  17436. // Bucket is a required field
  17437. Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"`
  17438. // Size of the body in bytes. This parameter is useful when the size of the
  17439. // body cannot be determined automatically.
  17440. ContentLength *int64 `location:"header" locationName:"Content-Length" type:"long"`
  17441. // The base64-encoded 128-bit MD5 digest of the part data.
  17442. ContentMD5 *string `location:"header" locationName:"Content-MD5" type:"string"`
  17443. // Object key for which the multipart upload was initiated.
  17444. //
  17445. // Key is a required field
  17446. Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"`
  17447. // Part number of part being uploaded. This is a positive integer between 1
  17448. // and 10,000.
  17449. //
  17450. // PartNumber is a required field
  17451. PartNumber *int64 `location:"querystring" locationName:"partNumber" type:"integer" required:"true"`
  17452. // Confirms that the requester knows that she or he will be charged for the
  17453. // request. Bucket owners need not specify this parameter in their requests.
  17454. // Documentation on downloading objects from requester pays buckets can be found
  17455. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  17456. RequestPayer *string `location:"header" locationName:"x-amz-request-payer" type:"string" enum:"RequestPayer"`
  17457. // Specifies the algorithm to use to when encrypting the object (e.g., AES256).
  17458. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  17459. // Specifies the customer-provided encryption key for Amazon S3 to use in encrypting
  17460. // data. This value is used to store the object and then it is discarded; Amazon
  17461. // does not store the encryption key. The key must be appropriate for use with
  17462. // the algorithm specified in the x-amz-server-side​-encryption​-customer-algorithm
  17463. // header. This must be the same encryption key specified in the initiate multipart
  17464. // upload request.
  17465. SSECustomerKey *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key" type:"string"`
  17466. // Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321.
  17467. // Amazon S3 uses this header for a message integrity check to ensure the encryption
  17468. // key was transmitted without error.
  17469. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  17470. // Upload ID identifying the multipart upload whose part is being uploaded.
  17471. //
  17472. // UploadId is a required field
  17473. UploadId *string `location:"querystring" locationName:"uploadId" type:"string" required:"true"`
  17474. }
  17475. // String returns the string representation
  17476. func (s UploadPartInput) String() string {
  17477. return awsutil.Prettify(s)
  17478. }
  17479. // GoString returns the string representation
  17480. func (s UploadPartInput) GoString() string {
  17481. return s.String()
  17482. }
  17483. // Validate inspects the fields of the type to determine if they are valid.
  17484. func (s *UploadPartInput) Validate() error {
  17485. invalidParams := request.ErrInvalidParams{Context: "UploadPartInput"}
  17486. if s.Bucket == nil {
  17487. invalidParams.Add(request.NewErrParamRequired("Bucket"))
  17488. }
  17489. if s.Key == nil {
  17490. invalidParams.Add(request.NewErrParamRequired("Key"))
  17491. }
  17492. if s.Key != nil && len(*s.Key) < 1 {
  17493. invalidParams.Add(request.NewErrParamMinLen("Key", 1))
  17494. }
  17495. if s.PartNumber == nil {
  17496. invalidParams.Add(request.NewErrParamRequired("PartNumber"))
  17497. }
  17498. if s.UploadId == nil {
  17499. invalidParams.Add(request.NewErrParamRequired("UploadId"))
  17500. }
  17501. if invalidParams.Len() > 0 {
  17502. return invalidParams
  17503. }
  17504. return nil
  17505. }
  17506. // SetBody sets the Body field's value.
  17507. func (s *UploadPartInput) SetBody(v io.ReadSeeker) *UploadPartInput {
  17508. s.Body = v
  17509. return s
  17510. }
  17511. // SetBucket sets the Bucket field's value.
  17512. func (s *UploadPartInput) SetBucket(v string) *UploadPartInput {
  17513. s.Bucket = &v
  17514. return s
  17515. }
  17516. func (s *UploadPartInput) getBucket() (v string) {
  17517. if s.Bucket == nil {
  17518. return v
  17519. }
  17520. return *s.Bucket
  17521. }
  17522. // SetContentLength sets the ContentLength field's value.
  17523. func (s *UploadPartInput) SetContentLength(v int64) *UploadPartInput {
  17524. s.ContentLength = &v
  17525. return s
  17526. }
  17527. // SetContentMD5 sets the ContentMD5 field's value.
  17528. func (s *UploadPartInput) SetContentMD5(v string) *UploadPartInput {
  17529. s.ContentMD5 = &v
  17530. return s
  17531. }
  17532. // SetKey sets the Key field's value.
  17533. func (s *UploadPartInput) SetKey(v string) *UploadPartInput {
  17534. s.Key = &v
  17535. return s
  17536. }
  17537. // SetPartNumber sets the PartNumber field's value.
  17538. func (s *UploadPartInput) SetPartNumber(v int64) *UploadPartInput {
  17539. s.PartNumber = &v
  17540. return s
  17541. }
  17542. // SetRequestPayer sets the RequestPayer field's value.
  17543. func (s *UploadPartInput) SetRequestPayer(v string) *UploadPartInput {
  17544. s.RequestPayer = &v
  17545. return s
  17546. }
  17547. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  17548. func (s *UploadPartInput) SetSSECustomerAlgorithm(v string) *UploadPartInput {
  17549. s.SSECustomerAlgorithm = &v
  17550. return s
  17551. }
  17552. // SetSSECustomerKey sets the SSECustomerKey field's value.
  17553. func (s *UploadPartInput) SetSSECustomerKey(v string) *UploadPartInput {
  17554. s.SSECustomerKey = &v
  17555. return s
  17556. }
  17557. func (s *UploadPartInput) getSSECustomerKey() (v string) {
  17558. if s.SSECustomerKey == nil {
  17559. return v
  17560. }
  17561. return *s.SSECustomerKey
  17562. }
  17563. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  17564. func (s *UploadPartInput) SetSSECustomerKeyMD5(v string) *UploadPartInput {
  17565. s.SSECustomerKeyMD5 = &v
  17566. return s
  17567. }
  17568. // SetUploadId sets the UploadId field's value.
  17569. func (s *UploadPartInput) SetUploadId(v string) *UploadPartInput {
  17570. s.UploadId = &v
  17571. return s
  17572. }
  17573. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/UploadPartOutput
  17574. type UploadPartOutput struct {
  17575. _ struct{} `type:"structure"`
  17576. // Entity tag for the uploaded object.
  17577. ETag *string `location:"header" locationName:"ETag" type:"string"`
  17578. // If present, indicates that the requester was successfully charged for the
  17579. // request.
  17580. RequestCharged *string `location:"header" locationName:"x-amz-request-charged" type:"string" enum:"RequestCharged"`
  17581. // If server-side encryption with a customer-provided encryption key was requested,
  17582. // the response will include this header confirming the encryption algorithm
  17583. // used.
  17584. SSECustomerAlgorithm *string `location:"header" locationName:"x-amz-server-side-encryption-customer-algorithm" type:"string"`
  17585. // If server-side encryption with a customer-provided encryption key was requested,
  17586. // the response will include this header to provide round trip message integrity
  17587. // verification of the customer-provided encryption key.
  17588. SSECustomerKeyMD5 *string `location:"header" locationName:"x-amz-server-side-encryption-customer-key-MD5" type:"string"`
  17589. // If present, specifies the ID of the AWS Key Management Service (KMS) master
  17590. // encryption key that was used for the object.
  17591. SSEKMSKeyId *string `location:"header" locationName:"x-amz-server-side-encryption-aws-kms-key-id" type:"string"`
  17592. // The Server-side encryption algorithm used when storing this object in S3
  17593. // (e.g., AES256, aws:kms).
  17594. ServerSideEncryption *string `location:"header" locationName:"x-amz-server-side-encryption" type:"string" enum:"ServerSideEncryption"`
  17595. }
  17596. // String returns the string representation
  17597. func (s UploadPartOutput) String() string {
  17598. return awsutil.Prettify(s)
  17599. }
  17600. // GoString returns the string representation
  17601. func (s UploadPartOutput) GoString() string {
  17602. return s.String()
  17603. }
  17604. // SetETag sets the ETag field's value.
  17605. func (s *UploadPartOutput) SetETag(v string) *UploadPartOutput {
  17606. s.ETag = &v
  17607. return s
  17608. }
  17609. // SetRequestCharged sets the RequestCharged field's value.
  17610. func (s *UploadPartOutput) SetRequestCharged(v string) *UploadPartOutput {
  17611. s.RequestCharged = &v
  17612. return s
  17613. }
  17614. // SetSSECustomerAlgorithm sets the SSECustomerAlgorithm field's value.
  17615. func (s *UploadPartOutput) SetSSECustomerAlgorithm(v string) *UploadPartOutput {
  17616. s.SSECustomerAlgorithm = &v
  17617. return s
  17618. }
  17619. // SetSSECustomerKeyMD5 sets the SSECustomerKeyMD5 field's value.
  17620. func (s *UploadPartOutput) SetSSECustomerKeyMD5(v string) *UploadPartOutput {
  17621. s.SSECustomerKeyMD5 = &v
  17622. return s
  17623. }
  17624. // SetSSEKMSKeyId sets the SSEKMSKeyId field's value.
  17625. func (s *UploadPartOutput) SetSSEKMSKeyId(v string) *UploadPartOutput {
  17626. s.SSEKMSKeyId = &v
  17627. return s
  17628. }
  17629. // SetServerSideEncryption sets the ServerSideEncryption field's value.
  17630. func (s *UploadPartOutput) SetServerSideEncryption(v string) *UploadPartOutput {
  17631. s.ServerSideEncryption = &v
  17632. return s
  17633. }
  17634. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/VersioningConfiguration
  17635. type VersioningConfiguration struct {
  17636. _ struct{} `type:"structure"`
  17637. // Specifies whether MFA delete is enabled in the bucket versioning configuration.
  17638. // This element is only returned if the bucket has been configured with MFA
  17639. // delete. If the bucket has never been so configured, this element is not returned.
  17640. MFADelete *string `locationName:"MfaDelete" type:"string" enum:"MFADelete"`
  17641. // The versioning state of the bucket.
  17642. Status *string `type:"string" enum:"BucketVersioningStatus"`
  17643. }
  17644. // String returns the string representation
  17645. func (s VersioningConfiguration) String() string {
  17646. return awsutil.Prettify(s)
  17647. }
  17648. // GoString returns the string representation
  17649. func (s VersioningConfiguration) GoString() string {
  17650. return s.String()
  17651. }
  17652. // SetMFADelete sets the MFADelete field's value.
  17653. func (s *VersioningConfiguration) SetMFADelete(v string) *VersioningConfiguration {
  17654. s.MFADelete = &v
  17655. return s
  17656. }
  17657. // SetStatus sets the Status field's value.
  17658. func (s *VersioningConfiguration) SetStatus(v string) *VersioningConfiguration {
  17659. s.Status = &v
  17660. return s
  17661. }
  17662. // See also, https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/WebsiteConfiguration
  17663. type WebsiteConfiguration struct {
  17664. _ struct{} `type:"structure"`
  17665. ErrorDocument *ErrorDocument `type:"structure"`
  17666. IndexDocument *IndexDocument `type:"structure"`
  17667. RedirectAllRequestsTo *RedirectAllRequestsTo `type:"structure"`
  17668. RoutingRules []*RoutingRule `locationNameList:"RoutingRule" type:"list"`
  17669. }
  17670. // String returns the string representation
  17671. func (s WebsiteConfiguration) String() string {
  17672. return awsutil.Prettify(s)
  17673. }
  17674. // GoString returns the string representation
  17675. func (s WebsiteConfiguration) GoString() string {
  17676. return s.String()
  17677. }
  17678. // Validate inspects the fields of the type to determine if they are valid.
  17679. func (s *WebsiteConfiguration) Validate() error {
  17680. invalidParams := request.ErrInvalidParams{Context: "WebsiteConfiguration"}
  17681. if s.ErrorDocument != nil {
  17682. if err := s.ErrorDocument.Validate(); err != nil {
  17683. invalidParams.AddNested("ErrorDocument", err.(request.ErrInvalidParams))
  17684. }
  17685. }
  17686. if s.IndexDocument != nil {
  17687. if err := s.IndexDocument.Validate(); err != nil {
  17688. invalidParams.AddNested("IndexDocument", err.(request.ErrInvalidParams))
  17689. }
  17690. }
  17691. if s.RedirectAllRequestsTo != nil {
  17692. if err := s.RedirectAllRequestsTo.Validate(); err != nil {
  17693. invalidParams.AddNested("RedirectAllRequestsTo", err.(request.ErrInvalidParams))
  17694. }
  17695. }
  17696. if s.RoutingRules != nil {
  17697. for i, v := range s.RoutingRules {
  17698. if v == nil {
  17699. continue
  17700. }
  17701. if err := v.Validate(); err != nil {
  17702. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RoutingRules", i), err.(request.ErrInvalidParams))
  17703. }
  17704. }
  17705. }
  17706. if invalidParams.Len() > 0 {
  17707. return invalidParams
  17708. }
  17709. return nil
  17710. }
  17711. // SetErrorDocument sets the ErrorDocument field's value.
  17712. func (s *WebsiteConfiguration) SetErrorDocument(v *ErrorDocument) *WebsiteConfiguration {
  17713. s.ErrorDocument = v
  17714. return s
  17715. }
  17716. // SetIndexDocument sets the IndexDocument field's value.
  17717. func (s *WebsiteConfiguration) SetIndexDocument(v *IndexDocument) *WebsiteConfiguration {
  17718. s.IndexDocument = v
  17719. return s
  17720. }
  17721. // SetRedirectAllRequestsTo sets the RedirectAllRequestsTo field's value.
  17722. func (s *WebsiteConfiguration) SetRedirectAllRequestsTo(v *RedirectAllRequestsTo) *WebsiteConfiguration {
  17723. s.RedirectAllRequestsTo = v
  17724. return s
  17725. }
  17726. // SetRoutingRules sets the RoutingRules field's value.
  17727. func (s *WebsiteConfiguration) SetRoutingRules(v []*RoutingRule) *WebsiteConfiguration {
  17728. s.RoutingRules = v
  17729. return s
  17730. }
  17731. const (
  17732. // AnalyticsS3ExportFileFormatCsv is a AnalyticsS3ExportFileFormat enum value
  17733. AnalyticsS3ExportFileFormatCsv = "CSV"
  17734. )
  17735. const (
  17736. // BucketAccelerateStatusEnabled is a BucketAccelerateStatus enum value
  17737. BucketAccelerateStatusEnabled = "Enabled"
  17738. // BucketAccelerateStatusSuspended is a BucketAccelerateStatus enum value
  17739. BucketAccelerateStatusSuspended = "Suspended"
  17740. )
  17741. const (
  17742. // BucketCannedACLPrivate is a BucketCannedACL enum value
  17743. BucketCannedACLPrivate = "private"
  17744. // BucketCannedACLPublicRead is a BucketCannedACL enum value
  17745. BucketCannedACLPublicRead = "public-read"
  17746. // BucketCannedACLPublicReadWrite is a BucketCannedACL enum value
  17747. BucketCannedACLPublicReadWrite = "public-read-write"
  17748. // BucketCannedACLAuthenticatedRead is a BucketCannedACL enum value
  17749. BucketCannedACLAuthenticatedRead = "authenticated-read"
  17750. )
  17751. const (
  17752. // BucketLocationConstraintEu is a BucketLocationConstraint enum value
  17753. BucketLocationConstraintEu = "EU"
  17754. // BucketLocationConstraintEuWest1 is a BucketLocationConstraint enum value
  17755. BucketLocationConstraintEuWest1 = "eu-west-1"
  17756. // BucketLocationConstraintUsWest1 is a BucketLocationConstraint enum value
  17757. BucketLocationConstraintUsWest1 = "us-west-1"
  17758. // BucketLocationConstraintUsWest2 is a BucketLocationConstraint enum value
  17759. BucketLocationConstraintUsWest2 = "us-west-2"
  17760. // BucketLocationConstraintApSouth1 is a BucketLocationConstraint enum value
  17761. BucketLocationConstraintApSouth1 = "ap-south-1"
  17762. // BucketLocationConstraintApSoutheast1 is a BucketLocationConstraint enum value
  17763. BucketLocationConstraintApSoutheast1 = "ap-southeast-1"
  17764. // BucketLocationConstraintApSoutheast2 is a BucketLocationConstraint enum value
  17765. BucketLocationConstraintApSoutheast2 = "ap-southeast-2"
  17766. // BucketLocationConstraintApNortheast1 is a BucketLocationConstraint enum value
  17767. BucketLocationConstraintApNortheast1 = "ap-northeast-1"
  17768. // BucketLocationConstraintSaEast1 is a BucketLocationConstraint enum value
  17769. BucketLocationConstraintSaEast1 = "sa-east-1"
  17770. // BucketLocationConstraintCnNorth1 is a BucketLocationConstraint enum value
  17771. BucketLocationConstraintCnNorth1 = "cn-north-1"
  17772. // BucketLocationConstraintEuCentral1 is a BucketLocationConstraint enum value
  17773. BucketLocationConstraintEuCentral1 = "eu-central-1"
  17774. )
  17775. const (
  17776. // BucketLogsPermissionFullControl is a BucketLogsPermission enum value
  17777. BucketLogsPermissionFullControl = "FULL_CONTROL"
  17778. // BucketLogsPermissionRead is a BucketLogsPermission enum value
  17779. BucketLogsPermissionRead = "READ"
  17780. // BucketLogsPermissionWrite is a BucketLogsPermission enum value
  17781. BucketLogsPermissionWrite = "WRITE"
  17782. )
  17783. const (
  17784. // BucketVersioningStatusEnabled is a BucketVersioningStatus enum value
  17785. BucketVersioningStatusEnabled = "Enabled"
  17786. // BucketVersioningStatusSuspended is a BucketVersioningStatus enum value
  17787. BucketVersioningStatusSuspended = "Suspended"
  17788. )
  17789. // Requests Amazon S3 to encode the object keys in the response and specifies
  17790. // the encoding method to use. An object key may contain any Unicode character;
  17791. // however, XML 1.0 parser cannot parse some characters, such as characters
  17792. // with an ASCII value from 0 to 10. For characters that are not supported in
  17793. // XML 1.0, you can add this parameter to request that Amazon S3 encode the
  17794. // keys in the response.
  17795. const (
  17796. // EncodingTypeUrl is a EncodingType enum value
  17797. EncodingTypeUrl = "url"
  17798. )
  17799. // Bucket event for which to send notifications.
  17800. const (
  17801. // EventS3ReducedRedundancyLostObject is a Event enum value
  17802. EventS3ReducedRedundancyLostObject = "s3:ReducedRedundancyLostObject"
  17803. // EventS3ObjectCreated is a Event enum value
  17804. EventS3ObjectCreated = "s3:ObjectCreated:*"
  17805. // EventS3ObjectCreatedPut is a Event enum value
  17806. EventS3ObjectCreatedPut = "s3:ObjectCreated:Put"
  17807. // EventS3ObjectCreatedPost is a Event enum value
  17808. EventS3ObjectCreatedPost = "s3:ObjectCreated:Post"
  17809. // EventS3ObjectCreatedCopy is a Event enum value
  17810. EventS3ObjectCreatedCopy = "s3:ObjectCreated:Copy"
  17811. // EventS3ObjectCreatedCompleteMultipartUpload is a Event enum value
  17812. EventS3ObjectCreatedCompleteMultipartUpload = "s3:ObjectCreated:CompleteMultipartUpload"
  17813. // EventS3ObjectRemoved is a Event enum value
  17814. EventS3ObjectRemoved = "s3:ObjectRemoved:*"
  17815. // EventS3ObjectRemovedDelete is a Event enum value
  17816. EventS3ObjectRemovedDelete = "s3:ObjectRemoved:Delete"
  17817. // EventS3ObjectRemovedDeleteMarkerCreated is a Event enum value
  17818. EventS3ObjectRemovedDeleteMarkerCreated = "s3:ObjectRemoved:DeleteMarkerCreated"
  17819. )
  17820. const (
  17821. // ExpirationStatusEnabled is a ExpirationStatus enum value
  17822. ExpirationStatusEnabled = "Enabled"
  17823. // ExpirationStatusDisabled is a ExpirationStatus enum value
  17824. ExpirationStatusDisabled = "Disabled"
  17825. )
  17826. const (
  17827. // ExpressionTypeSql is a ExpressionType enum value
  17828. ExpressionTypeSql = "SQL"
  17829. )
  17830. const (
  17831. // FileHeaderInfoUse is a FileHeaderInfo enum value
  17832. FileHeaderInfoUse = "USE"
  17833. // FileHeaderInfoIgnore is a FileHeaderInfo enum value
  17834. FileHeaderInfoIgnore = "IGNORE"
  17835. // FileHeaderInfoNone is a FileHeaderInfo enum value
  17836. FileHeaderInfoNone = "NONE"
  17837. )
  17838. const (
  17839. // FilterRuleNamePrefix is a FilterRuleName enum value
  17840. FilterRuleNamePrefix = "prefix"
  17841. // FilterRuleNameSuffix is a FilterRuleName enum value
  17842. FilterRuleNameSuffix = "suffix"
  17843. )
  17844. const (
  17845. // InventoryFormatCsv is a InventoryFormat enum value
  17846. InventoryFormatCsv = "CSV"
  17847. // InventoryFormatOrc is a InventoryFormat enum value
  17848. InventoryFormatOrc = "ORC"
  17849. )
  17850. const (
  17851. // InventoryFrequencyDaily is a InventoryFrequency enum value
  17852. InventoryFrequencyDaily = "Daily"
  17853. // InventoryFrequencyWeekly is a InventoryFrequency enum value
  17854. InventoryFrequencyWeekly = "Weekly"
  17855. )
  17856. const (
  17857. // InventoryIncludedObjectVersionsAll is a InventoryIncludedObjectVersions enum value
  17858. InventoryIncludedObjectVersionsAll = "All"
  17859. // InventoryIncludedObjectVersionsCurrent is a InventoryIncludedObjectVersions enum value
  17860. InventoryIncludedObjectVersionsCurrent = "Current"
  17861. )
  17862. const (
  17863. // InventoryOptionalFieldSize is a InventoryOptionalField enum value
  17864. InventoryOptionalFieldSize = "Size"
  17865. // InventoryOptionalFieldLastModifiedDate is a InventoryOptionalField enum value
  17866. InventoryOptionalFieldLastModifiedDate = "LastModifiedDate"
  17867. // InventoryOptionalFieldStorageClass is a InventoryOptionalField enum value
  17868. InventoryOptionalFieldStorageClass = "StorageClass"
  17869. // InventoryOptionalFieldEtag is a InventoryOptionalField enum value
  17870. InventoryOptionalFieldEtag = "ETag"
  17871. // InventoryOptionalFieldIsMultipartUploaded is a InventoryOptionalField enum value
  17872. InventoryOptionalFieldIsMultipartUploaded = "IsMultipartUploaded"
  17873. // InventoryOptionalFieldReplicationStatus is a InventoryOptionalField enum value
  17874. InventoryOptionalFieldReplicationStatus = "ReplicationStatus"
  17875. // InventoryOptionalFieldEncryptionStatus is a InventoryOptionalField enum value
  17876. InventoryOptionalFieldEncryptionStatus = "EncryptionStatus"
  17877. )
  17878. const (
  17879. // MFADeleteEnabled is a MFADelete enum value
  17880. MFADeleteEnabled = "Enabled"
  17881. // MFADeleteDisabled is a MFADelete enum value
  17882. MFADeleteDisabled = "Disabled"
  17883. )
  17884. const (
  17885. // MFADeleteStatusEnabled is a MFADeleteStatus enum value
  17886. MFADeleteStatusEnabled = "Enabled"
  17887. // MFADeleteStatusDisabled is a MFADeleteStatus enum value
  17888. MFADeleteStatusDisabled = "Disabled"
  17889. )
  17890. const (
  17891. // MetadataDirectiveCopy is a MetadataDirective enum value
  17892. MetadataDirectiveCopy = "COPY"
  17893. // MetadataDirectiveReplace is a MetadataDirective enum value
  17894. MetadataDirectiveReplace = "REPLACE"
  17895. )
  17896. const (
  17897. // ObjectCannedACLPrivate is a ObjectCannedACL enum value
  17898. ObjectCannedACLPrivate = "private"
  17899. // ObjectCannedACLPublicRead is a ObjectCannedACL enum value
  17900. ObjectCannedACLPublicRead = "public-read"
  17901. // ObjectCannedACLPublicReadWrite is a ObjectCannedACL enum value
  17902. ObjectCannedACLPublicReadWrite = "public-read-write"
  17903. // ObjectCannedACLAuthenticatedRead is a ObjectCannedACL enum value
  17904. ObjectCannedACLAuthenticatedRead = "authenticated-read"
  17905. // ObjectCannedACLAwsExecRead is a ObjectCannedACL enum value
  17906. ObjectCannedACLAwsExecRead = "aws-exec-read"
  17907. // ObjectCannedACLBucketOwnerRead is a ObjectCannedACL enum value
  17908. ObjectCannedACLBucketOwnerRead = "bucket-owner-read"
  17909. // ObjectCannedACLBucketOwnerFullControl is a ObjectCannedACL enum value
  17910. ObjectCannedACLBucketOwnerFullControl = "bucket-owner-full-control"
  17911. )
  17912. const (
  17913. // ObjectStorageClassStandard is a ObjectStorageClass enum value
  17914. ObjectStorageClassStandard = "STANDARD"
  17915. // ObjectStorageClassReducedRedundancy is a ObjectStorageClass enum value
  17916. ObjectStorageClassReducedRedundancy = "REDUCED_REDUNDANCY"
  17917. // ObjectStorageClassGlacier is a ObjectStorageClass enum value
  17918. ObjectStorageClassGlacier = "GLACIER"
  17919. )
  17920. const (
  17921. // ObjectVersionStorageClassStandard is a ObjectVersionStorageClass enum value
  17922. ObjectVersionStorageClassStandard = "STANDARD"
  17923. )
  17924. const (
  17925. // OwnerOverrideDestination is a OwnerOverride enum value
  17926. OwnerOverrideDestination = "Destination"
  17927. )
  17928. const (
  17929. // PayerRequester is a Payer enum value
  17930. PayerRequester = "Requester"
  17931. // PayerBucketOwner is a Payer enum value
  17932. PayerBucketOwner = "BucketOwner"
  17933. )
  17934. const (
  17935. // PermissionFullControl is a Permission enum value
  17936. PermissionFullControl = "FULL_CONTROL"
  17937. // PermissionWrite is a Permission enum value
  17938. PermissionWrite = "WRITE"
  17939. // PermissionWriteAcp is a Permission enum value
  17940. PermissionWriteAcp = "WRITE_ACP"
  17941. // PermissionRead is a Permission enum value
  17942. PermissionRead = "READ"
  17943. // PermissionReadAcp is a Permission enum value
  17944. PermissionReadAcp = "READ_ACP"
  17945. )
  17946. const (
  17947. // ProtocolHttp is a Protocol enum value
  17948. ProtocolHttp = "http"
  17949. // ProtocolHttps is a Protocol enum value
  17950. ProtocolHttps = "https"
  17951. )
  17952. const (
  17953. // QuoteFieldsAlways is a QuoteFields enum value
  17954. QuoteFieldsAlways = "ALWAYS"
  17955. // QuoteFieldsAsneeded is a QuoteFields enum value
  17956. QuoteFieldsAsneeded = "ASNEEDED"
  17957. )
  17958. const (
  17959. // ReplicationRuleStatusEnabled is a ReplicationRuleStatus enum value
  17960. ReplicationRuleStatusEnabled = "Enabled"
  17961. // ReplicationRuleStatusDisabled is a ReplicationRuleStatus enum value
  17962. ReplicationRuleStatusDisabled = "Disabled"
  17963. )
  17964. const (
  17965. // ReplicationStatusComplete is a ReplicationStatus enum value
  17966. ReplicationStatusComplete = "COMPLETE"
  17967. // ReplicationStatusPending is a ReplicationStatus enum value
  17968. ReplicationStatusPending = "PENDING"
  17969. // ReplicationStatusFailed is a ReplicationStatus enum value
  17970. ReplicationStatusFailed = "FAILED"
  17971. // ReplicationStatusReplica is a ReplicationStatus enum value
  17972. ReplicationStatusReplica = "REPLICA"
  17973. )
  17974. // If present, indicates that the requester was successfully charged for the
  17975. // request.
  17976. const (
  17977. // RequestChargedRequester is a RequestCharged enum value
  17978. RequestChargedRequester = "requester"
  17979. )
  17980. // Confirms that the requester knows that she or he will be charged for the
  17981. // request. Bucket owners need not specify this parameter in their requests.
  17982. // Documentation on downloading objects from requester pays buckets can be found
  17983. // at http://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
  17984. const (
  17985. // RequestPayerRequester is a RequestPayer enum value
  17986. RequestPayerRequester = "requester"
  17987. )
  17988. const (
  17989. // RestoreRequestTypeSelect is a RestoreRequestType enum value
  17990. RestoreRequestTypeSelect = "SELECT"
  17991. )
  17992. const (
  17993. // ServerSideEncryptionAes256 is a ServerSideEncryption enum value
  17994. ServerSideEncryptionAes256 = "AES256"
  17995. // ServerSideEncryptionAwsKms is a ServerSideEncryption enum value
  17996. ServerSideEncryptionAwsKms = "aws:kms"
  17997. )
  17998. const (
  17999. // SseKmsEncryptedObjectsStatusEnabled is a SseKmsEncryptedObjectsStatus enum value
  18000. SseKmsEncryptedObjectsStatusEnabled = "Enabled"
  18001. // SseKmsEncryptedObjectsStatusDisabled is a SseKmsEncryptedObjectsStatus enum value
  18002. SseKmsEncryptedObjectsStatusDisabled = "Disabled"
  18003. )
  18004. const (
  18005. // StorageClassStandard is a StorageClass enum value
  18006. StorageClassStandard = "STANDARD"
  18007. // StorageClassReducedRedundancy is a StorageClass enum value
  18008. StorageClassReducedRedundancy = "REDUCED_REDUNDANCY"
  18009. // StorageClassStandardIa is a StorageClass enum value
  18010. StorageClassStandardIa = "STANDARD_IA"
  18011. )
  18012. const (
  18013. // StorageClassAnalysisSchemaVersionV1 is a StorageClassAnalysisSchemaVersion enum value
  18014. StorageClassAnalysisSchemaVersionV1 = "V_1"
  18015. )
  18016. const (
  18017. // TaggingDirectiveCopy is a TaggingDirective enum value
  18018. TaggingDirectiveCopy = "COPY"
  18019. // TaggingDirectiveReplace is a TaggingDirective enum value
  18020. TaggingDirectiveReplace = "REPLACE"
  18021. )
  18022. const (
  18023. // TierStandard is a Tier enum value
  18024. TierStandard = "Standard"
  18025. // TierBulk is a Tier enum value
  18026. TierBulk = "Bulk"
  18027. // TierExpedited is a Tier enum value
  18028. TierExpedited = "Expedited"
  18029. )
  18030. const (
  18031. // TransitionStorageClassGlacier is a TransitionStorageClass enum value
  18032. TransitionStorageClassGlacier = "GLACIER"
  18033. // TransitionStorageClassStandardIa is a TransitionStorageClass enum value
  18034. TransitionStorageClassStandardIa = "STANDARD_IA"
  18035. )
  18036. const (
  18037. // TypeCanonicalUser is a Type enum value
  18038. TypeCanonicalUser = "CanonicalUser"
  18039. // TypeAmazonCustomerByEmail is a Type enum value
  18040. TypeAmazonCustomerByEmail = "AmazonCustomerByEmail"
  18041. // TypeGroup is a Type enum value
  18042. TypeGroup = "Group"
  18043. )