From 14f611d15959e3e964650db0f10fb1c3a06053dc Mon Sep 17 00:00:00 2001 From: William Cheng Date: Wed, 10 Jul 2019 16:35:34 +0800 Subject: [PATCH 01/62] add wso2 to company list (#3330) --- README.md | 1 + website/dynamic/users.yml | 5 +++++ website/static/img/companies/wso2.png | Bin 0 -> 35921 bytes 3 files changed, 6 insertions(+) create mode 100644 website/static/img/companies/wso2.png diff --git a/README.md b/README.md index 797a761f59..c385e05569 100644 --- a/README.md +++ b/README.md @@ -552,6 +552,7 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - [TUI InfoTec GmbH](http://www.tui-infotec.com/) - [unblu inc.](https://www.unblu.com/) - [Veamly](https://www.veamly.com/) +- [WSO2](https://wso2.com/) - [Xero](https://www.xero.com/) - [Yelp](https://www.yelp.com/) - [Zalando](https://www.zalando.com) diff --git a/website/dynamic/users.yml b/website/dynamic/users.yml index 2af7b7f22e..670b02df59 100644 --- a/website/dynamic/users.yml +++ b/website/dynamic/users.yml @@ -113,6 +113,11 @@ image: "img/companies/unblu.svg" infoLink: "https://www.unblu.com/" pinned: true +- + caption: WSO2 + image: "img/companies/wso2.png" + infoLink: "https://wso2.com/" + pinned: true - caption: Xero image: "img/companies/xero.png" diff --git a/website/static/img/companies/wso2.png b/website/static/img/companies/wso2.png new file mode 100644 index 0000000000000000000000000000000000000000..2cf18f9cfddc8a686d87e26ac26f92433e1b267e GIT binary patch literal 35921 zcmb??Wm6p86YnmIEbbQE9TsKf+e^U++Bh#o}dAOJ3M%R1VV7Q{BPC$ z2DfTvdS>2DpEIZXCnsJ@LlG109U1@tz*JU}(*^*5>~Ht6VC1)J-JH#@w}9%QWate5 zaMJzn1O}8#`T+oFnvSxvT3Qb7KJMNQ?jF?2va-}3UhZ~|F17$bz*>Qhy{^s)k@)S_ zUm4Xn=x0@TZ9*`$woD?FAdQig1{Fsoj;3Ul@ckgJygVY=x8gWZaxyfD@I5<50@@17 ze>A1Zkze8xCLVW#zc?@T-X2cBv@c5>)m;~~&Z5A<7@11E@A;t^)iRX0JCWlfW4r%x zO2N?RJpef1RvQ}cXF4F@E=){}jTVm54*&)%po0N$^*lI)JoXj)R3^s+2#o^5ebR(f z!B7H#R8X=^1wcvx2rbBF)BzMD0xTx2t@Z(08~_WZ@WTZFwBRl$7zi-_OhX7PP6JTm z+s4TO97F+ivmX-V0R|8Nft~7zFkpoP08!SrQvx(~0^l<^=q&&+1_1ItE}8{^7!0uZ zMn@L_h{^#FC|v1_{b6gsIbwawR8EUnH@&bt%oxn!iK4I1Ny$8;Ow2|gV2NOvE5$h! zm_y0~A~y^zYHbcuZl6h<7_fQ-9UU$!F71qpUU#Qxu;%(O;h^7HCJ5 zt-1|Z3HIOPc_z!{CSCKC)5goBvy3v#zuN3=vp<3)w)p`~P7=W2G>$4$YtTPcCL9AF z_}(o5aMj~J_>&n7f;vR*&icPzN&a%?I*i(}cTFGa zKt1s{*0at2hZPnt{fOQWZ5hJs<8Gsvs&T>irNC?WZc$HpZ{G z_ah`$JlwGcO6+t?cq#Z?IKgqUBZBmJ@v=Nj-Khx5&1Jgtc=HPLZrXGw?A3XEO7G}C zeP6S2Zb1?L%udbrE&9KL|AznL{g3QFnk!?p0xK!cvOAqUX6*?l719Ho1HJ=f+iV_b zy)U`in^h&cxcn(bGW8`L+KumHtMK`JbA_iPiIi2#>q|2h-Z>CE+&VTM`+UXS%%IfB z`k_BRd7^lnbqxCJkAWFO7&#ti&rF&}fQB;`tyV$0kVrbN3lZc#%Rb7%&T-c> zVC`THAxxV<%TUQ+%phas(ygwksM)GP*Spr6)J>^2(+O=*(BswFuSWfuS*ur5pmnB0 zrej|%S`}MkU*)bVSr%sa9FJ@`tTwDETlT)V*?hluj2hjVv^9X8#u>9V#uvsv!q_~$ z8sf*=ll@H5lPF$OT_P;YtHP__s(t<0P7-B5+w(5pM+5bUxiafIEMbe_l4XyDtb$Li zo7>jJxh69!)1X$V_I<75S)V||d1XOGpL~zuBMeJ=T!qPmNzp!K2C3jkXH{pj60MR* zU0md*fwRWBoUEir&VRtI@*=yi-wax)=3coK*mv|m9?JEs`|SEqd83G7fZU2fkGzgC zLn1cH@98c^!8N}A=e?}yu#{}MWrk(eZd6+LoYWr{jA^bth@l!3y$v zLx*cesHMFXv3=)g!|=tYzE7cFLq9%?qhQ9aV%1U@QG|K7c@c zT-ID^`t{3Ao#p;Dx0aX068|K;iuNV;#RRu_whYau1mT_EIwv)U-3!g5w`IfWUTt23 zUgrRnPzInqC>|yaGe&s43ksnbNR|{?xBb_$dM=$*+$~Kgof1(WaWGg<2bFwxFxViLiKb>F4?iK8z?*|iS zbA2=Q2rQWy`WszIRLzOUE|Mvw7N;Tf`L{Fl@hCZQ2MX5Uj9J(QQmU)gYGD%>eOB}OtsBCkwT(eKWbMVagjdm$n>;SPnjAT z^-mr4r}l?-ev@^!(Je2dZi$^-lo=@Bom*4ukPJD{I%F!2b&Z&pSy5W-ZT0O2rsF4s zGiwXkrq8EZC)QI1^Dm2D&+&%vcGEk`V^sAyC=3q!>YRjI#5@Dn(e??E*kV2)*NJr{ zbg;TEYSy0XXElWNF$SqS!^{RJA_m)m&S&U)Xa~`uXB*4srkVy^hTH9y4>1K~5`^&y z4Fv1NS%l#$%o_m*WU=lO134R?+p23vx@~6d=Iu@nw>S!ou`+A24zsY_Fjv>wFtQ6cbSi_ru7=Gp6BDBdC)To9ahJ3_s>O& zd2wCslqI$^MXYhE{+EJFe-2CmOudi!V|#QSa)JMy+@fyZQeuj%`6UI{?V>DD`BB(Y za5>53Ugav}>Eu2dTN!`VoRXMZI^7C-Qe3CP&gT;|3{<(+{qDGS60z{f{%SUtK@+*$d?!5eK;*n^t=#0r#m(Nwp`T@Rvmws-eh`H;j&#BnU zrv=UNp8THNhHew*?u($l_F%i)6S6|Vna#g_fq#fzmlg|!#W(w|gWPXNZ*R7VHp9G_ zo@XX|R{fbS>U%YN&HqZBORvgq#x6=4zig~rZiG9*{fn>XHWY7>qa$Zu(r!|)Wsy>H zQYK?CW6lbNB!q?cB)y(bo+@Q$ZDtt@iC;=zCL4%}xWeuh&z5KAvgb;&uChK2xQ3KJ zpTf^b8`sB%#wh#02k>&6{r&KGKIp&UPjUHW8(Z_g5bAK|SBLxN8=W7OkDo|CeR@R% zWnVv8^Kz`e^_$ezO4{lGKoA1}0F49y?qA>H2>{>=0RT=d005C}0D#y%-F#F50Dy%k z%Sr17to`cq4Iy8?k$Bn=ZR)KhY;~EON?pMc#;UY*t5RlJ;Zx>zRbg4^+<@?_gD|}* zJmB%%b{#H;7Tg>QaPdp3)^rYM{Y+a1_3fgW%1>)oPJV|&-q;ecxVQ?ox^Kq|aa0P{ zU{%sYRT9F|{|yt&79Zc9{$Ke2|K2iAEZ(w^OTaJGAgN08^a!$iUjjf_{aPZm2H3RlI~42iee1b`uYO?%2XAIYEr zfI1(>C90*9wh_SFu&Et7+wPd+(^rEj(`nfQks-k z^$a;B&5DY~BT?#h06^Y!On_K&_{+6t@9hf@1o>D2P2VI;IOr?r`1E3sv`7?_EwfS1 z%#HKk(xTL3Ij5CL0D8%|4bo*15fnc#BHC5$PBfBaJCd=eHW->@_$KC;gBEZ&vWMY zBctvU=#7C<5z}<&2I&Y<#;_&Vr6NTa6GReg$eF%5OzG(3Z$j)RFr5@wDjj}RdlA`# zvx5hxhkC+uP{6I*2E2=?LeEel|HPQ~BK-RGnNp=Ald%;7Tqhk8kdh}t3q>9AhAkoO z214_bG^7Vxt>ZkJ(v*d~o2%)`lZ)FQM!gz?D~X|C5QXC*M9$323|&4OEnM5gx0?H} zbY|us5}BY&{v=7Qo1^3O{rzlsA+jc6%Y3+ot-O4&J=0deK7a3@G3TB12&SSSR?3ud zXOW(@&im)?+VPae7cITTk5j`tJ|cs{ZC%k3ClF{%kE%-Cu_Eq#iq zOjq*{$pbIT$JLzzBVb2707wWWio4}Yi4atG#7&^C55r_a`X)jV#|212_8!jA0JSN{ z4pBT@J+~+!$~HFZL0xUrK-MZlpTCp8{H}K`S?nQ7k|m`uG@n04VgFHD46tHi(SlhT zcA$G&^W1V=)fdsG#1aLtA+#XhxIo5*afkirF_5H-#l}JSoRBQLnd`|&s^1)ODqbc} zxzo@)FnFOFp$ffUUCYn+7AnB%5|?Oe@0ba?S=8q;=y5y0pPruf=2JgIX=|~Hq+f?; zm%|M92Oj{j+{p3X9;3(za8g-k)lc{qt@`yQ!ens0noZbKZ?9{2V7IDE!g-*)-iL?h zuoV}9RBFhKLfWYkAaQc0OIP5?{4lxG?I;1CI>I6}ct|9N!YuAVZ#f<{F${BtqdlA+ zliJI0ZBWTIh!zryeYjT1sYr{_8aQcnS~Y7QsAu{aOxwyTEXIKqgKSr(fHk5F6@J2* z&P&0CRgg9XBa@u6Kbzw*8qAFhpjA?pjRH9%S52gj+|B~OAzo(!;w70xZZ0@* zM2dxgiv?kJ2<0is&lVaep+z^|d+Gd|El!~VKlru`UXCxbD}UQb?B0nQxE=7)C#4}> zS~}_=8fKM+-Dn3Rmn}>%=&m?U0j3twKn;ROgnqOaCi3A6IO;amV0G>55EMk7( zwq|O~ek`eay+iEse&o_ahLXS;ve&ahKHjr!(Qv@hOj6SqtP9qx=rt%2u8D>>Znnr< zU-nmj69E1IrpDTrS-iO(K>kOd3JICR7!2H#2ykbF^3^wtm^~=2%M`z;Q-jUS##ALY zh?x*&mg>5xOhgT>9iau2B%FP!K|!h+6ojWRJU+lHIB-RAcoi9#0GFZ*`TD6{;1?&H z&!S`5g!6->uzsQMuKbjK%lX1zXI$K?t1BEZVw2B_s9?QG_g?a0MW`O2xC#prqp9CY zqdIA=2E&Q6C}s*D{#rQuX?xvcmj!6BEXqAhlifjH{L1cT!R z19q+-6*FZ^q3rS7qB3<7`!Yji4l(XD{q}TF3{o4ARUen$8U@ZOqC9vt~w^Rm6HU-)Se zV?0Cnc<(`m<)52M?X=zt+d6PNH_?fidSy!hGn`+ zG(Qfrb&1YuuL+_2rJqX9H7;|k3xp%%w5%+km??w8>^; zLi|}sV|0aY)ekuxaCSACBAl9f(IBJ935u33AqVo!?)ykn`Wr`;B5hn6ol{1%Qi(t# zya=G0Z^Y`xlD9|TZ%cf}>`K6Au<*y5*|6e5k4@S`wpFR2Z)h;XUPM{EVaU$yV+kwT zR^VCvHv8-G7g4}u;7s}OZ9EzRMkJO{2s0@E5}QC7FVZJ_p=f!q&1Qia(* zMV-bnX%<}h7Azu;8} zSlN}xA&dyG;A#@VRzo3c&J8&6sfj)4^LFR}ea@*0b>ci&X@F`tXaqg99SFkmldk-QfJ~y0+8as>GUO~r3k9qq2W&x8Eh}@|MvOONwR1r zRf1-)L+K&`CAa|Zfh~IP|GF6nx)}m=v5GzpRzv79WrXD8$`IGAqAt3i)p?M|v8+fI zaw08K-mO4;Y0)v{9xu?|cka0a&hIU=tclC?Q#;y}MwuY+rsLc=yS0U=pj7>C!34MS zoYo8!601K($Hk@ywT#mvvCjhw!IXiNM7RO8h^=ln%W;2vK3^99MexvK#V8c4$b6hM zm$t{uu8TNRZn9uX!n`$i2zmND&EAP;BkbDZ6r-d7|Axp$G7!7Ek<$9)d8t&sAdt|< zwm<(1o#vw?ux!-AEfh4?@d`cq@Il-D+|%aRytH9$K}oZMpX;3iYdT=#9;bw8;NQqi zW3~DH?fc#kM&^w|z36n3NE$?17R(l(s+%Fp*3}=YbG}=7s%GJ6&;_1u1BKKT_X)$- zhRT1Dy2+}ebG8EHIyDwXB}vNnJSv-bPpq-*AT1JVUN+NVfKMcj3Tm62+D~NlU#CBs zOAW_s>@W)~LAe>f0jp!4#WaQAqjX&b08$W~?BCZ#uOau%qUpGce(I_|O+#A*^qs%bw4z&-6+giI|fljV3wEPqWgkp%*JP=2-q(jev8 zaracd?lB8~!p7bPN#-f7VE#Fl$dQs`W0{etbs^^dCyMLw*FHk-_ zPY+wg6@CpIi@kl3HVv8VWL`nc^vy*AlSi>aSpae$2DGH5fo9>)AKgQL54OBon?#gW zk*ak?n&koLY;!6&W0SlYzk0sVqi9rVX%#YoI{u0*Ar>3g6yiYB=)rh97^y;$Q?L+X z#eU7PDNl?Y#4_+X5T7lVzt`x~h^lBhSk4!K*X8s)V=-ymE}W(`((H4x9&Xr}Z2{`QNbZ6v1v-8JZX;brzC^g-e=LtZ*B^*$mo1s&oXHZ5~16DXw?}KSm zY!F)TO9R(^3C?wQ8>d1Hz!dbN7-l>-+;-lPNBW>3gr9mK>+^wdPP`KGL$(>L4;4TX zWhLt)Nfvd<$DlUXL>fY*oUeq!(;p;c5wnrMDIrt~?MxZc7I{6oc<)cXLdcfQhRB5t z$J6fFEJB|C6BO1rOSdb$rC|ta2~k8t^`be@rs19VI%vvCY-GG1-t0X7j|u>tzKFuH z(u)0>NdQ2sxpwVxYrrom+8xQ(9+SgCs?NCu|c2Hf&ajLy?fSn z(E4)YRe;#*0CN2<@Pk))HKwm1g75*?@7|gZBOnGX)8fe8XwNtU>{ghY9(|r4dQBGex+luOCoz0JWs9Jpn0(TzI03w7tvr zp@|Ni1hR-Z*H3o1v^;=jud%dmFcO(slM}f{3x#lh;Ca?wGQAa&7iq97l#z;)*r1Id zG_uZYoOIcIF#fC|O7utSFp_OC-eHh7yM`=*lDw&c1eCAAWMpg{-qGndi!GE@QsrbW z@E{e!Sf-6Y4WsQ$xa9KNkNL9EbmT>?qJ)f*P5ULWdLTu7z2EXV)KWnkfU1hm_DALJ z;lwN?6o!uNuC&uRIkd7_J_tozoOyWW5v4ZNe@~E|zklAj)!R~AyKwV+7~3?ps3@hQ zql3<986Pm$Pn3S9rSjm=GdOtZ>&HVZ9mOgL%N|F56q}PMxub@k|`L6v- zn}lKV4q=;mr>2@O)VAJxSU2J!3=qk#MqORA2Cod_x+!W@opv#&9f@|M}Q0`Wif>gh0v@nX`%Rw4Gt!;nri28+^j6SY`_Y;#eqZ zUknpc<3>5Gg^;l%*TKi*fGwB=8{;3(-OadyRm0?9p^8nOs7aL+{~i8zq9NUvqQwZk zX6yXBcx4+=Cr8rjVo+hRqc!X=<_8|a z!!hEz+0#G6MS`5tay``CsPlX407mKDhwf_~Y?CJ9cn@51Gq{p;nU%%XUZ~e#*SewG z0lHWt+Rsf3hAv9Tt$=vaMMU6=aR3kfJp7}ah&u*E9sjLTMMp=keDz(g$MkKN+%uWL z`Y@%UiW38iM-mY8vE@wj{UsR8U+xK2#@L94!WLL(2)Fcy*%)6aBfR@07jCfi_ypG0o?>U&n>Q^ zcCJ4TfDFVct)vi@3m>|JyqD(%r%W#kqx0vJ9%EUsviUDJhbHaCWrIQjUMjarwR@H) z{*WTiP1Ktra$WU`&jm1`4 zru}c+Oc_O-XJNyMFy9bIUXw)G8L~(J!wIA`ATJ?`BdS(!yY@)Xp^UFxgD}0NttnUU zKj+V2X_o-p9lX12B%IA)m<_loFea{noZu`**OxEAjPOS{Iu0^@xUz}(?pH2{%cpw| z5@ji0sTzqFN;9!P!R(~*U=E;){NuDRH&zdkjP|s2=x%(fg$%dOhcdxuUx7T#nwq^A z6iTt@`=g>q^dmfi#U-jbB?AVVd}-Aj0IG@b`bR~snds9!CBI_`BK!_ABr;W#XZr_d zXNFAdD%Z7-JH|mqN(DUi?u*quNA%rHt>x2ptaO+gk%-xLhgmvG1if-X2<&Aa!F)bm(}jZ+wFM&x3Zx}PeF?y(ttJd}|Fy#eMd zBNfCc=-FN|H#tkLjvYy|7!lQ=B-wYZ zfGHg?+PUg_n8;g=@8?)-c&d#!Ft1|uROFqcgpqkVmEe0LN{a+qklOgMl3YJjP?(=ag|g?~G_nEKt6AE_yHf!XnA zl`+95bGT62_A`N29g5YNv!GY(rQc+ZO01|?Ch_nAh``q19g+9pkjtu;!^QoM$suRc zMPL=-1PL`pTxg#A=OdG+h>UB#q{~AdW=enz#|PR2NEnq7L8#c{;}9bsm3<=keO}6Y!pwSCAhD;`zxfkDH)}MF&;lH1=077~_yxu&#`=J&$E9LiHhls>g<8mgdd1u4wS(X?C zPBCJSv{m|>DgRxj0HZ|#iZhT4M|pAK&L`sgO5Hp9{1+wSwz5LxdKjFR4NXmF zoDN&^X(Ga!NH-(nGikkRy<@BAUAmgnN`EMd-E1yD{aC_mvT`m$vYUucFlH|og| z`TS+~74@2bzTHJoI5}6{mTLU4<}5W%oHCRLBO@35n`m(3)_6|V2$Zcvs7nJ0Y1~)?+p$G2e=8*$8rOr{ zN^Snlaxa~kpqPFA3OJ(Lm#LYCx*1g?@ToPOa-_&jMDg8PK`N<2CP*RM4{TivMO)~x z!kZWXAvkKTG-S;upJzS(wsCTNFIKdKL4D=dJan0!wn_jcVo>VDJ?v&Z_Oj=--}#Nj z_|a}zF$aO4ds*LJY~BUjyvq-n-+MK(d;VP-^^!34x-%2YcawyYG~KwR9Hed4QvW)H z2wN4$fn}OBpY* zz;Cd#1Uqso##@UOYhK&Y{(kpfk(mhUuo{H_DZ_;&rC66>!@NB*I5CUnZ5DS#&WaJ& z*@$HGqS#Fb3qO1L3C_sGl=3cgyw7a_;`EyT5$)WT|Jd1+WzWz+!%$ z5;Nwa9U$6ex+@{`K>0SZ}t!K{5#4=bDyGBGjHIxUzLZqACv}9Vjb4np!^Ma8id{* zb{ZJuAqiq5 zRHf|V0D_L|aOQwf6Y8x`qbb>xiArz$$n5aO3o;Hi)P)mb&$%<9&MSh!wLR0KhT7bP zuX&MCa>8a|Z#VFtD*7wx0ikWcdAlIzYPa<|g7OC#sMH>1rl9()%c6!%QiKadAqB|c ziku8KVL(VlW22#XEPo+$86>uFG2^ky(ZYZ#N9o2U*An+MSIZB-)`JIk(C7s`a0nM+ z7Y#F4zGs4=N5lh9_m}<`8-WH`0SGW&RC)P(gPsfPr%u}djoZNxqGsxEC&8b(ubpwR zbw8bwcb$`>pn?dTdJI_w-79o|Iz>TjRxEIWM2|f}4QlXzn(0WJ`W|t2hG+W;f%efH zZczkv+(s8ZpsJky_A7M)d3Rwikn6$0JU2hXVc%KnM80BZY&$Uh_k}b3LvDzQ7Gf@( zjZr%MTJXnKFO}FV3N6s?R$+Hy(k%fMc-UBFH>%U2-StfE{o~4$+YpFn*|fphbjTq! zu959qD?Nl*6eMz&eQ(k1mO6}GrE!*UgP~kN16k1nX2Y$G)qnc>Q)}|$&gx>+F+0?` zkDN93zlZ|9jo^=x6fI2uaQ!@zBB==1X@j_ zRuL3Ajgf8$DscGa?CfChN0vHg73mi2U-)og5Xtz0rsRDq68fR|=e#^(aBNIr-l(u5 zZJHFb?pCGc^DHov&!8$3(IAW;a3^y>jGGGZ zc1w&U($S)fq~hVwAJ4_srxTHL?YAblZfurV?wKv>2)ayV`7M%KlYZ1oNC`etR|GQR z{}3Q~WNN-czZz0V9tCXO(#C|cabvq5hrbxOEl$!F&`-`wh}qrBv|UCxY-2fXV+KAL zW};RJ!A-g|W0>ZBV`QNBDwa$22y6v*^5Ee01Y1&w6$Vc^fM&Pc6yD)h{BuTn2NWg? zhV7N&^*+yt>ihfpC1nsAkI5=6*B6P0g<<6j^H`mWDDZtNmmd@}`!;Sa=pm$s@}Dp< z-OUvjd^3=4i6xGknv$uD0z=dEzwxr3^%6$}f%Yt?L%1#q8Q!1l=bPmh@9~uItNqJ2 zksAA?*ghZTjVjvVE=!vO$hv=Jw7?8f;X!@FsMq6S0R0Oti!ze`Fut*~6iewOYl)j{ zB@gU|oz{@$@|G+ot#u$C*T_~hh#Q7;;YQ7MJWu}j8)IkgRJ}uv7ST-X9&;WqgTSpo z^HFs_hw;{`8l+-^`DH# zKe|JF;qiWGlId z;mAr6v#)_}hp86jqyL;;}xcZ*1a?~H+)i4;6YWUS2i-I23><7`uk{x2H zKLH7NJdWZi#hPehLd8MXt#RNMCqLSmy!P*CB`ZDcZ%3 z4rJK?#&Wi;*cJUWnDqA3gFZ7ZVDdv*{pg_A_{c%?by2Z_putxj=u1a<1? zAQK1j_2GGn5N;%G^!r-Ey)8y6uYbKrHvqR8wfP@Ep!P+Vq$-Qul)HJFIG^jjKV>XPC&v>wZX0~ z`uJWbL>5HN2>cExmgjhvAscT6`ub1g&Cgf2Ti)EO(RPg=e`8~>BRJun*(z?=P19-TeYsvHTShTtarHD z->d~Zx3eLu3+{T?+$|vp;&5Af3GkGqp!9zN{D=R~S)afydgY2W4)jnnUR?Od>-9S_{$~cO|$g*?L z`ZBu)%IU=NK8z6Yr?UO^Vv+mLsez zj45|JwGhC*i^8X*=df!Id#9|$gMi0a);unq8-iSh$|Ri|fL3;jPs7o5Xm3a;JUZFSV+{ARde@^nv=&lTEO$gBf%UlT!xTp>#mpt%-86;DDDHS7yRO$XI) z-_o>khExo{`Jn2+_x(!x8!kdPGAvYLWK4hv-$wKgMbdOiX>s`#Gf88(waO?$p14!( z^83tt9*!-w^icv}#A6Tk^?x(|?y}GJkQ03TXhHnJc_JH3P|Pp=re`=1|&KX+qILN}}rmly_U zWp$|S0qBcBG=HJ#dUq3=X_42<&*e=)Q0&P=Wcu|Ie)b-+pYPcgX3EX~TMhU^0`j2{ zt9*LjeDp9FdDKB)p5hU#LlcRFDPCJKPXfv5GPIxbL3q$!dv-cGLX8Ep`Q(IoL+r@`$v zq!C8((o&aiFqMIh>yksi)$?eY8#F;xHg70tq2Zq(clr%FnFEsRk*4UOQO`+na0W|v zd2V35(sX|p&f2*S{PTBV*6fG#5V=ds@mE{4@W2X?5^DAiU6pA$ex|kZxACyRa5+vw zSpNezq=?w#P@3;Ns{5Ys+cl@E=yqd7|6gn=R;Tj7q&ioy9AZPh-8lA^4o*C}QpXg0 zWqv-WVe{gyaQTP=;+9T7$cGp)NIfw*(UMN_q6y3-#l}33Y{toM?EREd@EXzmJUu(C zFXEAg5Bg*i_b)e(!74oV7kR!P<9Qff1VBVC(VG^Mg>E-~sw!8;mJ*1@IUYr}_!;*t?-<~=1_`SkjfBmE!s7q&7wd9x%l^{j<=a+E#* z7Q>X9Y%dUg^!v8T?LU0kr382MZIR6Hr&bn)cIxsWmD*Ev1p(H{t&1}$AlPcUZ>lDx z(tgTogTvDuo=TKT_As`B-GHvHj7aTj4yc03(j{=;*lzd%{XfH_(AXpWzBoF|U z{xuVb(K|?k6#^q4nL&poZ^F}sbfw;V!e8|Z-tTVt3qMy|W2idEF?|q))XyV}yF@gX zv}2H=aRLxWf}{@csi}NN!_H6lD{20n1KG%&F$;$*>%w}mn+!CB%TDZvpMFzG{aL}i zwJ*m*2pnbQ%y$`=Tvn_LQ4|rfVlL^f_N-Yr&*!n9`9&cPD-6RoGct-OdcD#IN6Q*O zUXN!93^3Q}>GS;KvQTVp-=wFnOnnc$MSED1a*s1CcIPeD+0&K`RtfA`j;0^JGCdU>Pnf=;O zN|5(KB(VnKESa_Gy)}IEeg|JeZK5*tRxHs?XhSg~i_}CH;xECBTO}Y7c8V0bIACTo zls~$8|Doyy+;xMb56DaSgQVdTyLWtYDnpGk6~utA{Bv=U3Low73U7PbCDJB3lQ4j+ z7*~Or@7u$aC@z+)X#i&S^rE1`Sb`$_jS(q6WQ*zEr--Xie;o81BxaYnwM-Yps!=Kn zJmAW)8FU!(!~xK06-Y zar*{8wU6xeDL5qqTzB3&lN z2skcJs9HOEnS+j;A0<1w@10I)=rA|nF|We#$(*{lsR_rlU^7l`$U~%{=(}0$@UL`{k!;vWSgdR`2pdQcr!4bt=!_4BW_oX?Ln4UEV|;I4&V`+y z_YZxH=9@*bHv-yg0)@bpr)&Y(J6bShe8nd(vhWKi1a(e?rI>njuJ+#NM=tO_Tv&U< zg5KF(D=o`Z2TZUg_}OZD?(j?*V9T*uc^cc2@mEr~wDrWi`U4Qtj7uYm)in&wDNexblSx$K!8Av@2 zU>KMWW5n(UGaI#mf9@o`^#{$fH_0fycrIbBPLP0K%K2u}0Trr|DYQ!p?{Ls@eh2h| z-!j3ojA5j1U75AY-L4d)l>EEG8UySjBXL6nxeP;)3tbh5`e?Z;wPd@F#vDo8zphw) zN1~n`cy~BMXb~pBzLxXL0?mO%Mx!CgdQy*ll@v7T_4{(G&;DOcMlHv*T6U@}lBU=_ z0nt=Z%KZHNtV_!9uI*PUEL;-YD56NdXYW@Yzk$c#vQj^1=~f^asgV?6b8@4~=%+Bv zcsTVO0YYM1B+2AjYqAXzxO1i2bv$eL+xK5wRv4ebQaN60)>kXh5fSQuNt84wH65lC z0&~t4<2B*(`?g?qo^l^0o>V?dx8Q5L74HveMAH{VIEYn#9{SRLR7CsGY0NJ@7mT%L zJUVmqpi)zd#c_`Ph1qS+Js|w-o6F310d(@4fEaGuVhi4~lcQcxPjF`Qzimye;(Iwe zZ%j&DdIb8>i9>;pCar;IvvS2Z$b~w7T(eZST!+8;;XeRqSgtt`WEDnkfo?L&af5GP z5riZE*>tY{nA=LA5be;Ua=GSYP6KvE+026T%z_Z6PNKY|N~;WCxkoxW;k-y(`NBB$ zzK~@J(EVMbQQk$>WHHx0VJaBtHybBW$OzE06sk}gO)u~S%P43(NKr%Fc8Bf*ZEedp z=NvHdd3$fSdX6tngsn;kW($?SVSz$P0d#1G)7V!Le`a%fB){g?Hej4G!m6?2zUrA< zBH@Q?8s_mCICYna4AQeWpLxIOT5r8Lp`CxEp!2r44#@uic97C-j`&WxZ$lF!HON}! zJ9B^ri{*xAiW8OO4X@oTMi((Ij0G!B>x^OQr<-jJTXsgaR^}ky<_AL!M$AOSoxdPg zJbXYl8Eha)aI|4nSe-6+NKp?H7ZSbs9@v|kc%5XZFxUb*$; z?~K)=;jIq9l_}3uFWL>*4XK6)QC_U$`o6AxJ}4W?6lbM>KbQ!~Xv zQl`O7%6`i^AxqJ!KNf_3w5f<9OjEeS5DE;PQ0vv5I$Q<{S^oX{p4kitICy_~#eIFN z#cqK+S1wBNsrozxHHXn)YXzn2^Z`{(wiIJVNt>eBqer&p`8TV;MOP0?Zh5~}BJ86v z*oxP>U7$ z1J6C@s`)>vxwZqYpY8rY76HiOVkPdpG^4@xK8r>wnpEPtJvX z(loxoh=j}>(JPVXN)8uyhYeX9N-Zt_H5FCX)5 zBwf$SpY0t5U1lFf6T=RTGf>C3)lDWg2o2Mr4mdyi{dZ&-YX8bd`5k6I3YdP+-8zeUfNe0dX%A6pg)vxi{X9rN~-ZXF*r{nmk+V6!5;st9N_4T{e)G$ z{m7OOAw`{C>HO|L3?C*NK*GfPlTXmJHe}Mbnj%#g!c!K{bUq&QrtCxyTa*W`@-uLP zkOvL^q)5Q`^b}=tyGRaa%B9>!zf}kwM|m|y$#h07NgYb#42|@DIm|Q*ywN*$aE{GX zgK;CrZX&0Q>-?CX-!mTw3-z>?{eptA(qik}@`lwiRK8jq8hF_w76eI;WZ6Dp0zm|aQ!s~3 z;rG8xzGimg5#yj##A;koee5sfirLSbn_l{{=-ziZBhxZj4?%uN zL|~E%l2mXZK%wT#%t*&&6c0YZ?e3p3)m3BBD)+yKVHi-O5&ZJTi*dgHWVl44-)0y) zW(@AW=ic1k{Q6f=ZH|nXnd@XIa5AgC@<>X`fO5kA$RNc7FxEZ|?mq;#8VN98KFrN8 zgUbuP!}jxOng%G+ZmrEjWXcN}$YX>;m7#Tzb+K~A$|9Sp;DYnc zhhdr}^$m4D+Ol=a99=i2ZrrfJ`|?XKgQxvjmYGPf+wIzKe*L?>9)FpT%@ zcKddx%Lzj_KXKq1o-Ue=)BRA9Ak_g@HSamLcljSlPk1t&v`kSULOtBvzT|rO=qrDM zXh(muus3Av%C)$q4&2ZLaCZ*GzK`u<$6J>$S3%~aLI$v87<|S#j|#hAr(g>X?3d0s z2TwCs_T4%fgf!{YrRJUw_lowKad74i)DXD@m`Uh+mfxgKKJ9&rubu|_LG(Bfj|^OR zTmprfVYY6&ja2u*Xln2Cr(!^U^*hX4Qb&3cR#NLB9En;SBGha(L>Nl<4#q8DONIeg z-VW}syn>g_dWd4(cba=woXmvfYh#S3`|M=)%L9O598g>!GC|#YuQEd|m$SkNKb5?T zenmEqX^nk)UKxWhWcU+J@Oyg@;y$<}eLprz46-8m26MRkY!Y(p(ue^T13-}u$YW+e zo^$Dba9#N*sJ#)aWb6S&m|5;&_rPqagR$mGD5rkYdX+gBgO~jRBGQ3O={{_KXw*s$ zo^Ya-wsI(cpezBZ1n(Qmf%X8hr3f`OHRWvBumPJlZN;{2Tc_>VzWt`&Z6%2X+kR#QTQ2A2GjHXU zM=d>&EYV;xR26Xa)Z*V8gD7z{#g$~P=urRuWC{a*b|+7ieV$(BIvwUFjt0{eB(9-dzD z@`XUnOUOpdZyKf&kH_)S3oijc)b4OY9FQg?9q9Twpm{~FX3H2uBoe~T?ZGn{m(DCJ zD}CGPwEyVXV~$(h(bn;aIPZs*>CSAP;a!Rcu=&7?r`|UpC+I+NdLg>&E5+9Te2%5! z76((`)eeL^Kw1jIG$0JU?;<9Fy6Pb|zw$M*IkRufXgB!SW8RgDC)cy?dazUsEETn` zcmQ0OkiEr_-G%)w$?k(X=hDZRr$9rNZa+-1fr8CUv~2$(D;RIp%(-&+U!Eds(Whd4 zS^L(dS;TK`+iuz)?#bkzNP;=@nz^s!Wo9J7Bo&M+hrU#or7cA}4{H5B^avRxf>xlS zc+v~A$j9vGYd1GM4^g)n%v~^4 zp9r|S5Mu9Ym^^-W z=-Od{jMYxe4%O}i=MtLs?K|y>$DdgB#_MlLv9!n8V%9OD4Z!?Edf)ZgYasLG0>8mM^Pr)%8?$^sg=d zgWg{YRGr|8+Apfa96pH7nnJT~^~G@KWi523L;%wCvmT>@i6nX&helD;cRZzuhKId~ zEbWXEK`Vr>x;|ogV?N@gQ|D4Fcq6rJ`zm7HjM+T>a=0>wO#nE&fN4PNUH)xNXs1ZU z)2`t;rCW(h&{H~W4h82OI|VPwPWYYH8Yn3##;#qvV~2nkuw)M)1ZX52@9hyNmtAkA zh4e0k5AO%;^5G?Y@-&^&s((P5a=P`bMH3-UJ01G^m%#JK^wUy_aZpbi)X#kbyl_H) z3&BWc*Q^->BpLD0;K7)#&Q5vi)XDhgKmLKY-+srtbm`J`GBX2_fN5y`MzuG{!5Hfw zB_x6*NswhHQpqG9dho&DtzW-!*5pYOuU1ucL_uqKneOhq;eR6$n6DI6H2LpFVprji#=ZKOnSpudP6n1^NENbFpCGxVgT*<@;@nFxTDPH*8;PkVzB zJsBc(=|oF=?!X8g2_UB&%Iu5oF=|&_0%0Chf0s75>|Th@+A(H#{h7S__$3r>+YgFN zvg-C?U7!PtkwGx`uKW^GQH6O5GN&>K9o&%vo>zH4O9o+iYY*e_5C)J8g83^z20s`+ z4iC79EUhpV2lEuH=Vi05mx?F-)o9&*8@28FDiRUE=1gy@L6T3o1m-J+XxcP~>ONjA zFS_wsCflB4vI2@EFuAM{=bktpw)}FqZ5$@s?`?!aJu+Db}FqSe*a*tBU2)~;KZZ>=!{hA`lA zd*SgEgd|Ba075FIdAmA0mHp*pd;klnrE%Gy>pIr2`}nHvt}f>nzjWt0hTRW z7Uo<+CZ+~JM^y1cyM75AUN;Or19M-)^_-!!294HePkrRc(2Bc{-868*lt4Cmf0t zm6w+Sz3)?;7!@>i}^RXakVAdb{d zAD+`)b{yFvAOPNiILobk3_bNX!{*9dRP6LY)V%jakvHx~%;7UhkM_+G_vEI{4y&s$ z%PEJk_UUUW&?H$j!Xl&p2cAN(nHN4{3QC((Y~Z`aLZHst^a;iWYGB?XNR>xDU~YN! zFPZ4xtq!1WP{;3NJ$S;T>Q3e4`^ z#PY{of$~`oQrF&}in>+DGrJdLb7$S)l*@}mTR2e8)WI9U9;Pu20HS3(jLolr<(3Si0}g{A0p@W- ztbZ0b<9mRlf^iwrQJ2Ad_J`n}LaSkFs1?%K$xu%E`hM+d+Y%V-Uj?tM95l6os|=AO zp)=KiOa=D6=3IVmUh~}9bI{b-gyQ0&r!Ktk;=kqR`?XLwjLloN9KeOekVwP>Wo4yx zvu4g(#lZifDDv2j&d!^bE&JeBEg84Tip@%aAWEBv7PPEdx#F7dfB()cH{X2Y|JBvi z_j`_s6RSTRr#qR(kzIxk(lxLNiywl`lRZo;+kr%=gc5-Z;P6o<@k~tv4{6D|_8wJOoxeD+BYEf_Y2&U%oQH z;Ri3A@B~v`F$gX5vnzH`Jjji0OTHxH0f<;PM63%U+-9}EQoVrW03-*P>IJp$z72W; z+4@gWA`D(IzEPU~xg}QdajwA_+LI|ifJDz{;h1Sb1yBr%fY(RN=d5dA{T6cFh!r?H82!>%m*LCQ+rK!c^2?T>d zghC-Gic&X!{`~KrbMCpbX3mF_&pbQb<8dRAh$EFu zAeBsfiaspcNU$XeNcoi;gui^X*|m28bNGSGSw|4HAKk$6#ywA_iC!-%vpLgk(M>Q< z0nCPVi$wdb$;_37RW!XBc;48*i<=$|RzaR| z7W9>mgCrU9ltqx|ety3hy7Ez&yHks{DV~B!e8xGukfu;Jw=V%A?SO0tPlRCBt^OLZgXlf_V2=UG2$-*=mXA5= z9TKLM@ttikk!dB(F=R2jtSoN$%kL(}ug;dK%gZq1JRlZU)dcl3>mpQ<`?>!`$ux8QM@nxnQ0Gh_qOezNC(&fzLQ~VTtuKyJD6naR%T!DRjF*wOXiL@|4Nbev81}J zd?Xx9Wg`I91&VemRKMz8amqI?kX;_Mueuk1e&`8QmKKJ5KJUI{JT~RvZ+z+EZ7_R8+Shf&E7tNsc?zuq;0Pk+AOg!Nfw}!Hh}La=h1BxGFF;@ZH~<661;5CLh+SRwSbgiM)Pm&-jHZ;`N&iuze{&D5S7hm+G)ne?^ zbh_(_kvOwJ;WqG`(x;iP_%Eau*N31{1JKK;%h_Uzc3Dt<<*b(2*%3Fj=*T zGS)r`6iowDoj{^zP*aY&>%hxqKsoKZpw*9qdK!S-$`Nn?r5*Fp6r_sTuQ7kwNBWv4 z9%R9$OQ2-xZ^+W+ETu5_Z91QSc>gTqmu@=0T7mof-@~|Z<8a4!zO$vRrFlxGUW5R! zI^+TDg>dGXNSGtaH+n?us(qVXwn4<>&{sYN+eN>#z;^O!;J!StvKf%7kMAo0)876+ zh?WMh@^OdMdSwQ{B&=!H0FdS5qyE|v0hlm;!cIdsw5?mWK+`momzQHv^?2;uxdX;w z^ao8O5>QkXxw(E!n|97OdV)RU_U_qzo}%vG%aSC)(1GR4SN!CZlTUh*gn((9pCVw5 z5P?1k1H5XU#>b!Vl=1P?H?d4bphRGHFUm}3yw&BKrF}`#;O+>;36@*=H)>dWKg*DxL4ehJao_rr z&6@Ydviz}i6zc)0b})zCA{boz?=wa7mJ;NYW{ay^lRoX7zq6vLfYNyA{)dbKjvVM4 zo`>1A5%SpMhuEHrK(PR%@>w8HA&fVF0}3>yd+Uu%bw0&=07gNUQ+6p5f#*a#crkP4 zA|sQ7q=F)y5WC*F0af3=+3z$!T`@E?G@-b-crAd-GEN}l*wCV*u~S23p$f!IeAa{r zU>-lrjW2-C`AMJEqMY$P@X~4fHKt$_^mqOQmYWaOn+!Y1d1X@=l0g$6?$ZHS%{ls! z9H!T(*XLV1cI-HK+#ahBp{Aj=tra~zJ#Y^}%VLZnrD;eclBgb6joCA1!KSLHt{!*U zb=O_LFCLE<*z8u~C=o%D6x7%4o%r%AuP!PrEm;4 z%q&eyZ61hVOP<*FpG&0aXZ@2R9adQ0;Rki>hPn0iuV(Ft41f|L@Cl1w=6PdUDb{%i z1%=W;m8Sb0?6au^IX5gKA4PUNOf!N`cBYjGM1p-`th?ZIy>z{+N z@LKB(Jnh^475UeH282UES+$k0O^0ylyE#7El0a*~0GIgyMplvTt>E|Ptk}ABD?*`g z-*20yz>FC)uzSyLbaZy~(a0P;Eu3>iqcMybHx?%@Iv!dog|0*rLI_lisY-qR^3VV9 z(MKM+-!#p>o`#Yv!!&iYwzhwM{P;=BB9Y-)X~T;Wddo)a5{e6a`uW>g#hec<{}jur zjvH+|ZzN|9$X5h14G75wvup1e6mA{E1}OmMM39On-b*$oNVb7gd)5o86Oa{<&_JXQ zerXZF=7{jTs;8mFGCw;BtFunS+UrIAYL%kxR-K}+5@y5tG3K6+PKBo+d#Zq*03W;X zA$SV_SWf%w7YDPu0W%3v^Nz(pA=?f=$BJUq#pm{^*Ff`S4pT(EFmaY<>X$Pi(c z(yRJ~niQY|3j6GFllS>TZ4!*tPwdyI4uDp3-v;Q*9{~zWhGd3v5FjzUT%!RHP~?H@ z(KL0qJzjJA^l9&vmX=~nRb~3B!uaZOFijIaUk*+_>10Hs(E5TAQyvIDynM>p9-sokByij;dlAT2z32=J1NZyd@C3 z--D=M1wLkBKVO;l$`3)p1Xr9xDu=VH9Pus#&uven&B1|VNy0=`)tJ>sAANLNC=`Oo z=|ASCFi|~z0w#=~fW7s5p=lZvMeYNuU@(A+$_gw#X%V8a7^2Z=zs}H+NCcIYmE!p0 zkNd|fFTM1GgXgBby?s(^TT9j0F;xwp8es8k4(4II{uRhmPkTvhd9_Q#1NrPA-gE-2 z9H~eI)UoI5Y{CiGGc67Z?JG078_s5qfmy#Sz3C_w0WX~NSMIL@g<6NW*$6BV8QQZ4 zS|E7}*O>*?>#1Y++>Ep{1aQRxvv$>usF?Q@clp8euwvAH^d++UvTH!m9`NaBy~xKM z7ocD>VD}HQ_6f|D2ebAAh#hZ%c}qs1!>|=Gr9dO3i6?@p=0R+F8Pv5moxMKDSPH`; z8O*N+^A&>Ul!G~Q_p_{~4;bdJgfwCCKh3%|zs@vv#2AnWg21ZTysKc>LWr(yMr&6W zX3d%P+_GiwUv20HB)R`VA*&olO2Z?YH5jD0i zfw}Pwu)@kAffW(Jd@`Q>AdI$93S1d@xQR5~bai$0EA8!FXl-rH$Q;_#)B>B$2ERWK znwEsBDlknG?d|QTC@)7i8b(b`4Z6CzGV;II*VltFysN0T9~g!SNwQ2!S+PL~f$x6z zd(#yEy2}qyx9Tz)Gw)Vu(y2*p!%JU9 zq{B)F$fTiYaWH>{#;1PnvHcnfJH!^Xm_u3mR5_&Ug9KP!6{LxaAJFz~ypK6^Gizeb z98lZNMJ&`Z9p$sP8e87D0O5{e=E}|ZC5!|}wnOrl{*7xPkkAHAxMZpmlnTOZ-)Xht zVtj=BHt7grq!Vy>!Ka-CcnX1zooQZrWk7TfTEf!EBHbXx4rat*?Au^zdk2H4!v~6W zuVSt|WMp6`vJxeQQ7z&f;IR(aC4nAO!Gifmzx}V={79gu%Of3BeIbFtfP@Fv$MJ(j zZa5qgV#&{@mc@N}FgL#fI{Pj#kJX$+d*w%fO&N0ek3(TVQs8fEEfx_aL%RcAPl0h6 z^XAQY+HRAPpO-Tz0Lrq2a8w`~jlt{nVBvyeaphH)W9P12NF`H{<;?B@yTgt|Jhf-p z2OsHyo-Rd_9DUKkR4Rc}Pranz(n~J>^h`p@Up4Z!ytfFLdHy}-wk5a0)DGGR>18b2 zK#@+Lh;*I9!mZCy)217l-J5Yjtp*YiNX1iLOx6K$ktL+Ejc?QdT#m(Tv5Xxn)mgptns%D{-42!R((-odLEtq@vl z&~hloWsuzqbKR4mo(3>a(J;zJ4(%{UA_S;TNK;P-`O9I}uLpHE0KP)Y$C3o&!CdU99~ds9gMY4K{@GG=*u4h)vN_8 z9Xq6XBmqc%3IF*xj&=JIV6rrjHB_wHqvUfR&z-38Me{N9{%=$ek&`n|B( z?9lZTUU}s;EAlr;dWGHLKqwe$HVnO!bE&kSABzZ6r%v&lamMMN9$*=}-u)z|4RCmB zcwzP1)VcdK*mDkQc97o4iXEbU&1Fc2VcE*D2EZsN0qS}gsJ zsddQ85PfxckkH-KS;dO(!b~7HqjxgxW5F&1F%n zWUBB;M!<5bwj+P+GE<9NbjpY03{AwXc7Q_^5$OT1I_e&_IZ2QR{V$CJP_fw z>0V_LjqdM^o3%# z{84rfV5ma|Y0~0Wg5#VEL7QIzl}rU2w-C(G(vJQi4xVfWB%44w;?4%1Aiah<7z9XX zsC1+-f9gbpb%yyz ?zY zJMJxpXs*hcOP*NTR5?WVfm+OaA@r zGegSMCnBh-4K`K9cfRu-Fg~@eO{;^5m1PHs+DdavY1{G@JUBKPpYGbdYUr(qKE*+ z2E>CfxBVymcgLZ%D=vZA++glPuwV;Bxcwy2w6TiiRsAD-x9!YeN8S5C-3?&A60lSd zV(V*ZlP>Ld8j251vH@Bw2PEt)g9De+j(;Y}26OtLCjh%$#^no7M%Y=7@uhjtQ~LLB zx#eps4gFv(i-9wXi~O%EqxjM+2WC%lK<_Y)JRULP%Buv@<1ic64OvSjL2&pLv^DAY z&O2d%aY&qHC~LLuHDku~ABICAbai!u4IwvA2ov#m99La=6=u$yiAZELiD)dA z`_IS!l^>0S`v9v~ql?92!B9^Sc{#bC4q&lQDz8P4g6CJ7H161c8XI4{gDDwkj?<)X z#HH+$Y9zpXrG}I@?orm=2q_smoR`Yc_3~Psot<4l4_LP>Ny_ zR&DI$Q~wTsg~b4wMRjMMA{d*VhiKktMFlgaMwpfsMX>7gNVr6>=>%%o`Z=?s_GId+ zosQ-$;JH=LF~t$3Yz<%!enw9L%R(Shxop+S<%_`fYl$rVUsYj9 znFc=pLJ+%dx54e^h{i;E1O4~aE$Rgot^n?Q9J+bEWhy%C9FT#lUkD(PGNIb!1KxYT zS*N8E$S)|YnK5JfGl_TtF4xd%fi+D-)#OUFw6tLF-r504sM*Bl^I_Ze?bWeZ%+3#} zDlv2&HoF5Ke(*ut=8YS%WXY0GNyAcXpWMs|6Fhg!J$4^dGDi-~Ew8{_{TN{Pf)b&O4@;>i5Na7CQt@M{Y2z7`ik)I4LuHf*gDG|}n+Fy- zA{I%LPJV-e`wpRH5m-(+#HJS^S~gobT4}!@gaJgmAFvS?TRYe z-T~&$AMg&;t99zB8kR~xN+tlAV2^jAHIP6LGr=VZr=E7oEvr^8-)tJjfKWRTAgK~+ zI#T$`b3r_OZ653?Ldu}eq!a#-4@Cr-15&PxU%nK?(mip=O6GlH7}mkN_@u?(DJd&O zS7+CdnxG0HKt!mh8iSIeVx%-}h`KkSvZ4Z;wrri3O2(nu_t*EDrVd3_%`30Ga%)*x z>8EEBlEeRrO%(xP<4SlMH$jF277PLI4BhZAG`2w6pjbF>$0aZ*gRmW9n#dZtd?h4 zv`yypL+pC*k4Ei^3t@9vTls8R(to#BDmu0t0L z>@x{k+1H5-z*Z#VKOe{N!=*uhOV(1&5E(QL4KrrVe)k7Ixbu~sKmdke3?c3fsEUF_ zB7rrl*I;+eZm2`_TN4QN_4Qb`?8CGBPKyJisHkX{Bq=Q&o!y@zU?swz?5uDZ$RG1} z>|JpN+phr+>0F|C0K9DGChjX;PmSxd^*kK}?*tfEAmt1rHGlx-a6pVd{t>-p>$hNN zL=uMP2n@hPcl-jme66VT$>PrzsgP&xDZ!o}} z57D^(658?hEs&KYwB*1s6T%`TWHLlxpVc4F?zJ?)1Ea5!1d4V6&D(&yF@U!i%$<`N zcx4+P3{dlyvsspLA_gECg)(u`20mdC5a|FoP$hr~bwEhxuyFxzju)3*e(Bdg_~6~k zv{b@3pvfu$ip-EQCEWa456b)!&RgJuXw@Oo@dx@0163c@y8!IPGS=@%;oK*>0WjFq z%+BysDggj=*(H};6AT2<)73R3vyK3`TrTX{vl~s#O>nuKNNPhXAa^<)XlZTEudUsC zI?IsCGG)q?_X-LN(A?bo=>ZnAxjxz1A%Zl1(HmmVhfNe}D`$4^(6lVZtaO09s(Z*) z05Sy*|M;}J>X4oogb!;lFb@K%eLM3ME)#*qMNCqMtRYgY2h!BD{vnNB6roTHFxW6F z4v41pp!yXS0be#z9pJL^BJ-90kxV@^fGRFf&pw}CyYeb|_IVGBc%!8e^}2W%0Gr#& zscPO~IoY#mk3`mYI6R=;%fKq;fxM-lz&?vvwpY_icLJwS(_GQBZ!#QNf+Bhx%v%&= zzS1=m3jl@=lUXJn5&_gShLB^I(a>0r@{01*Qb2^L5iSAj`^tk{z2(LMlnP z;E680sW6;2$AMIvVMPu2|WUQ}AVevy9Fiio~E@uQQAuOK$lTSJ2*2>EA z<_|wuHY95kWF>fNx`uExiu{6n4As*oOcT}B)p+*V=f9pzL}lfGL&Hp)re)XMYIN28$ZGU36fa>M%wLh@rPH58pb^Z}4*#o#38p&0 zeZx$?Bm(mlgQlH!xAES+iD)9GflgHQ=eDxfNs&17WP#K=eh zc6UAV6|WQ>yN_WGUj{8kfGKu}=FQ)uITt>Rg7JVB>jQhnC5yDKeV3)pIeb98JYm@MWFMQ#R+C6m-tXTfx^}UTM`cDr*wR31m6Q@7Yfj6!##OIE3fp=<1 z8Td?^heQ_7mAzQTx|$SDc(4-*O+d9vS@(sZYnV2D=G))?_ILiCh{rKz?6@KMuD}3A zQ4xtmkW3{ZOGASQQym;}ureO}*@jo(7 z_nhKSev(|d;8RX{5WC*}(U43l#z3hEq|)h+NqJ+U6z>6OIDZg7eLsjt4HVj4STJucRBmNZ6A}Eme%$l- zzus{AnV&nRqrGj0YI9mQC#$|9_WH#v&$K%5(H6ciNT_rLwW`=gPt=RlLZH=};;+&O=cxP-2r&S7h_!!rrvJ)it+ zB?91{{C!fz>^DU1^0VMML`y3}2UHLElvD2~Nd`&sFm-$ZFd33$$FRK`B*03hfyOTQ zr@sD~Z?jBYf%Y%S^sz30obta2;-EwA7A9FB)wy@@rVhPeWCakOU{3!ZU>YuDIyDJk z?gE$}KlvAB`dKeYlTU3!xCKz%(APWxL|QGgFfk0`HD?aQ=GVX^8PZW#0;UP-u7mO3 zU;fD?3E&DSLw6UXqTmJN!pu|rf?2!LYLL;Z<%<;DsvnMm3afEy8bp(cBnpd)aLX;X zoblry{cyLIio4VdUBHP5HoJsW(!>ofbz?`njz696hdWO}qQ}To)%dBKfDi;%js(aY zzkVf%JKqWdU|G#T&N))aI3!udJ@?#m=JCfL7w+n8gVQmzs6OW$rYR5%bRnswAe%#j z2gVsvS{#4+(;v=Qvu5R0(g8`@j4>E`0uHCUXU^Q&_wK6Mg=8{0G;MF>d{~}OVa5o| zT?Dym-o2@s_s<%fYSC&jCFNFp%-#7LC>ie4LJs@g7z3Fa%pteY%5onvfxOE5xik0M zWM)gxNM~myBjEnB9(l&u&w$Gox7857n|X_dh`|DE+_6z3(DH=2>80ygZbgO#Pk_S< z5o}Slm+yR9(PE34k%HM-4@&fa%SylAe1{F-4lkg^V61oqq&i@(f9_EVwNLLY_RX*h zK;cfvb1wP|pLBOfSH8MROT}Tc zI|sZo5iIjiXZZ8VFxE7s@W6$+m^Q%<1WiQKwTGWJa1jA+)zYe(n{?dxayMSv83ULE z)y6Y72xbhaR1yHg)mLA0=|vY_xIPkzfH4L|8cLQd>r;v+Oq>YL`608~i3o}!WAfxF zxc8p>{Ez+PA5Q^*tjG|;(rSAfs9tsT72jUC@EC31zJ1_FkhMEZKCJMkGjZB(u;OX2 z@zQCnW_M!=%ix&p<0LQ=;FC_ipSg=b!4@z!%*`bTOtPb|i_dVCEXE;?U$lqztXOI` ztT~0eMPS+5&+AFBys=M6Ff|eF20PT33KNiR;6;uhn~!w zyedp^UkQxn%_q{b`|ej}oPC4Yy3HzNmeoO{mWMvRWq?UA+iM^i*Z$1hx8aM-Tawul zOcz?SoU(v2|C--2#s@TGWnfUafK6wJ>7rk=1;!XUJ3Dd4>8G#0{hPO+{ii?t@%2

hCm@OBWPqzOq?AoFaBIzuXz0!U!WwCOjDudaTsp`ih8w>y1a4XsqGxB9i$d_0sE z)Z4~u^{Ul)_@Reh1K_tz@HEdpW6)CxR91~y`~5racobkLD=8heb~S9kGP5#degaxn zP8nF)%)8ON|bU))QA4V)&@veobgBGe=xvEfR8!)ZnJUi zDJs z?phka(_0hx{_!4sVYU;lVhIQnVo4Jt9Zc+f5|@nuUKvOVys|ciUws(C>c%9j&dPFc zKirHfO-sfBFie^<e_E@X& z1oeTPma>9#ci#EEE5I09np=(ttcDF(lBwg<5*81FO+M`*bJx4SfSwqr888NlbU`}$ zil?LrC#FPCJz#f^*g`szSJ!^d1LmW zyYBEJr|EWG%v}I7w5i7Xci%6rlaZDhk2^d76As4J1G{g+BD-3XPK;}sH7nXj_UwVG+VEd$Rd4&$0EBG_?Cr7+9;V1prF8QL$_$A_ zfR>8G@6RK_O& z^c1E|pYik_iy!adL z%KZ+@DSwFzZ7GX~RzY=iLUBZy#4KKZo10U(BUgmlCW%1Pbn34E9ChwF56LiN4jL5yTYLf^f}%KM!y)^J33HWR=V=!Q%*jr zqrLOl4I9=S10bV`*z3EL7$Dgs2ynEAO+4^%7!Q0LMY&(b{4xa#%50cjC}T{nghGde z90!ABm(z3~Z2t*h2t*Tv_8t>WAp;vabZl%h@KKY7+73OfFLFpKhm>C1`yYu7(5iIZ zfG{;UovvNK{r&GQ&Ck!<@{6DUYFOshP+TWO1X-40x7*=#I#F6$ik1IbJ$37r&98!S zs5V=_`)F2%{oZ@;z3+;m;$rM;Y)ork;=cn}+*5>4Rb)G)F$^QmPs4chYim!C zOQ+q-wOG3S{0M|-WW^$uJMwnHR4B8)M#wzR_U_cvd5+2zOHf8V`-T(f4)H?lh84+`uk zHULG<0gmAmIwtyV22rb>tl!*f^H>A5@PW<8XFrCi^UKM zhx6{ZvsfN!<1Pr>1En&0{Ecg`p*$k#hN+S8is$OJ5g$2hv>^-mYDNPu~Z zAr(%z$LOm2W8cqH5inm_H=B9xv%-SWel9FC$5k5Rb>PZ(k!Wy6D1he(tQ#Eq&<0hyL2!+%yirAi%ZXD3dt@Yz)0! zX>>tIrGVO`j@r%xM~xly=kz6WD3UZZ=7YYj))o+eOt@U0u49gwfBWK-PkN%QtplB% zoyhU~hkVwtw1eI3GXoC|B$6T{&=SCwEnD&4viIz7zOm$e0EN9^)tj)IN+tmaTzA8D z7yb0EyY_6~z8$GlYDh_|pR5ndUx80s$mRmZ9`h9H*8B!WQib9GCBu-Woc09Cj)drL z7^!cvQX;rIVy6NHJHRHLx`gjs+A6yCmcW@~Ior!;zbltbtD|Jh(&!HNzIqB2>9q2( z4hygt(A@x#fbHC$pKL6kv2*ITR#%$Y~>Nw;1g;yu5luDUxZ)(yDwhMjmjwBg`DDhig01Kz?F z^08mO5@oX+#EOS-I2>X}0t5ii-QA5qAecP%*kiwc$t9OO{^E--{c!vC?N?Z4m*t!J zZ;6&l0T5tZLU~2y8?$E3_}Pgkp18VZ_a1b2cEaQH9=6Yl(qMHsVwxrj3k%U2Z3TmvHf`GWQ%^hX%IVW*{9)&g?YGqK-Fta3&||lT zNl7P3elj`lM3$3Ym;z=x@Zxm3QBhg>tkdcEo6nc?q0i?-S63I3iR58xEd$NK!JkEv zB+J3>a3U{151N+3cfb3+r#5a_cebM1vA;u+bvHv#A;+Kl(v??U`86Q~4AcC?=4^Nx zmXXANLnzb=mN({oUN~X5*|cSXRDJw?%c>RuI`IFIyz^ixupO|P*i2az)RQlK5d?H8I_e) zjX8e*Q}d3R_cWQbv8JX5(P$LOq_3ZLc(@LBA!vV}g24bmR*+02(9qC;=9XqiT*C9u zy>Rb4Z@+c9tk^6r__S}02+*|z^70Ely8MbOF65jc6bki~<$QJk%UkkaT3!MyryQ(k z(u=%h+qdB@dC5$3m5-$PM#2E=^QDa3z?&d&Ptg;??YV%Dng0y4=YT;P_IGd)gcbv7 zi39k_*>HBPwXowsFw@jo(WKugg%j=*WPVY!?Yf)-O~;TPw}3|&R)-xDY5HS+KnR~K zUz#KXrfzlC0RS$8<&-wa#Z#Z>uKWi9+R0QGDAr?r{xibq!Wcs$kwBoQ2fCp*Oq@9J z=a|5L-rdu+u&b-<+@9{h8R2kfUMLjozljt(gb)y>0WL}XG$0{FU*@=?D9{h0X7YHv z$ji&$K56pAckDL%ThpdZd%K~rL325sXl-eOrfEZJ7%`aXE5rc}WDjxXD6))DB8A<% zc4Pg!`LCBJx64E zlI84xXx|N9FfPsFAdY0mT7Z-Yfg~j?PdV+cX7%xZ72DsO$%3uNlEjZ?hCZ7j?Um3H zJ}~J3uwm)u2@K5C!8}E+Om*&ruXqhFnzWPz-j_Y{B2sH+}KPXMYDpH(422!%qB zxD30)v1-zkDXa2x3w{s@2PP&Gi8;w+YTou8J7(D(j&b$%^=0u`%z?DFmI*jWm|zV0 zlxfqO;<4D?(z3D|x68Fk;%xoYsnfU4m^B^CK3IliGKpw3I=lqXgG_KDI%Jv6z~wI> z$r8qn8-q8N{O8-LMB)crlA$O{zlflgild;gu;IS@?prir{Deg9-dY^o%r=|J$vKB@ znEt_G0hU}j`@gu70I6ikDxoJ zPe-au)cieHulrCHLp?h~ttuO7cW)mh&~Y z+Ft)vMMXItd;IY)zWdHQzh_K>qNx3Itx|Eg-0tqLfBn|Q#YIIub#--z1jgRq&&$gN zmn1YdeTo#x|K()_Fis${I>qo2_J45M+I^jOTvN#w#}kT(i*yt*bP!gl(pja1j+CVr zAp{U$Nk*@=FUAc z=boAKoAW)8;Z}A+Rt40^LI$`IDyPf`%&uwgZ8Ax)MbY59w*!;DYhz_`75v7Y@}=(v zoYpjhK5<)W*?j#L2jok)4Wx~SxbHn?8^9!e=}nlfXId|oTdGDjH> z(r1;G9Adc~Iy!n;J+r(Ly}}ssbqqBG+|2?5e?M9$>LYG4;~9D<8WP-AI$N@`uRM3K z)j|JyZ2ynwiLhKRDahr0WM`IWnPkHBdy(K>vD-7j zlp1F-J@GJ8^cK~(%$o!)Va3Z){nsF`lZ=J0-Dh{M7*O$sI^tur2)V^b|ay6?VDROrB_A6k8Q{T{7d0E zAhzQ@kvbc$voY^rTekTKmAK4~xBUCEa4iHmwla}bszlok)m9Jaw?7Uo7)pKm6#f_W z#mV|to9FdzCZ2)!h`}^a)65GZKS9PYF6WbUdZ8}*{Ly+k6QlnzcYB+A-H4YlSe@)R zg>Sv_snKspv(~+HX@S11ca+QSynjZKo2^Fwa95dD+Pu@R0jvayOMrOfoyJKH`&2rM z69ORyFhd*l#41}0k8p+5Aa(8 zf`ZZ%czT@RY!r1n5Bn5Q#oKDS(Rbe-Vu{+KAUJL**MHzi+ZAwPw`sQZF4N&3 z(L>$-#qsANl>bCWM$SC1WZng9`?D{jR^i|+2-#;?`&4qw`(W&~c4zXK-kfRhA2TXp z>yy{B_9|X7*@*3etE^UedHHw~I(Q@k)Uvme65E2g4iD?3*9A-Pw*zems%zyvP_(xM zYeicBah!47rc!`?cNY|v=>uuwyRxV*;Ju^!mg!HMnwo64bnValYRpbe1$IKR$m+|m zntnP`C8M=<+i2`mwWbiD#{goDtjU1u%P1V}&D!UVi^2sF@VgP_XmA5m`F@FSXfzryST{tGzx3e4l1J$+=-bIb7RxPo1a6ddy{cW#zMBSdm{n zG{o}5vE?m7Agb*5JMG0%Nx1_y^+-+GJyQLp5yuS!s!(`h@JHlan)S{?pC1ZZ7%zd# z`LHzPlcCKx_)Tngxs17UXrOzTta{A57^K5e0#C#>$FU<~fGE+ckwr&GrwX7q`;&tH z?H}HfqRxhqEDhURY+vvFO~QgdCME_1uK|2;Jox@tEJRUJQ5m8=5Cj`xs-->d4I_#( zr!YKI452sL{G2tp$dC{vb?d%Np_+zyvR31DGLbh~<@#`;Ev)L_acQhg%OK8W7(dls zu2l;I323YwuYtOV=*0*l6q~Y~90&8(oPO>qjvDdg>Exblt^2^Rg;j}a{Gw+x6&)zU zZ*sB7*f2rN$^p5XDdgHTZ(WNx3@eVRn8EJ#+9G~6qQ>nE&R)pNllsaFJdy(`6;E)T zqA%*i`Dg7qX+_Qj$jlVC8@}?JSs94`lPL3lrO}Sj%3H-$-k2_^;;F>ymZ5^ zTzUrpxg-lVWgb|t85sfqE?@$;Gp6^~V!nPY2>E*dBKE%##U?(>4}X7P8#OLkL9Xzj zFXaMEoqer)i^vOaYy%e3q`>f7VQO9bX&Sv?eQ5N+>gS8~KS_Kgi9Lu{eGV!z&X?K3zv(KV8a`-gkR!Y|MM(+5Vvp z@E|W*8|%KIAnDcB9O`Wlki81u+LRvByNR0J*$~hbPuSsmbwo%6wTqIIn@#DTRSy5P zh(c$FEl@O*$mBjJ7sMSCIan@IJ|#cj+5EkC>xLBE0{krgdu=dPJid8F+?i>xZ%DS$ zc$lBRdN9`3-LgK{vJC%xuq_%85@HG%;g(mf==0rpEhQj$uY9(#_7^kWA5!~eLmNKJ z`;U0Mx>EZLOFI=%6VvHac2w+;ylwwrV8hwdh))> ztQe=aHIJ)mOCqHdae@95XYY53jlLF)6gF3!+nq9ykm1=)osWMhs`0stLS%?X9(2T` z{b>^jn8}+7CTk+DT*j?PC46;!>3gK+*&!>8U$4ptl=GCz&<4;UaT$pw=)PaQs^x^6 zcECAPLbXQ&)a_wJ=0W)7l0lNNv~M;yw|hZ!beWcnXR(sN79&(Qa0MD0(%?a~XuhP> z!*X5q=x~QeWk-aB_Qc^lDRX4&TaPP2n#fJ`J5Pygsa&S7qH;Ycg8C)lS)<(IYq%1V z>2l0wZt&q1PV?R8=S%WbO%D^iY{o{OrSmu{3?1y$D|5Fm) ziAemg8rPxZm!R}QEAbqk20><0H5Cc{U5!BU`c99G1uQTv$MdJ?tMkU^xCG*_qMelr z9O^$_ot%u>+-#?I*~#bA_B^c2df`v*EtGI3v;VE2{v_`6$Gt~rc0;UlP2SCeeNVkI zmrBaULHWSp(&5r?D9O_kI%4d&mZI!Dhv$w6IT73{duasJeyR$mIV4D+mpo literal 0 HcmV?d00001 From 15f8c2c78b098ac6109adecf0048a538c071a3c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Bresson?= Date: Thu, 11 Jul 2019 05:14:27 +0200 Subject: [PATCH 02/62] [code] indicate replacement methods in the javadoc (#3329) See PR #2946 --- .../java/org/openapitools/codegen/ClientOptInput.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/ClientOptInput.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/ClientOptInput.java index 8453c1c905..71716ba25c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/ClientOptInput.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/ClientOptInput.java @@ -19,6 +19,7 @@ package org.openapitools.codegen; import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.parser.core.models.AuthorizationValue; + import org.openapitools.codegen.auth.AuthParser; import java.util.List; @@ -64,6 +65,10 @@ public class ClientOptInput { return config; } + /** + * @deprecated use {@link #config(CodegenConfig)} instead + * @param config codegen config + */ @Deprecated public void setConfig(CodegenConfig config) { this.config = config; @@ -74,6 +79,10 @@ public class ClientOptInput { return openAPI; } + /** + * @deprecated use {@link #openAPI(OpenAPI)} instead + * @param openAPI the specification + */ @Deprecated public void setOpenAPI(OpenAPI openAPI) { this.openAPI = openAPI; From 99ee68128d5401a5f50b1a974b3d448f49c1b31c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Bresson?= Date: Fri, 12 Jul 2019 06:55:23 +0200 Subject: [PATCH 03/62] [java-client][okhttp-gson] add missing import for bearer authentication (#3343) --- .../main/resources/Java/libraries/okhttp-gson/ApiClient.mustache | 1 + .../src/main/java/org/openapitools/client/ApiClient.java | 1 + .../src/main/java/org/openapitools/client/ApiClient.java | 1 + 3 files changed, 3 insertions(+) diff --git a/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/ApiClient.mustache b/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/ApiClient.mustache index a5617334a8..cd173326c1 100644 --- a/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/ApiClient.mustache +++ b/modules/openapi-generator/src/main/resources/Java/libraries/okhttp-gson/ApiClient.mustache @@ -52,6 +52,7 @@ import java.util.regex.Pattern; import {{invokerPackage}}.auth.Authentication; import {{invokerPackage}}.auth.HttpBasicAuth; +import {{invokerPackage}}.auth.HttpBearerAuth; import {{invokerPackage}}.auth.ApiKeyAuth; {{#hasOAuthMethods}} import {{invokerPackage}}.auth.OAuth; diff --git a/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/java/org/openapitools/client/ApiClient.java b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/java/org/openapitools/client/ApiClient.java index 781acbe492..0934b6f1aa 100644 --- a/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/java/org/openapitools/client/ApiClient.java +++ b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/java/org/openapitools/client/ApiClient.java @@ -49,6 +49,7 @@ import java.util.regex.Pattern; import org.openapitools.client.auth.Authentication; import org.openapitools.client.auth.HttpBasicAuth; +import org.openapitools.client.auth.HttpBearerAuth; import org.openapitools.client.auth.ApiKeyAuth; import org.openapitools.client.auth.OAuth; import org.openapitools.client.auth.RetryingOAuth; diff --git a/samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java b/samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java index 781acbe492..0934b6f1aa 100644 --- a/samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java +++ b/samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java @@ -49,6 +49,7 @@ import java.util.regex.Pattern; import org.openapitools.client.auth.Authentication; import org.openapitools.client.auth.HttpBasicAuth; +import org.openapitools.client.auth.HttpBearerAuth; import org.openapitools.client.auth.ApiKeyAuth; import org.openapitools.client.auth.OAuth; import org.openapitools.client.auth.RetryingOAuth; From 09b4bbc1e1414b7d403f608848ebf8ba64568021 Mon Sep 17 00:00:00 2001 From: Shunsuke Tadokoro Date: Sat, 13 Jul 2019 00:59:12 +0900 Subject: [PATCH 04/62] Correct CLI option (#3340) --- .../codegen/languages/ScalaPlayFrameworkServerCodegen.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java index 881b2cb6dc..a30f0bd797 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java @@ -84,7 +84,7 @@ public class ScalaPlayFrameworkServerCodegen extends AbstractScalaCodegen implem importMapping.put("TemporaryFile", "play.api.libs.Files.TemporaryFile"); cliOptions.add(new CliOption(ROUTES_FILE_NAME, "Name of the routes file to generate.").defaultValue(routesFileName)); - cliOptions.add(new CliOption(ROUTES_FILE_NAME, "Base package in which supporting classes are generated.").defaultValue(basePackage)); + cliOptions.add(new CliOption(BASE_PACKAGE, "Base package in which supporting classes are generated.").defaultValue(basePackage)); addCliOptionWithDefault(SKIP_STUBS, "If set, skips generation of stub classes.", skipStubs); addCliOptionWithDefault(SUPPORT_ASYNC, "If set, wraps API return types with Futures and generates async actions.", supportAsync); From e81e650627af79f2e35c825e306da0f1c0eb1c93 Mon Sep 17 00:00:00 2001 From: Michal Foksa Date: Fri, 12 Jul 2019 18:41:26 +0200 Subject: [PATCH 05/62] 1. Operations are grouped together by resourcePath so that operation s with same resourcePath can be rendered one after the other. (#3202) 2. Lambdas registered: lowercase, uppercase, onchnage, etc. --- .../languages/OpenAPIYamlGenerator.java | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java index e0d2a98294..5c46567fd9 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java @@ -18,9 +18,23 @@ package org.openapitools.codegen.languages; import org.openapitools.codegen.*; +import org.openapitools.codegen.templating.mustache.CamelCaseLambda; +import org.openapitools.codegen.templating.mustache.IndentedLambda; +import org.openapitools.codegen.templating.mustache.LowercaseLambda; +import org.openapitools.codegen.templating.mustache.TitlecaseLambda; +import org.openapitools.codegen.templating.mustache.UppercaseLambda; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import com.google.common.collect.ImmutableMap; +import com.samskivert.mustache.Mustache; +import com.samskivert.mustache.Template; +import io.swagger.v3.oas.models.Operation; + +import java.io.IOException; +import java.io.Writer; +import java.util.ArrayList; +import java.util.List; import java.util.Map; public class OpenAPIYamlGenerator extends DefaultCodegen implements CodegenConfig { @@ -61,6 +75,44 @@ public class OpenAPIYamlGenerator extends DefaultCodegen implements CodegenConfi } LOGGER.info("Output file [outputFile={}]", outputFile); supportingFiles.add(new SupportingFile("openapi.mustache", outputFile)); + + addMustacheLambdas(additionalProperties); + } + + private void addMustacheLambdas(Map objs) { + + Map lambdas = new ImmutableMap.Builder() + .put("lowercase", new LowercaseLambda().generator(this)) + .put("uppercase", new UppercaseLambda()) + .put("titlecase", new TitlecaseLambda()) + .put("camelcase", new CamelCaseLambda().generator(this)) + .put("indented", new IndentedLambda()) + .put("indented_8", new IndentedLambda(8, " ")) + .put("indented_12", new IndentedLambda(12, " ")) + .put("indented_16", new IndentedLambda(16, " ")) + .put("onchange", new OnChangeLambda()) + .build(); + + if (objs.containsKey("lambda")) { + LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + + "You'll likely need to use a custom template, " + + "see https://github.com/OpenAPITools/openapi-generator/blob/master/docs/templating.md. "); + objs.put("_lambda", lambdas); + } else { + objs.put("lambda", lambdas); + } + } + + /** + * Group operations by resourcePath so that operations with same path and + * different http method can be rendered one after the other. + */ + @Override + public void addOperationToGroup(String tag, String resourcePath, Operation operation, CodegenOperation + co, Map> operations) { + List opList = operations.computeIfAbsent(resourcePath, + k -> new ArrayList<>()); + opList.add(co); } @Override @@ -81,4 +133,24 @@ public class OpenAPIYamlGenerator extends DefaultCodegen implements CodegenConfi return input; } + /** + * Lambda writes current fragment to the output when it is different than + * previous fragment. + */ + public static class OnChangeLambda implements Mustache.Lambda { + private static final Logger LOGGER = LoggerFactory.getLogger(OnChangeLambda.class); + + private String lastVal = null; + + @Override + public void execute(Template.Fragment frag, Writer out) throws IOException { + String curVal = frag.execute(); + LOGGER.debug("[lastVal={}, curVal={}]", lastVal, curVal); + if (curVal != null && !curVal.equals(lastVal)) { + out.write(curVal); + lastVal = curVal; + } + } + } + } From a5f92ad150cda1bbac0e5398b5b2109bba6a11a5 Mon Sep 17 00:00:00 2001 From: William Cheng Date: Sat, 13 Jul 2019 01:20:15 +0800 Subject: [PATCH 06/62] update doc --- docs/generators/scala-play-server.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/generators/scala-play-server.md b/docs/generators/scala-play-server.md index 6aaa4d1017..e7b3a46bf6 100644 --- a/docs/generators/scala-play-server.md +++ b/docs/generators/scala-play-server.md @@ -15,7 +15,7 @@ sidebar_label: scala-play-server |apiPackage|package for generated api classes| |null| |sourceFolder|source folder for generated code| |null| |routesFileName|Name of the routes file to generate.| |routes| -|routesFileName|Base package in which supporting classes are generated.| |org.openapitools| +|basePackage|Base package in which supporting classes are generated.| |org.openapitools| |skipStubs|If set, skips generation of stub classes.| |false| |supportAsync|If set, wraps API return types with Futures and generates async actions.| |false| |generateCustomExceptions|If set, generates custom exception types.| |true| From 40a6e639d497685db4cb2201e8f3f62a917a96a3 Mon Sep 17 00:00:00 2001 From: William Cheng Date: Sat, 13 Jul 2019 10:39:58 +0800 Subject: [PATCH 07/62] Add links to Codewind OpenAPI Tools (#3350) --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index c385e05569..bf3009ef6b 100644 --- a/README.md +++ b/README.md @@ -592,6 +592,8 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - 2019-05-22 - [REST APIs代码生成指南(OpenAPI Generator)](https://gum.co/openapi_generator_ebook_gb) by [William Cheng](https://twitter.com/wing328), [Xin Meng](https://github.com/xmeng1) - 2019-05-24 - [REST API 代碼生成指南 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328) - 2019-06-24 - [Kubernetes Clients and OpenAPI Generator](https://speakerdeck.com/wing328/kubernetes-clients-and-openapi-generator) by [William Cheng](https://twitter.com/wing328) at [Kubernetes Contributor Summits Shanghai 2019](https://www.lfasiallc.com/events/contributors-summit-china-2019/) +- 2019-06-28 [Codewind OpenAPI Tools](https://marketplace.eclipse.org/content/codewind-openapi-tools) in [Eclipse Marketplace](https://marketplace.eclipse.org/) by IBM +- 2019-06-29 [Codewind OpenAPI Tools](https://marketplace.visualstudio.com/items?itemName=IBM.codewind-openapi-tools) in [Visual Studio Marketplace](https://marketplace.visualstudio.com/) by IBM - 2019-07-04 - [REST API のためのコード生成入門 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh), [和田拓朗](https://github.com/taxpon) ## [6 - About Us](#table-of-contents) From f04ef76d0763984c2c37056d94c4d500e627baf0 Mon Sep 17 00:00:00 2001 From: Josh Burton Date: Sat, 13 Jul 2019 16:32:24 +1200 Subject: [PATCH 08/62] [dart-jaguar] Adds option to customise the generated API client name (#3234) * [dart=-jaguar] Adds option to customise the generated API client name * [dart-jaguar] Removes explicit clientName CLI property and derives client name from pub name * [dart-jaguar] Updates samples * Reverts import changes --- .../codegen/languages/DartJaguarClientCodegen.java | 6 +++--- .../src/main/resources/dart-jaguar/README.mustache | 2 +- .../src/main/resources/dart-jaguar/apilib.mustache | 4 ++-- .../petstore/dart-jaguar/flutter_petstore/openapi/README.md | 4 ++-- .../dart-jaguar/flutter_petstore/openapi/lib/api.dart | 4 ++-- .../dart-jaguar/flutter_proto_petstore/openapi/README.md | 4 ++-- .../dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart | 4 ++-- samples/client/petstore/dart-jaguar/openapi/README.md | 4 ++-- samples/client/petstore/dart-jaguar/openapi/lib/api.dart | 4 ++-- samples/client/petstore/dart-jaguar/openapi_proto/README.md | 4 ++-- .../client/petstore/dart-jaguar/openapi_proto/lib/api.dart | 4 ++-- 11 files changed, 22 insertions(+), 22 deletions(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartJaguarClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartJaguarClientCodegen.java index 5e60619cd9..cc2516fee7 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartJaguarClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartJaguarClientCodegen.java @@ -16,15 +16,12 @@ package org.openapitools.codegen.languages; -import org.apache.commons.io.FilenameUtils; import org.openapitools.codegen.*; import org.openapitools.codegen.utils.ModelUtils; import io.swagger.v3.oas.models.media.*; import org.apache.commons.lang3.StringUtils; -import org.openapitools.codegen.*; -import org.openapitools.codegen.utils.ModelUtils; import org.openapitools.codegen.utils.ProcessUtils; import java.io.File; @@ -37,6 +34,8 @@ public class DartJaguarClientCodegen extends DartClientCodegen { private static final String SERIALIZATION_FORMAT = "serialization"; private static final String IS_FORMAT_JSON = "jsonFormat"; private static final String IS_FORMAT_PROTO = "protoFormat"; + private static final String CLIENT_NAME = "clientName"; + private static Set modelToIgnore = new HashSet<>(); private HashMap protoTypeMapping = new HashMap<>(); @@ -141,6 +140,7 @@ public class DartJaguarClientCodegen extends DartClientCodegen { //not set, use to be passed to template additionalProperties.put(PUB_NAME, pubName); } + additionalProperties.put(CLIENT_NAME, org.openapitools.codegen.utils.StringUtils.camelize(pubName)); if (additionalProperties.containsKey(PUB_VERSION)) { this.setPubVersion((String) additionalProperties.get(PUB_VERSION)); diff --git a/modules/openapi-generator/src/main/resources/dart-jaguar/README.mustache b/modules/openapi-generator/src/main/resources/dart-jaguar/README.mustache index f3e63b485e..93cdde77b2 100644 --- a/modules/openapi-generator/src/main/resources/dart-jaguar/README.mustache +++ b/modules/openapi-generator/src/main/resources/dart-jaguar/README.mustache @@ -82,7 +82,7 @@ import 'package:{{pubName}}/api.dart'; {{/authMethods}} {{/hasAuthMethods}} -final jaguarApiGen = JaguarApiGen(); +final jaguarApiGen = {{clientName}}(); var api_instance = jaguarApiGen.get{{classname}}(); {{#allParams}} var {{paramName}} = {{#isListContainer}}[{{/isListContainer}}{{#isBodyParam}}new {{dataType}}(){{/isBodyParam}}{{^isBodyParam}}{{{example}}}{{/isBodyParam}}{{#isListContainer}}]{{/isListContainer}}; // {{{dataType}}} | {{{description}}} diff --git a/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache b/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache index cb41c5243a..8571ea0a19 100644 --- a/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache +++ b/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache @@ -42,7 +42,7 @@ final Map converters = { final _defaultInterceptors = [OAuthInterceptor(), BasicAuthInterceptor(), ApiKeyAuthInterceptor()]; -class JaguarApiGen { +class {{clientName}} { List interceptors; String basePath = "{{basePath}}"; Route _baseRoute; @@ -51,7 +51,7 @@ class JaguarApiGen { /** * Add custom global interceptors, put overrideInterceptors to true to set your interceptors only (auth interceptors will not be added) */ - JaguarApiGen({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { + {{clientName}}({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { _baseRoute = Route(baseUrl ?? basePath).withClient(globalClient ?? IOClient()); if(interceptors == null) { this.interceptors = _defaultInterceptors; diff --git a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md index 0d0008ed4f..291b60d7e6 100644 --- a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md @@ -4,7 +4,7 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T11:26:01.157+12:00[Pacific/Auckland] +- Build date: 2019-06-29T09:47:15.495+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements @@ -55,7 +55,7 @@ import 'package:openapi/api.dart'; // TODO Configure OAuth2 access token for authorization: petstore_auth //openapi.api.Configuration.accessToken = 'YOUR_ACCESS_TOKEN'; -final jaguarApiGen = JaguarApiGen(); +final jaguarApiGen = Openapi(); var api_instance = jaguarApiGen.getPetApi(); var body = new Pet(); // Pet | Pet object that needs to be added to the store diff --git a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart index 23e4217515..b787b0405d 100644 --- a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart @@ -37,7 +37,7 @@ final Map converters = { final _defaultInterceptors = [OAuthInterceptor(), BasicAuthInterceptor(), ApiKeyAuthInterceptor()]; -class JaguarApiGen { +class Openapi { List interceptors; String basePath = "http://petstore.swagger.io/v2"; Route _baseRoute; @@ -46,7 +46,7 @@ class JaguarApiGen { /** * Add custom global interceptors, put overrideInterceptors to true to set your interceptors only (auth interceptors will not be added) */ - JaguarApiGen({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { + Openapi({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { _baseRoute = Route(baseUrl ?? basePath).withClient(globalClient ?? IOClient()); if(interceptors == null) { this.interceptors = _defaultInterceptors; diff --git a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md index e50b342433..8277867842 100644 --- a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md @@ -4,7 +4,7 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T11:26:04.013+12:00[Pacific/Auckland] +- Build date: 2019-06-29T09:47:16.421+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements @@ -55,7 +55,7 @@ import 'package:openapi/api.dart'; // TODO Configure OAuth2 access token for authorization: petstore_auth //openapi.api.Configuration.accessToken = 'YOUR_ACCESS_TOKEN'; -final jaguarApiGen = JaguarApiGen(); +final jaguarApiGen = Openapi(); var api_instance = jaguarApiGen.getPetApi(); var body = new Pet(); // Pet | Pet object that needs to be added to the store diff --git a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart index bed06dd13d..12dcdff72f 100644 --- a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart @@ -47,7 +47,7 @@ final Map converters = { final _defaultInterceptors = [OAuthInterceptor(), BasicAuthInterceptor(), ApiKeyAuthInterceptor()]; -class JaguarApiGen { +class Openapi { List interceptors; String basePath = "http://petstore.swagger.io/v2"; Route _baseRoute; @@ -56,7 +56,7 @@ class JaguarApiGen { /** * Add custom global interceptors, put overrideInterceptors to true to set your interceptors only (auth interceptors will not be added) */ - JaguarApiGen({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { + Openapi({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { _baseRoute = Route(baseUrl ?? basePath).withClient(globalClient ?? IOClient()); if(interceptors == null) { this.interceptors = _defaultInterceptors; diff --git a/samples/client/petstore/dart-jaguar/openapi/README.md b/samples/client/petstore/dart-jaguar/openapi/README.md index 2b99d076a7..7f45064333 100644 --- a/samples/client/petstore/dart-jaguar/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/openapi/README.md @@ -4,7 +4,7 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T11:25:59.502+12:00[Pacific/Auckland] +- Build date: 2019-06-29T09:47:14.533+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements @@ -55,7 +55,7 @@ import 'package:openapi/api.dart'; // TODO Configure OAuth2 access token for authorization: petstore_auth //openapi.api.Configuration.accessToken = 'YOUR_ACCESS_TOKEN'; -final jaguarApiGen = JaguarApiGen(); +final jaguarApiGen = Openapi(); var api_instance = jaguarApiGen.getPetApi(); var body = new Pet(); // Pet | Pet object that needs to be added to the store diff --git a/samples/client/petstore/dart-jaguar/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/openapi/lib/api.dart index 23e4217515..b787b0405d 100644 --- a/samples/client/petstore/dart-jaguar/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/openapi/lib/api.dart @@ -37,7 +37,7 @@ final Map converters = { final _defaultInterceptors = [OAuthInterceptor(), BasicAuthInterceptor(), ApiKeyAuthInterceptor()]; -class JaguarApiGen { +class Openapi { List interceptors; String basePath = "http://petstore.swagger.io/v2"; Route _baseRoute; @@ -46,7 +46,7 @@ class JaguarApiGen { /** * Add custom global interceptors, put overrideInterceptors to true to set your interceptors only (auth interceptors will not be added) */ - JaguarApiGen({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { + Openapi({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { _baseRoute = Route(baseUrl ?? basePath).withClient(globalClient ?? IOClient()); if(interceptors == null) { this.interceptors = _defaultInterceptors; diff --git a/samples/client/petstore/dart-jaguar/openapi_proto/README.md b/samples/client/petstore/dart-jaguar/openapi_proto/README.md index 761fc689ef..84be8a47c9 100644 --- a/samples/client/petstore/dart-jaguar/openapi_proto/README.md +++ b/samples/client/petstore/dart-jaguar/openapi_proto/README.md @@ -4,7 +4,7 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T11:26:07.058+12:00[Pacific/Auckland] +- Build date: 2019-06-29T09:47:17.358+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements @@ -55,7 +55,7 @@ import 'package:openapi/api.dart'; // TODO Configure OAuth2 access token for authorization: petstore_auth //openapi.api.Configuration.accessToken = 'YOUR_ACCESS_TOKEN'; -final jaguarApiGen = JaguarApiGen(); +final jaguarApiGen = Openapi(); var api_instance = jaguarApiGen.getPetApi(); var body = new Pet(); // Pet | Pet object that needs to be added to the store diff --git a/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart b/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart index bed06dd13d..12dcdff72f 100644 --- a/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart @@ -47,7 +47,7 @@ final Map converters = { final _defaultInterceptors = [OAuthInterceptor(), BasicAuthInterceptor(), ApiKeyAuthInterceptor()]; -class JaguarApiGen { +class Openapi { List interceptors; String basePath = "http://petstore.swagger.io/v2"; Route _baseRoute; @@ -56,7 +56,7 @@ class JaguarApiGen { /** * Add custom global interceptors, put overrideInterceptors to true to set your interceptors only (auth interceptors will not be added) */ - JaguarApiGen({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { + Openapi({List interceptors, bool overrideInterceptors = false, String baseUrl, this.timeout = const Duration(minutes: 2)}) { _baseRoute = Route(baseUrl ?? basePath).withClient(globalClient ?? IOClient()); if(interceptors == null) { this.interceptors = _defaultInterceptors; From 4843dfc24444f2399ff8a4475112c981991a8c08 Mon Sep 17 00:00:00 2001 From: Jim Schubert Date: Sat, 13 Jul 2019 04:43:05 -0400 Subject: [PATCH 09/62] Updates to address recent lodash Object prototype vulnerability (#3348) --- .../Javascript-Flowtyped/package.mustache | 3 +- .../.openapi-generator/VERSION | 2 +- .../javascript-flowtyped/package-lock.json | 332 +- .../javascript-flowtyped/package.json | 3 +- website/i18n/en.json | 15 + website/package.json | 6 +- website/yarn.lock | 3794 +++++++++-------- 7 files changed, 2349 insertions(+), 1806 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/Javascript-Flowtyped/package.mustache b/modules/openapi-generator/src/main/resources/Javascript-Flowtyped/package.mustache index 4f2598fa34..f2a1f86966 100644 --- a/modules/openapi-generator/src/main/resources/Javascript-Flowtyped/package.mustache +++ b/modules/openapi-generator/src/main/resources/Javascript-Flowtyped/package.mustache @@ -33,6 +33,7 @@ "@babel/preset-flow": "^7.0.0", "babel-preset-react-app": "^7.0.0", "flow-copy-source": "^2.0.0", - "rimraf": "^2.6.2" + "rimraf": "^2.6.2", + "lodash": ">=4.17.13" } } diff --git a/samples/client/petstore/javascript-flowtyped/.openapi-generator/VERSION b/samples/client/petstore/javascript-flowtyped/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/javascript-flowtyped/.openapi-generator/VERSION +++ b/samples/client/petstore/javascript-flowtyped/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/javascript-flowtyped/package-lock.json b/samples/client/petstore/javascript-flowtyped/package-lock.json index 2207ddfeef..7e63013475 100644 --- a/samples/client/petstore/javascript-flowtyped/package-lock.json +++ b/samples/client/petstore/javascript-flowtyped/package-lock.json @@ -1078,31 +1078,36 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", - "dev": true + "dev": true, + "optional": true }, "arr-flatten": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", "integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==", - "dev": true + "dev": true, + "optional": true }, "arr-union": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=", - "dev": true + "dev": true, + "optional": true }, "array-unique": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", - "dev": true + "dev": true, + "optional": true }, "assign-symbols": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=", - "dev": true + "dev": true, + "optional": true }, "async-each": { "version": "1.0.3", @@ -1115,7 +1120,8 @@ "version": "2.1.2", "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==", - "dev": true + "dev": true, + "optional": true }, "babel-loader": { "version": "8.0.5", @@ -1241,6 +1247,7 @@ "resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", "dev": true, + "optional": true, "requires": { "cache-base": "^1.0.1", "class-utils": "^0.3.5", @@ -1256,6 +1263,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^1.0.0" } @@ -1265,6 +1273,7 @@ "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1274,6 +1283,7 @@ "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1283,6 +1293,7 @@ "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, + "optional": true, "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -1319,6 +1330,7 @@ "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", "dev": true, + "optional": true, "requires": { "arr-flatten": "^1.1.0", "array-unique": "^0.3.2", @@ -1337,6 +1349,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -1359,6 +1372,7 @@ "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", "dev": true, + "optional": true, "requires": { "collection-visit": "^1.0.0", "component-emitter": "^1.2.1", @@ -1444,6 +1458,7 @@ "resolved": "https://registry.npmjs.org/class-utils/-/class-utils-0.3.6.tgz", "integrity": "sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==", "dev": true, + "optional": true, "requires": { "arr-union": "^3.1.0", "define-property": "^0.2.5", @@ -1456,6 +1471,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^0.1.0" } @@ -1478,6 +1494,7 @@ "resolved": "https://registry.npmjs.org/collection-visit/-/collection-visit-1.0.0.tgz", "integrity": "sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA=", "dev": true, + "optional": true, "requires": { "map-visit": "^1.0.0", "object-visit": "^1.0.0" @@ -1514,7 +1531,8 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==", - "dev": true + "dev": true, + "optional": true }, "concat-map": { "version": "0.0.1", @@ -1535,7 +1553,8 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz", "integrity": "sha1-Z29us8OZl8LuGsOpJP1hJHSPV40=", - "dev": true + "dev": true, + "optional": true }, "core-util-is": { "version": "1.0.2", @@ -1574,6 +1593,7 @@ "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, + "optional": true, "requires": { "ms": "2.0.0" } @@ -1588,7 +1608,8 @@ "version": "0.2.0", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.0.tgz", "integrity": "sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU=", - "dev": true + "dev": true, + "optional": true }, "define-properties": { "version": "1.1.3", @@ -1604,6 +1625,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-2.0.2.tgz", "integrity": "sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==", "dev": true, + "optional": true, "requires": { "is-descriptor": "^1.0.2", "isobject": "^3.0.1" @@ -1614,6 +1636,7 @@ "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1623,6 +1646,7 @@ "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1632,6 +1656,7 @@ "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, + "optional": true, "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -1747,6 +1772,7 @@ "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", "dev": true, + "optional": true, "requires": { "debug": "^2.3.3", "define-property": "^0.2.5", @@ -1762,6 +1788,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^0.1.0" } @@ -1771,6 +1798,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -1782,6 +1810,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-3.0.2.tgz", "integrity": "sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg=", "dev": true, + "optional": true, "requires": { "assign-symbols": "^1.0.0", "is-extendable": "^1.0.1" @@ -1792,6 +1821,7 @@ "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", "dev": true, + "optional": true, "requires": { "is-plain-object": "^2.0.4" } @@ -1803,6 +1833,7 @@ "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", "dev": true, + "optional": true, "requires": { "array-unique": "^0.3.2", "define-property": "^1.0.0", @@ -1819,6 +1850,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^1.0.0" } @@ -1828,6 +1860,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -1837,6 +1870,7 @@ "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1846,6 +1880,7 @@ "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -1855,6 +1890,7 @@ "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, + "optional": true, "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -1868,6 +1904,7 @@ "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", "dev": true, + "optional": true, "requires": { "extend-shallow": "^2.0.1", "is-number": "^3.0.0", @@ -1880,6 +1917,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -2024,13 +2062,15 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=", - "dev": true + "dev": true, + "optional": true }, "fragment-cache": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/fragment-cache/-/fragment-cache-0.2.1.tgz", "integrity": "sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk=", "dev": true, + "optional": true, "requires": { "map-cache": "^0.2.2" } @@ -2071,27 +2111,28 @@ "dependencies": { "abbrev": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "resolved": false, "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", "dev": true, "optional": true }, "ansi-regex": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "resolved": false, "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true + "dev": true, + "optional": true }, "aproba": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "resolved": false, "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", "dev": true, "optional": true }, "are-we-there-yet": { "version": "1.1.5", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz", + "resolved": false, "integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==", "dev": true, "optional": true, @@ -2102,15 +2143,17 @@ }, "balanced-match": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "resolved": false, "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "dev": true + "dev": true, + "optional": true }, "brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "resolved": false, "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, + "optional": true, "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -2118,32 +2161,35 @@ }, "chownr": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz", + "resolved": false, "integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==", "dev": true, "optional": true }, "code-point-at": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "resolved": false, "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", - "dev": true + "dev": true, + "optional": true }, "concat-map": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "resolved": false, "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true + "dev": true, + "optional": true }, "console-control-strings": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", + "resolved": false, "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", - "dev": true + "dev": true, + "optional": true }, "core-util-is": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "resolved": false, "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", "dev": true, "optional": true @@ -2160,28 +2206,28 @@ }, "deep-extend": { "version": "0.6.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "resolved": false, "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", "dev": true, "optional": true }, "delegates": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", + "resolved": false, "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", "dev": true, "optional": true }, "detect-libc": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", + "resolved": false, "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", "dev": true, "optional": true }, "fs-minipass": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz", + "resolved": false, "integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==", "dev": true, "optional": true, @@ -2191,14 +2237,14 @@ }, "fs.realpath": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "resolved": false, "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true, "optional": true }, "gauge": { "version": "2.7.4", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "resolved": false, "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", "dev": true, "optional": true, @@ -2215,7 +2261,7 @@ }, "glob": { "version": "7.1.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", + "resolved": false, "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", "dev": true, "optional": true, @@ -2230,14 +2276,14 @@ }, "has-unicode": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", + "resolved": false, "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", "dev": true, "optional": true }, "iconv-lite": { "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "resolved": false, "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", "dev": true, "optional": true, @@ -2247,7 +2293,7 @@ }, "ignore-walk": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz", + "resolved": false, "integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==", "dev": true, "optional": true, @@ -2257,7 +2303,7 @@ }, "inflight": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "resolved": false, "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "optional": true, @@ -2268,53 +2314,58 @@ }, "inherits": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "resolved": false, "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", - "dev": true + "dev": true, + "optional": true }, "ini": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", + "resolved": false, "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", "dev": true, "optional": true }, "is-fullwidth-code-point": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "resolved": false, "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", "dev": true, + "optional": true, "requires": { "number-is-nan": "^1.0.0" } }, "isarray": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "resolved": false, "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true, "optional": true }, "minimatch": { "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "resolved": false, "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "dev": true, + "optional": true, "requires": { "brace-expansion": "^1.1.7" } }, "minimist": { "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "resolved": false, "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", - "dev": true + "dev": true, + "optional": true }, "minipass": { "version": "2.3.5", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.5.tgz", + "resolved": false, "integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==", "dev": true, + "optional": true, "requires": { "safe-buffer": "^5.1.2", "yallist": "^3.0.0" @@ -2322,7 +2373,7 @@ }, "minizlib": { "version": "1.2.1", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.2.1.tgz", + "resolved": false, "integrity": "sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA==", "dev": true, "optional": true, @@ -2332,9 +2383,10 @@ }, "mkdirp": { "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "resolved": false, "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", "dev": true, + "optional": true, "requires": { "minimist": "0.0.8" } @@ -2379,7 +2431,7 @@ }, "nopt": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", + "resolved": false, "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", "dev": true, "optional": true, @@ -2408,7 +2460,7 @@ }, "npmlog": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "resolved": false, "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", "dev": true, "optional": true, @@ -2421,43 +2473,45 @@ }, "number-is-nan": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "resolved": false, "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", - "dev": true + "dev": true, + "optional": true }, "object-assign": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "resolved": false, "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", "dev": true, "optional": true }, "once": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "resolved": false, "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, + "optional": true, "requires": { "wrappy": "1" } }, "os-homedir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "resolved": false, "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true, "optional": true }, "os-tmpdir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "resolved": false, "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true, "optional": true }, "osenv": { "version": "0.1.5", - "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", + "resolved": false, "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "dev": true, "optional": true, @@ -2468,21 +2522,21 @@ }, "path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "resolved": false, "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true, "optional": true }, "process-nextick-args": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", + "resolved": false, "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==", "dev": true, "optional": true }, "rc": { "version": "1.2.8", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "resolved": false, "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", "dev": true, "optional": true, @@ -2495,7 +2549,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": false, "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true, "optional": true @@ -2504,7 +2558,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": false, "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "optional": true, @@ -2520,7 +2574,7 @@ }, "rimraf": { "version": "2.6.3", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", + "resolved": false, "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", "dev": true, "optional": true, @@ -2530,20 +2584,21 @@ }, "safe-buffer": { "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "resolved": false, "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true + "dev": true, + "optional": true }, "safer-buffer": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "resolved": false, "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true, "optional": true }, "sax": { "version": "1.2.4", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "resolved": false, "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==", "dev": true, "optional": true @@ -2557,23 +2612,24 @@ }, "set-blocking": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "resolved": false, "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true, "optional": true }, "signal-exit": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "resolved": false, "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true, "optional": true }, "string-width": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "resolved": false, "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", "dev": true, + "optional": true, "requires": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -2582,7 +2638,7 @@ }, "string_decoder": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "resolved": false, "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, "optional": true, @@ -2592,23 +2648,24 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": false, "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, + "optional": true, "requires": { "ansi-regex": "^2.0.0" } }, "strip-json-comments": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "resolved": false, "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true, "optional": true }, "tar": { "version": "4.4.8", - "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.8.tgz", + "resolved": false, "integrity": "sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ==", "dev": true, "optional": true, @@ -2624,14 +2681,14 @@ }, "util-deprecate": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "resolved": false, "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", "dev": true, "optional": true }, "wide-align": { "version": "1.1.3", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "resolved": false, "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "dev": true, "optional": true, @@ -2641,15 +2698,17 @@ }, "wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "resolved": false, "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true + "dev": true, + "optional": true }, "yallist": { "version": "3.0.3", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.3.tgz", + "resolved": false, "integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==", - "dev": true + "dev": true, + "optional": true } } }, @@ -2678,7 +2737,8 @@ "version": "2.0.6", "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=", - "dev": true + "dev": true, + "optional": true }, "glob": { "version": "7.1.4", @@ -2755,6 +2815,7 @@ "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", "integrity": "sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc=", "dev": true, + "optional": true, "requires": { "get-value": "^2.0.6", "has-values": "^1.0.0", @@ -2766,6 +2827,7 @@ "resolved": "https://registry.npmjs.org/has-values/-/has-values-1.0.0.tgz", "integrity": "sha1-lbC2P+whRmGab+V/51Yo1aOe/k8=", "dev": true, + "optional": true, "requires": { "is-number": "^3.0.0", "kind-of": "^4.0.0" @@ -2776,6 +2838,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -2836,6 +2899,7 @@ "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", "dev": true, + "optional": true, "requires": { "kind-of": "^3.0.2" }, @@ -2845,6 +2909,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -2871,7 +2936,8 @@ "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", - "dev": true + "dev": true, + "optional": true }, "is-callable": { "version": "1.1.4", @@ -2884,6 +2950,7 @@ "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", "dev": true, + "optional": true, "requires": { "kind-of": "^3.0.2" }, @@ -2893,6 +2960,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -2910,6 +2978,7 @@ "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", "dev": true, + "optional": true, "requires": { "is-accessor-descriptor": "^0.1.6", "is-data-descriptor": "^0.1.4", @@ -2920,7 +2989,8 @@ "version": "5.1.0", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", - "dev": true + "dev": true, + "optional": true } } }, @@ -2934,7 +3004,8 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=", - "dev": true + "dev": true, + "optional": true }, "is-extglob": { "version": "2.1.1", @@ -2962,6 +3033,7 @@ "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", "dev": true, + "optional": true, "requires": { "kind-of": "^3.0.2" }, @@ -2971,6 +3043,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -2988,6 +3061,7 @@ "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", "dev": true, + "optional": true, "requires": { "isobject": "^3.0.1" } @@ -3019,13 +3093,15 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", - "dev": true + "dev": true, + "optional": true }, "isarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "dev": true + "dev": true, + "optional": true }, "isexe": { "version": "2.0.0", @@ -3037,7 +3113,8 @@ "version": "3.0.1", "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", - "dev": true + "dev": true, + "optional": true }, "js-levenshtein": { "version": "1.1.6", @@ -3112,7 +3189,8 @@ "version": "6.0.2", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", - "dev": true + "dev": true, + "optional": true }, "lcid": { "version": "2.0.0", @@ -3162,9 +3240,9 @@ } }, "lodash": { - "version": "4.17.11", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", - "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==", + "version": "4.17.14", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.14.tgz", + "integrity": "sha512-mmKYbW3GLuJeX+iGP+Y7Gp1AiGHGbXHCOh/jZmrawMmsE7MS4znI3RL2FsjbqOyMayHInjOeykW7PEajUk1/xw==", "dev": true }, "loose-envify": { @@ -3199,13 +3277,15 @@ "version": "0.2.2", "resolved": "https://registry.npmjs.org/map-cache/-/map-cache-0.2.2.tgz", "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=", - "dev": true + "dev": true, + "optional": true }, "map-visit": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", "integrity": "sha1-7Nyo8TFE5mDxtb1B8S80edmN+48=", "dev": true, + "optional": true, "requires": { "object-visit": "^1.0.0" } @@ -3226,6 +3306,7 @@ "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", "dev": true, + "optional": true, "requires": { "arr-diff": "^4.0.0", "array-unique": "^0.3.2", @@ -3268,6 +3349,7 @@ "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.2.tgz", "integrity": "sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==", "dev": true, + "optional": true, "requires": { "for-in": "^1.0.2", "is-extendable": "^1.0.1" @@ -3278,6 +3360,7 @@ "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", "dev": true, + "optional": true, "requires": { "is-plain-object": "^2.0.4" } @@ -3297,7 +3380,8 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "dev": true + "dev": true, + "optional": true }, "nan": { "version": "2.14.0", @@ -3311,6 +3395,7 @@ "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.13.tgz", "integrity": "sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==", "dev": true, + "optional": true, "requires": { "arr-diff": "^4.0.0", "array-unique": "^0.3.2", @@ -3369,6 +3454,7 @@ "resolved": "https://registry.npmjs.org/object-copy/-/object-copy-0.1.0.tgz", "integrity": "sha1-fn2Fi3gb18mRpBupde04EnVOmYw=", "dev": true, + "optional": true, "requires": { "copy-descriptor": "^0.1.0", "define-property": "^0.2.5", @@ -3380,6 +3466,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^0.1.0" } @@ -3389,6 +3476,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -3406,6 +3494,7 @@ "resolved": "https://registry.npmjs.org/object-visit/-/object-visit-1.0.1.tgz", "integrity": "sha1-95xEk68MU3e1n+OdOV5BBC3QRbs=", "dev": true, + "optional": true, "requires": { "isobject": "^3.0.0" } @@ -3437,6 +3526,7 @@ "resolved": "https://registry.npmjs.org/object.pick/-/object.pick-1.3.0.tgz", "integrity": "sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c=", "dev": true, + "optional": true, "requires": { "isobject": "^3.0.1" } @@ -3528,7 +3618,8 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/pascalcase/-/pascalcase-0.1.1.tgz", "integrity": "sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ=", - "dev": true + "dev": true, + "optional": true }, "path-dirname": { "version": "1.0.2", @@ -3595,7 +3686,8 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", "integrity": "sha1-AerA/jta9xoqbAL+q7jB/vfgDqs=", - "dev": true + "dev": true, + "optional": true }, "private": { "version": "0.1.8", @@ -3683,6 +3775,7 @@ "resolved": "https://registry.npmjs.org/regex-not/-/regex-not-1.0.2.tgz", "integrity": "sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==", "dev": true, + "optional": true, "requires": { "extend-shallow": "^3.0.2", "safe-regex": "^1.1.0" @@ -3742,13 +3835,15 @@ "version": "1.1.3", "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.3.tgz", "integrity": "sha512-ahGq0ZnV5m5XtZLMb+vP76kcAM5nkLqk0lpqAuojSKGgQtn4eRi4ZZGm2olo2zKFH+sMsWaqOCW1dqAnOru72g==", - "dev": true + "dev": true, + "optional": true }, "repeat-string": { "version": "1.6.1", "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", - "dev": true + "dev": true, + "optional": true }, "require-directory": { "version": "2.1.1", @@ -3781,13 +3876,15 @@ "version": "0.2.1", "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", - "dev": true + "dev": true, + "optional": true }, "ret": { "version": "0.1.15", "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==", - "dev": true + "dev": true, + "optional": true }, "rimraf": { "version": "2.6.3", @@ -3809,6 +3906,7 @@ "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", "dev": true, + "optional": true, "requires": { "ret": "~0.1.10" } @@ -3835,6 +3933,7 @@ "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.1.tgz", "integrity": "sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==", "dev": true, + "optional": true, "requires": { "extend-shallow": "^2.0.1", "is-extendable": "^0.1.1", @@ -3847,6 +3946,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -3885,6 +3985,7 @@ "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", "integrity": "sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==", "dev": true, + "optional": true, "requires": { "base": "^0.11.1", "debug": "^2.2.0", @@ -3901,6 +4002,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^0.1.0" } @@ -3910,6 +4012,7 @@ "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", "dev": true, + "optional": true, "requires": { "is-extendable": "^0.1.0" } @@ -3921,6 +4024,7 @@ "resolved": "https://registry.npmjs.org/snapdragon-node/-/snapdragon-node-2.1.1.tgz", "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", "dev": true, + "optional": true, "requires": { "define-property": "^1.0.0", "isobject": "^3.0.0", @@ -3932,6 +4036,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^1.0.0" } @@ -3941,6 +4046,7 @@ "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -3950,6 +4056,7 @@ "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^6.0.0" } @@ -3959,6 +4066,7 @@ "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", "dev": true, + "optional": true, "requires": { "is-accessor-descriptor": "^1.0.0", "is-data-descriptor": "^1.0.0", @@ -3972,6 +4080,7 @@ "resolved": "https://registry.npmjs.org/snapdragon-util/-/snapdragon-util-3.0.1.tgz", "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", "dev": true, + "optional": true, "requires": { "kind-of": "^3.2.0" }, @@ -3981,6 +4090,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -3998,6 +4108,7 @@ "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.2.tgz", "integrity": "sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA==", "dev": true, + "optional": true, "requires": { "atob": "^2.1.1", "decode-uri-component": "^0.2.0", @@ -4010,13 +4121,15 @@ "version": "0.4.0", "resolved": "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.0.tgz", "integrity": "sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=", - "dev": true + "dev": true, + "optional": true }, "split-string": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", "dev": true, + "optional": true, "requires": { "extend-shallow": "^3.0.0" } @@ -4032,6 +4145,7 @@ "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", "integrity": "sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY=", "dev": true, + "optional": true, "requires": { "define-property": "^0.2.5", "object-copy": "^0.1.0" @@ -4042,6 +4156,7 @@ "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", "dev": true, + "optional": true, "requires": { "is-descriptor": "^0.1.0" } @@ -4110,6 +4225,7 @@ "resolved": "https://registry.npmjs.org/to-object-path/-/to-object-path-0.3.0.tgz", "integrity": "sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68=", "dev": true, + "optional": true, "requires": { "kind-of": "^3.0.2" }, @@ -4119,6 +4235,7 @@ "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "dev": true, + "optional": true, "requires": { "is-buffer": "^1.1.5" } @@ -4130,6 +4247,7 @@ "resolved": "https://registry.npmjs.org/to-regex/-/to-regex-3.0.2.tgz", "integrity": "sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==", "dev": true, + "optional": true, "requires": { "define-property": "^2.0.2", "extend-shallow": "^3.0.2", @@ -4142,6 +4260,7 @@ "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-2.1.1.tgz", "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", "dev": true, + "optional": true, "requires": { "is-number": "^3.0.0", "repeat-string": "^1.6.1" @@ -4186,6 +4305,7 @@ "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.1.tgz", "integrity": "sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==", "dev": true, + "optional": true, "requires": { "arr-union": "^3.1.0", "get-value": "^2.0.6", @@ -4204,6 +4324,7 @@ "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", "integrity": "sha1-g3aHP30jNRef+x5vw6jtDfyKtVk=", "dev": true, + "optional": true, "requires": { "has-value": "^0.3.1", "isobject": "^3.0.0" @@ -4214,6 +4335,7 @@ "resolved": "https://registry.npmjs.org/has-value/-/has-value-0.3.1.tgz", "integrity": "sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8=", "dev": true, + "optional": true, "requires": { "get-value": "^2.0.3", "has-values": "^0.1.4", @@ -4225,6 +4347,7 @@ "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", "dev": true, + "optional": true, "requires": { "isarray": "1.0.0" } @@ -4235,7 +4358,8 @@ "version": "0.1.4", "resolved": "https://registry.npmjs.org/has-values/-/has-values-0.1.4.tgz", "integrity": "sha1-bWHeldkd/Km5oCCJrThL/49it3E=", - "dev": true + "dev": true, + "optional": true } } }, @@ -4250,13 +4374,15 @@ "version": "0.1.0", "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=", - "dev": true + "dev": true, + "optional": true }, "use": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz", "integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==", - "dev": true + "dev": true, + "optional": true }, "util-deprecate": { "version": "1.0.2", diff --git a/samples/client/petstore/javascript-flowtyped/package.json b/samples/client/petstore/javascript-flowtyped/package.json index 39ff710060..7b108518c7 100644 --- a/samples/client/petstore/javascript-flowtyped/package.json +++ b/samples/client/petstore/javascript-flowtyped/package.json @@ -28,6 +28,7 @@ "@babel/preset-flow": "^7.0.0", "babel-preset-react-app": "^7.0.0", "flow-copy-source": "^2.0.0", - "rimraf": "^2.6.2" + "rimraf": "^2.6.2", + "lodash": ">=4.17.13" } } diff --git a/website/i18n/en.json b/website/i18n/en.json index 096838689d..a42620c4a4 100644 --- a/website/i18n/en.json +++ b/website/i18n/en.json @@ -136,6 +136,15 @@ "generators/flash": { "title": "generators/flash" }, + "generators/fsharp-giraffe-server": { + "title": "generators/fsharp-giraffe-server" + }, + "generators/fsharp-giraffe": { + "title": "generators/fsharp-giraffe" + }, + "generators/go-experimental": { + "title": "generators/go-experimental" + }, "generators/go-gin-server": { "title": "generators/go-gin-server" }, @@ -241,6 +250,9 @@ "generators/mysql-schema": { "title": "generators/mysql-schema" }, + "generators/nodejs-server-deprecated": { + "title": "generators/nodejs-server-deprecated" + }, "generators/nodejs-server": { "title": "generators/nodejs-server" }, @@ -286,6 +298,9 @@ "generators/python-blueplanet": { "title": "generators/python-blueplanet" }, + "generators/python-experimental": { + "title": "generators/python-experimental" + }, "generators/python-flask": { "title": "generators/python-flask" }, diff --git a/website/package.json b/website/package.json index 0a32df0c13..f7df0effef 100644 --- a/website/package.json +++ b/website/package.json @@ -9,9 +9,11 @@ "rename-version": "docusaurus-rename-version" }, "devDependencies": { - "docusaurus": "^1.6.2" + "docusaurus": "^1.11.1" }, "dependencies": { - "js-yaml": "^3.12.0" + "js-yaml": "^3.12.0", + "lodash.template": "^4.5.0", + "lodash.merge": "^4.6.2" } } diff --git a/website/yarn.lock b/website/yarn.lock index 696ec9f4a4..db52f3b285 100644 --- a/website/yarn.lock +++ b/website/yarn.lock @@ -681,6 +681,24 @@ lodash "^4.17.10" to-fast-properties "^2.0.0" +"@mrmlnc/readdir-enhanced@^2.2.1": + version "2.2.1" + resolved "https://registry.yarnpkg.com/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde" + integrity sha512-bPHp6Ji8b41szTOcaP63VlnbbO5Ny6dwAATtY6JTjh5N2OLrb5Qk/Th5cRkRQhkWCt+EJsYrNB0MiL+Gpn6e3g== + dependencies: + call-me-maybe "^1.0.1" + glob-to-regexp "^0.3.0" + +"@nodelib/fs.stat@^1.1.2": + version "1.1.3" + resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b" + integrity sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw== + +"@sindresorhus/is@^0.7.0": + version "0.7.0" + resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd" + integrity sha512-ONhaKPIufzzrlNbqtWFFd+jlnemX6lJAgq9ZeiZtS7I1PIf/la7CW4m83rTXRnVnsMbW2k56pGYu7AUFJD9Pow== + "@types/cheerio@^0.22.8": version "0.22.10" resolved "https://registry.yarnpkg.com/@types/cheerio/-/cheerio-0.22.10.tgz#780d552467824be4a241b29510a7873a7432c4a6" @@ -691,13 +709,13 @@ resolved "https://registry.yarnpkg.com/@types/q/-/q-1.5.1.tgz#48fd98c1561fe718b61733daed46ff115b496e18" integrity sha512-eqz8c/0kwNi/OEHQfvIuJVLTst3in0e7uTKeuY+WL/zfKn0xVujOTp42bS/vUUokhK5P2BppLd9JXMOMHcgbjA== -accepts@~1.3.5: - version "1.3.5" - resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.5.tgz#eb777df6011723a3b14e8a72c0805c8e86746bd2" - integrity sha1-63d99gEXI6OxTopywIBcjoZ0a9I= +accepts@~1.3.7: + version "1.3.7" + resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.7.tgz#531bc726517a3b2b41f850021c6cc15eaab507cd" + integrity sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA== dependencies: - mime-types "~2.1.18" - negotiator "0.6.1" + mime-types "~2.1.24" + negotiator "0.6.2" address@1.0.3, address@^1.0.1: version "1.0.3" @@ -714,7 +732,7 @@ ajv@^6.5.5: json-schema-traverse "^0.4.1" uri-js "^4.2.2" -alphanum-sort@^1.0.1, alphanum-sort@^1.0.2: +alphanum-sort@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/alphanum-sort/-/alphanum-sort-1.0.2.tgz#97a1119649b211ad33691d9f9f486a8ec9fbe0a3" integrity sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM= @@ -724,13 +742,6 @@ ansi-escapes@^3.0.0: resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" integrity sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw== -ansi-gray@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" - integrity sha1-KWLPVOyXksSFEKPetSRDaGHvclE= - dependencies: - ansi-wrap "0.1.0" - ansi-red@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-red/-/ansi-red-0.1.1.tgz#8c638f9d1080800a353c9c28c8a81ca4705d946c" @@ -765,12 +776,25 @@ ansi-wrap@0.1.0: resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768= -archive-type@^3.0.0, archive-type@^3.0.1: - version "3.2.0" - resolved "https://registry.yarnpkg.com/archive-type/-/archive-type-3.2.0.tgz#9cd9c006957ebe95fadad5bd6098942a813737f6" - integrity sha1-nNnABpV+vpX62tW9YJiUKoE3N/Y= +anymatch@^3.0.1: + version "3.0.3" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.0.3.tgz#2fb624fe0e84bccab00afee3d0006ed310f22f09" + integrity sha512-c6IvoeBECQlMVuYUjSwimnhmztImpErfxJzWZhIQinIvQWoGOnB0dLIgifbPHQt5heS6mNlaZG16f06H3C8t1g== dependencies: - file-type "^3.1.0" + normalize-path "^3.0.0" + picomatch "^2.0.4" + +arch@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/arch/-/arch-2.1.1.tgz#8f5c2731aa35a30929221bb0640eed65175ec84e" + integrity sha512-BLM56aPo9vLLFVa8+/+pJLnrZ7QGGTVHWsCwieAWT9o9K8UeGaQbzZbGoabWLOo2ksBCztoXdqBZBplqLDDCSg== + +archive-type@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/archive-type/-/archive-type-4.0.0.tgz#f92e72233056dfc6969472749c267bdb046b1d70" + integrity sha1-+S5yIzBW38aWlHJ0nCZ72wRrHXA= + dependencies: + file-type "^4.2.0" argparse@^1.0.7: version "1.0.10" @@ -787,22 +811,20 @@ argparse@~0.1.15: underscore "~1.7.0" underscore.string "~2.4.0" -arr-diff@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-2.0.0.tgz#8f3b827f955a8bd669697e4a4256ac3ceae356cf" - integrity sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8= - dependencies: - arr-flatten "^1.0.1" +arr-diff@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" + integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= -arr-flatten@^1.0.1: +arr-flatten@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== -array-differ@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" - integrity sha1-7/UuN1gknTO+QCuLuOVkuytdQDE= +arr-union@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" + integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= array-filter@~0.0.0: version "0.0.1" @@ -836,15 +858,25 @@ array-union@^1.0.1: dependencies: array-uniq "^1.0.1" -array-uniq@^1.0.0, array-uniq@^1.0.1, array-uniq@^1.0.2: +array-uniq@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" integrity sha1-r2rId6Jcx/dOBYiUdThY39sk/bY= -array-unique@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.2.1.tgz#a1d97ccafcbc2625cc70fadceb36a50c58b01a53" - integrity sha1-odl8yvy8JiXMcPrc6zalDFiwGlM= +array-uniq@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-2.1.0.tgz#46603d5e28e79bfd02b046fcc1d77c6820bd8e98" + integrity sha512-bdHxtev7FN6+MXI1YFW0Q8mQ8dTJc2S8AMfju+ZR77pbg2yAdVyDlwkaUI7Har0LyOMRFPHrJ9lYdyjZZswdlQ== + +array-unique@^0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" + integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= + +arrify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" + integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= asn1@~0.2.3: version "0.2.4" @@ -858,10 +890,10 @@ assert-plus@1.0.0, assert-plus@^1.0.0: resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= -async-each-series@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/async-each-series/-/async-each-series-1.1.0.tgz#f42fd8155d38f21a5b8ea07c28e063ed1700b138" - integrity sha1-9C/YFV048hpbjqB8KOBj7RcAsTg= +assign-symbols@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" + integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= async@^1.5.2: version "1.5.2" @@ -873,34 +905,28 @@ asynckit@^0.4.0: resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= +atob@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" + integrity sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg== + autolinker@~0.15.0: version "0.15.3" resolved "https://registry.yarnpkg.com/autolinker/-/autolinker-0.15.3.tgz#342417d8f2f3461b14cf09088d5edf8791dc9832" integrity sha1-NCQX2PLzRhsUzwkIjV7fh5HcmDI= -autoprefixer@^6.3.1: - version "6.7.7" - resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-6.7.7.tgz#1dbd1c835658e35ce3f9984099db00585c782014" - integrity sha1-Hb0cg1ZY41zj+ZhAmdsAWFx4IBQ= +autoprefixer@^9.6.0: + version "9.6.1" + resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.6.1.tgz#51967a02d2d2300bb01866c1611ec8348d355a47" + integrity sha512-aVo5WxR3VyvyJxcJC3h4FKfwCQvQWb1tSI5VHNibddCVWrcD1NvlxEweg3TSgiPztMnWfjpy2FURKA2kvDE+Tw== dependencies: - browserslist "^1.7.6" - caniuse-db "^1.0.30000634" + browserslist "^4.6.3" + caniuse-lite "^1.0.30000980" + chalk "^2.4.2" normalize-range "^0.1.2" num2fraction "^1.2.2" - postcss "^5.2.16" - postcss-value-parser "^3.2.3" - -autoprefixer@^9.1.5: - version "9.4.3" - resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.4.3.tgz#c97384a8fd80477b78049163a91bbc725d9c41d9" - integrity sha512-/XSnzDepRkAU//xLcXA/lUWxpsBuw0WiriAHOqnxkuCtzLhaz+fL4it4gp20BQ8n5SyLzK/FOc7A0+u/rti2FQ== - dependencies: - browserslist "^4.3.6" - caniuse-lite "^1.0.30000921" - normalize-range "^0.1.2" - num2fraction "^1.2.2" - postcss "^7.0.6" - postcss-value-parser "^3.3.1" + postcss "^7.0.17" + postcss-value-parser "^4.0.0" aws-sign2@~0.7.0: version "0.7.0" @@ -926,16 +952,29 @@ babylon@^6.17.4: resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" integrity sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ== -balanced-match@^0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-0.4.2.tgz#cb3f3e3c732dc0f01ee70b403f302e61d7709838" - integrity sha1-yz8+PHMtwPAe5wtAPzAuYddwmDg= - balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= +base64-js@^1.0.2: + version "1.3.0" + resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.3.0.tgz#cab1e6118f051095e58b5281aea8c1cd22bfc0e3" + integrity sha512-ccav/yGvoa80BQDljCxsmmQ3Xvx60/UpBIij5QN21W3wBi/hhIC9OoO+KLpu9IJTS9j4DRVJ3aDDF9cMSoa2lw== + +base@^0.11.1: + version "0.11.2" + resolved "https://registry.yarnpkg.com/base/-/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" + integrity sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg== + dependencies: + cache-base "^1.0.1" + class-utils "^0.3.5" + component-emitter "^1.2.1" + define-property "^1.0.0" + isobject "^3.0.1" + mixin-deep "^1.2.0" + pascalcase "^0.1.1" + bcrypt-pbkdf@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" @@ -943,59 +982,58 @@ bcrypt-pbkdf@^1.0.0: dependencies: tweetnacl "^0.14.3" -beeper@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/beeper/-/beeper-1.1.1.tgz#e6d5ea8c5dad001304a70b22638447f69cb2f809" - integrity sha1-5tXqjF2tABMEpwsiY4RH9pyy+Ak= - -bin-build@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/bin-build/-/bin-build-2.2.0.tgz#11f8dd61f70ffcfa2bdcaa5b46f5e8fedd4221cc" - integrity sha1-EfjdYfcP/Por3KpbRvXo/t1CIcw= +bin-build@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/bin-build/-/bin-build-3.0.0.tgz#c5780a25a8a9f966d8244217e6c1f5082a143861" + integrity sha512-jcUOof71/TNAI2uM5uoUaDq2ePcVBQ3R/qhxAz1rX7UfvduAL/RXD3jXzvn8cVcDJdGVkiR1shal3OH0ImpuhA== dependencies: - archive-type "^3.0.1" - decompress "^3.0.0" - download "^4.1.2" - exec-series "^1.0.0" - rimraf "^2.2.6" - tempfile "^1.0.0" - url-regex "^3.0.0" + decompress "^4.0.0" + download "^6.2.2" + execa "^0.7.0" + p-map-series "^1.0.0" + tempfile "^2.0.0" -bin-check@^2.0.0: +bin-check@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/bin-check/-/bin-check-4.1.0.tgz#fc495970bdc88bb1d5a35fc17e65c4a149fc4a49" + integrity sha512-b6weQyEUKsDGFlACWSIOfveEnImkJyK/FGW6FAG42loyoquvjdtOIqO6yBFzHyqyVVhNgNkQxxx09SFLK28YnA== + dependencies: + execa "^0.7.0" + executable "^4.1.0" + +bin-version-check@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/bin-version-check/-/bin-version-check-4.0.0.tgz#7d819c62496991f80d893e6e02a3032361608f71" + integrity sha512-sR631OrhC+1f8Cvs8WyVWOA33Y8tgwjETNPyyD/myRBXLkfS/vl74FmH/lFcRl9KY3zwGh7jFhvyk9vV3/3ilQ== + dependencies: + bin-version "^3.0.0" + semver "^5.6.0" + semver-truncate "^1.1.2" + +bin-version@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/bin-version/-/bin-version-3.1.0.tgz#5b09eb280752b1bd28f0c9db3f96f2f43b6c0839" + integrity sha512-Mkfm4iE1VFt4xd4vH+gx+0/71esbfus2LsnCGe8Pi4mndSPyT+NGES/Eg99jx8/lUGWfu3z2yuB/bt5UB+iVbQ== + dependencies: + execa "^1.0.0" + find-versions "^3.0.0" + +bin-wrapper@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/bin-wrapper/-/bin-wrapper-4.1.0.tgz#99348f2cf85031e3ef7efce7e5300aeaae960605" + integrity sha512-hfRmo7hWIXPkbpi0ZltboCMVrU+0ClXR/JgbCKKjlDjQf6igXa7OwdqNcFWQZPZTgiY7ZpzE3+LjjkLiTN2T7Q== + dependencies: + bin-check "^4.1.0" + bin-version-check "^4.0.0" + download "^7.1.0" + import-lazy "^3.1.0" + os-filter-obj "^2.0.0" + pify "^4.0.1" + +binary-extensions@^2.0.0: version "2.0.0" - resolved "https://registry.yarnpkg.com/bin-check/-/bin-check-2.0.0.tgz#86f8e6f4253893df60dc316957f5af02acb05930" - integrity sha1-hvjm9CU4k99g3DFpV/WvAqywWTA= - dependencies: - executable "^1.0.0" - -bin-version-check@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/bin-version-check/-/bin-version-check-2.1.0.tgz#e4e5df290b9069f7d111324031efc13fdd11a5b0" - integrity sha1-5OXfKQuQaffRETJAMe/BP90RpbA= - dependencies: - bin-version "^1.0.0" - minimist "^1.1.0" - semver "^4.0.3" - semver-truncate "^1.0.0" - -bin-version@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/bin-version/-/bin-version-1.0.4.tgz#9eb498ee6fd76f7ab9a7c160436f89579435d78e" - integrity sha1-nrSY7m/Xb3q5p8FgQ2+JV5Q1144= - dependencies: - find-versions "^1.0.0" - -bin-wrapper@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/bin-wrapper/-/bin-wrapper-3.0.2.tgz#67d3306262e4b1a5f2f88ee23464f6a655677aeb" - integrity sha1-Z9MwYmLksaXy+I7iNGT2plVneus= - dependencies: - bin-check "^2.0.0" - bin-version-check "^2.1.0" - download "^4.0.0" - each-async "^1.1.1" - lazy-req "^1.0.0" - os-filter-obj "^1.0.0" + resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.0.0.tgz#23c0df14f6a88077f5f986c0d167ec03c3d5537c" + integrity sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow== bl@^1.0.0: version "1.2.2" @@ -1005,21 +1043,21 @@ bl@^1.0.0: readable-stream "^2.3.5" safe-buffer "^5.1.1" -body-parser@1.18.3: - version "1.18.3" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.18.3.tgz#5b292198ffdd553b3a0f20ded0592b956955c8b4" - integrity sha1-WykhmP/dVTs6DyDe0FkrlWlVyLQ= +body-parser@1.19.0: + version "1.19.0" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.0.tgz#96b2709e57c9c4e09a6fd66a8fd979844f69f08a" + integrity sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw== dependencies: - bytes "3.0.0" + bytes "3.1.0" content-type "~1.0.4" debug "2.6.9" depd "~1.1.2" - http-errors "~1.6.3" - iconv-lite "0.4.23" + http-errors "1.7.2" + iconv-lite "0.4.24" on-finished "~2.3.0" - qs "6.5.2" - raw-body "2.3.3" - type-is "~1.6.16" + qs "6.7.0" + raw-body "2.4.0" + type-is "~1.6.17" body@^5.1.0: version "5.1.0" @@ -1044,24 +1082,39 @@ brace-expansion@^1.0.0, brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" -braces@^1.8.2: - version "1.8.5" - resolved "https://registry.yarnpkg.com/braces/-/braces-1.8.5.tgz#ba77962e12dff969d6b76711e914b737857bf6a7" - integrity sha1-uneWLhLf+WnWt2cR6RS3N4V79qc= +braces@^2.3.1: + version "2.3.2" + resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" + integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== dependencies: - expand-range "^1.8.1" - preserve "^0.2.0" + arr-flatten "^1.1.0" + array-unique "^0.3.2" + extend-shallow "^2.0.1" + fill-range "^4.0.0" + isobject "^3.0.1" repeat-element "^1.1.2" + snapdragon "^0.8.1" + snapdragon-node "^2.0.1" + split-string "^3.0.2" + to-regex "^3.0.1" -browserslist@^1.3.6, browserslist@^1.5.2, browserslist@^1.7.6: - version "1.7.7" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-1.7.7.tgz#0bd76704258be829b2398bb50e4b62d1a166b0b9" - integrity sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk= +braces@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== dependencies: - caniuse-db "^1.0.30000639" - electron-to-chromium "^1.2.7" + fill-range "^7.0.1" -browserslist@^4.3.4, browserslist@^4.3.6: +browserslist@^4.0.0, browserslist@^4.6.3: + version "4.6.4" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.4.tgz#fd0638b3f8867fec2c604ed0ed9300379f8ec7c2" + integrity sha512-ErJT8qGfRt/VWHSr1HeqZzz50DvxHtr1fVL1m5wf20aGrG8e1ce8fpZ2EjZEfs09DDZYSvtRaDlMpWslBf8Low== + dependencies: + caniuse-lite "^1.0.30000981" + electron-to-chromium "^1.3.188" + node-releases "^1.1.25" + +browserslist@^4.3.4: version "4.3.6" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.3.6.tgz#0f9d9081afc66b36f477c6bdf3813f784f42396a" integrity sha512-kMGKs4BTzRWviZ8yru18xBpx+CyHG9eqgRbj9XbE3IMgtczf4aiA0Y1YCpVdvUieKGZ03kolSPXqTcscBCb9qw== @@ -1093,25 +1146,18 @@ buffer-fill@^1.0.0: resolved "https://registry.yarnpkg.com/buffer-fill/-/buffer-fill-1.0.0.tgz#f8f78b76789888ef39f205cd637f68e702122b2c" integrity sha1-+PeLdniYiO858gXNY39o5wISKyw= -buffer-from@^0.1.1: - version "0.1.2" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-0.1.2.tgz#15f4b9bcef012044df31142c14333caf6e0260d0" - integrity sha512-RiWIenusJsmI2KcvqQABB83tLxCByE3upSP8QU3rJDMVFGPWLvPQJt/O1Su9moRWeH7d+Q2HYb68f6+v+tw2vg== - buffer-from@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== -buffer-to-vinyl@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/buffer-to-vinyl/-/buffer-to-vinyl-1.1.0.tgz#00f15faee3ab7a1dda2cde6d9121bffdd07b2262" - integrity sha1-APFfruOreh3aLN5tkSG//dB7ImI= +buffer@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.2.1.tgz#dd57fa0f109ac59c602479044dca7b8b3d0b71d6" + integrity sha512-c+Ko0loDaFfuPWiL02ls9Xd3GO3cPVmUobQ6t3rXNUk304u6hGq+8N/kFi+QEIKhzK3uwolVhLzszmfLmMLnqg== dependencies: - file-type "^3.1.0" - readable-stream "^2.0.2" - uuid "^2.0.1" - vinyl "^1.0.0" + base64-js "^1.0.2" + ieee754 "^1.1.4" builtin-modules@^1.0.0: version "1.1.1" @@ -1123,10 +1169,62 @@ bytes@1: resolved "https://registry.yarnpkg.com/bytes/-/bytes-1.0.0.tgz#3569ede8ba34315fab99c3e92cb04c7220de1fa8" integrity sha1-NWnt6Lo0MV+rmcPpLLBMciDeH6g= -bytes@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.0.0.tgz#d32815404d689699f85a4ea4fa8755dd13a96048" - integrity sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg= +bytes@3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.0.tgz#f6cf7933a360e0588fa9fde85651cdc7f805d1f6" + integrity sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg== + +cache-base@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" + integrity sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ== + dependencies: + collection-visit "^1.0.0" + component-emitter "^1.2.1" + get-value "^2.0.6" + has-value "^1.0.0" + isobject "^3.0.1" + set-value "^2.0.0" + to-object-path "^0.3.0" + union-value "^1.0.0" + unset-value "^1.0.0" + +cacheable-request@^2.1.1: + version "2.1.4" + resolved "https://registry.yarnpkg.com/cacheable-request/-/cacheable-request-2.1.4.tgz#0d808801b6342ad33c91df9d0b44dc09b91e5c3d" + integrity sha1-DYCIAbY0KtM8kd+dC0TcCbkeXD0= + dependencies: + clone-response "1.0.2" + get-stream "3.0.0" + http-cache-semantics "3.8.1" + keyv "3.0.0" + lowercase-keys "1.0.0" + normalize-url "2.0.1" + responselike "1.0.2" + +call-me-maybe@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/call-me-maybe/-/call-me-maybe-1.0.1.tgz#26d208ea89e37b5cbde60250a15f031c16a4d66b" + integrity sha1-JtII6onje1y95gJQoV8DHBak1ms= + +caller-callsite@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/caller-callsite/-/caller-callsite-2.0.0.tgz#847e0fce0a223750a9a027c54b33731ad3154134" + integrity sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ= + dependencies: + callsites "^2.0.0" + +caller-path@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-2.0.0.tgz#468f83044e369ab2010fac5f06ceee15bb2cb1f4" + integrity sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ= + dependencies: + caller-callsite "^2.0.0" + +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz#06eb84f00eea413da86affefacbffb36093b3c50" + integrity sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA= camelcase-keys@^2.0.0: version "2.1.0" @@ -1141,45 +1239,40 @@ camelcase@^2.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" integrity sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8= -caniuse-api@^1.5.2: - version "1.6.1" - resolved "https://registry.yarnpkg.com/caniuse-api/-/caniuse-api-1.6.1.tgz#b534e7c734c4f81ec5fbe8aca2ad24354b962c6c" - integrity sha1-tTTnxzTE+B7F++isoq0kNUuWLGw= +caniuse-api@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/caniuse-api/-/caniuse-api-3.0.0.tgz#5e4d90e2274961d46291997df599e3ed008ee4c0" + integrity sha512-bsTwuIg/BZZK/vreVTYYbSWoe2F+71P7K5QGEX+pT250DZbfU1MQ5prOKpPR+LL6uWKK3KMwMCAS74QB3Um1uw== dependencies: - browserslist "^1.3.6" - caniuse-db "^1.0.30000529" + browserslist "^4.0.0" + caniuse-lite "^1.0.0" lodash.memoize "^4.1.2" lodash.uniq "^4.5.0" -caniuse-db@^1.0.30000529, caniuse-db@^1.0.30000634, caniuse-db@^1.0.30000639: - version "1.0.30000923" - resolved "https://registry.yarnpkg.com/caniuse-db/-/caniuse-db-1.0.30000923.tgz#0724b5fbd7f9fe424060b788b11e6b8d77102deb" - integrity sha512-PlFnZSgXcf/Z1kuNhTRq9vV4FnzizSDHpcgs5b/EY9sN60F3aBpkJwvEsHNeACHZi56/L8Cm3VsONdY1bOus/g== +caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000980, caniuse-lite@^1.0.30000981: + version "1.0.30000983" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000983.tgz#ab3c70061ca2a3467182a10ac75109b199b647f8" + integrity sha512-/llD1bZ6qwNkt41AsvjsmwNOoA4ZB+8iqmf5LVyeSXuBODT/hAMFNVOh84NdUzoiYiSKqo5vQ3ZzeYHSi/olDQ== caniuse-lite@^1.0.30000921: version "1.0.30000923" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000923.tgz#148f9bda508024b5ce957b463ae2e8302b451bb2" integrity sha512-j5ur7eeluOFjjPUkydtXP4KFAsmH3XaQNch5tvWSO+dLHYt5PE+VgJZLWtbVOodfWij6m6zas28T4gB/cLYq1w== -capture-stack-trace@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/capture-stack-trace/-/capture-stack-trace-1.0.1.tgz#a6c0bbe1f38f3aa0b92238ecb6ff42c344d4135d" - integrity sha512-mYQLZnx5Qt1JgB1WEiMCf2647plpGeQ2NMR/5L0HNZzGQo4fuSPnK+wjfPnKZV0aiJDgzmWqqkV/g7JD+DW0qw== - caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= -caw@^1.0.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/caw/-/caw-1.2.0.tgz#ffb226fe7efc547288dc62ee3e97073c212d1034" - integrity sha1-/7Im/n78VHKI3GLuPpcHPCEtEDQ= +caw@^2.0.0, caw@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/caw/-/caw-2.0.1.tgz#6c3ca071fc194720883c2dc5da9b074bfc7e9e95" + integrity sha512-Cg8/ZSBEa8ZVY9HspcGUYaK63d/bN7rqS3CYCzEGUxuYv6UlmcjzDUz2fCFFHyTvUW5Pk0I+3hkA3iXlIj6guA== dependencies: - get-proxy "^1.0.1" - is-obj "^1.0.0" - object-assign "^3.0.0" - tunnel-agent "^0.4.0" + get-proxy "^2.0.0" + isurl "^1.0.0-alpha5" + tunnel-agent "^0.6.0" + url-to-options "^1.0.1" chalk@1.1.3, chalk@^1.0.0, chalk@^1.1.3: version "1.1.3" @@ -1192,7 +1285,7 @@ chalk@1.1.3, chalk@^1.0.0, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.0, chalk@^2.1.0, chalk@^2.4.1: +chalk@^2.0.0, chalk@^2.4.1: version "2.4.1" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" integrity sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ== @@ -1201,6 +1294,15 @@ chalk@^2.0.0, chalk@^2.1.0, chalk@^2.4.1: escape-string-regexp "^1.0.5" supports-color "^5.3.0" +chalk@^2.4.2: + version "2.4.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" @@ -1228,12 +1330,30 @@ cheerio@0.22.0: lodash.reject "^4.4.0" lodash.some "^4.4.0" -clap@^1.0.9: - version "1.2.3" - resolved "https://registry.yarnpkg.com/clap/-/clap-1.2.3.tgz#4f36745b32008492557f46412d66d50cb99bce51" - integrity sha512-4CoL/A3hf90V3VIEjeuhSvlGFEHKzOz+Wfc2IVZc+FaUgU0ZQafJTP49fvnULipOPcAfqhyI2duwQyns6xqjYA== +chokidar@^3.0.1: + version "3.0.2" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.0.2.tgz#0d1cd6d04eb2df0327446188cd13736a3367d681" + integrity sha512-c4PR2egjNjI1um6bamCQ6bUNPDiyofNQruHvKgHQ4gDUP/ITSVSzNsiI5OWtHOsX323i5ha/kk4YmOZ1Ktg7KA== dependencies: - chalk "^1.1.3" + anymatch "^3.0.1" + braces "^3.0.2" + glob-parent "^5.0.0" + is-binary-path "^2.1.0" + is-glob "^4.0.1" + normalize-path "^3.0.0" + readdirp "^3.1.1" + optionalDependencies: + fsevents "^2.0.6" + +class-utils@^0.3.5: + version "0.3.6" + resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" + integrity sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg== + dependencies: + arr-union "^3.1.0" + define-property "^0.2.5" + isobject "^3.0.0" + static-extend "^0.1.1" classnames@^2.2.6: version "2.2.6" @@ -1261,34 +1381,14 @@ clipboard@^2.0.0: select "^1.1.2" tiny-emitter "^2.0.0" -clone-stats@^0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" - integrity sha1-uI+UqCzzi4eR1YBG6kAprYjKmdE= - -clone@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/clone/-/clone-0.2.0.tgz#c6126a90ad4f72dbf5acdb243cc37724fe93fc1f" - integrity sha1-xhJqkK1Pctv1rNskPMN3JP6T/B8= - -clone@^1.0.0, clone@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" - integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= - -co@3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/co/-/co-3.1.0.tgz#4ea54ea5a08938153185e15210c68d9092bc1b78" - integrity sha1-TqVOpaCJOBUxheFSEMaNkJK8G3g= - -coa@~1.0.1: - version "1.0.4" - resolved "https://registry.yarnpkg.com/coa/-/coa-1.0.4.tgz#a9ef153660d6a86a8bdec0289a5c684d217432fd" - integrity sha1-qe8VNmDWqGqL3sAomlxoTSF0Mv0= +clone-response@1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/clone-response/-/clone-response-1.0.2.tgz#d1dc973920314df67fbeb94223b4ee350239e96b" + integrity sha1-0dyXOSAxTfZ/vrlCI7TuNQI56Ws= dependencies: - q "^1.1.2" + mimic-response "^1.0.0" -coa@~2.0.1: +coa@^2.0.2, coa@~2.0.1: version "2.0.2" resolved "https://registry.yarnpkg.com/coa/-/coa-2.0.2.tgz#43f6c21151b4ef2bf57187db0d73de229e3e7ec3" integrity sha512-q5/jG+YQnSy4nRTV4F7lPepBJZ8qBNJJDBuJdoejDyLXgmL7IEo+Le2JDZudFTFt7mrCqIRaSjws4ygRCTCAXA== @@ -1302,7 +1402,15 @@ coffee-script@^1.12.4: resolved "https://registry.yarnpkg.com/coffee-script/-/coffee-script-1.12.7.tgz#c05dae0cb79591d05b3070a8433a98c9a89ccc53" integrity sha512-fLeEhqwymYat/MpTPUjSKHVYYl0ec2mOyALEMLmzr5i1isuG+6jfI2j2d5oBO3VIzgUXgBVIcOT9uH1TFxBckw== -color-convert@^1.3.0, color-convert@^1.9.0, color-convert@^1.9.1: +collection-visit@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" + integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= + dependencies: + map-visit "^1.0.0" + object-visit "^1.0.0" + +color-convert@^1.9.0, color-convert@^1.9.1: version "1.9.3" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== @@ -1319,13 +1427,6 @@ color-name@^1.0.0: resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -color-string@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/color-string/-/color-string-0.3.0.tgz#27d46fb67025c5c2fa25993bfbf579e47841b991" - integrity sha1-J9RvtnAlxcL6JZk7+/V55HhBuZE= - dependencies: - color-name "^1.0.0" - color-string@^1.5.2: version "1.5.3" resolved "https://registry.yarnpkg.com/color-string/-/color-string-1.5.3.tgz#c9bbc5f01b58b5492f3d6857459cb6590ce204cc" @@ -1334,20 +1435,6 @@ color-string@^1.5.2: color-name "^1.0.0" simple-swizzle "^0.2.2" -color-support@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" - integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== - -color@^0.11.0: - version "0.11.4" - resolved "https://registry.yarnpkg.com/color/-/color-0.11.4.tgz#6d7b5c74fb65e841cd48792ad1ed5e07b904d764" - integrity sha1-bXtcdPtl6EHNSHkq0e1eB7kE12Q= - dependencies: - clone "^1.0.2" - color-convert "^1.3.0" - color-string "^0.3.0" - color@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/color/-/color-2.0.1.tgz#e4ed78a3c4603d0891eba5430b04b86314f4c839" @@ -1356,14 +1443,13 @@ color@^2.0.1: color-convert "^1.9.1" color-string "^1.5.2" -colormin@^1.0.5: - version "1.1.2" - resolved "https://registry.yarnpkg.com/colormin/-/colormin-1.1.2.tgz#ea2f7420a72b96881a38aae59ec124a6f7298133" - integrity sha1-6i90IKcrlogaOKrlnsEkpvcpgTM= +color@^3.0.0: + version "3.1.2" + resolved "https://registry.yarnpkg.com/color/-/color-3.1.2.tgz#68148e7f85d41ad7649c5fa8c8106f098d229e10" + integrity sha512-vXTJhHebByxZn3lDvDJYw4lR5+uB3vuoHsuYA5AKuxRVn5wzzIfQKGLBmgdVRHKTJYeK5rvJcHnrd0Li49CFpg== dependencies: - color "^0.11.0" - css-color-names "0.0.4" - has "^1.0.1" + color-convert "^1.9.1" + color-string "^1.5.2" colors@~1.1.2: version "1.1.2" @@ -1377,11 +1463,16 @@ combined-stream@^1.0.6, combined-stream@~1.0.6: dependencies: delayed-stream "~1.0.0" -commander@^2.15.1, commander@^2.18.0: +commander@^2.15.1: version "2.19.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.19.0.tgz#f6198aa84e5b83c46054b94ddedbfed5ee9ff12a" integrity sha512-6tvAOO+D6OENvRAh524Dh9jcfKTYDQAqvqezbCW82xj5X0pSrcpxtvRKHLG0yBY6SD7PSDrJaj+0AiOcKVd1Xg== +commander@^2.20.0: + version "2.20.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422" + integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== + commander@~2.8.1: version "2.8.1" resolved "https://registry.yarnpkg.com/commander/-/commander-2.8.1.tgz#06be367febfda0c330aa1e2a072d3dc9762425d4" @@ -1394,12 +1485,17 @@ commondir@^1.0.1: resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= +component-emitter@^1.2.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" + integrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg== + concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -concat-stream@^1.4.6, concat-stream@^1.4.7, concat-stream@^1.5.2: +concat-stream@^1.5.2: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== @@ -1409,15 +1505,25 @@ concat-stream@^1.4.6, concat-stream@^1.4.7, concat-stream@^1.5.2: readable-stream "^2.2.2" typedarray "^0.0.6" +config-chain@^1.1.11: + version "1.1.12" + resolved "https://registry.yarnpkg.com/config-chain/-/config-chain-1.1.12.tgz#0fde8d091200eb5e808caf25fe618c02f48e4efa" + integrity sha512-a1eOIcu8+7lUInge4Rpf/n4Krkf3Dd9lqhljRzII1/Zno/kRtUWnznPO3jOKBmTEktkt3fkxisUcivoj0ebzoA== + dependencies: + ini "^1.3.4" + proto-list "~1.2.1" + console-stream@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/console-stream/-/console-stream-0.1.1.tgz#a095fe07b20465955f2fafd28b5d72bccd949d44" integrity sha1-oJX+B7IEZZVfL6/Si11yvM2UnUQ= -content-disposition@0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.2.tgz#0cf68bb9ddf5f2be7961c3a85178cb85dba78cb4" - integrity sha1-DPaLud318r55YcOoUXjLhdunjLQ= +content-disposition@0.5.3, content-disposition@^0.5.2: + version "0.5.3" + resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.3.tgz#e130caf7e7279087c5616c2007d0485698984fbd" + integrity sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g== + dependencies: + safe-buffer "5.1.2" content-type@~1.0.4: version "1.0.4" @@ -1429,7 +1535,7 @@ continuable-cache@^0.3.1: resolved "https://registry.yarnpkg.com/continuable-cache/-/continuable-cache-0.3.1.tgz#bd727a7faed77e71ff3985ac93351a912733ad0f" integrity sha1-vXJ6f67XfnH/OYWskzUakSczrQ8= -convert-source-map@^1.1.0, convert-source-map@^1.1.1: +convert-source-map@^1.1.0: version "1.6.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== @@ -1441,10 +1547,15 @@ cookie-signature@1.0.6: resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw= -cookie@0.3.1: - version "0.3.1" - resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.3.1.tgz#e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb" - integrity sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s= +cookie@0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.0.tgz#beb437e7022b3b6d49019d088665303ebe9c14ba" + integrity sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg== + +copy-descriptor@^0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" + integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= core-js@^2.5.7: version "2.6.1" @@ -1456,12 +1567,15 @@ core-util-is@1.0.2, core-util-is@~1.0.0: resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -create-error-class@^3.0.1: - version "3.0.2" - resolved "https://registry.yarnpkg.com/create-error-class/-/create-error-class-3.0.2.tgz#06be7abef947a3f14a30fd610671d401bca8b7b6" - integrity sha1-Br56vvlHo/FKMP1hBnHUAbyot7Y= +cosmiconfig@^5.0.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-5.2.1.tgz#040f726809c591e77a17c0a3626ca45b4f168b1a" + integrity sha512-H65gsXo1SKjf8zmrJ67eJk8aIRKV5ff2D4uKZIBZShbhGSpEmsQOPW/SKMKYhSTrqR7ufy6RP69rPogdaPh/kA== dependencies: - capture-stack-trace "^1.0.0" + import-fresh "^2.0.0" + is-directory "^0.3.1" + js-yaml "^3.13.1" + parse-json "^4.0.0" cross-spawn@5.1.0, cross-spawn@^5.0.1: version "5.1.0" @@ -1472,7 +1586,7 @@ cross-spawn@5.1.0, cross-spawn@^5.0.1: shebang-command "^1.2.0" which "^1.2.9" -cross-spawn@^6.0.5: +cross-spawn@^6.0.0, cross-spawn@^6.0.5: version "6.0.5" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== @@ -1492,12 +1606,20 @@ crowdin-cli@^0.3.0: yamljs "^0.2.1" yargs "^2.3.0" -css-color-names@0.0.4: +css-color-names@0.0.4, css-color-names@^0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/css-color-names/-/css-color-names-0.0.4.tgz#808adc2e79cf84738069b646cb20ec27beb629e0" integrity sha1-gIrcLnnPhHOAabZGyyDsJ762KeA= -css-select-base-adapter@~0.1.0: +css-declaration-sorter@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/css-declaration-sorter/-/css-declaration-sorter-4.0.1.tgz#c198940f63a76d7e36c1e71018b001721054cb22" + integrity sha512-BcxQSKTSEEQUftYpBVnsH4SF05NTuBokb19/sBt6asXGKZ/6VP7PLG1CBCkFDYOnhXhPh0jMhO6xZ71oYHXHBA== + dependencies: + postcss "^7.0.1" + timsort "^0.3.0" + +css-select-base-adapter@^0.1.1, css-select-base-adapter@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/css-select-base-adapter/-/css-select-base-adapter-0.1.1.tgz#3b2ff4972cc362ab88561507a95408a1432135d7" integrity sha512-jQVeeRG70QI08vSTwf1jHxp74JoZsr2XSgETae8/xC8ovSnL2WF87GTLO86Sbwdt2lK4Umg4HnnwMO4YF3Ce7w== @@ -1538,6 +1660,11 @@ css-tree@1.0.0-alpha.29: mdn-data "~1.1.0" source-map "^0.5.3" +css-unit-converter@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/css-unit-converter/-/css-unit-converter-1.1.1.tgz#d9b9281adcfd8ced935bdbaba83786897f64e996" + integrity sha1-2bkoGtz9jO2TW9urqDeGiX9k6ZY= + css-url-regex@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/css-url-regex/-/css-url-regex-1.1.0.tgz#83834230cc9f74c457de59eebd1543feeb83b7ec" @@ -1548,59 +1675,86 @@ css-what@2.1, css-what@^2.1.2: resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.2.tgz#c0876d9d0480927d7d4920dcd72af3595649554d" integrity sha512-wan8dMWQ0GUeF7DGEPVjhHemVW/vy6xUYmFzRY8RYqgA0JtXC9rJmbScBjqSu6dg9q0lwPQy6ZAmJVr3PPTvqQ== -cssnano@^3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-3.10.0.tgz#4f38f6cea2b9b17fa01490f23f1dc68ea65c1c38" - integrity sha1-Tzj2zqK5sX+gFJDyPx3GjqZcHDg= - dependencies: - autoprefixer "^6.3.1" - decamelize "^1.1.2" - defined "^1.0.0" - has "^1.0.1" - object-assign "^4.0.1" - postcss "^5.0.14" - postcss-calc "^5.2.0" - postcss-colormin "^2.1.8" - postcss-convert-values "^2.3.4" - postcss-discard-comments "^2.0.4" - postcss-discard-duplicates "^2.0.1" - postcss-discard-empty "^2.0.1" - postcss-discard-overridden "^0.1.1" - postcss-discard-unused "^2.2.1" - postcss-filter-plugins "^2.0.0" - postcss-merge-idents "^2.1.5" - postcss-merge-longhand "^2.0.1" - postcss-merge-rules "^2.0.3" - postcss-minify-font-values "^1.0.2" - postcss-minify-gradients "^1.0.1" - postcss-minify-params "^1.0.4" - postcss-minify-selectors "^2.0.4" - postcss-normalize-charset "^1.1.0" - postcss-normalize-url "^3.0.7" - postcss-ordered-values "^2.1.0" - postcss-reduce-idents "^2.2.2" - postcss-reduce-initial "^1.0.0" - postcss-reduce-transforms "^1.0.3" - postcss-svgo "^2.1.1" - postcss-unique-selectors "^2.0.2" - postcss-value-parser "^3.2.3" - postcss-zindex "^2.0.1" +cssesc@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-2.0.0.tgz#3b13bd1bb1cb36e1bcb5a4dcd27f54c5dcb35703" + integrity sha512-MsCAG1z9lPdoO/IUMLSBWBSVxVtJ1395VGIQ+Fc2gNdkQ1hNDnQdw3YhA71WJCBW1vdwA0cAnk/DnW6bqoEUYg== -csso@^3.5.0: +cssnano-preset-default@^4.0.7: + version "4.0.7" + resolved "https://registry.yarnpkg.com/cssnano-preset-default/-/cssnano-preset-default-4.0.7.tgz#51ec662ccfca0f88b396dcd9679cdb931be17f76" + integrity sha512-x0YHHx2h6p0fCl1zY9L9roD7rnlltugGu7zXSKQx6k2rYw0Hi3IqxcoAGF7u9Q5w1nt7vK0ulxV8Lo+EvllGsA== + dependencies: + css-declaration-sorter "^4.0.1" + cssnano-util-raw-cache "^4.0.1" + postcss "^7.0.0" + postcss-calc "^7.0.1" + postcss-colormin "^4.0.3" + postcss-convert-values "^4.0.1" + postcss-discard-comments "^4.0.2" + postcss-discard-duplicates "^4.0.2" + postcss-discard-empty "^4.0.1" + postcss-discard-overridden "^4.0.1" + postcss-merge-longhand "^4.0.11" + postcss-merge-rules "^4.0.3" + postcss-minify-font-values "^4.0.2" + postcss-minify-gradients "^4.0.2" + postcss-minify-params "^4.0.2" + postcss-minify-selectors "^4.0.2" + postcss-normalize-charset "^4.0.1" + postcss-normalize-display-values "^4.0.2" + postcss-normalize-positions "^4.0.2" + postcss-normalize-repeat-style "^4.0.2" + postcss-normalize-string "^4.0.2" + postcss-normalize-timing-functions "^4.0.2" + postcss-normalize-unicode "^4.0.1" + postcss-normalize-url "^4.0.1" + postcss-normalize-whitespace "^4.0.2" + postcss-ordered-values "^4.1.2" + postcss-reduce-initial "^4.0.3" + postcss-reduce-transforms "^4.0.2" + postcss-svgo "^4.0.2" + postcss-unique-selectors "^4.0.1" + +cssnano-util-get-arguments@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/cssnano-util-get-arguments/-/cssnano-util-get-arguments-4.0.0.tgz#ed3a08299f21d75741b20f3b81f194ed49cc150f" + integrity sha1-7ToIKZ8h11dBsg87gfGU7UnMFQ8= + +cssnano-util-get-match@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/cssnano-util-get-match/-/cssnano-util-get-match-4.0.0.tgz#c0e4ca07f5386bb17ec5e52250b4f5961365156d" + integrity sha1-wOTKB/U4a7F+xeUiULT1lhNlFW0= + +cssnano-util-raw-cache@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/cssnano-util-raw-cache/-/cssnano-util-raw-cache-4.0.1.tgz#b26d5fd5f72a11dfe7a7846fb4c67260f96bf282" + integrity sha512-qLuYtWK2b2Dy55I8ZX3ky1Z16WYsx544Q0UWViebptpwn/xDBmog2TLg4f+DBMg1rJ6JDWtn96WHbOKDWt1WQA== + dependencies: + postcss "^7.0.0" + +cssnano-util-same-parent@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/cssnano-util-same-parent/-/cssnano-util-same-parent-4.0.1.tgz#574082fb2859d2db433855835d9a8456ea18bbf3" + integrity sha512-WcKx5OY+KoSIAxBW6UBBRay1U6vkYheCdjyVNDm85zt5K9mHoGOfsOsqIszfAqrQQFIIKgjh2+FDgIj/zsl21Q== + +cssnano@^4.1.0: + version "4.1.10" + resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-4.1.10.tgz#0ac41f0b13d13d465487e111b778d42da631b8b2" + integrity sha512-5wny+F6H4/8RgNlaqab4ktc3e0/blKutmq8yNlBFXA//nSFFAqAngjNVRzUvCgYROULmZZUoosL/KSoZo5aUaQ== + dependencies: + cosmiconfig "^5.0.0" + cssnano-preset-default "^4.0.7" + is-resolvable "^1.0.0" + postcss "^7.0.0" + +csso@^3.5.0, csso@^3.5.1: version "3.5.1" resolved "https://registry.yarnpkg.com/csso/-/csso-3.5.1.tgz#7b9eb8be61628973c1b261e169d2f024008e758b" integrity sha512-vrqULLffYU1Q2tLdJvaCYbONStnfkfimRxXNaGjxMldI0C7JPBC4rB1RyjhfdZ4m1frm8pM9uRPKH3d2knZ8gg== dependencies: css-tree "1.0.0-alpha.29" -csso@~2.3.1: - version "2.3.2" - resolved "https://registry.yarnpkg.com/csso/-/csso-2.3.2.tgz#ddd52c587033f49e94b71fc55569f252e8ff5f85" - integrity sha1-3dUsWHAz9J6Utx/FVWnyUuj/X4U= - dependencies: - clap "^1.0.9" - source-map "^0.5.3" - currently-unhandled@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" @@ -1615,17 +1769,12 @@ dashdash@^1.12.0: dependencies: assert-plus "^1.0.0" -dateformat@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" - integrity sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI= - debug@0.7.4: version "0.7.4" resolved "https://registry.yarnpkg.com/debug/-/debug-0.7.4.tgz#06e1ea8082c2cb14e39806e22e2f6f757f92af39" integrity sha1-BuHqgILCyxTjmAbiLi9vdX+Srzk= -debug@2.6.9, debug@^2.2.0, debug@^2.6.0, debug@^2.6.6: +debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.6: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== @@ -1651,97 +1800,104 @@ decamelize@^1.1.2: resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= -decompress-tar@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/decompress-tar/-/decompress-tar-3.1.0.tgz#217c789f9b94450efaadc5c5e537978fc333c466" - integrity sha1-IXx4n5uURQ76rcXF5TeXj8MzxGY= - dependencies: - is-tar "^1.0.0" - object-assign "^2.0.0" - strip-dirs "^1.0.0" - tar-stream "^1.1.1" - through2 "^0.6.1" - vinyl "^0.4.3" +decode-uri-component@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" + integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= -decompress-tarbz2@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/decompress-tarbz2/-/decompress-tarbz2-3.1.0.tgz#8b23935681355f9f189d87256a0f8bdd96d9666d" - integrity sha1-iyOTVoE1X58YnYclag+L3ZbZZm0= +decompress-response@^3.2.0, decompress-response@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/decompress-response/-/decompress-response-3.3.0.tgz#80a4dd323748384bfa248083622aedec982adff3" + integrity sha1-gKTdMjdIOEv6JICDYirt7Jgq3/M= dependencies: - is-bzip2 "^1.0.0" - object-assign "^2.0.0" - seek-bzip "^1.0.3" - strip-dirs "^1.0.0" - tar-stream "^1.1.1" - through2 "^0.6.1" - vinyl "^0.4.3" + mimic-response "^1.0.0" -decompress-targz@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/decompress-targz/-/decompress-targz-3.1.0.tgz#b2c13df98166268991b715d6447f642e9696f5a0" - integrity sha1-ssE9+YFmJomRtxXWRH9kLpaW9aA= +decompress-tar@^4.0.0, decompress-tar@^4.1.0, decompress-tar@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-tar/-/decompress-tar-4.1.1.tgz#718cbd3fcb16209716e70a26b84e7ba4592e5af1" + integrity sha512-JdJMaCrGpB5fESVyxwpCx4Jdj2AagLmv3y58Qy4GE6HMVjWz1FeVQk1Ct4Kye7PftcdOo/7U7UKzYBJgqnGeUQ== dependencies: - is-gzip "^1.0.0" - object-assign "^2.0.0" - strip-dirs "^1.0.0" - tar-stream "^1.1.1" - through2 "^0.6.1" - vinyl "^0.4.3" + file-type "^5.2.0" + is-stream "^1.1.0" + tar-stream "^1.5.2" -decompress-unzip@^3.0.0: - version "3.4.0" - resolved "https://registry.yarnpkg.com/decompress-unzip/-/decompress-unzip-3.4.0.tgz#61475b4152066bbe3fee12f9d629d15fe6478eeb" - integrity sha1-YUdbQVIGa74/7hL51inRX+ZHjus= +decompress-tarbz2@^4.0.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-tarbz2/-/decompress-tarbz2-4.1.1.tgz#3082a5b880ea4043816349f378b56c516be1a39b" + integrity sha512-s88xLzf1r81ICXLAVQVzaN6ZmX4A6U4z2nMbOwobxkLoIIfjVMBg7TeguTUXkKeXni795B6y5rnvDw7rxhAq9A== dependencies: - is-zip "^1.0.0" - read-all-stream "^3.0.0" - stat-mode "^0.2.0" - strip-dirs "^1.0.0" - through2 "^2.0.0" - vinyl "^1.0.0" - yauzl "^2.2.1" + decompress-tar "^4.1.0" + file-type "^6.1.0" + is-stream "^1.1.0" + seek-bzip "^1.0.5" + unbzip2-stream "^1.0.9" -decompress@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/decompress/-/decompress-3.0.0.tgz#af1dd50d06e3bfc432461d37de11b38c0d991bed" - integrity sha1-rx3VDQbjv8QyRh033hGzjA2ZG+0= +decompress-targz@^4.0.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/decompress-targz/-/decompress-targz-4.1.1.tgz#c09bc35c4d11f3de09f2d2da53e9de23e7ce1eee" + integrity sha512-4z81Znfr6chWnRDNfFNqLwPvm4db3WuZkqV+UgXQzSngG3CEKdBkw5jrv3axjjL96glyiiKjsxJG3X6WBZwX3w== dependencies: - buffer-to-vinyl "^1.0.0" - concat-stream "^1.4.6" - decompress-tar "^3.0.0" - decompress-tarbz2 "^3.0.0" - decompress-targz "^3.0.0" - decompress-unzip "^3.0.0" - stream-combiner2 "^1.1.1" - vinyl-assign "^1.0.1" - vinyl-fs "^2.2.0" + decompress-tar "^4.1.1" + file-type "^5.2.0" + is-stream "^1.1.0" -deep-extend@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" - integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== +decompress-unzip@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/decompress-unzip/-/decompress-unzip-4.0.1.tgz#deaaccdfd14aeaf85578f733ae8210f9b4848f69" + integrity sha1-3qrM39FK6vhVePczroIQ+bSEj2k= + dependencies: + file-type "^3.8.0" + get-stream "^2.2.0" + pify "^2.3.0" + yauzl "^2.4.2" + +decompress@^4.0.0, decompress@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/decompress/-/decompress-4.2.0.tgz#7aedd85427e5a92dacfe55674a7c505e96d01f9d" + integrity sha1-eu3YVCflqS2s/lVnSnxQXpbQH50= + dependencies: + decompress-tar "^4.0.0" + decompress-tarbz2 "^4.0.0" + decompress-targz "^4.0.0" + decompress-unzip "^4.0.1" + graceful-fs "^4.1.10" + make-dir "^1.0.0" + pify "^2.3.0" + strip-dirs "^2.0.0" deep-is@0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.2.tgz#9ced65ea0bc0b09f42a6d79c1b1903f9d913cc18" integrity sha1-nO1l6gvAsJ9CptecGxkD+dkTzBg= -deepmerge@^2.1.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-2.2.1.tgz#5d3ff22a01c00f645405a2fbc17d0778a1801170" - integrity sha512-R9hc1Xa/NOBi9WRVUWg19rl1UB7Tt4kuPd+thNJgFZoxXsTz7ncaPaeIm+40oSGuP33DfMb4sZt1QIGiJzC4EA== - -define-properties@^1.1.2: +define-properties@^1.1.2, define-properties@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== dependencies: object-keys "^1.0.12" -defined@^1.0.0: +define-property@^0.2.5: + version "0.2.5" + resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" + integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= + dependencies: + is-descriptor "^0.1.0" + +define-property@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.0.tgz#c98d9bcef75674188e110969151199e39b1fa693" - integrity sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM= + resolved "https://registry.yarnpkg.com/define-property/-/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" + integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= + dependencies: + is-descriptor "^1.0.0" + +define-property@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/define-property/-/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" + integrity sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ== + dependencies: + is-descriptor "^1.0.2" + isobject "^3.0.1" delayed-stream@~1.0.0: version "1.0.0" @@ -1776,10 +1932,18 @@ diacritics-map@^0.1.0: resolved "https://registry.yarnpkg.com/diacritics-map/-/diacritics-map-0.1.0.tgz#6dfc0ff9d01000a2edf2865371cac316e94977af" integrity sha1-bfwP+dAQAKLt8oZTccrDFulJd68= -docusaurus@^1.6.2: - version "1.6.2" - resolved "https://registry.yarnpkg.com/docusaurus/-/docusaurus-1.6.2.tgz#60d581955fb9f28afb6e9cdea17c5c0cbf1784ec" - integrity sha512-I7ku328iQ3BAvnxVzVef8LR+Ek4BEWvao0W3JjnGrz/ZS3p+mIV2A9rF3B3yxvkTW4gofRpH+A8fN/UKi2r+1w== +dir-glob@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-2.0.0.tgz#0b205d2b6aef98238ca286598a8204d29d0a0034" + integrity sha512-37qirFDz8cA5fimp9feo43fSuRo2gHwaIn6dXL8Ber1dGwUosDrGZeCCXq57WnIqE4aQ+u3eQZzsk1yOzhdwag== + dependencies: + arrify "^1.0.1" + path-type "^3.0.0" + +docusaurus@^1.11.1: + version "1.11.1" + resolved "https://registry.yarnpkg.com/docusaurus/-/docusaurus-1.11.1.tgz#786bae93946bc21ab7ef457c5672e2e2bd930b25" + integrity sha512-oIdftD4E8dnzXcNohTdE6MICsiJIR1pAmKa/sRHDiG3T3v8f2eiq9nt88CidSIPpyEw50TbCr3bOoExHS90UGg== dependencies: "@babel/core" "^7.0.0" "@babel/plugin-proposal-class-properties" "^7.0.0" @@ -1790,28 +1954,28 @@ docusaurus@^1.6.2: "@babel/register" "^7.0.0" "@babel/traverse" "^7.0.0" "@babel/types" "^7.1.2" - autoprefixer "^9.1.5" + autoprefixer "^9.6.0" babylon "^6.17.4" - chalk "^2.1.0" + chalk "^2.4.2" + chokidar "^3.0.1" classnames "^2.2.6" color "^2.0.1" - commander "^2.18.0" + commander "^2.20.0" cross-spawn "^6.0.5" crowdin-cli "^0.3.0" - cssnano "^3.10.0" - deepmerge "^2.1.1" + cssnano "^4.1.0" escape-string-regexp "^1.0.5" - express "^4.15.3" + express "^4.17.1" feed "^1.1.0" fs-extra "^5.0.0" gaze "^1.1.2" glob "^7.1.3" highlight.js "^9.12.0" - imagemin "^5.3.1" - imagemin-gifsicle "^5.2.0" - imagemin-jpegtran "^5.0.2" - imagemin-optipng "^5.2.1" - imagemin-svgo "^6.0.0" + imagemin "^6.0.0" + imagemin-gifsicle "^6.0.1" + imagemin-jpegtran "^6.0.0" + imagemin-optipng "^6.0.0" + imagemin-svgo "^7.0.0" lodash "^4.17.11" markdown-toc "^1.2.0" mkdirp "^0.5.1" @@ -1823,7 +1987,7 @@ docusaurus@^1.6.2: react-dom "^16.5.0" remarkable "^1.7.1" request "^2.87.0" - shelljs "^0.7.8" + shelljs "^0.8.3" sitemap "^1.13.0" tcp-port-used "^0.1.2" tiny-lr "^1.1.1" @@ -1871,64 +2035,58 @@ domutils@^1.5.1, domutils@^1.7.0: dom-serializer "0" domelementtype "1" -download@^4.0.0, download@^4.1.2: - version "4.4.3" - resolved "https://registry.yarnpkg.com/download/-/download-4.4.3.tgz#aa55fdad392d95d4b68e8c2be03e0c2aa21ba9ac" - integrity sha1-qlX9rTktldS2jowr4D4MKqIbqaw= +dot-prop@^4.1.1: + version "4.2.0" + resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-4.2.0.tgz#1f19e0c2e1aa0e32797c49799f2837ac6af69c57" + integrity sha512-tUMXrxlExSW6U2EXiiKGSBVdYgtV8qlHL+C10TsW4PURY/ic+eaysnSkwB4kA/mBlCyy/IKDJ+Lc3wbWeaXtuQ== dependencies: - caw "^1.0.1" - concat-stream "^1.4.7" - each-async "^1.0.0" - filenamify "^1.0.1" - got "^5.0.0" - gulp-decompress "^1.2.0" - gulp-rename "^1.2.0" - is-url "^1.2.0" - object-assign "^4.0.1" - read-all-stream "^3.0.0" - readable-stream "^2.0.2" - stream-combiner2 "^1.1.1" - vinyl "^1.0.0" - vinyl-fs "^2.2.0" - ware "^1.2.0" + is-obj "^1.0.0" -duplexer2@0.0.2: - version "0.0.2" - resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" - integrity sha1-xhTc9n4vsUmVqRcR5aYX6KYKMds= +download@^6.2.2: + version "6.2.5" + resolved "https://registry.yarnpkg.com/download/-/download-6.2.5.tgz#acd6a542e4cd0bb42ca70cfc98c9e43b07039714" + integrity sha512-DpO9K1sXAST8Cpzb7kmEhogJxymyVUd5qz/vCOSyvwtp2Klj2XcDt5YUuasgxka44SxF0q5RriKIwJmQHG2AuA== dependencies: - readable-stream "~1.1.9" + caw "^2.0.0" + content-disposition "^0.5.2" + decompress "^4.0.0" + ext-name "^5.0.0" + file-type "5.2.0" + filenamify "^2.0.0" + get-stream "^3.0.0" + got "^7.0.0" + make-dir "^1.0.0" + p-event "^1.0.0" + pify "^3.0.0" -duplexer2@^0.1.4, duplexer2@~0.1.0: +download@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/download/-/download-7.1.0.tgz#9059aa9d70b503ee76a132897be6dec8e5587233" + integrity sha512-xqnBTVd/E+GxJVrX5/eUJiLYjCGPwMpdL+jGhGU57BvtcA7wwhtHVbXBeUk51kOpW3S7Jn3BQbN9Q1R1Km2qDQ== + dependencies: + archive-type "^4.0.0" + caw "^2.0.1" + content-disposition "^0.5.2" + decompress "^4.2.0" + ext-name "^5.0.0" + file-type "^8.1.0" + filenamify "^2.0.0" + get-stream "^3.0.0" + got "^8.3.1" + make-dir "^1.2.0" + p-event "^2.1.0" + pify "^3.0.0" + +duplexer3@^0.1.4: version "0.1.4" - resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.1.4.tgz#8b12dab878c0d69e3e7891051662a32fc6bddcc1" - integrity sha1-ixLauHjA1p4+eJEFFmKjL8a93ME= - dependencies: - readable-stream "^2.0.2" + resolved "https://registry.yarnpkg.com/duplexer3/-/duplexer3-0.1.4.tgz#ee01dd1cac0ed3cbc7fdbea37dc0a8f1ce002ce2" + integrity sha1-7gHdHKwO08vH/b6jfcCo8c4ALOI= duplexer@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.1.tgz#ace6ff808c1ce66b57d1ebf97977acb02334cfc1" integrity sha1-rOb/gIwc5mtX0ev5eXessCM0z8E= -duplexify@^3.2.0: - version "3.6.1" - resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.6.1.tgz#b1a7a29c4abfd639585efaecce80d666b1e34125" - integrity sha512-vM58DwdnKmty+FSPzT14K9JXb90H+j5emaR4KYbr2KTIz00WHGbWOe5ghQTx233ZCLZtrGDALzKwcjEtSt35mA== - dependencies: - end-of-stream "^1.0.0" - inherits "^2.0.1" - readable-stream "^2.0.0" - stream-shift "^1.0.0" - -each-async@^1.0.0, each-async@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/each-async/-/each-async-1.1.1.tgz#dee5229bdf0ab6ba2012a395e1b869abf8813473" - integrity sha1-3uUim98KtrogEqOV4bhpq/iBNHM= - dependencies: - onetime "^1.0.0" - set-immediate-shim "^1.0.0" - ecc-jsbn@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" @@ -1942,7 +2100,12 @@ ee-first@1.1.1: resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= -electron-to-chromium@^1.2.7, electron-to-chromium@^1.3.92: +electron-to-chromium@^1.3.188: + version "1.3.190" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.190.tgz#5bf599519983bfffd9d4387817039a3ed7ca085f" + integrity sha512-cs9WnTnGBGnYYVFMCtLmr9jXNTOkdp95RLz5VhwzDn7dErg1Lnt9o4d01gEH69XlmRKWUr91Yu1hA+Hi8qW0PA== + +electron-to-chromium@^1.3.92: version "1.3.96" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.96.tgz#25770ec99b8b07706dedf3a5f43fa50cb54c4f9a" integrity sha512-ZUXBUyGLeoJxp4Nt6G/GjBRLnyz8IKQGexZ2ndWaoegThgMGFO1tdDYID5gBV32/1S83osjJHyfzvanE/8HY4Q== @@ -1952,7 +2115,7 @@ encodeurl@~1.0.2: resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" integrity sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k= -end-of-stream@^1.0.0: +end-of-stream@^1.0.0, end-of-stream@^1.1.0: version "1.4.1" resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== @@ -1964,7 +2127,7 @@ entities@^1.1.1, entities@~1.1.1: resolved "https://registry.yarnpkg.com/entities/-/entities-1.1.2.tgz#bdfa735299664dfafd34529ed4f8522a275fea56" integrity sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w== -error-ex@^1.2.0: +error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== @@ -1979,6 +2142,18 @@ error@^7.0.0: string-template "~0.2.1" xtend "~4.0.0" +es-abstract@^1.12.0: + version "1.13.0" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.13.0.tgz#ac86145fdd5099d8dd49558ccba2eaf9b88e24e9" + integrity sha512-vDZfg/ykNxQVwup/8E1BZhVzFfBxs9NqMzGcvIJrqg5k2/5Za2bWo40dK2J1pgLngZ7c+Shh8lwYtLGyrwPutg== + dependencies: + es-to-primitive "^1.2.0" + function-bind "^1.1.1" + has "^1.0.3" + is-callable "^1.1.4" + is-regex "^1.0.4" + object-keys "^1.0.12" + es-abstract@^1.5.1, es-abstract@^1.6.1: version "1.12.0" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.12.0.tgz#9dbbdd27c6856f0001421ca18782d786bf8a6165" @@ -1990,7 +2165,7 @@ es-abstract@^1.5.1, es-abstract@^1.6.1: is-callable "^1.1.3" is-regex "^1.0.4" -es-to-primitive@^1.1.1: +es-to-primitive@^1.1.1, es-to-primitive@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.0.tgz#edf72478033456e8dda8ef09e00ad9650707f377" integrity sha512-qZryBOJjV//LaxLTV6UC//WewneB3LcXOL9NP++ozKVXsIIIpm/2c13UDiD9Jp2eThsecw9m3jPqDwTyobcdbg== @@ -2009,11 +2184,6 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1 resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= -esprima@^2.6.0: - version "2.7.3" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" - integrity sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE= - esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" @@ -2047,14 +2217,6 @@ exec-buffer@^3.0.0: rimraf "^2.5.4" tempfile "^2.0.0" -exec-series@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/exec-series/-/exec-series-1.0.3.tgz#6d257a9beac482a872c7783bc8615839fc77143a" - integrity sha1-bSV6m+rEgqhyx3g7yGFYOfx3FDo= - dependencies: - async-each-series "^1.1.0" - object-assign "^4.1.0" - execa@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" @@ -2068,19 +2230,38 @@ execa@^0.7.0: signal-exit "^3.0.0" strip-eof "^1.0.0" -executable@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/executable/-/executable-1.1.0.tgz#877980e9112f3391066da37265de7ad8434ab4d9" - integrity sha1-h3mA6REvM5EGbaNyZd562ENKtNk= +execa@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8" + integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== dependencies: - meow "^3.1.0" + cross-spawn "^6.0.0" + get-stream "^4.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" -expand-brackets@^0.1.4: - version "0.1.5" - resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-0.1.5.tgz#df07284e342a807cd733ac5af72411e581d1177b" - integrity sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s= +executable@^4.1.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/executable/-/executable-4.1.1.tgz#41532bff361d3e57af4d763b70582db18f5d133c" + integrity sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg== dependencies: - is-posix-bracket "^0.1.0" + pify "^2.2.0" + +expand-brackets@^2.1.4: + version "2.1.4" + resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" + integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= + dependencies: + debug "^2.3.3" + define-property "^0.2.5" + extend-shallow "^2.0.1" + posix-character-classes "^0.1.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" expand-range@^1.8.1: version "1.8.2" @@ -2096,42 +2277,57 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2: dependencies: homedir-polyfill "^1.0.1" -express@^4.15.3: - version "4.16.4" - resolved "https://registry.yarnpkg.com/express/-/express-4.16.4.tgz#fddef61926109e24c515ea97fd2f1bdbf62df12e" - integrity sha512-j12Uuyb4FMrd/qQAm6uCHAkPtO8FDTRJZBDd5D2KOL2eLaz1yUNdUB/NOIyq0iU4q4cFarsUCrnFDPBcnksuOg== +express@^4.17.1: + version "4.17.1" + resolved "https://registry.yarnpkg.com/express/-/express-4.17.1.tgz#4491fc38605cf51f8629d39c2b5d026f98a4c134" + integrity sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g== dependencies: - accepts "~1.3.5" + accepts "~1.3.7" array-flatten "1.1.1" - body-parser "1.18.3" - content-disposition "0.5.2" + body-parser "1.19.0" + content-disposition "0.5.3" content-type "~1.0.4" - cookie "0.3.1" + cookie "0.4.0" cookie-signature "1.0.6" debug "2.6.9" depd "~1.1.2" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "1.1.1" + finalhandler "~1.1.2" fresh "0.5.2" merge-descriptors "1.0.1" methods "~1.1.2" on-finished "~2.3.0" - parseurl "~1.3.2" + parseurl "~1.3.3" path-to-regexp "0.1.7" - proxy-addr "~2.0.4" - qs "6.5.2" - range-parser "~1.2.0" + proxy-addr "~2.0.5" + qs "6.7.0" + range-parser "~1.2.1" safe-buffer "5.1.2" - send "0.16.2" - serve-static "1.13.2" - setprototypeof "1.1.0" - statuses "~1.4.0" - type-is "~1.6.16" + send "0.17.1" + serve-static "1.14.1" + setprototypeof "1.1.1" + statuses "~1.5.0" + type-is "~1.6.18" utils-merge "1.0.1" vary "~1.1.2" +ext-list@^2.0.0: + version "2.2.2" + resolved "https://registry.yarnpkg.com/ext-list/-/ext-list-2.2.2.tgz#0b98e64ed82f5acf0f2931babf69212ef52ddd37" + integrity sha512-u+SQgsubraE6zItfVA0tBuCBhfU9ogSRnsvygI7wht9TS510oLkBRXBsqopeUG/GBOIQyKZO9wjTqIu/sf5zFA== + dependencies: + mime-db "^1.28.0" + +ext-name@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/ext-name/-/ext-name-5.0.0.tgz#70781981d183ee15d13993c8822045c506c8f0a6" + integrity sha512-yblEwXAbGv1VQDmow7s38W77hzAgJAO50ztBLMcUyUBfxv1HC+LGwtiEN+Co6LtlqT/5uwVOxsD4TNIilWhwdQ== + dependencies: + ext-list "^2.0.0" + sort-keys-length "^1.0.0" + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -2139,7 +2335,15 @@ extend-shallow@^2.0.1: dependencies: is-extendable "^0.1.0" -extend@^3.0.0, extend@~3.0.2: +extend-shallow@^3.0.0, extend-shallow@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" + integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= + dependencies: + assign-symbols "^1.0.0" + is-extendable "^1.0.1" + +extend@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== @@ -2153,12 +2357,19 @@ external-editor@^2.0.4: iconv-lite "^0.4.17" tmp "^0.0.33" -extglob@^0.3.1: - version "0.3.2" - resolved "https://registry.yarnpkg.com/extglob/-/extglob-0.3.2.tgz#2e18ff3d2f49ab2765cec9023f011daa8d8349a1" - integrity sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE= +extglob@^2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" + integrity sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw== dependencies: - is-extglob "^1.0.0" + array-unique "^0.3.2" + define-property "^1.0.0" + expand-brackets "^2.1.4" + extend-shallow "^2.0.1" + fragment-cache "^0.2.1" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" extsprintf@1.3.0: version "1.3.0" @@ -2170,21 +2381,23 @@ extsprintf@^1.2.0: resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= -fancy-log@^1.1.0: - version "1.3.3" - resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" - integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== - dependencies: - ansi-gray "^0.1.1" - color-support "^1.1.3" - parse-node-version "^1.0.0" - time-stamp "^1.0.0" - fast-deep-equal@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= +fast-glob@^2.0.2: + version "2.2.7" + resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-2.2.7.tgz#6953857c3afa475fff92ee6015d52da70a4cd39d" + integrity sha512-g1KuQwHOZAmOZMuBtHdxDtju+T2RT8jgCC9aANsbpdiDDTSnjgfuVsIBNKbUeJI3oKMRExcfNDtJl4OhbffMsw== + dependencies: + "@mrmlnc/readdir-enhanced" "^2.2.1" + "@nodelib/fs.stat" "^1.1.2" + glob-parent "^3.1.0" + is-glob "^4.0.0" + merge2 "^1.2.3" + micromatch "^3.1.10" + fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" @@ -2233,32 +2446,47 @@ figures@^2.0.0: dependencies: escape-string-regexp "^1.0.5" -file-type@^3.1.0: +file-type@5.2.0, file-type@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-5.2.0.tgz#2ddbea7c73ffe36368dfae49dc338c058c2b8ad6" + integrity sha1-LdvqfHP/42No365J3DOMBYwritY= + +file-type@^10.4.0, file-type@^10.7.0: + version "10.11.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-10.11.0.tgz#2961d09e4675b9fb9a3ee6b69e9cd23f43fd1890" + integrity sha512-uzk64HRpUZyTGZtVuvrjP0FYxzQrBf4rojot6J65YMEbwBLB0CWm0CLojVpwpmFmxcE/lkvYICgfcGozbBq6rw== + +file-type@^3.8.0: version "3.9.0" resolved "https://registry.yarnpkg.com/file-type/-/file-type-3.9.0.tgz#257a078384d1db8087bc449d107d52a52672b9e9" integrity sha1-JXoHg4TR24CHvESdEH1SpSZyuek= -file-type@^4.1.0: +file-type@^4.2.0: version "4.4.0" resolved "https://registry.yarnpkg.com/file-type/-/file-type-4.4.0.tgz#1b600e5fca1fbdc6e80c0a70c71c8dba5f7906c5" integrity sha1-G2AOX8ofvcboDApwxxyNul95BsU= -filename-regex@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" - integrity sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY= +file-type@^6.1.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-6.2.0.tgz#e50cd75d356ffed4e306dc4f5bcf52a79903a919" + integrity sha512-YPcTBDV+2Tm0VqjybVd32MHdlEGAtuxS3VAYsumFokDSMG+ROT5wawGlnHDoz7bfMcMDt9hxuXvXwoKUx2fkOg== -filename-reserved-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/filename-reserved-regex/-/filename-reserved-regex-1.0.0.tgz#e61cf805f0de1c984567d0386dc5df50ee5af7e4" - integrity sha1-5hz4BfDeHJhFZ9A4bcXfUO5a9+Q= +file-type@^8.1.0: + version "8.1.0" + resolved "https://registry.yarnpkg.com/file-type/-/file-type-8.1.0.tgz#244f3b7ef641bbe0cca196c7276e4b332399f68c" + integrity sha512-qyQ0pzAy78gVoJsmYeNgl8uH8yKhr1lVhW7JbzJmnlRi0I4R2eEDEJZVKG8agpDnLpacwNbDhLNG/LMdxHD2YQ== -filenamify@^1.0.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/filenamify/-/filenamify-1.2.1.tgz#a9f2ffd11c503bed300015029272378f1f1365a5" - integrity sha1-qfL/0RxQO+0wABUCknI3jx8TZaU= +filename-reserved-regex@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/filename-reserved-regex/-/filename-reserved-regex-2.0.0.tgz#abf73dfab735d045440abfea2d91f389ebbfa229" + integrity sha1-q/c9+rc10EVECr/qLZHzieu/oik= + +filenamify@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/filenamify/-/filenamify-2.1.0.tgz#88faf495fb1b47abfd612300002a16228c677ee9" + integrity sha512-ICw7NTT6RsDp2rnYKVd8Fu4cr6ITzGy3+u4vUujPkabyaz+03F24NWEX7fs5fp+kBonlaqPH8fAO2NM+SXt/JA== dependencies: - filename-reserved-regex "^1.0.0" + filename-reserved-regex "^2.0.0" strip-outer "^1.0.0" trim-repeated "^1.0.0" @@ -2278,17 +2506,34 @@ fill-range@^2.1.0: repeat-element "^1.1.2" repeat-string "^1.5.2" -finalhandler@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.1.tgz#eebf4ed840079c83f4249038c9d703008301b105" - integrity sha512-Y1GUDo39ez4aHAw7MysnUD5JzYX+WaIj8I57kO3aEPT1fFRL4sr7mjei97FgnwhAyyzRYmQZaTHb2+9uZ1dPtg== +fill-range@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" + integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= + dependencies: + extend-shallow "^2.0.1" + is-number "^3.0.0" + repeat-string "^1.6.1" + to-regex-range "^2.1.0" + +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== + dependencies: + to-regex-range "^5.0.1" + +finalhandler@~1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" + integrity sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA== dependencies: debug "2.6.9" encodeurl "~1.0.2" escape-html "~1.0.3" on-finished "~2.3.0" - parseurl "~1.3.2" - statuses "~1.4.0" + parseurl "~1.3.3" + statuses "~1.5.0" unpipe "~1.0.0" find-cache-dir@^1.0.0: @@ -2315,38 +2560,19 @@ find-up@^2.1.0: dependencies: locate-path "^2.0.0" -find-versions@^1.0.0: - version "1.2.1" - resolved "https://registry.yarnpkg.com/find-versions/-/find-versions-1.2.1.tgz#cbde9f12e38575a0af1be1b9a2c5d5fd8f186b62" - integrity sha1-y96fEuOFdaCvG+G5osXV/Y8Ya2I= +find-versions@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/find-versions/-/find-versions-3.1.0.tgz#10161f29cf3eb4350dec10a29bdde75bff0df32d" + integrity sha512-NCTfNiVzeE/xL+roNDffGuRbrWI6atI18lTJ22vKp7rs2OhYzMK3W1dIdO2TUndH/QMcacM4d1uWwgcZcHK69Q== dependencies: - array-uniq "^1.0.0" - get-stdin "^4.0.1" - meow "^3.5.0" - semver-regex "^1.0.0" + array-uniq "^2.1.0" + semver-regex "^2.0.0" -first-chunk-stream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/first-chunk-stream/-/first-chunk-stream-1.0.0.tgz#59bfb50cd905f60d7c394cd3d9acaab4e6ad934e" - integrity sha1-Wb+1DNkF9g18OUzT2ayqtOatk04= - -flatten@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/flatten/-/flatten-1.0.2.tgz#dae46a9d78fbe25292258cc1e780a41d95c03782" - integrity sha1-2uRqnXj74lKSJYzB54CkHZXAN4I= - -for-in@^1.0.1, for-in@^1.0.2: +for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= -for-own@^0.1.4: - version "0.1.5" - resolved "https://registry.yarnpkg.com/for-own/-/for-own-0.1.5.tgz#5265c681a4f294dabbf17c9509b6763aa84510ce" - integrity sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4= - dependencies: - for-in "^1.0.1" - forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" @@ -2366,11 +2592,26 @@ forwarded@~0.1.2: resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.1.2.tgz#98c23dab1175657b8c0573e8ceccd91b0ff18c84" integrity sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ= +fragment-cache@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/fragment-cache/-/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" + integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= + dependencies: + map-cache "^0.2.2" + fresh@0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7" integrity sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac= +from2@^2.1.1: + version "2.3.0" + resolved "https://registry.yarnpkg.com/from2/-/from2-2.3.0.tgz#8bfb5502bde4a4d36cfdeea007fcca21d7e382af" + integrity sha1-i/tVAr3kpNNs/e6gB/zKIdfjgq8= + dependencies: + inherits "^2.0.1" + readable-stream "^2.0.0" + fs-constants@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs-constants/-/fs-constants-1.0.0.tgz#6be0de9be998ce16af8afc24497b9ee9b7ccd9ad" @@ -2390,6 +2631,11 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= +fsevents@^2.0.6: + version "2.0.7" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.0.7.tgz#382c9b443c6cbac4c57187cdda23aa3bf1ccfc2a" + integrity sha512-a7YT0SV3RB+DjYcppwVDLtn13UQnmg0SWZS7ezZD0UjnLwXmy8Zm21GMVGLaFGimIqcvyMQaOJBrop8MyOp1kQ== + function-bind@^1.1.0, function-bind@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" @@ -2402,23 +2648,43 @@ gaze@^1.1.2: dependencies: globule "^1.0.0" -get-proxy@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/get-proxy/-/get-proxy-1.1.0.tgz#894854491bc591b0f147d7ae570f5c678b7256eb" - integrity sha1-iUhUSRvFkbDxR9euVw9cZ4tyVus= +get-proxy@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/get-proxy/-/get-proxy-2.1.0.tgz#349f2b4d91d44c4d4d4e9cba2ad90143fac5ef93" + integrity sha512-zmZIaQTWnNQb4R4fJUEp/FC51eZsc6EkErspy3xtIYStaq8EB/hDIWipxsal+E8rz0qD7f2sL/NA9Xee4RInJw== dependencies: - rc "^1.1.2" + npm-conf "^1.1.0" get-stdin@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-4.0.1.tgz#b968c6b0a04384324902e8bf1a5df32579a450fe" integrity sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4= -get-stream@^3.0.0: +get-stream@3.0.0, get-stream@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" integrity sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ= +get-stream@^2.2.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-2.3.1.tgz#5f38f93f346009666ee0150a054167f91bdd95de" + integrity sha1-Xzj5PzRgCWZu4BUKBUFn+Rvdld4= + dependencies: + object-assign "^4.0.1" + pinkie-promise "^2.0.0" + +get-stream@^4.0.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-4.1.0.tgz#c1b255575f3dc21d59bfc79cd3d2b46b1c3a54b5" + integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== + dependencies: + pump "^3.0.0" + +get-value@^2.0.3, get-value@^2.0.6: + version "2.0.6" + resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" + integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= + getpass@^0.1.1: version "0.1.7" resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" @@ -2426,31 +2692,17 @@ getpass@^0.1.1: dependencies: assert-plus "^1.0.0" -gifsicle@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/gifsicle/-/gifsicle-3.0.4.tgz#f45cb5ed10165b665dc929e0e9328b6c821dfa3b" - integrity sha1-9Fy17RAWW2ZdySng6TKLbIId+js= +gifsicle@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/gifsicle/-/gifsicle-4.0.1.tgz#30e1e61e3ee4884ef702641b2e98a15c2127b2e2" + integrity sha512-A/kiCLfDdV+ERV/UB+2O41mifd+RxH8jlRG8DMxZO84Bma/Fw0htqZ+hY2iaalLRNyUu7tYZQslqUBJxBggxbg== dependencies: - bin-build "^2.0.0" - bin-wrapper "^3.0.0" + bin-build "^3.0.0" + bin-wrapper "^4.0.0" + execa "^1.0.0" logalot "^2.0.0" -glob-base@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/glob-base/-/glob-base-0.3.0.tgz#dbb164f6221b1c0b1ccf82aea328b497df0ea3c4" - integrity sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q= - dependencies: - glob-parent "^2.0.0" - is-glob "^2.0.0" - -glob-parent@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-2.0.0.tgz#81383d72db054fcccf5336daa902f182f6edbb28" - integrity sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg= - dependencies: - is-glob "^2.0.0" - -glob-parent@^3.0.0: +glob-parent@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= @@ -2458,32 +2710,19 @@ glob-parent@^3.0.0: is-glob "^3.1.0" path-dirname "^1.0.0" -glob-stream@^5.3.2: - version "5.3.5" - resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-5.3.5.tgz#a55665a9a8ccdc41915a87c701e32d4e016fad22" - integrity sha1-pVZlqajM3EGRWofHAeMtTgFvrSI= +glob-parent@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.0.0.tgz#1dc99f0f39b006d3e92c2c284068382f0c20e954" + integrity sha512-Z2RwiujPRGluePM6j699ktJYxmPpJKCfpGA13jz2hmFZC7gKetzrWvg5KN3+OsIFmydGyZ1AVwERCq1w/ZZwRg== dependencies: - extend "^3.0.0" - glob "^5.0.3" - glob-parent "^3.0.0" - micromatch "^2.3.7" - ordered-read-streams "^0.3.0" - through2 "^0.6.0" - to-absolute-glob "^0.1.1" - unique-stream "^2.0.2" + is-glob "^4.0.1" -glob@^5.0.3: - version "5.0.15" - resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" - integrity sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E= - dependencies: - inflight "^1.0.4" - inherits "2" - minimatch "2 || 3" - once "^1.3.0" - path-is-absolute "^1.0.0" +glob-to-regexp@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.3.0.tgz#8c5a1494d2066c570cc3bfe4496175acc4d502ab" + integrity sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs= -glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.1.3, glob@~7.1.1: +glob@^7.0.0, glob@^7.0.5, glob@^7.1.3, glob@~7.1.1: version "7.1.3" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" integrity sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ== @@ -2495,6 +2734,18 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.1.3, glob@~7.1.1: once "^1.3.0" path-is-absolute "^1.0.0" +glob@^7.1.2: + version "7.1.4" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + global-modules@1.0.0, global-modules@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea" @@ -2520,16 +2771,18 @@ globals@^11.1.0: resolved "https://registry.yarnpkg.com/globals/-/globals-11.9.0.tgz#bde236808e987f290768a93d065060d78e6ab249" integrity sha512-5cJVtyXWH8PiJPVLZzzoIizXx944O4OmRro5MWKx5fT4MgcN7OfaMutPeaTdJCCURwbWdhhcCWcKIffPnmTzBg== -globby@^6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/globby/-/globby-6.1.0.tgz#f5a6d70e8395e21c858fb0489d64df02424d506c" - integrity sha1-9abXDoOV4hyFj7BInWTfAkJNUGw= +globby@^8.0.1: + version "8.0.2" + resolved "https://registry.yarnpkg.com/globby/-/globby-8.0.2.tgz#5697619ccd95c5275dbb2d6faa42087c1a941d8d" + integrity sha512-yTzMmKygLp8RUpG1Ymu2VXPSJQZjNAZPD4ywgYEaG7e4tBJeUQBO8OpXrf1RCNcEs5alsoJYPAMiIHP0cmeC7w== dependencies: array-union "^1.0.1" - glob "^7.0.3" - object-assign "^4.0.1" - pify "^2.0.0" - pinkie-promise "^2.0.0" + dir-glob "2.0.0" + fast-glob "^2.0.2" + glob "^7.1.2" + ignore "^3.3.5" + pify "^3.0.0" + slash "^1.0.0" globule@^1.0.0: version "1.2.1" @@ -2540,13 +2793,6 @@ globule@^1.0.0: lodash "~4.17.10" minimatch "~3.0.2" -glogg@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.2.tgz#2d7dd702beda22eb3bffadf880696da6d846313f" - integrity sha512-5mwUoSuBk44Y4EshyiqcH95ZntbDdTQqA3QYSrxmzj28Ai0vXBGMH1ApSANH14j2sIRtqCEyg6PfsuP7ElOEDA== - dependencies: - sparkles "^1.0.0" - good-listener@^1.2.2: version "1.2.2" resolved "https://registry.yarnpkg.com/good-listener/-/good-listener-1.2.2.tgz#d53b30cdf9313dffb7dc9a0d477096aa6d145c50" @@ -2554,28 +2800,55 @@ good-listener@^1.2.2: dependencies: delegate "^3.1.2" -got@^5.0.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/got/-/got-5.7.1.tgz#5f81635a61e4a6589f180569ea4e381680a51f35" - integrity sha1-X4FjWmHkplifGAVp6k44FoClHzU= +got@^7.0.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/got/-/got-7.1.0.tgz#05450fd84094e6bbea56f451a43a9c289166385a" + integrity sha512-Y5WMo7xKKq1muPsxD+KmrR8DH5auG7fBdDVueZwETwV6VytKyU9OX/ddpq2/1hp1vIPvVb4T81dKQz3BivkNLw== dependencies: - create-error-class "^3.0.1" - duplexer2 "^0.1.4" - is-redirect "^1.0.0" + decompress-response "^3.2.0" + duplexer3 "^0.1.4" + get-stream "^3.0.0" + is-plain-obj "^1.1.0" is-retry-allowed "^1.0.0" is-stream "^1.0.0" + isurl "^1.0.0-alpha5" lowercase-keys "^1.0.0" - node-status-codes "^1.0.0" - object-assign "^4.0.1" - parse-json "^2.1.0" - pinkie-promise "^2.0.0" - read-all-stream "^3.0.0" - readable-stream "^2.0.5" - timed-out "^3.0.0" - unzip-response "^1.0.2" + p-cancelable "^0.3.0" + p-timeout "^1.1.1" + safe-buffer "^5.0.1" + timed-out "^4.0.0" url-parse-lax "^1.0.0" + url-to-options "^1.0.1" -graceful-fs@^4.0.0, graceful-fs@^4.1.2, graceful-fs@^4.1.6: +got@^8.3.1: + version "8.3.2" + resolved "https://registry.yarnpkg.com/got/-/got-8.3.2.tgz#1d23f64390e97f776cac52e5b936e5f514d2e937" + integrity sha512-qjUJ5U/hawxosMryILofZCkm3C84PLJS/0grRIpjAwu+Lkxxj5cxeCU25BG0/3mDSpXKTyZr8oh8wIgLaH0QCw== + dependencies: + "@sindresorhus/is" "^0.7.0" + cacheable-request "^2.1.1" + decompress-response "^3.3.0" + duplexer3 "^0.1.4" + get-stream "^3.0.0" + into-stream "^3.1.0" + is-retry-allowed "^1.1.0" + isurl "^1.0.0-alpha5" + lowercase-keys "^1.0.0" + mimic-response "^1.0.0" + p-cancelable "^0.4.0" + p-timeout "^2.0.1" + pify "^3.0.0" + safe-buffer "^5.1.1" + timed-out "^4.0.1" + url-parse-lax "^3.0.0" + url-to-options "^1.0.1" + +graceful-fs@^4.1.10: + version "4.2.0" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz#8d8fdc73977cb04104721cb53666c1ca64cd328b" + integrity sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg== + +graceful-fs@^4.1.2, graceful-fs@^4.1.6: version "4.1.15" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== @@ -2596,63 +2869,6 @@ gray-matter@^2.1.0: js-yaml "^3.8.1" toml "^2.3.2" -gulp-decompress@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/gulp-decompress/-/gulp-decompress-1.2.0.tgz#8eeb65a5e015f8ed8532cafe28454960626f0dc7" - integrity sha1-jutlpeAV+O2FMsr+KEVJYGJvDcc= - dependencies: - archive-type "^3.0.0" - decompress "^3.0.0" - gulp-util "^3.0.1" - readable-stream "^2.0.2" - -gulp-rename@^1.2.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/gulp-rename/-/gulp-rename-1.4.0.tgz#de1c718e7c4095ae861f7296ef4f3248648240bd" - integrity sha512-swzbIGb/arEoFK89tPY58vg3Ok1bw+d35PfUNwWqdo7KM4jkmuGA78JiDNqR+JeZFaeeHnRg9N7aihX3YPmsyg== - -gulp-sourcemaps@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/gulp-sourcemaps/-/gulp-sourcemaps-1.6.0.tgz#b86ff349d801ceb56e1d9e7dc7bbcb4b7dee600c" - integrity sha1-uG/zSdgBzrVuHZ59x7vLS33uYAw= - dependencies: - convert-source-map "^1.1.1" - graceful-fs "^4.1.2" - strip-bom "^2.0.0" - through2 "^2.0.0" - vinyl "^1.0.0" - -gulp-util@^3.0.1: - version "3.0.8" - resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" - integrity sha1-AFTh50RQLifATBh8PsxQXdVLu08= - dependencies: - array-differ "^1.0.0" - array-uniq "^1.0.2" - beeper "^1.0.0" - chalk "^1.0.0" - dateformat "^2.0.0" - fancy-log "^1.1.0" - gulplog "^1.0.0" - has-gulplog "^0.1.0" - lodash._reescape "^3.0.0" - lodash._reevaluate "^3.0.0" - lodash._reinterpolate "^3.0.0" - lodash.template "^3.0.0" - minimist "^1.1.0" - multipipe "^0.1.2" - object-assign "^3.0.0" - replace-ext "0.0.1" - through2 "^2.0.0" - vinyl "^0.5.0" - -gulplog@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/gulplog/-/gulplog-1.0.0.tgz#e28c4d45d05ecbbed818363ce8f9c5926229ffe5" - integrity sha1-4oxNRdBey77YGDY86PnFkmIp/+U= - dependencies: - glogg "^1.0.0" - gzip-size@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/gzip-size/-/gzip-size-3.0.0.tgz#546188e9bdc337f673772f81660464b389dce520" @@ -2680,35 +2896,71 @@ has-ansi@^2.0.0: dependencies: ansi-regex "^2.0.0" -has-flag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" - integrity sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo= - has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= -has-gulplog@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/has-gulplog/-/has-gulplog-0.1.0.tgz#6414c82913697da51590397dafb12f22967811ce" - integrity sha1-ZBTIKRNpfaUVkDl9r7EvIpZ4Ec4= - dependencies: - sparkles "^1.0.0" +has-symbol-support-x@^1.4.1: + version "1.4.2" + resolved "https://registry.yarnpkg.com/has-symbol-support-x/-/has-symbol-support-x-1.4.2.tgz#1409f98bc00247da45da67cee0a36f282ff26455" + integrity sha512-3ToOva++HaW+eCpgqZrCfN51IPB+7bJNVT6CUATzueB5Heb8o6Nam0V3HG5dlDvZU1Gn5QLcbahiKw/XVk5JJw== has-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" integrity sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q= -has@^1.0.1: +has-to-string-tag-x@^1.2.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/has-to-string-tag-x/-/has-to-string-tag-x-1.4.1.tgz#a045ab383d7b4b2012a00148ab0aa5f290044d4d" + integrity sha512-vdbKfmw+3LoOYVr+mtxHaX5a96+0f3DljYd8JOqvOLsf5mw2Otda2qCDT9qRqLAhrjyQ0h7ual5nOiASpsGNFw== + dependencies: + has-symbol-support-x "^1.4.1" + +has-value@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" + integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= + dependencies: + get-value "^2.0.3" + has-values "^0.1.4" + isobject "^2.0.0" + +has-value@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-value/-/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" + integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= + dependencies: + get-value "^2.0.6" + has-values "^1.0.0" + isobject "^3.0.0" + +has-values@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/has-values/-/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" + integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= + +has-values@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-values/-/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" + integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= + dependencies: + is-number "^3.0.0" + kind-of "^4.0.0" + +has@^1.0.0, has@^1.0.1, has@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== dependencies: function-bind "^1.1.1" +hex-color-regex@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/hex-color-regex/-/hex-color-regex-1.1.0.tgz#4c06fccb4602fe2602b3c93df82d7e7dbf1a8a8e" + integrity sha512-l9sfDFsuqtOqKDsQdqrMRk0U85RZc0RtOR9yPI7mRVOa4FsR/BVnZ0shmQRM96Ji99kYZP/7hn1cedc1+ApsTQ== + highlight.js@^9.12.0: version "9.13.1" resolved "https://registry.yarnpkg.com/highlight.js/-/highlight.js-9.13.1.tgz#054586d53a6863311168488a0f58d6c505ce641e" @@ -2731,6 +2983,16 @@ hosted-git-info@^2.1.4: resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" integrity sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w== +hsl-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/hsl-regex/-/hsl-regex-1.0.0.tgz#d49330c789ed819e276a4c0d272dffa30b18fe6e" + integrity sha1-1JMwx4ntgZ4nakwNJy3/owsY/m4= + +hsla-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/hsla-regex/-/hsla-regex-1.0.0.tgz#c1ce7a3168c8c6614033a4b5f7877f3b225f9c38" + integrity sha1-wc56MWjIxmFAM6S194d/OyJfnDg= + html-comment-regex@^1.1.0: version "1.1.2" resolved "https://registry.yarnpkg.com/html-comment-regex/-/html-comment-regex-1.1.2.tgz#97d4688aeb5c81886a364faa0cad1dda14d433a7" @@ -2748,15 +3010,32 @@ htmlparser2@^3.9.1: inherits "^2.0.1" readable-stream "^3.0.6" -http-errors@1.6.3, http-errors@~1.6.2, http-errors@~1.6.3: - version "1.6.3" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.6.3.tgz#8b55680bb4be283a0b5bf4ea2e38580be1d9320d" - integrity sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0= +http-cache-semantics@3.8.1: + version "3.8.1" + resolved "https://registry.yarnpkg.com/http-cache-semantics/-/http-cache-semantics-3.8.1.tgz#39b0e16add9b605bf0a9ef3d9daaf4843b4cacd2" + integrity sha512-5ai2iksyV8ZXmnZhHH4rWPoxxistEexSi5936zIQ1bnNTW5VnA85B6P/VpXiRM017IgRvb2kKo1a//y+0wSp3w== + +http-errors@1.7.2: + version "1.7.2" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.7.2.tgz#4f5029cf13239f31036e5b2e55292bcfbcc85c8f" + integrity sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg== dependencies: depd "~1.1.2" inherits "2.0.3" - setprototypeof "1.1.0" - statuses ">= 1.4.0 < 2" + setprototypeof "1.1.1" + statuses ">= 1.5.0 < 2" + toidentifier "1.0.0" + +http-errors@~1.7.2: + version "1.7.3" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.7.3.tgz#6c619e4f9c60308c38519498c14fbb10aacebb06" + integrity sha512-ZTTX0MWrsQ2ZAhA1cejAwDLycFsd7I7nVtnkT3Ol0aqodaKW+0CTZDQ1uBv5whptCnc8e8HeRRJxRs0kmm/Qfw== + dependencies: + depd "~1.1.2" + inherits "2.0.4" + setprototypeof "1.1.1" + statuses ">= 1.5.0 < 2" + toidentifier "1.0.0" http-parser-js@>=0.4.0: version "0.5.0" @@ -2772,68 +3051,83 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" -iconv-lite@0.4.23: - version "0.4.23" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.23.tgz#297871f63be507adcfbfca715d0cd0eed84e9a63" - integrity sha512-neyTUVFtahjf0mB3dZT77u+8O0QB89jFdnBkd5P1JgYPbPaia3gXXOVL2fq8VyU2gMMD7SaN7QukTB/pmXYvDA== - dependencies: - safer-buffer ">= 2.1.2 < 3" - -iconv-lite@^0.4.17: +iconv-lite@0.4.24, iconv-lite@^0.4.17: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== dependencies: safer-buffer ">= 2.1.2 < 3" -imagemin-gifsicle@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/imagemin-gifsicle/-/imagemin-gifsicle-5.2.0.tgz#3781524c457612ef04916af34241a2b42bfcb40a" - integrity sha512-K01m5QuPK+0en8oVhiOOAicF7KjrHlCZxS++mfLI2mV/Ksfq/Y9nCXCWDz6jRv13wwlqe5T7hXT+ji2DnLc2yQ== +ieee754@^1.1.4: + version "1.1.13" + resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.13.tgz#ec168558e95aa181fd87d37f55c32bbcb6708b84" + integrity sha512-4vf7I2LYV/HaWerSo3XmlMkp5eZ83i+/CDluXi/IGTs/O1sejBNhTtnxzmRZfvOUqj7lZjqHkeTvpgSFDlWZTg== + +ignore@^3.3.5: + version "3.3.10" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" + integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== + +imagemin-gifsicle@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/imagemin-gifsicle/-/imagemin-gifsicle-6.0.1.tgz#6abad4e95566d52e5a104aba1c24b4f3b48581b3" + integrity sha512-kuu47c6iKDQ6R9J10xCwL0lgs0+sMz3LRHqRcJ2CRBWdcNmo3T5hUaM8hSZfksptZXJLGKk8heSAvwtSdB1Fng== dependencies: exec-buffer "^3.0.0" - gifsicle "^3.0.0" - is-gif "^1.0.0" + gifsicle "^4.0.0" + is-gif "^3.0.0" -imagemin-jpegtran@^5.0.2: - version "5.0.2" - resolved "https://registry.yarnpkg.com/imagemin-jpegtran/-/imagemin-jpegtran-5.0.2.tgz#e6882263b8f7916fddb800640cf75d2e970d2ad6" - integrity sha1-5ogiY7j3kW/duABkDPddLpcNKtY= +imagemin-jpegtran@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/imagemin-jpegtran/-/imagemin-jpegtran-6.0.0.tgz#c8d3bcfb6ec9c561c20a987142854be70d90b04f" + integrity sha512-Ih+NgThzqYfEWv9t58EItncaaXIHR0u9RuhKa8CtVBlMBvY0dCIxgQJQCfwImA4AV1PMfmUKlkyIHJjb7V4z1g== dependencies: exec-buffer "^3.0.0" - is-jpg "^1.0.0" - jpegtran-bin "^3.0.0" + is-jpg "^2.0.0" + jpegtran-bin "^4.0.0" -imagemin-optipng@^5.2.1: - version "5.2.1" - resolved "https://registry.yarnpkg.com/imagemin-optipng/-/imagemin-optipng-5.2.1.tgz#d22da412c09f5ff00a4339960b98a88b1dbe8695" - integrity sha1-0i2kEsCfX/AKQzmWC5ioix2+hpU= +imagemin-optipng@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/imagemin-optipng/-/imagemin-optipng-6.0.0.tgz#a6bfc7b542fc08fc687e83dfb131249179a51a68" + integrity sha512-FoD2sMXvmoNm/zKPOWdhKpWdFdF9qiJmKC17MxZJPH42VMAp17/QENI/lIuP7LCUnLVAloO3AUoTSNzfhpyd8A== dependencies: exec-buffer "^3.0.0" is-png "^1.0.0" - optipng-bin "^3.0.0" + optipng-bin "^5.0.0" -imagemin-svgo@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/imagemin-svgo/-/imagemin-svgo-6.0.0.tgz#2dd8c82946be42a8e2cbcae3c5bf007bc2b8b9e8" - integrity sha512-xwjBZQKpbkklHtJYnCOwRJjTRJA/nR0hQzKMh+CUZRvm/L0QwKKPJQ9tkPWQHrg+cydPu2i1vLgHuy2E0hKEkg== +imagemin-svgo@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/imagemin-svgo/-/imagemin-svgo-7.0.0.tgz#a22d0a5917a0d0f37e436932c30f5e000fa91b1c" + integrity sha512-+iGJFaPIMx8TjFW6zN+EkOhlqcemdL7F3N3Y0wODvV2kCUBuUtZK7DRZc1+Zfu4U2W/lTMUyx2G8YMOrZntIWg== dependencies: - buffer-from "^0.1.1" - is-svg "^2.0.0" - svgo "^1.0.0" + is-svg "^3.0.0" + svgo "^1.0.5" -imagemin@^5.3.1: - version "5.3.1" - resolved "https://registry.yarnpkg.com/imagemin/-/imagemin-5.3.1.tgz#f19c2eee1e71ba6c6558c515f9fc96680189a6d4" - integrity sha1-8Zwu7h5xumxlWMUV+fyWaAGJptQ= +imagemin@^6.0.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/imagemin/-/imagemin-6.1.0.tgz#62508b465728fea36c03cdc07d915fe2d8cf9e13" + integrity sha512-8ryJBL1CN5uSHpiBMX0rJw79C9F9aJqMnjGnrd/1CafegpNuA81RBAAru/jQQEOWlOJJlpRnlcVFF6wq+Ist0A== dependencies: - file-type "^4.1.0" - globby "^6.1.0" + file-type "^10.7.0" + globby "^8.0.1" make-dir "^1.0.0" p-pipe "^1.1.0" - pify "^2.3.0" + pify "^4.0.1" replace-ext "^1.0.0" +import-fresh@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-2.0.0.tgz#d81355c15612d386c61f9ddd3922d4304822a546" + integrity sha1-2BNVwVYS04bGH53dOSLUMEgipUY= + dependencies: + caller-path "^2.0.0" + resolve-from "^3.0.0" + +import-lazy@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-3.1.0.tgz#891279202c8a2280fdbd6674dbd8da1a1dfc67cc" + integrity sha512-8/gvXvX2JMn0F+CDlSC4l6kOmVaLOO3XLkksI7CI3Ud95KDYJuYur2b9P/PUt/i/pDAMd/DulQsNbbbmRRsDIQ== + indent-string@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" @@ -2854,12 +3148,17 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= -ini@^1.3.4, ini@~1.3.0: +inherits@2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +ini@^1.3.4: version "1.3.5" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== @@ -2889,6 +3188,14 @@ interpret@^1.0.0: resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" integrity sha1-ftGxQQxqDg94z5XTuEQMY/eLhhQ= +into-stream@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/into-stream/-/into-stream-3.1.0.tgz#96fb0a936c12babd6ff1752a17d05616abd094c6" + integrity sha1-lvsKk2wSur1v8XUqF9BWFqvQlMY= + dependencies: + from2 "^2.1.1" + p-is-promise "^1.1.0" + invariant@^2.2.2: version "2.2.4" resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" @@ -2896,27 +3203,29 @@ invariant@^2.2.2: dependencies: loose-envify "^1.0.0" -ip-regex@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-1.0.3.tgz#dc589076f659f419c222039a33316f1c7387effd" - integrity sha1-3FiQdvZZ9BnCIgOaMzFvHHOH7/0= - -ipaddr.js@1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.8.0.tgz#eaa33d6ddd7ace8f7f6fe0c9ca0440e706738b1e" - integrity sha1-6qM9bd16zo9/b+DJygRA5wZzix4= +ipaddr.js@1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.9.0.tgz#37df74e430a0e47550fe54a2defe30d8acd95f65" + integrity sha512-M4Sjn6N/+O6/IXSJseKqHoFc+5FdGJ22sXqnjTpdZweHK64MzEPAyQZyEU3R/KRv2GLoa7nNtg/C2Ev6m7z+eA== is-absolute-url@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-absolute-url/-/is-absolute-url-2.1.0.tgz#50530dfb84fcc9aa7dbe7852e83a37b93b9f2aa6" integrity sha1-UFMN+4T8yap9vnhS6Do3uTufKqY= -is-absolute@^0.1.5: - version "0.1.7" - resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-0.1.7.tgz#847491119fccb5fb436217cc737f7faad50f603f" - integrity sha1-hHSREZ/MtftDYhfMc39/qtUPYD8= +is-accessor-descriptor@^0.1.6: + version "0.1.6" + resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" + integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= dependencies: - is-relative "^0.1.0" + kind-of "^3.0.2" + +is-accessor-descriptor@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" + integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== + dependencies: + kind-of "^6.0.0" is-arrayish@^0.2.1: version "0.2.1" @@ -2928,6 +3237,13 @@ is-arrayish@^0.3.1: resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.3.2.tgz#4574a2ae56f7ab206896fb431eaeed066fdf8f03" integrity sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ== +is-binary-path@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" + integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== + dependencies: + binary-extensions "^2.0.0" + is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" @@ -2940,32 +3256,64 @@ is-builtin-module@^1.0.0: dependencies: builtin-modules "^1.0.0" -is-bzip2@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-bzip2/-/is-bzip2-1.0.0.tgz#5ee58eaa5a2e9c80e21407bedf23ae5ac091b3fc" - integrity sha1-XuWOqlounIDiFAe+3yOuWsCRs/w= - is-callable@^1.1.3, is-callable@^1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" integrity sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA== +is-color-stop@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-color-stop/-/is-color-stop-1.1.0.tgz#cfff471aee4dd5c9e158598fbe12967b5cdad345" + integrity sha1-z/9HGu5N1cnhWFmPvhKWe1za00U= + dependencies: + css-color-names "^0.0.4" + hex-color-regex "^1.1.0" + hsl-regex "^1.0.0" + hsla-regex "^1.0.0" + rgb-regex "^1.0.1" + rgba-regex "^1.0.0" + +is-data-descriptor@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" + integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= + dependencies: + kind-of "^3.0.2" + +is-data-descriptor@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" + integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== + dependencies: + kind-of "^6.0.0" + is-date-object@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" integrity sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY= -is-dotfile@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/is-dotfile/-/is-dotfile-1.0.3.tgz#a6a2f32ffd2dfb04f5ca25ecd0f6b83cf798a1e1" - integrity sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE= - -is-equal-shallow@^0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/is-equal-shallow/-/is-equal-shallow-0.1.3.tgz#2238098fc221de0bcfa5d9eac4c45d638aa1c534" - integrity sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ= +is-descriptor@^0.1.0: + version "0.1.6" + resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" + integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== dependencies: - is-primitive "^2.0.0" + is-accessor-descriptor "^0.1.6" + is-data-descriptor "^0.1.4" + kind-of "^5.0.0" + +is-descriptor@^1.0.0, is-descriptor@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" + integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== + dependencies: + is-accessor-descriptor "^1.0.0" + is-data-descriptor "^1.0.0" + kind-of "^6.0.2" + +is-directory@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/is-directory/-/is-directory-0.3.1.tgz#61339b6f2475fc772fd9c9d83f5c8575dc154ae1" + integrity sha1-YTObbyR1/Hcv2cnYP1yFddwVSuE= is-extendable@^0.1.0, is-extendable@^0.1.1: version "0.1.1" @@ -2979,12 +3327,7 @@ is-extendable@^1.0.1: dependencies: is-plain-object "^2.0.4" -is-extglob@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-1.0.0.tgz#ac468177c4943405a092fc8f29760c6ffc6206c0" - integrity sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA= - -is-extglob@^2.1.0: +is-extglob@^2.1.0, is-extglob@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= @@ -3001,17 +3344,12 @@ is-fullwidth-code-point@^2.0.0: resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= -is-gif@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-gif/-/is-gif-1.0.0.tgz#a6d2ae98893007bffa97a1d8c01d63205832097e" - integrity sha1-ptKumIkwB7/6l6HYwB1jIFgyCX4= - -is-glob@^2.0.0, is-glob@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-2.0.1.tgz#d096f926a3ded5600f3fdfd91198cb0888c2d863" - integrity sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM= +is-gif@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-gif/-/is-gif-3.0.0.tgz#c4be60b26a301d695bb833b20d9b5d66c6cf83b1" + integrity sha512-IqJ/jlbw5WJSNfwQ/lHEDXF8rxhRgF6ythk2oiEvhpG29F704eX9NO6TvPfMiq9DrbwgcEDnETYNcZDPewQoVw== dependencies: - is-extglob "^1.0.0" + file-type "^10.4.0" is-glob@^3.1.0: version "3.1.0" @@ -3020,20 +3358,22 @@ is-glob@^3.1.0: dependencies: is-extglob "^2.1.0" -is-gzip@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-gzip/-/is-gzip-1.0.0.tgz#6ca8b07b99c77998025900e555ced8ed80879a83" - integrity sha1-bKiwe5nHeZgCWQDlVc7Y7YCHmoM= +is-glob@^4.0.0, is-glob@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" + integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== + dependencies: + is-extglob "^2.1.1" -is-jpg@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-jpg/-/is-jpg-1.0.1.tgz#296d57fdd99ce010434a7283e346ab9a1035e975" - integrity sha1-KW1X/dmc4BBDSnKD40armhA16XU= +is-jpg@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-jpg/-/is-jpg-2.0.0.tgz#2e1997fa6e9166eaac0242daae443403e4ef1d97" + integrity sha1-LhmX+m6RZuqsAkLarkQ0A+TvHZc= -is-natural-number@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/is-natural-number/-/is-natural-number-2.1.1.tgz#7d4c5728377ef386c3e194a9911bf57c6dc335e7" - integrity sha1-fUxXKDd+84bD4ZSpkRv1fG3DNec= +is-natural-number@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/is-natural-number/-/is-natural-number-4.0.1.tgz#ab9d76e1db4ced51e35de0c72ebecf09f734cde8" + integrity sha1-q5124dtM7VHjXeDHLr7PCfc0zeg= is-number@^2.1.0: version "2.1.0" @@ -3042,22 +3382,39 @@ is-number@^2.1.0: dependencies: kind-of "^3.0.2" +is-number@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" + integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= + dependencies: + kind-of "^3.0.2" + is-number@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" integrity sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ== +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== + is-obj@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-1.0.1.tgz#3e4729ac1f5fde025cd7d83a896dab9f4f67db0f" integrity sha1-PkcprB9f3gJc19g6iW2rn09n2w8= -is-plain-obj@^1.0.0: +is-object@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-object/-/is-object-1.0.1.tgz#8952688c5ec2ffd6b03ecc85e769e02903083470" + integrity sha1-iVJojF7C/9awPsyF52ngKQMINHA= + +is-plain-obj@^1.0.0, is-plain-obj@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" integrity sha1-caUMhCnfync8kqOQpKA7OfzVHT4= -is-plain-object@^2.0.4: +is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" integrity sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og== @@ -3069,26 +3426,11 @@ is-png@^1.0.0: resolved "https://registry.yarnpkg.com/is-png/-/is-png-1.1.0.tgz#d574b12bf275c0350455570b0e5b57ab062077ce" integrity sha1-1XSxK/J1wDUEVVcLDltXqwYgd84= -is-posix-bracket@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz#3334dc79774368e92f016e6fbc0a88f5cd6e6bc4" - integrity sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q= - -is-primitive@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-primitive/-/is-primitive-2.0.0.tgz#207bab91638499c07b2adf240a41a87210034575" - integrity sha1-IHurkWOEmcB7Kt8kCkGochADRXU= - is-promise@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= -is-redirect@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24" - integrity sha1-HQPd7VO9jbDzDCbk+V02/HyH3CQ= - is-regex@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.4.tgz#5517489b547091b0930e095654ced25ee97e9491" @@ -3096,12 +3438,12 @@ is-regex@^1.0.4: dependencies: has "^1.0.1" -is-relative@^0.1.0: - version "0.1.3" - resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-0.1.3.tgz#905fee8ae86f45b3ec614bc3c15c869df0876e82" - integrity sha1-kF/uiuhvRbPsYUvDwVyGnfCHboI= +is-resolvable@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" + integrity sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg== -is-retry-allowed@^1.0.0: +is-retry-allowed@^1.0.0, is-retry-allowed@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-retry-allowed/-/is-retry-allowed-1.1.0.tgz#11a060568b67339444033d0125a61a20d564fb34" integrity sha1-EaBgVotnM5REAz0BJaYaINVk+zQ= @@ -3111,15 +3453,15 @@ is-root@1.0.0: resolved "https://registry.yarnpkg.com/is-root/-/is-root-1.0.0.tgz#07b6c233bc394cd9d02ba15c966bd6660d6342d5" integrity sha1-B7bCM7w5TNnQK6FclmvWZg1jQtU= -is-stream@^1.0.0, is-stream@^1.0.1, is-stream@^1.1.0: +is-stream@^1.0.0, is-stream@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= -is-svg@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-svg/-/is-svg-2.1.0.tgz#cf61090da0d9efbcab8722deba6f032208dbb0e9" - integrity sha1-z2EJDaDZ77yrhyLeum8DIgjbsOk= +is-svg@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-svg/-/is-svg-3.0.0.tgz#9321dbd29c212e5ca99c4fa9794c714bcafa2f75" + integrity sha512-gi4iHK53LR2ujhLVVj+37Ykh9GLqYHX6JOVXbLAucaG/Cqw9xwdFOjDM2qeifLs1sF1npXXFvDu0r5HNgCMrzQ== dependencies: html-comment-regex "^1.1.0" @@ -3130,32 +3472,17 @@ is-symbol@^1.0.2: dependencies: has-symbols "^1.0.0" -is-tar@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-tar/-/is-tar-1.0.0.tgz#2f6b2e1792c1f5bb36519acaa9d65c0d26fe853d" - integrity sha1-L2suF5LB9bs2UZrKqdZcDSb+hT0= - is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= -is-url@^1.2.0: - version "1.2.4" - resolved "https://registry.yarnpkg.com/is-url/-/is-url-1.2.4.tgz#04a4df46d28c4cff3d73d01ff06abeb318a1aa52" - integrity sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww== - is-utf8@^0.2.0: version "0.2.1" resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= -is-valid-glob@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/is-valid-glob/-/is-valid-glob-0.3.0.tgz#d4b55c69f51886f9b65c70d6c2622d37e29f48fe" - integrity sha1-1LVcafUYhvm2XHDWwmItN+KfSP4= - -is-windows@^1.0.1: +is-windows@^1.0.1, is-windows@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== @@ -3165,11 +3492,6 @@ is-wsl@^1.1.0: resolved "https://registry.yarnpkg.com/is-wsl/-/is-wsl-1.1.0.tgz#1f16e4aa22b04d1336b66188a66af3c600c3a66d" integrity sha1-HxbkqiKwTRM2tmGIpmrzxgDDpm0= -is-zip@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-zip/-/is-zip-1.0.0.tgz#47b0a8ff4d38a76431ccfd99a8e15a4c86ba2325" - integrity sha1-R7Co/004p2QxzP2ZqOFaTIa6IyU= - is2@0.0.9: version "0.0.9" resolved "https://registry.yarnpkg.com/is2/-/is2-0.0.9.tgz#119556d1d1651a41ba105af803267c80b299f629" @@ -3177,11 +3499,6 @@ is2@0.0.9: dependencies: deep-is "0.1.2" -isarray@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" - integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= - isarray@1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" @@ -3199,7 +3516,7 @@ isobject@^2.0.0: dependencies: isarray "1.0.0" -isobject@^3.0.1: +isobject@^3.0.0, isobject@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= @@ -3209,19 +3526,22 @@ isstream@~0.1.2: resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= -jpegtran-bin@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/jpegtran-bin/-/jpegtran-bin-3.2.0.tgz#f60ecf4ae999c0bdad2e9fbcdf2b6f0981e7a29b" - integrity sha1-9g7PSumZwL2tLp+83ytvCYHnops= +isurl@^1.0.0-alpha5: + version "1.0.0" + resolved "https://registry.yarnpkg.com/isurl/-/isurl-1.0.0.tgz#b27f4f49f3cdaa3ea44a0a5b7f3462e6edc39d67" + integrity sha512-1P/yWsxPlDtn7QeRD+ULKQPaIaN6yF368GZ2vDfv0AL0NwpStafjWCDDdn0k8wgFMWpVAqG7oJhxHnlud42i9w== dependencies: - bin-build "^2.0.0" - bin-wrapper "^3.0.0" - logalot "^2.0.0" + has-to-string-tag-x "^1.2.0" + is-object "^1.0.1" -js-base64@^2.1.9: - version "2.5.0" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.5.0.tgz#42255ba183ab67ce59a0dee640afdc00ab5ae93e" - integrity sha512-wlEBIZ5LP8usDylWbDNhKPEFVFdI5hCHpnVoT/Ysvoi/PRhJENm/Rlh9TvjYB38HFfKZN7OzEbRjmjvLkFw11g== +jpegtran-bin@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jpegtran-bin/-/jpegtran-bin-4.0.0.tgz#d00aed809fba7aa6f30817e59eee4ddf198f8f10" + integrity sha512-2cRl1ism+wJUoYAYFt6O/rLBfpXNWG2dUWbgcEkTt5WGMnqI46eEro8T4C5zGROxKRqyKpCBSdHPvt5UYCtxaQ== + dependencies: + bin-build "^3.0.0" + bin-wrapper "^4.0.0" + logalot "^2.0.0" js-levenshtein@^1.1.3: version "1.1.4" @@ -3246,13 +3566,13 @@ js-yaml@^3.12.0, js-yaml@^3.8.1: argparse "^1.0.7" esprima "^4.0.0" -js-yaml@~3.7.0: - version "3.7.0" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.7.0.tgz#5c967ddd837a9bfdca5f2de84253abe8a1c03b80" - integrity sha1-XJZ93YN6m/3KXy3oQlOr6KHAO4A= +js-yaml@^3.13.1: + version "3.13.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" + integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== dependencies: argparse "^1.0.7" - esprima "^2.6.0" + esprima "^4.0.0" jsbn@~0.1.0: version "0.1.1" @@ -3269,6 +3589,16 @@ jsesc@~0.5.0: resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= +json-buffer@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898" + integrity sha1-Wx85evx11ne96Lz8Dkfh+aPZqJg= + +json-parse-better-errors@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" + integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== + json-schema-traverse@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" @@ -3279,11 +3609,6 @@ json-schema@0.2.3: resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= -json-stable-stringify-without-jsonify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" - integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= - json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -3323,14 +3648,33 @@ jsprim@^1.2.2: json-schema "0.2.3" verror "1.10.0" -kind-of@^3.0.2: +keyv@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/keyv/-/keyv-3.0.0.tgz#44923ba39e68b12a7cec7df6c3268c031f2ef373" + integrity sha512-eguHnq22OE3uVoSYG0LVWNP+4ppamWr9+zWBe1bsNcovIMy6huUJFPgy4mGwCd/rnl3vOLGW1MTlu4c57CT1xA== + dependencies: + json-buffer "3.0.0" + +kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= dependencies: is-buffer "^1.1.5" -kind-of@^6.0.0: +kind-of@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" + integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= + dependencies: + is-buffer "^1.1.5" + +kind-of@^5.0.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" + integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== + +kind-of@^6.0.0, kind-of@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== @@ -3342,18 +3686,6 @@ lazy-cache@^2.0.2: dependencies: set-getter "^0.1.0" -lazy-req@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/lazy-req/-/lazy-req-1.1.0.tgz#bdaebead30f8d824039ce0ce149d4daa07ba1fac" - integrity sha1-va6+rTD42CQDnODOFJ1Nqge6H6w= - -lazystream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" - integrity sha1-9plf4PggOS9hOWvolGJAe7dxaOQ= - dependencies: - readable-stream "^2.0.5" - list-item@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/list-item/-/list-item-1.1.1.tgz#0c65d00e287cb663ccb3cb3849a77e89ec268a56" @@ -3388,51 +3720,11 @@ locate-path@^2.0.0: p-locate "^2.0.0" path-exists "^3.0.0" -lodash._basecopy@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36" - integrity sha1-jaDmqHbPNEwK2KVIghEd08XHyjY= - -lodash._basetostring@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5" - integrity sha1-0YYdh3+CSlL2aYMtyvPuFVZqB9U= - -lodash._basevalues@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._basevalues/-/lodash._basevalues-3.0.0.tgz#5b775762802bde3d3297503e26300820fdf661b7" - integrity sha1-W3dXYoAr3j0yl1A+JjAIIP32Ybc= - -lodash._getnative@^3.0.0: - version "3.9.1" - resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5" - integrity sha1-VwvH3t5G1hzc3mh9ZdPuy6o6r/U= - -lodash._isiterateecall@^3.0.0: - version "3.0.9" - resolved "https://registry.yarnpkg.com/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz#5203ad7ba425fae842460e696db9cf3e6aac057c" - integrity sha1-UgOte6Ql+uhCRg5pbbnPPmqsBXw= - -lodash._reescape@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._reescape/-/lodash._reescape-3.0.0.tgz#2b1d6f5dfe07c8a355753e5f27fac7f1cde1616a" - integrity sha1-Kx1vXf4HyKNVdT5fJ/rH8c3hYWo= - -lodash._reevaluate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._reevaluate/-/lodash._reevaluate-3.0.0.tgz#58bc74c40664953ae0b124d806996daca431e2ed" - integrity sha1-WLx0xAZklTrgsSTYBpltrKQx4u0= - lodash._reinterpolate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" integrity sha1-DM8tiRZq8Ds2Y8eWU4t1rG4RTZ0= -lodash._root@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" - integrity sha1-+6HEUkwZ7ppfgTa0YJ8BfPTe1pI= - lodash.assignin@^4.0.9: version "4.2.0" resolved "https://registry.yarnpkg.com/lodash.assignin/-/lodash.assignin-4.2.0.tgz#ba8df5fb841eb0a3e8044232b0e263a8dc6a28a2" @@ -3448,13 +3740,6 @@ lodash.defaults@^4.0.1: resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" integrity sha1-0JF4cW/+pN3p5ft7N/bwgCJ0WAw= -lodash.escape@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" - integrity sha1-mV7g3BjBtIzJLv+ucaEKq1tIdpg= - dependencies: - lodash._root "^3.0.0" - lodash.filter@^4.4.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.filter/-/lodash.filter-4.6.0.tgz#668b1d4981603ae1cc5a6fa760143e480b4c4ace" @@ -3470,30 +3755,6 @@ lodash.foreach@^4.3.0: resolved "https://registry.yarnpkg.com/lodash.foreach/-/lodash.foreach-4.5.0.tgz#1a6a35eace401280c7f06dddec35165ab27e3e53" integrity sha1-Gmo16s5AEoDH8G3d7DUWWrJ+PlM= -lodash.isarguments@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a" - integrity sha1-L1c9hcaiQon/AGY7SRwdM4/zRYo= - -lodash.isarray@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/lodash.isarray/-/lodash.isarray-3.0.4.tgz#79e4eb88c36a8122af86f844aa9bcd851b5fbb55" - integrity sha1-eeTriMNqgSKvhvhEqpvNhRtfu1U= - -lodash.isequal@^4.0.0: - version "4.5.0" - resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0" - integrity sha1-QVxEePK8wwEgwizhDtMib30+GOA= - -lodash.keys@^3.0.0: - version "3.1.2" - resolved "https://registry.yarnpkg.com/lodash.keys/-/lodash.keys-3.1.2.tgz#4dbc0472b156be50a0b286855d1bd0b0c656098a" - integrity sha1-TbwEcrFWvlCgsoaFXRvQsMZWCYo= - dependencies: - lodash._getnative "^3.0.0" - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - lodash.map@^4.4.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.map/-/lodash.map-4.6.0.tgz#771ec7839e3473d9c4cde28b19394c3562f4f6d3" @@ -3509,6 +3770,11 @@ lodash.merge@^4.4.0: resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.1.tgz#adc25d9cb99b9391c59624f379fbba60d7111d54" integrity sha512-AOYza4+Hf5z1/0Hztxpm2/xiPZgi/cjMqdnKTUWTBSKchJlxXXuUSxCCl8rJlf4g6yww/j6mA8nC8Hw/EZWxKQ== +lodash.merge@^4.6.2: + version "4.6.2" + resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" + integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== + lodash.pick@^4.2.1: version "4.4.0" resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-4.4.0.tgz#52f05610fff9ded422611441ed1fc123a03001b3" @@ -3524,38 +3790,25 @@ lodash.reject@^4.4.0: resolved "https://registry.yarnpkg.com/lodash.reject/-/lodash.reject-4.6.0.tgz#80d6492dc1470864bbf583533b651f42a9f52415" integrity sha1-gNZJLcFHCGS79YNTO2UfQqn1JBU= -lodash.restparam@^3.0.0: - version "3.6.1" - resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" - integrity sha1-k2pOMJ7zMKdkXtQUWYbIWuWyCAU= - lodash.some@^4.4.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.some/-/lodash.some-4.6.0.tgz#1bb9f314ef6b8baded13b549169b2a945eb68e4d" integrity sha1-G7nzFO9ri63tE7VJFpsqlF62jk0= -lodash.template@^3.0.0: - version "3.6.2" - resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-3.6.2.tgz#f8cdecc6169a255be9098ae8b0c53d378931d14f" - integrity sha1-+M3sxhaaJVvpCYrosMU9N4kx0U8= +lodash.template@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-4.5.0.tgz#f976195cf3f347d0d5f52483569fe8031ccce8ab" + integrity sha512-84vYFxIkmidUiFxidA/KjjH9pAycqW+h980j7Fuz5qxRtO9pgB7MDFTdys1N7A5mcucRiDyEq4fusljItR1T/A== dependencies: - lodash._basecopy "^3.0.0" - lodash._basetostring "^3.0.0" - lodash._basevalues "^3.0.0" - lodash._isiterateecall "^3.0.0" lodash._reinterpolate "^3.0.0" - lodash.escape "^3.0.0" - lodash.keys "^3.0.0" - lodash.restparam "^3.0.0" - lodash.templatesettings "^3.0.0" + lodash.templatesettings "^4.0.0" -lodash.templatesettings@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-3.1.1.tgz#fb307844753b66b9f1afa54e262c745307dba8e5" - integrity sha1-+zB4RHU7Zrnxr6VOJix0UwfbqOU= +lodash.templatesettings@^4.0.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-4.2.0.tgz#e481310f049d3cf6d47e912ad09313b154f0fb33" + integrity sha512-stgLz+i3Aa9mZgnjr/O+v9ruKZsPsndy7qPZOchbqk2cnTU1ZaldKK+v7m54WoKIyxiuMZTKT2H81F8BeAc3ZQ== dependencies: lodash._reinterpolate "^3.0.0" - lodash.escape "^3.0.0" lodash.uniq@^4.5.0: version "4.5.0" @@ -3595,6 +3848,11 @@ loud-rejection@^1.0.0: currently-unhandled "^0.4.1" signal-exit "^3.0.0" +lowercase-keys@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-1.0.0.tgz#4e3366b39e7f5457e35f1324bdf6f88d0bfc7306" + integrity sha1-TjNms55/VFfjXxMkvfb4jQv8cwY= + lowercase-keys@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-1.0.1.tgz#6f9e30b47084d971a7c820ff15a6c5167b74c26f" @@ -3618,18 +3876,30 @@ lru-cache@^4.0.1: pseudomap "^1.0.2" yallist "^2.1.2" -make-dir@^1.0.0: +make-dir@^1.0.0, make-dir@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.3.0.tgz#79c1033b80515bd6d24ec9933e860ca75ee27f0c" integrity sha512-2w31R7SJtieJJnQtGc7RVL2StM2vGYVfqUOvUDxH6bC6aJTxPxTF0GnIgCyu7tjockiUWAYQRbxa7vKn34s5sQ== dependencies: pify "^3.0.0" +map-cache@^0.2.2: + version "0.2.2" + resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" + integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= + map-obj@^1.0.0, map-obj@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" integrity sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0= +map-visit@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" + integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= + dependencies: + object-visit "^1.0.0" + markdown-link@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/markdown-link/-/markdown-link-0.1.1.tgz#32c5c65199a6457316322d1e4229d13407c8c7cf" @@ -3653,11 +3923,6 @@ markdown-toc@^1.2.0: repeat-string "^1.6.1" strip-color "^0.1.0" -math-expression-evaluator@^1.2.14: - version "1.2.17" - resolved "https://registry.yarnpkg.com/math-expression-evaluator/-/math-expression-evaluator-1.2.17.tgz#de819fdbcd84dccd8fae59c6aeb79615b9d266ac" - integrity sha1-3oGf282E3M2PrlnGrreWFbnSZqw= - math-random@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/math-random/-/math-random-1.0.1.tgz#8b3aac588b8a66e4975e3cdea67f7bb329601fac" @@ -3673,7 +3938,7 @@ media-typer@0.3.0: resolved "https://registry.yarnpkg.com/media-typer/-/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" integrity sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g= -meow@^3.1.0, meow@^3.3.0, meow@^3.5.0: +meow@^3.3.0: version "3.7.0" resolved "https://registry.yarnpkg.com/meow/-/meow-3.7.0.tgz#72cb668b425228290abbfa856892587308a801fb" integrity sha1-cstmi0JSKCkKu/qFaJJYcwioAfs= @@ -3694,65 +3959,73 @@ merge-descriptors@1.0.1: resolved "https://registry.yarnpkg.com/merge-descriptors/-/merge-descriptors-1.0.1.tgz#b00aaa556dd8b44568150ec9d1b953f3f90cbb61" integrity sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E= -merge-stream@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-1.0.1.tgz#4041202d508a342ba00174008df0c251b8c135e1" - integrity sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE= - dependencies: - readable-stream "^2.0.1" +merge2@^1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.2.3.tgz#7ee99dbd69bb6481689253f018488a1b902b0ed5" + integrity sha512-gdUU1Fwj5ep4kplwcmftruWofEFt6lfpkkr3h860CXbAB9c3hGb55EOL2ali0Td5oebvW0E1+3Sr+Ur7XfKpRA== methods@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" integrity sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4= -micromatch@^2.3.7: - version "2.3.11" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-2.3.11.tgz#86677c97d1720b363431d04d0d15293bd38c1565" - integrity sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU= +micromatch@^3.1.10: + version "3.1.10" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" + integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== dependencies: - arr-diff "^2.0.0" - array-unique "^0.2.1" - braces "^1.8.2" - expand-brackets "^0.1.4" - extglob "^0.3.1" - filename-regex "^2.0.0" - is-extglob "^1.0.0" - is-glob "^2.0.1" - kind-of "^3.0.2" - normalize-path "^2.0.1" - object.omit "^2.0.0" - parse-glob "^3.0.4" - regex-cache "^0.4.2" + arr-diff "^4.0.0" + array-unique "^0.3.2" + braces "^2.3.1" + define-property "^2.0.2" + extend-shallow "^3.0.2" + extglob "^2.0.4" + fragment-cache "^0.2.1" + kind-of "^6.0.2" + nanomatch "^1.2.9" + object.pick "^1.3.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.2" + +mime-db@1.40.0, mime-db@^1.28.0: + version "1.40.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz#a65057e998db090f732a68f6c276d387d4126c32" + integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== mime-db@~1.37.0: version "1.37.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.37.0.tgz#0b6a0ce6fdbe9576e25f1f2d2fde8830dc0ad0d8" integrity sha512-R3C4db6bgQhlIhPU48fUtdVmKnflq+hRdad7IyKhtFj06VPNVdk2RhiYL3UjQIlso8L+YxAtFkobT0VK+S/ybg== -mime-types@^2.1.12, mime-types@~2.1.18, mime-types@~2.1.19: +mime-types@^2.1.12, mime-types@~2.1.19: version "2.1.21" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.21.tgz#28995aa1ecb770742fe6ae7e58f9181c744b3f96" integrity sha512-3iL6DbwpyLzjR3xHSFNFeb9Nz/M8WDkX33t1GFQnFOllWk8pOrh/LSrB5OXlnlW5P9LH73X6loW/eogc+F5lJg== dependencies: mime-db "~1.37.0" -mime@1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/mime/-/mime-1.4.1.tgz#121f9ebc49e3766f311a76e1fa1c8003c4b03aa6" - integrity sha512-KI1+qOZu5DcW6wayYHSzR/tXKCDC5Om4s1z2QJjDULzLcmf3DvzS7oluY4HCTrc+9FiKmWUgeNLg7W3uIQvxtQ== +mime-types@~2.1.24: + version "2.1.24" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz#b6f8d0b3e951efb77dedeca194cff6d16f676f81" + integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== + dependencies: + mime-db "1.40.0" + +mime@1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== -"minimatch@2 || 3", minimatch@^3.0.4, minimatch@~3.0.2: - version "3.0.4" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== - dependencies: - brace-expansion "^1.1.7" +mimic-response@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b" + integrity sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ== minimatch@3.0.3: version "3.0.3" @@ -3761,12 +4034,19 @@ minimatch@3.0.3: dependencies: brace-expansion "^1.0.0" +minimatch@^3.0.4, minimatch@~3.0.2: + version "3.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== + dependencies: + brace-expansion "^1.1.7" + minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= -minimist@^1.1.0, minimist@^1.1.3, minimist@^1.2.0: +minimist@^1.1.3, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= @@ -3779,7 +4059,15 @@ mixin-deep@^1.1.3: for-in "^1.0.2" is-extendable "^1.0.1" -mkdirp@0.5.x, mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.1: +mixin-deep@^1.2.0: + version "1.3.2" + resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.2.tgz#1120b43dc359a785dce65b55b82e257ccf479566" + integrity sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA== + dependencies: + for-in "^1.0.2" + is-extendable "^1.0.1" + +mkdirp@0.5.x, mkdirp@^0.5.1, mkdirp@~0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= @@ -3791,27 +4079,37 @@ ms@2.0.0: resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= -ms@^2.1.1: +ms@2.1.1, ms@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== -multipipe@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/multipipe/-/multipipe-0.1.2.tgz#2a8f2ddf70eed564dff2d57f1e1a137d9f05078b" - integrity sha1-Ko8t33Du1WTf8tV/HhoTfZ8FB4s= - dependencies: - duplexer2 "0.0.2" - mute-stream@0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= -negotiator@0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9" - integrity sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk= +nanomatch@^1.2.9: + version "1.2.13" + resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" + integrity sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA== + dependencies: + arr-diff "^4.0.0" + array-unique "^0.3.2" + define-property "^2.0.2" + extend-shallow "^3.0.2" + fragment-cache "^0.2.1" + is-windows "^1.0.2" + kind-of "^6.0.2" + object.pick "^1.3.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" + +negotiator@0.6.2: + version "0.6.2" + resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.2.tgz#feacf7ccf525a77ae9634436a64883ffeca346fb" + integrity sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw== nice-try@^1.0.4: version "1.0.5" @@ -3830,10 +4128,12 @@ node-releases@^1.1.1: dependencies: semver "^5.3.0" -node-status-codes@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/node-status-codes/-/node-status-codes-1.0.0.tgz#5ae5541d024645d32a58fcddc9ceecea7ae3ac2f" - integrity sha1-WuVUHQJGRdMqWPzdyc7s6nrjrC8= +node-releases@^1.1.25: + version "1.1.25" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.25.tgz#0c2d7dbc7fed30fbe02a9ee3007b8c90bf0133d3" + integrity sha512-fI5BXuk83lKEoZDdH3gRhtsNgh05/wZacuXkgbiYkceE7+QIMXOg98n9ZV7mz27B+kFHnqHcUpscZZlGRSmTpQ== + dependencies: + semver "^5.3.0" normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: version "2.4.0" @@ -3845,27 +4145,37 @@ normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: semver "2 || 3 || 4 || 5" validate-npm-package-license "^3.0.1" -normalize-path@^2.0.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" - integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= - dependencies: - remove-trailing-separator "^1.0.1" +normalize-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== normalize-range@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/normalize-range/-/normalize-range-0.1.2.tgz#2d10c06bdfd312ea9777695a4d28439456b75942" integrity sha1-LRDAa9/TEuqXd2laTShDlFa3WUI= -normalize-url@^1.4.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-1.9.1.tgz#2cc0d66b31ea23036458436e3620d85954c66c3c" - integrity sha1-LMDWazHqIwNkWENuNiDYWVTGbDw= +normalize-url@2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-2.0.1.tgz#835a9da1551fa26f70e92329069a23aa6574d7e6" + integrity sha512-D6MUW4K/VzoJ4rJ01JFKxDrtY1v9wrgzCX5f2qj/lzH1m/lW6MhUZFKerVsnyjOhOsYzI9Kqqak+10l4LvLpMw== dependencies: - object-assign "^4.0.1" - prepend-http "^1.0.0" - query-string "^4.1.0" - sort-keys "^1.0.0" + prepend-http "^2.0.0" + query-string "^5.0.1" + sort-keys "^2.0.0" + +normalize-url@^3.0.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-3.3.0.tgz#b2e1c4dc4f7c6d57743df733a4f5978d18650559" + integrity sha512-U+JJi7duF1o+u2pynbp2zXDW2/PADgC30f0GsHZtRh+HOcXHnw137TrNlyxxRvWW5fjKd3bcLHPxofWuCjaeZg== + +npm-conf@^1.1.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/npm-conf/-/npm-conf-1.1.3.tgz#256cc47bd0e218c259c4e9550bf413bc2192aff9" + integrity sha512-Yic4bZHJOt9RCFbRP3GgpqhScOY4HH3V2P8yBj6CeYq118Qr+BLXqT2JvpJ00mryLESpgOxf5XlFv4ZjXxLScw== + dependencies: + config-chain "^1.1.11" + pify "^3.0.0" npm-run-path@^2.0.0: version "2.0.2" @@ -3896,26 +4206,32 @@ oauth-sign@~0.9.0: resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== -object-assign@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-2.1.1.tgz#43c36e5d569ff8e4816c4efa8be02d26967c18aa" - integrity sha1-Q8NuXVaf+OSBbE76i+AtJpZ8GKo= - -object-assign@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" - integrity sha1-m+3VygiXlJvKR+f/QIBi1Un1h/I= - -object-assign@^4.0.0, object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: +object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= +object-copy@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" + integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= + dependencies: + copy-descriptor "^0.1.0" + define-property "^0.2.5" + kind-of "^3.0.3" + object-keys@^1.0.12: version "1.0.12" resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.12.tgz#09c53855377575310cca62f55bb334abff7b3ed2" integrity sha512-FTMyFUm2wBcGHnH2eXmz7tC6IwlqQZ6mVZ+6dm6vZ4IQIHjs6FdNsQBuKGPuUUUY6NfJw2PshC08Tn6LzLDOag== +object-visit@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" + integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= + dependencies: + isobject "^3.0.0" + object.getownpropertydescriptors@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz#8758c846f5b407adab0f236e0986f14b051caa16" @@ -3924,15 +4240,7 @@ object.getownpropertydescriptors@^2.0.3: define-properties "^1.1.2" es-abstract "^1.5.1" -object.omit@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/object.omit/-/object.omit-2.0.1.tgz#1a9c744829f39dbb858c76ca3579ae2a54ebd1fa" - integrity sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo= - dependencies: - for-own "^0.1.4" - is-extendable "^0.1.1" - -object.pick@^1.2.0: +object.pick@^1.2.0, object.pick@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= @@ -3949,6 +4257,16 @@ object.values@^1.0.4: function-bind "^1.1.0" has "^1.0.1" +object.values@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.0.tgz#bf6810ef5da3e5325790eaaa2be213ea84624da9" + integrity sha512-8mf0nKLAoFX6VlNVdhGj31SVYpaNFtUnuoOXWyFEstsWRgU837AK+JYM0iAxwkSzGRbwn8cbFmgbyxj1j4VbXg== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.12.0" + function-bind "^1.1.1" + has "^1.0.3" + on-finished@~2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" @@ -3956,18 +4274,13 @@ on-finished@~2.3.0: dependencies: ee-first "1.1.1" -once@^1.3.0, once@^1.4.0: +once@^1.3.0, once@^1.3.1, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= dependencies: wrappy "1" -onetime@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-1.1.0.tgz#a1f7838f8314c516f05ecefcbc4ccfe04b4ed789" - integrity sha1-ofeDj4MUxRbwXs78vEzP4EtO14k= - onetime@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" @@ -3982,23 +4295,15 @@ opn@5.2.0: dependencies: is-wsl "^1.1.0" -optipng-bin@^3.0.0: - version "3.1.4" - resolved "https://registry.yarnpkg.com/optipng-bin/-/optipng-bin-3.1.4.tgz#95d34f2c488704f6fd70606bfea0c659f1d95d84" - integrity sha1-ldNPLEiHBPb9cGBr/qDGWfHZXYQ= +optipng-bin@^5.0.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/optipng-bin/-/optipng-bin-5.1.0.tgz#a7c7ab600a3ab5a177dae2f94c2d800aa386b5a9" + integrity sha512-9baoqZTNNmXQjq/PQTWEXbVV3AMO2sI/GaaqZJZ8SExfAzjijeAP7FEeT+TtyumSw7gr0PZtSUYB/Ke7iHQVKA== dependencies: - bin-build "^2.0.0" - bin-wrapper "^3.0.0" + bin-build "^3.0.0" + bin-wrapper "^4.0.0" logalot "^2.0.0" -ordered-read-streams@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-0.3.0.tgz#7137e69b3298bb342247a1bbee3881c80e2fd78b" - integrity sha1-cTfmmzKYuzQiR6G77jiByA4v14s= - dependencies: - is-stream "^1.0.1" - readable-stream "^2.0.1" - original@>=0.0.5: version "1.0.2" resolved "https://registry.yarnpkg.com/original/-/original-1.0.2.tgz#e442a61cffe1c5fd20a65f3261c26663b303f25f" @@ -4006,21 +4311,52 @@ original@>=0.0.5: dependencies: url-parse "^1.4.3" -os-filter-obj@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/os-filter-obj/-/os-filter-obj-1.0.3.tgz#5915330d90eced557d2d938a31c6dd214d9c63ad" - integrity sha1-WRUzDZDs7VV9LZOKMcbdIU2cY60= +os-filter-obj@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/os-filter-obj/-/os-filter-obj-2.0.0.tgz#1c0b62d5f3a2442749a2d139e6dddee6e81d8d16" + integrity sha512-uksVLsqG3pVdzzPvmAHpBK0wKxYItuzZr7SziusRPoz67tGV8rL1szZ6IdeUrbqLjGDwApBtN29eEE3IqGHOjg== + dependencies: + arch "^2.1.0" -os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: +os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= +p-cancelable@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/p-cancelable/-/p-cancelable-0.3.0.tgz#b9e123800bcebb7ac13a479be195b507b98d30fa" + integrity sha512-RVbZPLso8+jFeq1MfNvgXtCRED2raz/dKpacfTNxsx6pLEpEomM7gah6VeHSYV3+vo0OAi4MkArtQcWWXuQoyw== + +p-cancelable@^0.4.0: + version "0.4.1" + resolved "https://registry.yarnpkg.com/p-cancelable/-/p-cancelable-0.4.1.tgz#35f363d67d52081c8d9585e37bcceb7e0bbcb2a0" + integrity sha512-HNa1A8LvB1kie7cERyy21VNeHb2CWJJYqyyC2o3klWFfMGlFmWv2Z7sFgZH8ZiaYL95ydToKTFVXgMV/Os0bBQ== + +p-event@^1.0.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/p-event/-/p-event-1.3.0.tgz#8e6b4f4f65c72bc5b6fe28b75eda874f96a4a085" + integrity sha1-jmtPT2XHK8W2/ii3XtqHT5akoIU= + dependencies: + p-timeout "^1.1.1" + +p-event@^2.1.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/p-event/-/p-event-2.3.1.tgz#596279ef169ab2c3e0cae88c1cfbb08079993ef6" + integrity sha512-NQCqOFhbpVTMX4qMe8PF8lbGtzZ+LCiN7pcNrb/413Na7+TRoe1xkKUzuWa/YEJdGQ0FvKtj35EEbDoVPO2kbA== + dependencies: + p-timeout "^2.0.1" + p-finally@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= +p-is-promise@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-1.1.0.tgz#9c9456989e9f6588017b0434d56097675c3da05e" + integrity sha1-nJRWmJ6fZYgBewQ01WCXZ1w9oF4= + p-limit@^1.1.0: version "1.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" @@ -4035,47 +4371,71 @@ p-locate@^2.0.0: dependencies: p-limit "^1.1.0" +p-map-series@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-map-series/-/p-map-series-1.0.0.tgz#bf98fe575705658a9e1351befb85ae4c1f07bdca" + integrity sha1-v5j+V1cFZYqeE1G++4WuTB8Hvco= + dependencies: + p-reduce "^1.0.0" + p-pipe@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/p-pipe/-/p-pipe-1.2.0.tgz#4b1a11399a11520a67790ee5a0c1d5881d6befe9" integrity sha1-SxoROZoRUgpneQ7loMHViB1r7+k= +p-reduce@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-reduce/-/p-reduce-1.0.0.tgz#18c2b0dd936a4690a529f8231f58a0fdb6a47dfa" + integrity sha1-GMKw3ZNqRpClKfgjH1ig/bakffo= + +p-timeout@^1.1.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/p-timeout/-/p-timeout-1.2.1.tgz#5eb3b353b7fce99f101a1038880bb054ebbea386" + integrity sha1-XrOzU7f86Z8QGhA4iAuwVOu+o4Y= + dependencies: + p-finally "^1.0.0" + +p-timeout@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/p-timeout/-/p-timeout-2.0.1.tgz#d8dd1979595d2dc0139e1fe46b8b646cb3cdf038" + integrity sha512-88em58dDVB/KzPEx1X0N3LwFfYZPyDc4B6eF38M1rk9VTZMbxXXgjugz8mmwpS9Ox4BDZ+t6t3QP5+/gazweIA== + dependencies: + p-finally "^1.0.0" + p-try@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" integrity sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M= -parse-glob@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/parse-glob/-/parse-glob-3.0.4.tgz#b2c376cfb11f35513badd173ef0bb6e3a388391c" - integrity sha1-ssN2z7EfNVE7rdFz7wu246OIORw= - dependencies: - glob-base "^0.3.0" - is-dotfile "^1.0.0" - is-extglob "^1.0.0" - is-glob "^2.0.0" - -parse-json@^2.1.0, parse-json@^2.2.0: +parse-json@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= dependencies: error-ex "^1.2.0" -parse-node-version@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.0.tgz#33d9aa8920dcc3c0d33658ec18ce237009a56d53" - integrity sha512-02GTVHD1u0nWc20n2G7WX/PgdhNFG04j5fi1OkaJzPWLTcf6vh6229Lta1wTmXG/7Dg42tCssgkccVt7qvd8Kg== +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" + integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" integrity sha1-bVuTSkVpk7I9N/QKOC1vFmao5cY= -parseurl@~1.3.2: - version "1.3.2" - resolved "https://registry.yarnpkg.com/parseurl/-/parseurl-1.3.2.tgz#fc289d4ed8993119460c156253262cdc8de65bf3" - integrity sha1-/CidTtiZMRlGDBViUyYs3I3mW/M= +parseurl@~1.3.3: + version "1.3.3" + resolved "https://registry.yarnpkg.com/parseurl/-/parseurl-1.3.3.tgz#9da19e7bee8d12dff0513ed5b76957793bc2e8d4" + integrity sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ== + +pascalcase@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" + integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= path-dirname@^1.0.0: version "1.0.2" @@ -4123,6 +4483,13 @@ path-type@^1.0.0: pify "^2.0.0" pinkie-promise "^2.0.0" +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" + integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== + dependencies: + pify "^3.0.0" + pend@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/pend/-/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50" @@ -4133,7 +4500,12 @@ performance-now@^2.1.0: resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= -pify@^2.0.0, pify@^2.3.0: +picomatch@^2.0.4: + version "2.0.7" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.0.7.tgz#514169d8c7cd0bdbeecc8a2609e34a7163de69f6" + integrity sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA== + +pify@^2.0.0, pify@^2.2.0, pify@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= @@ -4143,6 +4515,11 @@ pify@^3.0.0: resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= +pify@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" + integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== + pinkie-promise@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" @@ -4178,246 +4555,297 @@ portfinder@^1.0.17: debug "^2.2.0" mkdirp "0.5.x" -postcss-calc@^5.2.0: - version "5.3.1" - resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-5.3.1.tgz#77bae7ca928ad85716e2fda42f261bf7c1d65b5e" - integrity sha1-d7rnypKK2FcW4v2kLyYb98HWW14= - dependencies: - postcss "^5.0.2" - postcss-message-helpers "^2.0.0" - reduce-css-calc "^1.2.6" - -postcss-colormin@^2.1.8: - version "2.2.2" - resolved "https://registry.yarnpkg.com/postcss-colormin/-/postcss-colormin-2.2.2.tgz#6631417d5f0e909a3d7ec26b24c8a8d1e4f96e4b" - integrity sha1-ZjFBfV8OkJo9fsJrJMio0eT5bks= - dependencies: - colormin "^1.0.5" - postcss "^5.0.13" - postcss-value-parser "^3.2.3" - -postcss-convert-values@^2.3.4: - version "2.6.1" - resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-2.6.1.tgz#bbd8593c5c1fd2e3d1c322bb925dcae8dae4d62d" - integrity sha1-u9hZPFwf0uPRwyK7kl3K6Nrk1i0= - dependencies: - postcss "^5.0.11" - postcss-value-parser "^3.1.2" - -postcss-discard-comments@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/postcss-discard-comments/-/postcss-discard-comments-2.0.4.tgz#befe89fafd5b3dace5ccce51b76b81514be00e3d" - integrity sha1-vv6J+v1bPazlzM5Rt2uBUUvgDj0= - dependencies: - postcss "^5.0.14" - -postcss-discard-duplicates@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/postcss-discard-duplicates/-/postcss-discard-duplicates-2.1.0.tgz#b9abf27b88ac188158a5eb12abcae20263b91932" - integrity sha1-uavye4isGIFYpesSq8riAmO5GTI= - dependencies: - postcss "^5.0.4" - -postcss-discard-empty@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/postcss-discard-empty/-/postcss-discard-empty-2.1.0.tgz#d2b4bd9d5ced5ebd8dcade7640c7d7cd7f4f92b5" - integrity sha1-0rS9nVztXr2Nyt52QMfXzX9PkrU= - dependencies: - postcss "^5.0.14" - -postcss-discard-overridden@^0.1.1: +posix-character-classes@^0.1.0: version "0.1.1" - resolved "https://registry.yarnpkg.com/postcss-discard-overridden/-/postcss-discard-overridden-0.1.1.tgz#8b1eaf554f686fb288cd874c55667b0aa3668d58" - integrity sha1-ix6vVU9ob7KIzYdMVWZ7CqNmjVg= - dependencies: - postcss "^5.0.16" + resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" + integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= -postcss-discard-unused@^2.2.1: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-discard-unused/-/postcss-discard-unused-2.2.3.tgz#bce30b2cc591ffc634322b5fb3464b6d934f4433" - integrity sha1-vOMLLMWR/8Y0Mitfs0ZLbZNPRDM= +postcss-calc@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-7.0.1.tgz#36d77bab023b0ecbb9789d84dcb23c4941145436" + integrity sha512-oXqx0m6tb4N3JGdmeMSc/i91KppbYsFZKdH0xMOqK8V1rJlzrKlTdokz8ozUXLVejydRN6u2IddxpcijRj2FqQ== dependencies: - postcss "^5.0.14" - uniqs "^2.0.0" + css-unit-converter "^1.1.1" + postcss "^7.0.5" + postcss-selector-parser "^5.0.0-rc.4" + postcss-value-parser "^3.3.1" -postcss-filter-plugins@^2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/postcss-filter-plugins/-/postcss-filter-plugins-2.0.3.tgz#82245fdf82337041645e477114d8e593aa18b8ec" - integrity sha512-T53GVFsdinJhgwm7rg1BzbeBRomOg9y5MBVhGcsV0CxurUdVj1UlPdKtn7aqYA/c/QVkzKMjq2bSV5dKG5+AwQ== +postcss-colormin@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/postcss-colormin/-/postcss-colormin-4.0.3.tgz#ae060bce93ed794ac71264f08132d550956bd381" + integrity sha512-WyQFAdDZpExQh32j0U0feWisZ0dmOtPl44qYmJKkq9xFWY3p+4qnRzCHeNrkeRhwPHz9bQ3mo0/yVkaply0MNw== dependencies: - postcss "^5.0.4" + browserslist "^4.0.0" + color "^3.0.0" + has "^1.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-merge-idents@^2.1.5: - version "2.1.7" - resolved "https://registry.yarnpkg.com/postcss-merge-idents/-/postcss-merge-idents-2.1.7.tgz#4c5530313c08e1d5b3bbf3d2bbc747e278eea270" - integrity sha1-TFUwMTwI4dWzu/PSu8dH4njuonA= +postcss-convert-values@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-4.0.1.tgz#ca3813ed4da0f812f9d43703584e449ebe189a7f" + integrity sha512-Kisdo1y77KUC0Jmn0OXU/COOJbzM8cImvw1ZFsBgBgMgb1iL23Zs/LXRe3r+EZqM3vGYKdQ2YJVQ5VkJI+zEJQ== dependencies: - has "^1.0.1" - postcss "^5.0.10" - postcss-value-parser "^3.1.1" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-merge-longhand@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/postcss-merge-longhand/-/postcss-merge-longhand-2.0.2.tgz#23d90cd127b0a77994915332739034a1a4f3d658" - integrity sha1-I9kM0Sewp3mUkVMyc5A0oaTz1lg= +postcss-discard-comments@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-discard-comments/-/postcss-discard-comments-4.0.2.tgz#1fbabd2c246bff6aaad7997b2b0918f4d7af4033" + integrity sha512-RJutN259iuRf3IW7GZyLM5Sw4GLTOH8FmsXBnv8Ab/Tc2k4SR4qbV4DNbyyY4+Sjo362SyDmW2DQ7lBSChrpkg== dependencies: - postcss "^5.0.4" + postcss "^7.0.0" -postcss-merge-rules@^2.0.3: - version "2.1.2" - resolved "https://registry.yarnpkg.com/postcss-merge-rules/-/postcss-merge-rules-2.1.2.tgz#d1df5dfaa7b1acc3be553f0e9e10e87c61b5f721" - integrity sha1-0d9d+qexrMO+VT8OnhDofGG19yE= +postcss-discard-duplicates@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-discard-duplicates/-/postcss-discard-duplicates-4.0.2.tgz#3fe133cd3c82282e550fc9b239176a9207b784eb" + integrity sha512-ZNQfR1gPNAiXZhgENFfEglF93pciw0WxMkJeVmw8eF+JZBbMD7jp6C67GqJAXVZP2BWbOztKfbsdmMp/k8c6oQ== dependencies: - browserslist "^1.5.2" - caniuse-api "^1.5.2" - postcss "^5.0.4" - postcss-selector-parser "^2.2.2" + postcss "^7.0.0" + +postcss-discard-empty@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-discard-empty/-/postcss-discard-empty-4.0.1.tgz#c8c951e9f73ed9428019458444a02ad90bb9f765" + integrity sha512-B9miTzbznhDjTfjvipfHoqbWKwd0Mj+/fL5s1QOz06wufguil+Xheo4XpOnc4NqKYBCNqqEzgPv2aPBIJLox0w== + dependencies: + postcss "^7.0.0" + +postcss-discard-overridden@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-discard-overridden/-/postcss-discard-overridden-4.0.1.tgz#652aef8a96726f029f5e3e00146ee7a4e755ff57" + integrity sha512-IYY2bEDD7g1XM1IDEsUT4//iEYCxAmP5oDSFMVU/JVvT7gh+l4fmjciLqGgwjdWpQIdb0Che2VX00QObS5+cTg== + dependencies: + postcss "^7.0.0" + +postcss-merge-longhand@^4.0.11: + version "4.0.11" + resolved "https://registry.yarnpkg.com/postcss-merge-longhand/-/postcss-merge-longhand-4.0.11.tgz#62f49a13e4a0ee04e7b98f42bb16062ca2549e24" + integrity sha512-alx/zmoeXvJjp7L4mxEMjh8lxVlDFX1gqWHzaaQewwMZiVhLo42TEClKaeHbRf6J7j82ZOdTJ808RtN0ZOZwvw== + dependencies: + css-color-names "0.0.4" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + stylehacks "^4.0.0" + +postcss-merge-rules@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/postcss-merge-rules/-/postcss-merge-rules-4.0.3.tgz#362bea4ff5a1f98e4075a713c6cb25aefef9a650" + integrity sha512-U7e3r1SbvYzO0Jr3UT/zKBVgYYyhAz0aitvGIYOYK5CPmkNih+WDSsS5tvPrJ8YMQYlEMvsZIiqmn7HdFUaeEQ== + dependencies: + browserslist "^4.0.0" + caniuse-api "^3.0.0" + cssnano-util-same-parent "^4.0.0" + postcss "^7.0.0" + postcss-selector-parser "^3.0.0" vendors "^1.0.0" -postcss-message-helpers@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/postcss-message-helpers/-/postcss-message-helpers-2.0.0.tgz#a4f2f4fab6e4fe002f0aed000478cdf52f9ba60e" - integrity sha1-pPL0+rbk/gAvCu0ABHjN9S+bpg4= - -postcss-minify-font-values@^1.0.2: - version "1.0.5" - resolved "https://registry.yarnpkg.com/postcss-minify-font-values/-/postcss-minify-font-values-1.0.5.tgz#4b58edb56641eba7c8474ab3526cafd7bbdecb69" - integrity sha1-S1jttWZB66fIR0qzUmyv17vey2k= +postcss-minify-font-values@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-minify-font-values/-/postcss-minify-font-values-4.0.2.tgz#cd4c344cce474343fac5d82206ab2cbcb8afd5a6" + integrity sha512-j85oO6OnRU9zPf04+PZv1LYIYOprWm6IA6zkXkrJXyRveDEuQggG6tvoy8ir8ZwjLxLuGfNkCZEQG7zan+Hbtg== dependencies: - object-assign "^4.0.1" - postcss "^5.0.4" - postcss-value-parser "^3.0.2" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-minify-gradients@^1.0.1: - version "1.0.5" - resolved "https://registry.yarnpkg.com/postcss-minify-gradients/-/postcss-minify-gradients-1.0.5.tgz#5dbda11373703f83cfb4a3ea3881d8d75ff5e6e1" - integrity sha1-Xb2hE3NwP4PPtKPqOIHY11/15uE= +postcss-minify-gradients@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-minify-gradients/-/postcss-minify-gradients-4.0.2.tgz#93b29c2ff5099c535eecda56c4aa6e665a663471" + integrity sha512-qKPfwlONdcf/AndP1U8SJ/uzIJtowHlMaSioKzebAXSG4iJthlWC9iSWznQcX4f66gIWX44RSA841HTHj3wK+Q== dependencies: - postcss "^5.0.12" - postcss-value-parser "^3.3.0" + cssnano-util-get-arguments "^4.0.0" + is-color-stop "^1.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-minify-params@^1.0.4: - version "1.2.2" - resolved "https://registry.yarnpkg.com/postcss-minify-params/-/postcss-minify-params-1.2.2.tgz#ad2ce071373b943b3d930a3fa59a358c28d6f1f3" - integrity sha1-rSzgcTc7lDs9kwo/pZo1jCjW8fM= +postcss-minify-params@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-minify-params/-/postcss-minify-params-4.0.2.tgz#6b9cef030c11e35261f95f618c90036d680db874" + integrity sha512-G7eWyzEx0xL4/wiBBJxJOz48zAKV2WG3iZOqVhPet/9geefm/Px5uo1fzlHu+DOjT+m0Mmiz3jkQzVHe6wxAWg== dependencies: - alphanum-sort "^1.0.1" - postcss "^5.0.2" - postcss-value-parser "^3.0.2" + alphanum-sort "^1.0.0" + browserslist "^4.0.0" + cssnano-util-get-arguments "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" uniqs "^2.0.0" -postcss-minify-selectors@^2.0.4: - version "2.1.1" - resolved "https://registry.yarnpkg.com/postcss-minify-selectors/-/postcss-minify-selectors-2.1.1.tgz#b2c6a98c0072cf91b932d1a496508114311735bf" - integrity sha1-ssapjAByz5G5MtGkllCBFDEXNb8= +postcss-minify-selectors@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-minify-selectors/-/postcss-minify-selectors-4.0.2.tgz#e2e5eb40bfee500d0cd9243500f5f8ea4262fbd8" + integrity sha512-D5S1iViljXBj9kflQo4YutWnJmwm8VvIsU1GeXJGiG9j8CIg9zs4voPMdQDUmIxetUOh60VilsNzCiAFTOqu3g== dependencies: - alphanum-sort "^1.0.2" - has "^1.0.1" - postcss "^5.0.14" - postcss-selector-parser "^2.0.0" + alphanum-sort "^1.0.0" + has "^1.0.0" + postcss "^7.0.0" + postcss-selector-parser "^3.0.0" -postcss-normalize-charset@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/postcss-normalize-charset/-/postcss-normalize-charset-1.1.1.tgz#ef9ee71212d7fe759c78ed162f61ed62b5cb93f1" - integrity sha1-757nEhLX/nWceO0WL2HtYrXLk/E= +postcss-normalize-charset@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-normalize-charset/-/postcss-normalize-charset-4.0.1.tgz#8b35add3aee83a136b0471e0d59be58a50285dd4" + integrity sha512-gMXCrrlWh6G27U0hF3vNvR3w8I1s2wOBILvA87iNXaPvSNo5uZAMYsZG7XjCUf1eVxuPfyL4TJ7++SGZLc9A3g== dependencies: - postcss "^5.0.5" + postcss "^7.0.0" -postcss-normalize-url@^3.0.7: - version "3.0.8" - resolved "https://registry.yarnpkg.com/postcss-normalize-url/-/postcss-normalize-url-3.0.8.tgz#108f74b3f2fcdaf891a2ffa3ea4592279fc78222" - integrity sha1-EI90s/L82viRov+j6kWSJ5/HgiI= +postcss-normalize-display-values@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-display-values/-/postcss-normalize-display-values-4.0.2.tgz#0dbe04a4ce9063d4667ed2be476bb830c825935a" + integrity sha512-3F2jcsaMW7+VtRMAqf/3m4cPFhPD3EFRgNs18u+k3lTJJlVe7d0YPO+bnwqo2xg8YiRpDXJI2u8A0wqJxMsQuQ== + dependencies: + cssnano-util-get-match "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-positions@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-positions/-/postcss-normalize-positions-4.0.2.tgz#05f757f84f260437378368a91f8932d4b102917f" + integrity sha512-Dlf3/9AxpxE+NF1fJxYDeggi5WwV35MXGFnnoccP/9qDtFrTArZ0D0R+iKcg5WsUd8nUYMIl8yXDCtcrT8JrdA== + dependencies: + cssnano-util-get-arguments "^4.0.0" + has "^1.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-repeat-style@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-repeat-style/-/postcss-normalize-repeat-style-4.0.2.tgz#c4ebbc289f3991a028d44751cbdd11918b17910c" + integrity sha512-qvigdYYMpSuoFs3Is/f5nHdRLJN/ITA7huIoCyqqENJe9PvPmLhNLMu7QTjPdtnVf6OcYYO5SHonx4+fbJE1+Q== + dependencies: + cssnano-util-get-arguments "^4.0.0" + cssnano-util-get-match "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-string@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-string/-/postcss-normalize-string-4.0.2.tgz#cd44c40ab07a0c7a36dc5e99aace1eca4ec2690c" + integrity sha512-RrERod97Dnwqq49WNz8qo66ps0swYZDSb6rM57kN2J+aoyEAJfZ6bMx0sx/F9TIEX0xthPGCmeyiam/jXif0eA== + dependencies: + has "^1.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-timing-functions@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-timing-functions/-/postcss-normalize-timing-functions-4.0.2.tgz#8e009ca2a3949cdaf8ad23e6b6ab99cb5e7d28d9" + integrity sha512-acwJY95edP762e++00Ehq9L4sZCEcOPyaHwoaFOhIwWCDfik6YvqsYNxckee65JHLKzuNSSmAdxwD2Cud1Z54A== + dependencies: + cssnano-util-get-match "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-unicode@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-normalize-unicode/-/postcss-normalize-unicode-4.0.1.tgz#841bd48fdcf3019ad4baa7493a3d363b52ae1cfb" + integrity sha512-od18Uq2wCYn+vZ/qCOeutvHjB5jm57ToxRaMeNuf0nWVHaP9Hua56QyMF6fs/4FSUnVIw0CBPsU0K4LnBPwYwg== + dependencies: + browserslist "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + +postcss-normalize-url@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-normalize-url/-/postcss-normalize-url-4.0.1.tgz#10e437f86bc7c7e58f7b9652ed878daaa95faae1" + integrity sha512-p5oVaF4+IHwu7VpMan/SSpmpYxcJMtkGppYf0VbdH5B6hN8YNmVyJLuY9FmLQTzY3fag5ESUUHDqM+heid0UVA== dependencies: is-absolute-url "^2.0.0" - normalize-url "^1.4.0" - postcss "^5.0.14" - postcss-value-parser "^3.2.3" + normalize-url "^3.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-ordered-values@^2.1.0: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-ordered-values/-/postcss-ordered-values-2.2.3.tgz#eec6c2a67b6c412a8db2042e77fe8da43f95c11d" - integrity sha1-7sbCpntsQSqNsgQud/6NpD+VwR0= +postcss-normalize-whitespace@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-normalize-whitespace/-/postcss-normalize-whitespace-4.0.2.tgz#bf1d4070fe4fcea87d1348e825d8cc0c5faa7d82" + integrity sha512-tO8QIgrsI3p95r8fyqKV+ufKlSHh9hMJqACqbv2XknufqEDhDvbguXGBBqxw9nsQoXWf0qOqppziKJKHMD4GtA== dependencies: - postcss "^5.0.4" - postcss-value-parser "^3.0.1" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-reduce-idents@^2.2.2: - version "2.4.0" - resolved "https://registry.yarnpkg.com/postcss-reduce-idents/-/postcss-reduce-idents-2.4.0.tgz#c2c6d20cc958284f6abfbe63f7609bf409059ad3" - integrity sha1-wsbSDMlYKE9qv75j92Cb9AkFmtM= +postcss-ordered-values@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/postcss-ordered-values/-/postcss-ordered-values-4.1.2.tgz#0cf75c820ec7d5c4d280189559e0b571ebac0eee" + integrity sha512-2fCObh5UanxvSxeXrtLtlwVThBvHn6MQcu4ksNT2tsaV2Fg76R2CV98W7wNSlX+5/pFwEyaDwKLLoEV7uRybAw== dependencies: - postcss "^5.0.4" - postcss-value-parser "^3.0.2" + cssnano-util-get-arguments "^4.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-reduce-initial@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/postcss-reduce-initial/-/postcss-reduce-initial-1.0.1.tgz#68f80695f045d08263a879ad240df8dd64f644ea" - integrity sha1-aPgGlfBF0IJjqHmtJA343WT2ROo= +postcss-reduce-initial@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/postcss-reduce-initial/-/postcss-reduce-initial-4.0.3.tgz#7fd42ebea5e9c814609639e2c2e84ae270ba48df" + integrity sha512-gKWmR5aUulSjbzOfD9AlJiHCGH6AEVLaM0AV+aSioxUDd16qXP1PCh8d1/BGVvpdWn8k/HiK7n6TjeoXN1F7DA== dependencies: - postcss "^5.0.4" + browserslist "^4.0.0" + caniuse-api "^3.0.0" + has "^1.0.0" + postcss "^7.0.0" -postcss-reduce-transforms@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/postcss-reduce-transforms/-/postcss-reduce-transforms-1.0.4.tgz#ff76f4d8212437b31c298a42d2e1444025771ae1" - integrity sha1-/3b02CEkN7McKYpC0uFEQCV3GuE= +postcss-reduce-transforms@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-reduce-transforms/-/postcss-reduce-transforms-4.0.2.tgz#17efa405eacc6e07be3414a5ca2d1074681d4e29" + integrity sha512-EEVig1Q2QJ4ELpJXMZR8Vt5DQx8/mo+dGWSR7vWXqcob2gQLyQGsionYcGKATXvQzMPn6DSN1vTN7yFximdIAg== dependencies: - has "^1.0.1" - postcss "^5.0.8" - postcss-value-parser "^3.0.1" + cssnano-util-get-match "^4.0.0" + has "^1.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" -postcss-selector-parser@^2.0.0, postcss-selector-parser@^2.2.2: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-2.2.3.tgz#f9437788606c3c9acee16ffe8d8b16297f27bb90" - integrity sha1-+UN3iGBsPJrO4W/+jYsWKX8nu5A= +postcss-selector-parser@^3.0.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-3.1.1.tgz#4f875f4afb0c96573d5cf4d74011aee250a7e865" + integrity sha1-T4dfSvsMllc9XPTXQBGu4lCn6GU= dependencies: - flatten "^1.0.2" + dot-prop "^4.1.1" indexes-of "^1.0.1" uniq "^1.0.1" -postcss-svgo@^2.1.1: - version "2.1.6" - resolved "https://registry.yarnpkg.com/postcss-svgo/-/postcss-svgo-2.1.6.tgz#b6df18aa613b666e133f08adb5219c2684ac108d" - integrity sha1-tt8YqmE7Zm4TPwittSGcJoSsEI0= +postcss-selector-parser@^5.0.0-rc.4: + version "5.0.0" + resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-5.0.0.tgz#249044356697b33b64f1a8f7c80922dddee7195c" + integrity sha512-w+zLE5Jhg6Liz8+rQOWEAwtwkyqpfnmsinXjXg6cY7YIONZZtgvE0v2O0uhQBs0peNomOJwWRKt6JBfTdTd3OQ== dependencies: - is-svg "^2.0.0" - postcss "^5.0.14" - postcss-value-parser "^3.2.3" - svgo "^0.7.0" + cssesc "^2.0.0" + indexes-of "^1.0.1" + uniq "^1.0.1" -postcss-unique-selectors@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/postcss-unique-selectors/-/postcss-unique-selectors-2.0.2.tgz#981d57d29ddcb33e7b1dfe1fd43b8649f933ca1d" - integrity sha1-mB1X0p3csz57Hf4f1DuGSfkzyh0= +postcss-svgo@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-svgo/-/postcss-svgo-4.0.2.tgz#17b997bc711b333bab143aaed3b8d3d6e3d38258" + integrity sha512-C6wyjo3VwFm0QgBy+Fu7gCYOkCmgmClghO+pjcxvrcBKtiKt0uCF+hvbMO1fyv5BMImRK90SMb+dwUnfbGd+jw== dependencies: - alphanum-sort "^1.0.1" - postcss "^5.0.4" + is-svg "^3.0.0" + postcss "^7.0.0" + postcss-value-parser "^3.0.0" + svgo "^1.0.0" + +postcss-unique-selectors@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/postcss-unique-selectors/-/postcss-unique-selectors-4.0.1.tgz#9446911f3289bfd64c6d680f073c03b1f9ee4bac" + integrity sha512-+JanVaryLo9QwZjKrmJgkI4Fn8SBgRO6WXQBJi7KiAVPlmxikB5Jzc4EvXMT2H0/m0RjrVVm9rGNhZddm/8Spg== + dependencies: + alphanum-sort "^1.0.0" + postcss "^7.0.0" uniqs "^2.0.0" -postcss-value-parser@^3.0.1, postcss-value-parser@^3.0.2, postcss-value-parser@^3.1.1, postcss-value-parser@^3.1.2, postcss-value-parser@^3.2.3, postcss-value-parser@^3.3.0, postcss-value-parser@^3.3.1: +postcss-value-parser@^3.0.0, postcss-value-parser@^3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-3.3.1.tgz#9ff822547e2893213cf1c30efa51ac5fd1ba8281" integrity sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ== -postcss-zindex@^2.0.1: - version "2.2.0" - resolved "https://registry.yarnpkg.com/postcss-zindex/-/postcss-zindex-2.2.0.tgz#d2109ddc055b91af67fc4cb3b025946639d2af22" - integrity sha1-0hCd3AVbka9n/EyzsCWUZjnSryI= - dependencies: - has "^1.0.1" - postcss "^5.0.4" - uniqs "^2.0.0" +postcss-value-parser@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.0.0.tgz#99a983d365f7b2ad8d0f9b8c3094926eab4b936d" + integrity sha512-ESPktioptiSUchCKgggAkzdmkgzKfmp0EU8jXH+5kbIUB+unr0Y4CY9SRMvibuvYUBjNh1ACLbxqYNpdTQOteQ== -postcss@^5.0.10, postcss@^5.0.11, postcss@^5.0.12, postcss@^5.0.13, postcss@^5.0.14, postcss@^5.0.16, postcss@^5.0.2, postcss@^5.0.4, postcss@^5.0.5, postcss@^5.0.8, postcss@^5.2.16: - version "5.2.18" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-5.2.18.tgz#badfa1497d46244f6390f58b319830d9107853c5" - integrity sha512-zrUjRRe1bpXKsX1qAJNJjqZViErVuyEkMTRrwu4ud4sbTtIBRmtaYDrHmcGgmrbsW3MHfmtIf+vJumgQn+PrXg== +postcss@^7.0.0, postcss@^7.0.17, postcss@^7.0.5: + version "7.0.17" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.17.tgz#4da1bdff5322d4a0acaab4d87f3e782436bad31f" + integrity sha512-546ZowA+KZ3OasvQZHsbuEpysvwTZNGJv9EfyCQdsIDltPSWHAeTQ5fQy/Npi2ZDtLI3zs7Ps/p6wThErhm9fQ== dependencies: - chalk "^1.1.3" - js-base64 "^2.1.9" - source-map "^0.5.6" - supports-color "^3.2.3" + chalk "^2.4.2" + source-map "^0.6.1" + supports-color "^6.1.0" -postcss@^7.0.1, postcss@^7.0.6: +postcss@^7.0.1: version "7.0.7" resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.7.tgz#2754d073f77acb4ef08f1235c36c5721a7201614" integrity sha512-HThWSJEPkupqew2fnuQMEI2YcTj/8gMV3n80cMdJsKxfIh5tHf7nM5JigNX6LxVMqo6zkgQNAI88hyFvBk41Pg== @@ -4426,15 +4854,15 @@ postcss@^7.0.1, postcss@^7.0.6: source-map "^0.6.1" supports-color "^5.5.0" -prepend-http@^1.0.0, prepend-http@^1.0.1: +prepend-http@^1.0.1: version "1.0.4" resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" integrity sha1-1PRWKwzjaW5BrFLQ4ALlemNdxtw= -preserve@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" - integrity sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks= +prepend-http@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897" + integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc= prismjs@^1.15.0: version "1.15.0" @@ -4461,13 +4889,18 @@ prop-types@^15.6.2: loose-envify "^1.3.1" object-assign "^4.1.1" -proxy-addr@~2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.4.tgz#ecfc733bf22ff8c6f407fa275327b9ab67e48b93" - integrity sha512-5erio2h9jp5CHGwcybmxmVqHmnCBZeewlfJ0pex+UW7Qny7OOZXTtH56TGNyBizkgiOwhJtMKrVzDTeKcySZwA== +proto-list@~1.2.1: + version "1.2.4" + resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849" + integrity sha1-IS1b/hMYMGpCD2QCuOJv85ZHqEk= + +proxy-addr@~2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.5.tgz#34cbd64a2d81f4b1fd21e76f9f06c8a45299ee34" + integrity sha512-t/7RxHXPH6cJtP0pRG6smSr9QJidhB+3kXu0KgXnbGYMgzEnUxRQ4/LDdfOwZEMyIh3/xHb8PX3t+lfL9z+YVQ== dependencies: forwarded "~0.1.2" - ipaddr.js "1.8.0" + ipaddr.js "1.9.0" pseudomap@^1.0.2: version "1.0.2" @@ -4479,6 +4912,14 @@ psl@^1.1.24: resolved "https://registry.yarnpkg.com/psl/-/psl-1.1.31.tgz#e9aa86d0101b5b105cbe93ac6b784cd547276184" integrity sha512-/6pt4+C+T+wZUieKR620OpzN/LlnNKuWjy1iFLQ/UG35JqHlR/89MP1d96dUfkf6Dne3TuLQzOYEYshJ+Hx8mw== +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" + integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" @@ -4499,21 +4940,27 @@ q@^1.1.2: resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" integrity sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc= -qs@6.5.2, qs@~6.5.2: - version "6.5.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" - integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== +qs@6.7.0: + version "6.7.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.7.0.tgz#41dc1a015e3d581f1621776be31afb2876a9b1bc" + integrity sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ== qs@^6.4.0: version "6.6.0" resolved "https://registry.yarnpkg.com/qs/-/qs-6.6.0.tgz#a99c0f69a8d26bf7ef012f871cdabb0aee4424c2" integrity sha512-KIJqT9jQJDQx5h5uAVPimw6yVg2SekOKu959OCtktD3FjzbpvaPr8i4zzg07DOMz+igA4W/aNM7OV8H37pFYfA== -query-string@^4.1.0: - version "4.3.4" - resolved "https://registry.yarnpkg.com/query-string/-/query-string-4.3.4.tgz#bbb693b9ca915c232515b228b1a02b609043dbeb" - integrity sha1-u7aTucqRXCMlFbIosaArYJBD2+s= +qs@~6.5.2: + version "6.5.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" + integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== + +query-string@^5.0.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.1.1.tgz#a78c012b71c17e05f2e3fa2319dd330682efb3cb" + integrity sha512-gjWOsm2SoGlgLEdAGt7a6slVOk9mGiXmPFMqrEhLQ68rhQuBnpfs3+EmlvqKyxnCo9/PPlF+9MtY02S1aFg+Jw== dependencies: + decode-uri-component "^0.2.0" object-assign "^4.1.0" strict-uri-encode "^1.0.0" @@ -4531,19 +4978,19 @@ randomatic@^3.0.0: kind-of "^6.0.0" math-random "^1.0.1" -range-parser@~1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.0.tgz#f49be6b487894ddc40dcc94a322f611092e00d5e" - integrity sha1-9JvmtIeJTdxA3MlKMi9hEJLgDV4= +range-parser@~1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" + integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.3.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.3.3.tgz#1b324ece6b5706e153855bc1148c65bb7f6ea0c3" - integrity sha512-9esiElv1BrZoI3rCDuOuKCBRbuApGGaDPQfjSflGxdy4oyzqghxu6klEkkVIvBje+FF0BX9coEv8KqW6X/7njw== +raw-body@2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.4.0.tgz#a1ce6fb9c9bc356ca52e89256ab59059e13d0332" + integrity sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q== dependencies: - bytes "3.0.0" - http-errors "1.6.3" - iconv-lite "0.4.23" + bytes "3.1.0" + http-errors "1.7.2" + iconv-lite "0.4.24" unpipe "1.0.0" raw-body@~1.1.0: @@ -4554,16 +5001,6 @@ raw-body@~1.1.0: bytes "1" string_decoder "0.10" -rc@^1.1.2: - version "1.2.8" - resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" - integrity sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw== - dependencies: - deep-extend "^0.6.0" - ini "~1.3.0" - minimist "^1.2.0" - strip-json-comments "~2.0.1" - react-dev-utils@^5.0.2: version "5.0.3" resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-5.0.3.tgz#92f97668f03deb09d7fa11ea288832a8c756e35e" @@ -4613,14 +5050,6 @@ react@^16.5.0: prop-types "^15.6.2" scheduler "^0.12.0" -read-all-stream@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/read-all-stream/-/read-all-stream-3.1.0.tgz#35c3e177f2078ef789ee4bfafa4373074eaef4fa" - integrity sha1-NcPhd/IHjveJ7kv6+kNzB06u9Po= - dependencies: - pinkie-promise "^2.0.0" - readable-stream "^2.0.0" - read-pkg-up@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" @@ -4638,17 +5067,7 @@ read-pkg@^1.0.0: normalize-package-data "^2.3.2" path-type "^1.0.0" -"readable-stream@>=1.0.33-1 <1.1.0-0": - version "1.0.34" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" - integrity sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw= - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" - -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.5, readable-stream@~2.3.6: +readable-stream@^2.0.0, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.5: version "2.3.6" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== @@ -4670,15 +5089,12 @@ readable-stream@^3.0.6: string_decoder "^1.1.1" util-deprecate "^1.0.1" -readable-stream@~1.1.9: - version "1.1.14" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" - integrity sha1-fPTFTvZI44EwhMY23SB54WbAgdk= +readdirp@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.1.1.tgz#b158123ac343c8b0f31d65680269cc0fc1025db1" + integrity sha512-XXdSXZrQuvqoETj50+JAitxz1UPdt5dupjT6T5nVB+WvjMv2XKYj+s7hPeAVCXvmJrL36O4YYyWlIC3an2ePiQ== dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" + picomatch "^2.0.4" rechoir@^0.6.2: version "0.6.2" @@ -4702,22 +5118,6 @@ redent@^1.0.0: indent-string "^2.1.0" strip-indent "^1.0.1" -reduce-css-calc@^1.2.6: - version "1.3.0" - resolved "https://registry.yarnpkg.com/reduce-css-calc/-/reduce-css-calc-1.3.0.tgz#747c914e049614a4c9cfbba629871ad1d2927716" - integrity sha1-dHyRTgSWFKTJz7umKYca0dKSdxY= - dependencies: - balanced-match "^0.4.2" - math-expression-evaluator "^1.2.14" - reduce-function-call "^1.0.1" - -reduce-function-call@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/reduce-function-call/-/reduce-function-call-1.0.2.tgz#5a200bf92e0e37751752fe45b0ab330fd4b6be99" - integrity sha1-WiAL+S4ON3UXUv5FsKszD9S2vpk= - dependencies: - balanced-match "^0.4.2" - regenerate-unicode-properties@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-7.0.0.tgz#107405afcc4a190ec5ed450ecaa00ed0cafa7a4c" @@ -4742,12 +5142,13 @@ regenerator-transform@^0.13.3: dependencies: private "^0.1.6" -regex-cache@^0.4.2: - version "0.4.4" - resolved "https://registry.yarnpkg.com/regex-cache/-/regex-cache-0.4.4.tgz#75bdc58a2a1496cec48a12835bc54c8d562336dd" - integrity sha512-nVIZwtCjkC9YgvWkpM55B5rBhBYRZhAaJbgcFYXXsHnbZ9UZI9nnVWYZpBlCqv9ho2eZryPnWrZGsOdPwVWXWQ== +regex-not@^1.0.0, regex-not@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" + integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== dependencies: - is-equal-shallow "^0.1.3" + extend-shallow "^3.0.2" + safe-regex "^1.1.0" regexpu-core@^4.1.3, regexpu-core@^4.2.0: version "4.4.0" @@ -4781,11 +5182,6 @@ remarkable@^1.7.1: argparse "~0.1.15" autolinker "~0.15.0" -remove-trailing-separator@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" - integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= - repeat-element@^1.1.2: version "1.1.3" resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.3.tgz#782e0d825c0c5a3bb39731f84efee6b742e6b1ce" @@ -4803,11 +5199,6 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" -replace-ext@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-0.0.1.tgz#29bbd92078a739f0bcce2b4ee41e837953522924" - integrity sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ= - replace-ext@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" @@ -4852,6 +5243,16 @@ resolve-dir@^1.0.0: expand-tilde "^2.0.0" global-modules "^1.0.0" +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" + integrity sha1-six699nWiBvItuZTM17rywoYh0g= + +resolve-url@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" + integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= + resolve@^1.1.6, resolve@^1.3.2: version "1.9.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.9.0.tgz#a14c6fdfa8f92a7df1d996cb7105fa744658ea06" @@ -4859,6 +5260,13 @@ resolve@^1.1.6, resolve@^1.3.2: dependencies: path-parse "^1.0.6" +responselike@1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/responselike/-/responselike-1.0.2.tgz#918720ef3b631c5642be068f15ade5a46f4ba1e7" + integrity sha1-kYcg7ztjHFZCvgaPFa3lpG9Loec= + dependencies: + lowercase-keys "^1.0.0" + restore-cursor@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" @@ -4867,7 +5275,22 @@ restore-cursor@^2.0.0: onetime "^2.0.0" signal-exit "^3.0.2" -rimraf@^2.2.6, rimraf@^2.5.4: +ret@~0.1.10: + version "0.1.15" + resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" + integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== + +rgb-regex@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/rgb-regex/-/rgb-regex-1.0.1.tgz#c0e0d6882df0e23be254a475e8edd41915feaeb1" + integrity sha1-wODWiC3w4jviVKR16O3UGRX+rrE= + +rgba-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/rgba-regex/-/rgba-regex-1.0.0.tgz#43374e2e2ca0968b0ef1523460b7d730ff22eeb3" + integrity sha1-QzdOLiyglosO8VI0YLfXMP8i7rM= + +rimraf@^2.5.4: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" integrity sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w== @@ -4903,12 +5326,19 @@ safe-json-parse@~1.0.1: resolved "https://registry.yarnpkg.com/safe-json-parse/-/safe-json-parse-1.0.1.tgz#3e76723e38dfdda13c9b1d29a1e07ffee4b30b57" integrity sha1-PnZyPjjf3aE8mx0poeB//uSzC1c= +safe-regex@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" + integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= + dependencies: + ret "~0.1.10" + "safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== -sax@~1.2.1, sax@~1.2.4: +sax@~1.2.4: version "1.2.4" resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw== @@ -4921,7 +5351,7 @@ scheduler@^0.12.0: loose-envify "^1.1.0" object-assign "^4.1.1" -seek-bzip@^1.0.3: +seek-bzip@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/seek-bzip/-/seek-bzip-1.0.5.tgz#cfe917cb3d274bcffac792758af53173eb1fabdc" integrity sha1-z+kXyz0nS8/6x5J1ivUxc+sfq9w= @@ -4933,12 +5363,12 @@ select@^1.1.2: resolved "https://registry.yarnpkg.com/select/-/select-1.1.2.tgz#0e7350acdec80b1108528786ec1d4418d11b396d" integrity sha1-DnNQrN7ICxEIUoeG7B1EGNEbOW0= -semver-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/semver-regex/-/semver-regex-1.0.0.tgz#92a4969065f9c70c694753d55248fc68f8f652c9" - integrity sha1-kqSWkGX5xwxpR1PVUkj8aPj2Usk= +semver-regex@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/semver-regex/-/semver-regex-2.0.0.tgz#a93c2c5844539a770233379107b38c7b4ac9d338" + integrity sha512-mUdIBBvdn0PLOeP3TEkMH7HHeUP3GjsXCwKarjv/kGmUFOYg1VqEemKhoQpWMu6X2I8kHeuVdGibLGkVK+/5Qw== -semver-truncate@^1.0.0: +semver-truncate@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/semver-truncate/-/semver-truncate-1.1.2.tgz#57f41de69707a62709a7e0104ba2117109ea47e8" integrity sha1-V/Qd5pcHpicJp+AQS6IRcQnqR+g= @@ -4950,15 +5380,15 @@ semver-truncate@^1.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.6.0.tgz#7e74256fbaa49c75aa7c7a205cc22799cac80004" integrity sha512-RS9R6R35NYgQn++fkDWaOmqGoj4Ek9gGs+DPxNUZKuwE183xjJroKvyo1IzVFeXvUrvmALy6FWD5xrdJT25gMg== -semver@^4.0.3: - version "4.3.6" - resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" - integrity sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto= +semver@^5.6.0: + version "5.7.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" + integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== -send@0.16.2: - version "0.16.2" - resolved "https://registry.yarnpkg.com/send/-/send-0.16.2.tgz#6ecca1e0f8c156d141597559848df64730a6bbc1" - integrity sha512-E64YFPUssFHEFBvpbbjr44NCLtI1AohxQ8ZSiJjQLskAdKuriYEP6VyGEsRDH8ScozGpkaX1BGvhanqCwkcEZw== +send@0.17.1: + version "0.17.1" + resolved "https://registry.yarnpkg.com/send/-/send-0.17.1.tgz#c1d8b059f7900f7466dd4938bdc44e11ddb376c8" + integrity sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg== dependencies: debug "2.6.9" depd "~1.1.2" @@ -4967,22 +5397,22 @@ send@0.16.2: escape-html "~1.0.3" etag "~1.8.1" fresh "0.5.2" - http-errors "~1.6.2" - mime "1.4.1" - ms "2.0.0" + http-errors "~1.7.2" + mime "1.6.0" + ms "2.1.1" on-finished "~2.3.0" - range-parser "~1.2.0" - statuses "~1.4.0" + range-parser "~1.2.1" + statuses "~1.5.0" -serve-static@1.13.2: - version "1.13.2" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.13.2.tgz#095e8472fd5b46237db50ce486a43f4b86c6cec1" - integrity sha512-p/tdJrO4U387R9oMjb1oj7qSMaMfmOyd4j9hOFoxZe2baQszgHcSWjuya/CiT5kgZZKRudHNOA0pYXOl8rQ5nw== +serve-static@1.14.1: + version "1.14.1" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.14.1.tgz#666e636dc4f010f7ef29970a88a674320898b2f9" + integrity sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg== dependencies: encodeurl "~1.0.2" escape-html "~1.0.3" - parseurl "~1.3.2" - send "0.16.2" + parseurl "~1.3.3" + send "0.17.1" set-getter@^0.1.0: version "0.1.0" @@ -4991,15 +5421,20 @@ set-getter@^0.1.0: dependencies: to-object-path "^0.3.0" -set-immediate-shim@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz#4b2b1b27eb808a9f8dcc481a58e5e56f599f3f61" - integrity sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E= +set-value@^2.0.0, set-value@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b" + integrity sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw== + dependencies: + extend-shallow "^2.0.1" + is-extendable "^0.1.1" + is-plain-object "^2.0.3" + split-string "^3.0.1" -setprototypeof@1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.1.0.tgz#d0bd85536887b6fe7c0d818cb962d9d91c54e656" - integrity sha512-BvE/TwpZX4FXExxOxZyRGQQv651MSwmWKZGqvmPcRIjDqWub67kTKuIMx43cZZrS/cBBzwBcNDWoFxt2XEFIpQ== +setprototypeof@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.1.1.tgz#7e95acb24aa92f5885e0abef5ba131330d4ae683" + integrity sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw== shebang-command@^1.2.0: version "1.2.0" @@ -5023,10 +5458,10 @@ shell-quote@1.6.1: array-reduce "~0.0.0" jsonify "~0.0.0" -shelljs@^0.7.8: - version "0.7.8" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.7.8.tgz#decbcf874b0d1e5fb72e14b164a9683048e9acb3" - integrity sha1-3svPh0sNHl+3LhSxZKloMEjprLM= +shelljs@^0.8.3: + version "0.8.3" + resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.3.tgz#a7f3319520ebf09ee81275b2368adb286659b097" + integrity sha512-fc0BKlAWiLpwZljmOvAOTE/gXawtCoNrP5oaY7KIaQbbyHeQVg01pSEuEGvGh3HEdBU4baCD7wQBwADmM/7f7A== dependencies: glob "^7.0.0" interpret "^1.0.0" @@ -5052,6 +5487,41 @@ sitemap@^1.13.0: underscore "^1.7.0" url-join "^1.1.0" +slash@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" + integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= + +snapdragon-node@^2.0.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" + integrity sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw== + dependencies: + define-property "^1.0.0" + isobject "^3.0.0" + snapdragon-util "^3.0.1" + +snapdragon-util@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/snapdragon-util/-/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" + integrity sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ== + dependencies: + kind-of "^3.2.0" + +snapdragon@^0.8.1: + version "0.8.2" + resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" + integrity sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg== + dependencies: + base "^0.11.1" + debug "^2.2.0" + define-property "^0.2.5" + extend-shallow "^2.0.1" + map-cache "^0.2.2" + source-map "^0.5.6" + source-map-resolve "^0.5.0" + use "^3.1.0" + sockjs-client@1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/sockjs-client/-/sockjs-client-1.1.5.tgz#1bb7c0f7222c40f42adf14f4442cbd1269771a83" @@ -5064,6 +5534,13 @@ sockjs-client@1.1.5: json3 "^3.3.2" url-parse "^1.1.8" +sort-keys-length@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/sort-keys-length/-/sort-keys-length-1.0.1.tgz#9cb6f4f4e9e48155a6aa0671edd336ff1479a188" + integrity sha1-nLb09OnkgVWmqgZx7dM2/xR5oYg= + dependencies: + sort-keys "^1.0.0" + sort-keys@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/sort-keys/-/sort-keys-1.1.2.tgz#441b6d4d346798f1b4e49e8920adfba0e543f9ad" @@ -5071,6 +5548,24 @@ sort-keys@^1.0.0: dependencies: is-plain-obj "^1.0.0" +sort-keys@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/sort-keys/-/sort-keys-2.0.0.tgz#658535584861ec97d730d6cf41822e1f56684128" + integrity sha1-ZYU1WEhh7JfXMNbPQYIuH1ZoQSg= + dependencies: + is-plain-obj "^1.0.0" + +source-map-resolve@^0.5.0: + version "0.5.2" + resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.2.tgz#72e2cc34095543e43b2c62b2c4c10d4a9054f259" + integrity sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA== + dependencies: + atob "^2.1.1" + decode-uri-component "^0.2.0" + resolve-url "^0.2.1" + source-map-url "^0.4.0" + urix "^0.1.0" + source-map-support@^0.5.9: version "0.5.9" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.9.tgz#41bc953b2534267ea2d605bccfa7bfa3111ced5f" @@ -5079,6 +5574,11 @@ source-map-support@^0.5.9: buffer-from "^1.0.0" source-map "^0.6.0" +source-map-url@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" + integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= + source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" @@ -5089,11 +5589,6 @@ source-map@^0.6.0, source-map@^0.6.1: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== -sparkles@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.1.tgz#008db65edce6c50eec0c5e228e1945061dd0437c" - integrity sha512-dSO0DDYUahUt/0/pD/Is3VIm5TGJjludZ0HVymmhYF6eNA53PVLhnUk0znSYbH8IYBuJdCE+1luR22jNLMaQdw== - spdx-correct@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz#fb83e504445268f154b074e218c87c003cd31df4" @@ -5120,6 +5615,13 @@ spdx-license-ids@^3.0.0: resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.3.tgz#81c0ce8f21474756148bbb5f3bfc0f36bf15d76e" integrity sha512-uBIcIl3Ih6Phe3XHK1NqboJLdGfwr1UN3k6wSD1dZpmPsIkb8AGNbZYJ1fOBk834+Gxy8rpfDxrS6XLEMZMY2g== +split-string@^3.0.1, split-string@^3.0.2: + version "3.1.0" + resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" + integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw== + dependencies: + extend-shallow "^3.0.0" + sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" @@ -5149,39 +5651,24 @@ sshpk@^1.7.0: safer-buffer "^2.0.2" tweetnacl "~0.14.0" -stable@~0.1.6: +stable@^0.1.8, stable@~0.1.6: version "0.1.8" resolved "https://registry.yarnpkg.com/stable/-/stable-0.1.8.tgz#836eb3c8382fe2936feaf544631017ce7d47a3cf" integrity sha512-ji9qxRnOVfcuLDySj9qzhGSEFVobyt1kIOSkj1qZzYLzq7Tos/oUUWvotUPQLlrsidqsK6tBH89Bc9kL5zHA6w== -stat-mode@^0.2.0: - version "0.2.2" - resolved "https://registry.yarnpkg.com/stat-mode/-/stat-mode-0.2.2.tgz#e6c80b623123d7d80cf132ce538f346289072502" - integrity sha1-5sgLYjEj19gM8TLOU480YokHJQI= +static-extend@^0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" + integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= + dependencies: + define-property "^0.2.5" + object-copy "^0.1.0" -"statuses@>= 1.4.0 < 2": +"statuses@>= 1.5.0 < 2", statuses@~1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= -statuses@~1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.4.0.tgz#bb73d446da2796106efcc1b601a253d6c46bd087" - integrity sha512-zhSCtt8v2NDrRlPQpCNtw/heZLtfUDqxBM1udqikb/Hbk52LK4nQSwr10u77iopCW5LsyHpuXS0GnEc48mLeew== - -stream-combiner2@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/stream-combiner2/-/stream-combiner2-1.1.1.tgz#fb4d8a1420ea362764e21ad4780397bebcb41cbe" - integrity sha1-+02KFCDqNidk4hrUeAOXvry0HL4= - dependencies: - duplexer2 "~0.1.0" - readable-stream "^2.0.2" - -stream-shift@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" - integrity sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI= - strict-uri-encode@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713" @@ -5200,7 +5687,7 @@ string-width@^2.1.0: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" -string_decoder@0.10, string_decoder@~0.10.x: +string_decoder@0.10: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" integrity sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= @@ -5233,14 +5720,6 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" -strip-bom-stream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/strip-bom-stream/-/strip-bom-stream-1.0.0.tgz#e7144398577d51a6bed0fa1994fa05f43fd988ee" - integrity sha1-5xRDmFd9Uaa+0PoZlPoF9D/ZiO4= - dependencies: - first-chunk-stream "^1.0.0" - strip-bom "^2.0.0" - strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" @@ -5253,17 +5732,12 @@ strip-color@^0.1.0: resolved "https://registry.yarnpkg.com/strip-color/-/strip-color-0.1.0.tgz#106f65d3d3e6a2d9401cac0eb0ce8b8a702b4f7b" integrity sha1-EG9l09PmotlAHKwOsM6LinArT3s= -strip-dirs@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/strip-dirs/-/strip-dirs-1.1.1.tgz#960bbd1287844f3975a4558aa103a8255e2456a0" - integrity sha1-lgu9EoeETzl1pFWKoQOoJV4kVqA= +strip-dirs@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/strip-dirs/-/strip-dirs-2.1.0.tgz#4987736264fc344cf20f6c34aca9d13d1d4ed6c5" + integrity sha512-JOCxOeKLm2CAS73y/U4ZeZPTkE+gNVCzKt7Eox84Iej1LT/2pTWYpZKJuxwQpvX1LiZb1xokNR7RLfuBAa7T3g== dependencies: - chalk "^1.0.0" - get-stdin "^4.0.1" - is-absolute "^0.1.5" - is-natural-number "^2.0.0" - minimist "^1.1.0" - sum-up "^1.0.1" + is-natural-number "^4.0.1" strip-eof@^1.0.0: version "1.0.0" @@ -5277,11 +5751,6 @@ strip-indent@^1.0.1: dependencies: get-stdin "^4.0.1" -strip-json-comments@~2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= - strip-outer@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/strip-outer/-/strip-outer-1.0.1.tgz#b2fd2abf6604b9d1e6013057195df836b8a9d631" @@ -5289,25 +5758,20 @@ strip-outer@^1.0.0: dependencies: escape-string-regexp "^1.0.2" -sum-up@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/sum-up/-/sum-up-1.0.3.tgz#1c661f667057f63bcb7875aa1438bc162525156e" - integrity sha1-HGYfZnBX9jvLeHWqFDi8FiUlFW4= +stylehacks@^4.0.0: + version "4.0.3" + resolved "https://registry.yarnpkg.com/stylehacks/-/stylehacks-4.0.3.tgz#6718fcaf4d1e07d8a1318690881e8d96726a71d5" + integrity sha512-7GlLk9JwlElY4Y6a/rmbH2MhVlTyVmiJd1PfTCqFaIBEGMYNsrO/v3SeGTdhBThLg4Z+NbOk/qFMwCa+J+3p/g== dependencies: - chalk "^1.0.0" + browserslist "^4.0.0" + postcss "^7.0.0" + postcss-selector-parser "^3.0.0" supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= -supports-color@^3.2.3: - version "3.2.3" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" - integrity sha1-ZawFBLOVQXHYpklGsq48u4pfVPY= - dependencies: - has-flag "^1.0.0" - supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" @@ -5315,18 +5779,12 @@ supports-color@^5.3.0, supports-color@^5.5.0: dependencies: has-flag "^3.0.0" -svgo@^0.7.0: - version "0.7.2" - resolved "https://registry.yarnpkg.com/svgo/-/svgo-0.7.2.tgz#9f5772413952135c6fefbf40afe6a4faa88b4bb5" - integrity sha1-n1dyQTlSE1xv779Ar+ak+qiLS7U= +supports-color@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-6.1.0.tgz#0764abc69c63d5ac842dd4867e8d025e880df8f3" + integrity sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ== dependencies: - coa "~1.0.1" - colors "~1.1.2" - csso "~2.3.1" - js-yaml "~3.7.0" - mkdirp "~0.5.1" - sax "~1.2.1" - whet.extend "~0.9.9" + has-flag "^3.0.0" svgo@^1.0.0: version "1.1.1" @@ -5348,7 +5806,27 @@ svgo@^1.0.0: unquote "~1.1.1" util.promisify "~1.0.0" -tar-stream@^1.1.1: +svgo@^1.0.5: + version "1.2.2" + resolved "https://registry.yarnpkg.com/svgo/-/svgo-1.2.2.tgz#0253d34eccf2aed4ad4f283e11ee75198f9d7316" + integrity sha512-rAfulcwp2D9jjdGu+0CuqlrAUin6bBWrpoqXWwKDZZZJfXcUXQSxLJOFJCQCSA0x0pP2U0TxSlJu2ROq5Bq6qA== + dependencies: + chalk "^2.4.1" + coa "^2.0.2" + css-select "^2.0.0" + css-select-base-adapter "^0.1.1" + css-tree "1.0.0-alpha.28" + css-url-regex "^1.1.0" + csso "^3.5.1" + js-yaml "^3.13.1" + mkdirp "~0.5.1" + object.values "^1.1.0" + sax "~1.2.4" + stable "^0.1.8" + unquote "~1.1.1" + util.promisify "~1.0.0" + +tar-stream@^1.5.2: version "1.6.2" resolved "https://registry.yarnpkg.com/tar-stream/-/tar-stream-1.6.2.tgz#8ea55dab37972253d9a9af90fdcd559ae435c555" integrity sha512-rzS0heiNf8Xn7/mpdSVVSMAWAoy9bfb1WOTYC78Z0UQKeKa/CWS8FOq0lKGNa8DWKAn9gxjCvMLYc5PGXYlK2A== @@ -5375,14 +5853,6 @@ temp-dir@^1.0.0: resolved "https://registry.yarnpkg.com/temp-dir/-/temp-dir-1.0.0.tgz#0a7c0ea26d3a39afa7e0ebea9c1fc0bc4daa011d" integrity sha1-CnwOom06Oa+n4OvqnB/AvE2qAR0= -tempfile@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/tempfile/-/tempfile-1.1.1.tgz#5bcc4eaecc4ab2c707d8bc11d99ccc9a2cb287f2" - integrity sha1-W8xOrsxKsscH2LwR2ZzMmiyyh/I= - dependencies: - os-tmpdir "^1.0.0" - uuid "^2.0.1" - tempfile@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/tempfile/-/tempfile-2.0.0.tgz#6b0446856a9b1114d1856ffcbe509cccb0977265" @@ -5396,52 +5866,20 @@ text-table@0.2.0: resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= -through2-filter@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-2.0.0.tgz#60bc55a0dacb76085db1f9dae99ab43f83d622ec" - integrity sha1-YLxVoNrLdghdsfna6Zq0P4PWIuw= - dependencies: - through2 "~2.0.0" - xtend "~4.0.0" - -through2-filter@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-3.0.0.tgz#700e786df2367c2c88cd8aa5be4cf9c1e7831254" - integrity sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA== - dependencies: - through2 "~2.0.0" - xtend "~4.0.0" - -through2@^0.6.0, through2@^0.6.1: - version "0.6.5" - resolved "https://registry.yarnpkg.com/through2/-/through2-0.6.5.tgz#41ab9c67b29d57209071410e1d7a7a968cd3ad48" - integrity sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg= - dependencies: - readable-stream ">=1.0.33-1 <1.1.0-0" - xtend ">=4.0.0 <4.1.0-0" - -through2@^2.0.0, through2@~2.0.0: - version "2.0.5" - resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" - integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== - dependencies: - readable-stream "~2.3.6" - xtend "~4.0.1" - -through@^2.3.6: +through@^2.3.6, through@^2.3.8: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= -time-stamp@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" - integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= +timed-out@^4.0.0, timed-out@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-4.0.1.tgz#f32eacac5a175bea25d7fab565ab3ed8741ef56f" + integrity sha1-8y6srFoXW+ol1/q1Zas+2HQe9W8= -timed-out@^3.0.0: - version "3.1.3" - resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-3.1.3.tgz#95860bfcc5c76c277f8f8326fd0f5b2e20eba217" - integrity sha1-lYYL/MXHbCd/j4Mm/Q9bLiDrohc= +timsort@^0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/timsort/-/timsort-0.3.0.tgz#405411a8e7e6339fe64db9a234de11dc31e02bd4" + integrity sha1-QFQRqOfmM5/mTbmiNN4R3DHgK9Q= tiny-emitter@^2.0.0: version "2.0.2" @@ -5467,13 +5905,6 @@ tmp@^0.0.33: dependencies: os-tmpdir "~1.0.2" -to-absolute-glob@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-0.1.1.tgz#1cdfa472a9ef50c239ee66999b662ca0eb39937f" - integrity sha1-HN+kcqnvUMI57maZm2YsoOs5k38= - dependencies: - extend-shallow "^2.0.1" - to-buffer@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/to-buffer/-/to-buffer-1.1.1.tgz#493bd48f62d7c43fcded313a03dcadb2e1213a80" @@ -5491,6 +5922,36 @@ to-object-path@^0.3.0: dependencies: kind-of "^3.0.2" +to-regex-range@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" + integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= + dependencies: + is-number "^3.0.0" + repeat-string "^1.6.1" + +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== + dependencies: + is-number "^7.0.0" + +to-regex@^3.0.1, to-regex@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" + integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== + dependencies: + define-property "^2.0.2" + extend-shallow "^3.0.2" + regex-not "^1.0.2" + safe-regex "^1.1.0" + +toidentifier@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553" + integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw== + toml@^2.3.2: version "2.3.3" resolved "https://registry.yarnpkg.com/toml/-/toml-2.3.3.tgz#8d683d729577cb286231dfc7a8affe58d31728fb" @@ -5536,11 +5997,6 @@ truncate-html@^1.0.1: "@types/cheerio" "^0.22.8" cheerio "0.22.0" -tunnel-agent@^0.4.0: - version "0.4.3" - resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.4.3.tgz#6373db76909fe570e08d73583365ed828a74eeeb" - integrity sha1-Y3PbdpCf5XDgjXNYM2Xtgop07us= - tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" @@ -5553,19 +6009,27 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0: resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= -type-is@~1.6.16: - version "1.6.16" - resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.16.tgz#f89ce341541c672b25ee7ae3c73dee3b2be50194" - integrity sha512-HRkVv/5qY2G6I8iab9cI7v1bOIdhm94dVjQCPFElW9W+3GeDOSHmy2EBYe4VTApuzolPcmgFTN3ftVJRKR2J9Q== +type-is@~1.6.17, type-is@~1.6.18: + version "1.6.18" + resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.18.tgz#4e552cd05df09467dcbc4ef739de89f2cf37c131" + integrity sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g== dependencies: media-typer "0.3.0" - mime-types "~2.1.18" + mime-types "~2.1.24" typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= +unbzip2-stream@^1.0.9: + version "1.3.3" + resolved "https://registry.yarnpkg.com/unbzip2-stream/-/unbzip2-stream-1.3.3.tgz#d156d205e670d8d8c393e1c02ebd506422873f6a" + integrity sha512-fUlAF7U9Ah1Q6EieQ4x4zLNejrRvDWUYmxXUpN3uziFYCHapjWFaCAnreY9bGgxzaMCFAPPpYNng57CypwJVhg== + dependencies: + buffer "^5.2.1" + through "^2.3.8" + underscore.string@~2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/underscore.string/-/underscore.string-2.4.0.tgz#8cdd8fbac4e2d2ea1e7e2e8097c42f442280f85b" @@ -5604,6 +6068,16 @@ unicode-property-aliases-ecmascript@^1.0.4: resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.4.tgz#5a533f31b4317ea76f17d807fa0d116546111dd0" integrity sha512-2WSLa6OdYd2ng8oqiGIWnJqyFArvhn+5vgx5GTxMbUYjCYKUcuKS62YLFF0R/BDGlB1yzXjQOLtPAfHsgirEpg== +union-value@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" + integrity sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg== + dependencies: + arr-union "^3.1.0" + get-value "^2.0.6" + is-extendable "^0.1.1" + set-value "^2.0.1" + uniq@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/uniq/-/uniq-1.0.1.tgz#b31c5ae8254844a3a8281541ce2b04b865a734ff" @@ -5614,14 +6088,6 @@ uniqs@^2.0.0: resolved "https://registry.yarnpkg.com/uniqs/-/uniqs-2.0.0.tgz#ffede4b36b25290696e6e165d4a59edb998e6b02" integrity sha1-/+3ks2slKQaW5uFl1KWe25mOawI= -unique-stream@^2.0.2: - version "2.3.1" - resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac" - integrity sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A== - dependencies: - json-stable-stringify-without-jsonify "^1.0.1" - through2-filter "^3.0.0" - universalify@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" @@ -5637,10 +6103,13 @@ unquote@~1.1.1: resolved "https://registry.yarnpkg.com/unquote/-/unquote-1.1.1.tgz#8fded7324ec6e88a0ff8b905e7c098cdc086d544" integrity sha1-j97XMk7G6IoP+LkF58CYzcCG1UQ= -unzip-response@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/unzip-response/-/unzip-response-1.0.2.tgz#b984f0877fc0a89c2c773cc1ef7b5b232b5b06fe" - integrity sha1-uYTwh3/AqJwsdzzB73tbIytbBv4= +unset-value@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/unset-value/-/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" + integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= + dependencies: + has-value "^0.3.1" + isobject "^3.0.0" uri-js@^4.2.2: version "4.2.2" @@ -5649,6 +6118,11 @@ uri-js@^4.2.2: dependencies: punycode "^2.1.0" +urix@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" + integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= + url-join@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/url-join/-/url-join-1.1.0.tgz#741c6c2f4596c4830d6718460920d0c92202dc78" @@ -5661,6 +6135,13 @@ url-parse-lax@^1.0.0: dependencies: prepend-http "^1.0.1" +url-parse-lax@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/url-parse-lax/-/url-parse-lax-3.0.0.tgz#16b5cafc07dbe3676c1b1999177823d6503acb0c" + integrity sha1-FrXK/Afb42dsGxmZF3gj1lA6yww= + dependencies: + prepend-http "^2.0.0" + url-parse@^1.1.8, url-parse@^1.4.3: version "1.4.4" resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.4.4.tgz#cac1556e95faa0303691fec5cf9d5a1bc34648f8" @@ -5669,12 +6150,15 @@ url-parse@^1.1.8, url-parse@^1.4.3: querystringify "^2.0.0" requires-port "^1.0.0" -url-regex@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/url-regex/-/url-regex-3.2.0.tgz#dbad1e0c9e29e105dd0b1f09f6862f7fdb482724" - integrity sha1-260eDJ4p4QXdCx8J9oYvf9tIJyQ= - dependencies: - ip-regex "^1.0.1" +url-to-options@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/url-to-options/-/url-to-options-1.0.1.tgz#1505a03a289a48cbd7a434efbaeec5055f5633a9" + integrity sha1-FQWgOiiaSMvXpDTvuu7FBV9WM6k= + +use@^3.1.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" + integrity sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ== util-deprecate@^1.0.1, util-deprecate@~1.0.1: version "1.0.2" @@ -5694,21 +6178,11 @@ utils-merge@1.0.1: resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= -uuid@^2.0.1: - version "2.0.3" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-2.0.3.tgz#67e2e863797215530dff318e5bf9dcebfd47b21a" - integrity sha1-Z+LoY3lyFVMN/zGOW/nc6/1Hsho= - uuid@^3.0.1, uuid@^3.3.2: version "3.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== -vali-date@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/vali-date/-/vali-date-1.0.0.tgz#1b904a59609fb328ef078138420934f6b86709a6" - integrity sha1-G5BKWWCfsyjvB4E4Qgk09rhnCaY= - validate-npm-package-license@^3.0.1: version "3.0.4" resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" @@ -5736,70 +6210,6 @@ verror@1.10.0: core-util-is "1.0.2" extsprintf "^1.2.0" -vinyl-assign@^1.0.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/vinyl-assign/-/vinyl-assign-1.2.1.tgz#4d198891b5515911d771a8cd9c5480a46a074a45" - integrity sha1-TRmIkbVRWRHXcajNnFSApGoHSkU= - dependencies: - object-assign "^4.0.1" - readable-stream "^2.0.0" - -vinyl-fs@^2.2.0: - version "2.4.4" - resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-2.4.4.tgz#be6ff3270cb55dfd7d3063640de81f25d7532239" - integrity sha1-vm/zJwy1Xf19MGNkDegfJddTIjk= - dependencies: - duplexify "^3.2.0" - glob-stream "^5.3.2" - graceful-fs "^4.0.0" - gulp-sourcemaps "1.6.0" - is-valid-glob "^0.3.0" - lazystream "^1.0.0" - lodash.isequal "^4.0.0" - merge-stream "^1.0.0" - mkdirp "^0.5.0" - object-assign "^4.0.0" - readable-stream "^2.0.4" - strip-bom "^2.0.0" - strip-bom-stream "^1.0.0" - through2 "^2.0.0" - through2-filter "^2.0.0" - vali-date "^1.0.0" - vinyl "^1.0.0" - -vinyl@^0.4.3: - version "0.4.6" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.4.6.tgz#2f356c87a550a255461f36bbeb2a5ba8bf784847" - integrity sha1-LzVsh6VQolVGHza76ypbqL94SEc= - dependencies: - clone "^0.2.0" - clone-stats "^0.0.1" - -vinyl@^0.5.0: - version "0.5.3" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.5.3.tgz#b0455b38fc5e0cf30d4325132e461970c2091cde" - integrity sha1-sEVbOPxeDPMNQyUTLkYZcMIJHN4= - dependencies: - clone "^1.0.0" - clone-stats "^0.0.1" - replace-ext "0.0.1" - -vinyl@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-1.2.0.tgz#5c88036cf565e5df05558bfc911f8656df218884" - integrity sha1-XIgDbPVl5d8FVYv8kR+GVt8hiIQ= - dependencies: - clone "^1.0.0" - clone-stats "^0.0.1" - replace-ext "0.0.1" - -ware@^1.2.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/ware/-/ware-1.3.0.tgz#d1b14f39d2e2cb4ab8c4098f756fe4b164e473d4" - integrity sha1-0bFPOdLiy0q4xAmPdW/ksWTkc9Q= - dependencies: - wrap-fn "^0.1.0" - websocket-driver@>=0.5.1: version "0.7.0" resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.0.tgz#0caf9d2d755d93aee049d4bdd0d3fe2cca2a24eb" @@ -5813,11 +6223,6 @@ websocket-extensions@>=0.1.1: resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.3.tgz#5d2ff22977003ec687a4b87073dfbbac146ccf29" integrity sha512-nqHUnMXmBzT0w570r2JpJxfiSD1IzoI+HGVdd3aZ0yNi3ngvQ4jv1dtHt5VGxfI2yj5yqImPhOK4vmIh2xMbGg== -whet.extend@~0.9.9: - version "0.9.9" - resolved "https://registry.yarnpkg.com/whet.extend/-/whet.extend-0.9.9.tgz#f877d5bf648c97e5aa542fadc16d6a259b9c11a1" - integrity sha1-+HfVv2SMl+WqVC+twW1qJZucEaE= - which@^1.2.14, which@^1.2.9: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" @@ -5830,13 +6235,6 @@ wordwrap@0.0.2: resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.2.tgz#b79669bb42ecb409f83d583cad52ca17eaa1643f" integrity sha1-t5Zpu0LstAn4PVg8rVLKF+qhZD8= -wrap-fn@^0.1.0: - version "0.1.5" - resolved "https://registry.yarnpkg.com/wrap-fn/-/wrap-fn-0.1.5.tgz#f21b6e41016ff4a7e31720dbc63a09016bdf9845" - integrity sha1-8htuQQFv9KfjFyDbxjoJAWvfmEU= - dependencies: - co "3.1.0" - wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" @@ -5847,7 +6245,7 @@ xml@^1.0.1: resolved "https://registry.yarnpkg.com/xml/-/xml-1.0.1.tgz#78ba72020029c5bc87b8a81a3cfcd74b4a2fc1e5" integrity sha1-eLpyAgApxbyHuKgaPPzXS0ovweU= -"xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@~4.0.0, xtend@~4.0.1: +xtend@^4.0.0, xtend@~4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" integrity sha1-pcbVMr5lbiPbgg77lDofBJmNY68= @@ -5872,7 +6270,7 @@ yargs@^2.3.0: dependencies: wordwrap "0.0.2" -yauzl@^2.2.1: +yauzl@^2.4.2: version "2.10.0" resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.10.0.tgz#c7eb17c93e112cb1086fa6d8e51fb0667b79a5f9" integrity sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk= From c1df082d65a070c73072cb22cb45d3ca9947a3ac Mon Sep 17 00:00:00 2001 From: "Mateusz Szychowski (Muttley)" Date: Sat, 13 Jul 2019 13:31:14 +0200 Subject: [PATCH 10/62] [C++][Pistache] Add compatibility for nlohmann-json 3.5.0 (#3306) * [C++][Pistache] Replace contains with find on json object This makes generator compatible with nlohmann-json 3.5.0 * [C++][Pistache] Update Petstore sample --- .../cpp-pistache-server/model-source.mustache | 2 +- .../petstore/cpp-pistache/model/ApiResponse.cpp | 6 +++--- .../petstore/cpp-pistache/model/Category.cpp | 4 ++-- .../cpp-pistache/model/Inline_object.cpp | 4 ++-- .../cpp-pistache/model/Inline_object_1.cpp | 4 ++-- .../server/petstore/cpp-pistache/model/Order.cpp | 12 ++++++------ .../server/petstore/cpp-pistache/model/Pet.cpp | 8 ++++---- .../server/petstore/cpp-pistache/model/Tag.cpp | 4 ++-- .../server/petstore/cpp-pistache/model/User.cpp | 16 ++++++++-------- 9 files changed, 30 insertions(+), 30 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/cpp-pistache-server/model-source.mustache b/modules/openapi-generator/src/main/resources/cpp-pistache-server/model-source.mustache index c58a2fc79a..e69d65cafc 100644 --- a/modules/openapi-generator/src/main/resources/cpp-pistache-server/model-source.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-pistache-server/model-source.mustache @@ -37,7 +37,7 @@ void to_json(nlohmann::json& j, const {{classname}}& o) void from_json(const nlohmann::json& j, {{classname}}& o) { {{#vars}} - {{#required}}j.at("{{baseName}}").get_to(o.m_{{name}});{{/required}}{{^required}}if(j.contains("{{baseName}}")) + {{#required}}j.at("{{baseName}}").get_to(o.m_{{name}});{{/required}}{{^required}}if(j.find("{{baseName}}") != j.end()) { j.at("{{baseName}}").get_to(o.m_{{name}}); o.m_{{name}}IsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp b/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp index a78fb1cc7f..77cd466e14 100644 --- a/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp +++ b/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp @@ -51,17 +51,17 @@ void to_json(nlohmann::json& j, const ApiResponse& o) void from_json(const nlohmann::json& j, ApiResponse& o) { - if(j.contains("code")) + if(j.find("code") != j.end()) { j.at("code").get_to(o.m_Code); o.m_CodeIsSet = true; } - if(j.contains("type")) + if(j.find("type") != j.end()) { j.at("type").get_to(o.m_Type); o.m_TypeIsSet = true; } - if(j.contains("message")) + if(j.find("message") != j.end()) { j.at("message").get_to(o.m_Message); o.m_MessageIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Category.cpp b/samples/server/petstore/cpp-pistache/model/Category.cpp index 2abb0c3c5e..43ff1d4900 100644 --- a/samples/server/petstore/cpp-pistache/model/Category.cpp +++ b/samples/server/petstore/cpp-pistache/model/Category.cpp @@ -47,12 +47,12 @@ void to_json(nlohmann::json& j, const Category& o) void from_json(const nlohmann::json& j, Category& o) { - if(j.contains("id")) + if(j.find("id") != j.end()) { j.at("id").get_to(o.m_Id); o.m_IdIsSet = true; } - if(j.contains("name")) + if(j.find("name") != j.end()) { j.at("name").get_to(o.m_Name); o.m_NameIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Inline_object.cpp b/samples/server/petstore/cpp-pistache/model/Inline_object.cpp index ebb3130390..89638a8456 100644 --- a/samples/server/petstore/cpp-pistache/model/Inline_object.cpp +++ b/samples/server/petstore/cpp-pistache/model/Inline_object.cpp @@ -47,12 +47,12 @@ void to_json(nlohmann::json& j, const Inline_object& o) void from_json(const nlohmann::json& j, Inline_object& o) { - if(j.contains("name")) + if(j.find("name") != j.end()) { j.at("name").get_to(o.m_Name); o.m_NameIsSet = true; } - if(j.contains("status")) + if(j.find("status") != j.end()) { j.at("status").get_to(o.m_Status); o.m_StatusIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Inline_object_1.cpp b/samples/server/petstore/cpp-pistache/model/Inline_object_1.cpp index d5ffe1fef8..0da3bdba2b 100644 --- a/samples/server/petstore/cpp-pistache/model/Inline_object_1.cpp +++ b/samples/server/petstore/cpp-pistache/model/Inline_object_1.cpp @@ -46,12 +46,12 @@ void to_json(nlohmann::json& j, const Inline_object_1& o) void from_json(const nlohmann::json& j, Inline_object_1& o) { - if(j.contains("additionalMetadata")) + if(j.find("additionalMetadata") != j.end()) { j.at("additionalMetadata").get_to(o.m_AdditionalMetadata); o.m_AdditionalMetadataIsSet = true; } - if(j.contains("file")) + if(j.find("file") != j.end()) { j.at("file").get_to(o.m_file); o.m_fileIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Order.cpp b/samples/server/petstore/cpp-pistache/model/Order.cpp index b24cc0fce9..82efbce6cb 100644 --- a/samples/server/petstore/cpp-pistache/model/Order.cpp +++ b/samples/server/petstore/cpp-pistache/model/Order.cpp @@ -63,32 +63,32 @@ void to_json(nlohmann::json& j, const Order& o) void from_json(const nlohmann::json& j, Order& o) { - if(j.contains("id")) + if(j.find("id") != j.end()) { j.at("id").get_to(o.m_Id); o.m_IdIsSet = true; } - if(j.contains("petId")) + if(j.find("petId") != j.end()) { j.at("petId").get_to(o.m_PetId); o.m_PetIdIsSet = true; } - if(j.contains("quantity")) + if(j.find("quantity") != j.end()) { j.at("quantity").get_to(o.m_Quantity); o.m_QuantityIsSet = true; } - if(j.contains("shipDate")) + if(j.find("shipDate") != j.end()) { j.at("shipDate").get_to(o.m_ShipDate); o.m_ShipDateIsSet = true; } - if(j.contains("status")) + if(j.find("status") != j.end()) { j.at("status").get_to(o.m_Status); o.m_StatusIsSet = true; } - if(j.contains("complete")) + if(j.find("complete") != j.end()) { j.at("complete").get_to(o.m_Complete); o.m_CompleteIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Pet.cpp b/samples/server/petstore/cpp-pistache/model/Pet.cpp index 7781e283ce..1bceb861ad 100644 --- a/samples/server/petstore/cpp-pistache/model/Pet.cpp +++ b/samples/server/petstore/cpp-pistache/model/Pet.cpp @@ -56,24 +56,24 @@ void to_json(nlohmann::json& j, const Pet& o) void from_json(const nlohmann::json& j, Pet& o) { - if(j.contains("id")) + if(j.find("id") != j.end()) { j.at("id").get_to(o.m_Id); o.m_IdIsSet = true; } - if(j.contains("category")) + if(j.find("category") != j.end()) { j.at("category").get_to(o.m_Category); o.m_CategoryIsSet = true; } j.at("name").get_to(o.m_Name); j.at("photoUrls").get_to(o.m_PhotoUrls); - if(j.contains("tags")) + if(j.find("tags") != j.end()) { j.at("tags").get_to(o.m_Tags); o.m_TagsIsSet = true; } - if(j.contains("status")) + if(j.find("status") != j.end()) { j.at("status").get_to(o.m_Status); o.m_StatusIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/Tag.cpp b/samples/server/petstore/cpp-pistache/model/Tag.cpp index b81cb82572..7f56fb2bcc 100644 --- a/samples/server/petstore/cpp-pistache/model/Tag.cpp +++ b/samples/server/petstore/cpp-pistache/model/Tag.cpp @@ -47,12 +47,12 @@ void to_json(nlohmann::json& j, const Tag& o) void from_json(const nlohmann::json& j, Tag& o) { - if(j.contains("id")) + if(j.find("id") != j.end()) { j.at("id").get_to(o.m_Id); o.m_IdIsSet = true; } - if(j.contains("name")) + if(j.find("name") != j.end()) { j.at("name").get_to(o.m_Name); o.m_NameIsSet = true; diff --git a/samples/server/petstore/cpp-pistache/model/User.cpp b/samples/server/petstore/cpp-pistache/model/User.cpp index 66a026e9c7..20ae06352f 100644 --- a/samples/server/petstore/cpp-pistache/model/User.cpp +++ b/samples/server/petstore/cpp-pistache/model/User.cpp @@ -71,42 +71,42 @@ void to_json(nlohmann::json& j, const User& o) void from_json(const nlohmann::json& j, User& o) { - if(j.contains("id")) + if(j.find("id") != j.end()) { j.at("id").get_to(o.m_Id); o.m_IdIsSet = true; } - if(j.contains("username")) + if(j.find("username") != j.end()) { j.at("username").get_to(o.m_Username); o.m_UsernameIsSet = true; } - if(j.contains("firstName")) + if(j.find("firstName") != j.end()) { j.at("firstName").get_to(o.m_FirstName); o.m_FirstNameIsSet = true; } - if(j.contains("lastName")) + if(j.find("lastName") != j.end()) { j.at("lastName").get_to(o.m_LastName); o.m_LastNameIsSet = true; } - if(j.contains("email")) + if(j.find("email") != j.end()) { j.at("email").get_to(o.m_Email); o.m_EmailIsSet = true; } - if(j.contains("password")) + if(j.find("password") != j.end()) { j.at("password").get_to(o.m_Password); o.m_PasswordIsSet = true; } - if(j.contains("phone")) + if(j.find("phone") != j.end()) { j.at("phone").get_to(o.m_Phone); o.m_PhoneIsSet = true; } - if(j.contains("userStatus")) + if(j.find("userStatus") != j.end()) { j.at("userStatus").get_to(o.m_UserStatus); o.m_UserStatusIsSet = true; From ee27a1ec2bbc8128858e3c8fd1313ec03bf5c6e6 Mon Sep 17 00:00:00 2001 From: yuji38kwmt Date: Sun, 14 Jul 2019 15:22:24 +0900 Subject: [PATCH 11/62] Update README.md (#3353) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit add "OpenAPI GeneratorでPythonのクライアントライブラリを作成した by yuji38kwmt" to "Presentations/Videos/Tutorials/Books" --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index bf3009ef6b..ab8bce4e67 100644 --- a/README.md +++ b/README.md @@ -595,6 +595,7 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - 2019-06-28 [Codewind OpenAPI Tools](https://marketplace.eclipse.org/content/codewind-openapi-tools) in [Eclipse Marketplace](https://marketplace.eclipse.org/) by IBM - 2019-06-29 [Codewind OpenAPI Tools](https://marketplace.visualstudio.com/items?itemName=IBM.codewind-openapi-tools) in [Visual Studio Marketplace](https://marketplace.visualstudio.com/) by IBM - 2019-07-04 - [REST API のためのコード生成入門 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh), [和田拓朗](https://github.com/taxpon) +- 2019-07-14 - [OpenAPI GeneratorでPythonのクライアントライブラリを作成した](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) ## [6 - About Us](#table-of-contents) From 41d5750ddb6f22d90b959ad9c6cb4305a1933366 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Bresson?= Date: Sun, 14 Jul 2019 12:06:44 +0200 Subject: [PATCH 12/62] [JaxRS-Spec] add openApiSpecFileLocation parameter (#3344) * [JaxRS-Spec] add openApiSpecFileLocation parameter * Update samples --- docs/generators/jaxrs-cxf-cdi.md | 1 + docs/generators/jaxrs-spec.md | 1 + .../languages/JavaJAXRSSpecServerCodegen.java | 37 +++- .../org/openapitools/codegen/TestUtils.java | 11 + .../jaxrs/JavaJAXRSSpecServerCodegenTest.java | 203 ++++++++++++++++-- 5 files changed, 236 insertions(+), 17 deletions(-) diff --git a/docs/generators/jaxrs-cxf-cdi.md b/docs/generators/jaxrs-cxf-cdi.md index ae4443c496..78d31c8573 100644 --- a/docs/generators/jaxrs-cxf-cdi.md +++ b/docs/generators/jaxrs-cxf-cdi.md @@ -51,4 +51,5 @@ sidebar_label: jaxrs-cxf-cdi |interfaceOnly|Whether to generate only API interface stubs without the server files.| |false| |returnResponse|Whether generate API interface should return javax.ws.rs.core.Response instead of a deserialized entity. Only useful if interfaceOnly is true.| |false| |useSwaggerAnnotations|Whether to generate Swagger annotations.| |true| +|openApiSpecFileLocation|Location where the file containing the spec will be generated in the output folder. No file generated when set to null or empty string.| |null| |useBeanValidation|Use BeanValidation API annotations| |true| diff --git a/docs/generators/jaxrs-spec.md b/docs/generators/jaxrs-spec.md index 9ea4207189..8d338ebfef 100644 --- a/docs/generators/jaxrs-spec.md +++ b/docs/generators/jaxrs-spec.md @@ -51,3 +51,4 @@ sidebar_label: jaxrs-spec |interfaceOnly|Whether to generate only API interface stubs without the server files.| |false| |returnResponse|Whether generate API interface should return javax.ws.rs.core.Response instead of a deserialized entity. Only useful if interfaceOnly is true.| |false| |useSwaggerAnnotations|Whether to generate Swagger annotations.| |true| +|openApiSpecFileLocation|Location where the file containing the spec will be generated in the output folder. No file generated when set to null or empty string.| |null| diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaJAXRSSpecServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaJAXRSSpecServerCodegen.java index 776915734a..8b7736fce3 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaJAXRSSpecServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaJAXRSSpecServerCodegen.java @@ -37,12 +37,14 @@ public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen { public static final String GENERATE_POM = "generatePom"; public static final String USE_SWAGGER_ANNOTATIONS = "useSwaggerAnnotations"; public static final String JACKSON = "jackson"; + public static final String OPEN_API_SPEC_FILE_LOCATION = "openApiSpecFileLocation"; private boolean interfaceOnly = false; private boolean returnResponse = false; private boolean generatePom = true; private boolean useSwaggerAnnotations = true; private boolean useJackson = false; + private String openApiSpecFileLocation = "src/main/openapi/openapi.yaml"; private String primaryResourceName; @@ -91,6 +93,7 @@ public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen { cliOptions.add(CliOption.newBoolean(INTERFACE_ONLY, "Whether to generate only API interface stubs without the server files.").defaultValue(String.valueOf(interfaceOnly))); cliOptions.add(CliOption.newBoolean(RETURN_RESPONSE, "Whether generate API interface should return javax.ws.rs.core.Response instead of a deserialized entity. Only useful if interfaceOnly is true.").defaultValue(String.valueOf(returnResponse))); cliOptions.add(CliOption.newBoolean(USE_SWAGGER_ANNOTATIONS, "Whether to generate Swagger annotations.", useSwaggerAnnotations)); + cliOptions.add(CliOption.newString(OPEN_API_SPEC_FILE_LOCATION, "Location where the file containing the spec will be generated in the output folder. No file generated when set to null or empty string.")); } @Override @@ -114,6 +117,10 @@ public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen { useSwaggerAnnotations = Boolean.valueOf(additionalProperties.get(USE_SWAGGER_ANNOTATIONS).toString()); } writePropertyBack(USE_SWAGGER_ANNOTATIONS, useSwaggerAnnotations); + if (additionalProperties.containsKey(OPEN_API_SPEC_FILE_LOCATION)) { + openApiSpecFileLocation = additionalProperties.get(OPEN_API_SPEC_FILE_LOCATION).toString(); + } + additionalProperties.put(OPEN_API_SPEC_FILE_LOCATION, openApiSpecFileLocation); useJackson = convertPropertyToBoolean(JACKSON); @@ -134,18 +141,38 @@ public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen { (sourceFolder + '/' + invokerPackage).replace(".", "/"), "RestApplication.java")); } - supportingFiles.add(new SupportingFile("openapi.mustache", - "src/main/openapi", - "openapi.yaml") - ); + if(StringUtils.isNotEmpty(openApiSpecFileLocation)) { + int index = openApiSpecFileLocation.lastIndexOf('/'); + String fileFolder; + String fileName; + if(index >= 0) { + fileFolder = openApiSpecFileLocation.substring(0, index); + fileName = openApiSpecFileLocation.substring(index + 1); + } else { + fileFolder = ""; + fileName = openApiSpecFileLocation; + } + supportingFiles.add(new SupportingFile("openapi.mustache", fileFolder, fileName)); + } } - @Override public String getName() { return "jaxrs-spec"; } + public String getOpenApiSpecFileLocation() { + return openApiSpecFileLocation; + } + + /** + * Location where the file containing the spec will be generated in the output folder. + * @param location location inside the output folder. No file generated when set to null or empty string. + */ + public void setOpenApiSpecFileLocation(String location) { + this.openApiSpecFileLocation = location; + } + @Override public void addOperationToGroup(String tag, String resourcePath, Operation operation, CodegenOperation co, Map> operations) { String basePath = resourcePath; diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/TestUtils.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/TestUtils.java index 65614c7e51..188d7d2b90 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/TestUtils.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/TestUtils.java @@ -1,5 +1,6 @@ package org.openapitools.codegen; +import static org.testng.Assert.assertFalse; import static org.testng.Assert.assertTrue; import io.swagger.parser.OpenAPIParser; @@ -70,4 +71,14 @@ public class TestUtils { } assertTrue(generatedFiles.containsKey(absoluteFilename), "File '" + absoluteFilename + "' was not fould in the list of generated files"); } + + public static void ensureDoesNotContainsFile(Map generatedFiles, File root, String filename) { + File file = new File(root, filename); + String absoluteFilename = file.getAbsolutePath().replace("\\", "/"); + if (generatedFiles.containsKey(absoluteFilename)) { + Assert.fail("File '" + absoluteFilename + "' exists in file in list:\n" + + generatedFiles.keySet().stream().sorted().collect(Collectors.joining(",\n"))); + } + assertFalse(generatedFiles.containsKey(absoluteFilename), "File '" + absoluteFilename + "' was fould in the list of generated files"); + } } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/jaxrs/JavaJAXRSSpecServerCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/jaxrs/JavaJAXRSSpecServerCodegenTest.java index 341d2456f4..e5a13ce839 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/jaxrs/JavaJAXRSSpecServerCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/jaxrs/JavaJAXRSSpecServerCodegenTest.java @@ -1,12 +1,24 @@ package org.openapitools.codegen.java.jaxrs; +import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.Operation; +import io.swagger.v3.oas.models.servers.Server; + +import org.openapitools.codegen.ClientOptInput; +import org.openapitools.codegen.CodegenConstants; import org.openapitools.codegen.CodegenOperation; +import org.openapitools.codegen.MockDefaultGenerator; +import org.openapitools.codegen.TestUtils; +import org.openapitools.codegen.config.CodegenConfigurator; +import org.openapitools.codegen.languages.AbstractJavaJAXRSServerCodegen; +import org.openapitools.codegen.languages.JavaClientCodegen; import org.openapitools.codegen.languages.JavaJAXRSSpecServerCodegen; import org.testng.Assert; import org.testng.annotations.BeforeMethod; import org.testng.annotations.Test; +import java.io.File; +import java.nio.file.Files; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -22,7 +34,79 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { public void before() { codegen = new JavaJAXRSSpecServerCodegen(); } - + + @Test + public void testInitialConfigValues() throws Exception { + final JavaJAXRSSpecServerCodegen codegen = new JavaJAXRSSpecServerCodegen(); + codegen.processOpts(); + + OpenAPI openAPI = new OpenAPI(); + openAPI.addServersItem(new Server().url("https://api.abcde.xy:8082/v2")); + codegen.preprocessOpenAPI(openAPI); + + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.HIDE_GENERATION_TIMESTAMP), Boolean.FALSE); + Assert.assertEquals(codegen.isHideGenerationTimestamp(), false); + Assert.assertEquals(codegen.modelPackage(), "org.openapitools.model"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.MODEL_PACKAGE), "org.openapitools.model"); + Assert.assertEquals(codegen.apiPackage(), "org.openapitools.api"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.API_PACKAGE), "org.openapitools.api"); + Assert.assertEquals(codegen.getInvokerPackage(), "org.openapitools.api"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.INVOKER_PACKAGE), "org.openapitools.api"); + Assert.assertEquals(codegen.additionalProperties().get(JavaJAXRSSpecServerCodegen.SERVER_PORT), "8082"); + Assert.assertEquals(codegen.getOpenApiSpecFileLocation(), "src/main/openapi/openapi.yaml"); + Assert.assertEquals(codegen.additionalProperties().get(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION), "src/main/openapi/openapi.yaml"); + } + + @Test + public void testSettersForConfigValues() throws Exception { + final JavaJAXRSSpecServerCodegen codegen = new JavaJAXRSSpecServerCodegen(); + codegen.setHideGenerationTimestamp(true); + codegen.setModelPackage("xx.yyyyyyyy.model"); + codegen.setApiPackage("xx.yyyyyyyy.api"); + codegen.setInvokerPackage("xx.yyyyyyyy.invoker"); + codegen.setOpenApiSpecFileLocation("src/main/resources/META-INF/openapi.yaml"); + codegen.processOpts(); + + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.HIDE_GENERATION_TIMESTAMP), Boolean.TRUE); + Assert.assertEquals(codegen.isHideGenerationTimestamp(), true); + Assert.assertEquals(codegen.modelPackage(), "xx.yyyyyyyy.model"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.MODEL_PACKAGE), "xx.yyyyyyyy.model"); + Assert.assertEquals(codegen.apiPackage(), "xx.yyyyyyyy.api"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.API_PACKAGE), "xx.yyyyyyyy.api"); + Assert.assertEquals(codegen.getInvokerPackage(), "xx.yyyyyyyy.invoker"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.INVOKER_PACKAGE), "xx.yyyyyyyy.invoker"); + Assert.assertEquals(codegen.getOpenApiSpecFileLocation(), "src/main/resources/META-INF/openapi.yaml"); + Assert.assertEquals(codegen.additionalProperties().get(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION), "src/main/resources/META-INF/openapi.yaml"); + } + + @Test + public void testAdditionalPropertiesPutForConfigValues() throws Exception { + final JavaJAXRSSpecServerCodegen codegen = new JavaJAXRSSpecServerCodegen(); + codegen.additionalProperties().put(CodegenConstants.HIDE_GENERATION_TIMESTAMP, "true"); + codegen.additionalProperties().put(CodegenConstants.MODEL_PACKAGE, "xyz.yyyyy.mmmmm.model"); + codegen.additionalProperties().put(CodegenConstants.API_PACKAGE, "xyz.yyyyy.aaaaa.api"); + codegen.additionalProperties().put(CodegenConstants.INVOKER_PACKAGE, "xyz.yyyyy.iiii.invoker"); + codegen.additionalProperties().put("serverPort", "8088"); + codegen.additionalProperties().put(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION, "openapi.yml"); + codegen.processOpts(); + + OpenAPI openAPI = new OpenAPI(); + openAPI.addServersItem(new Server().url("https://api.abcde.xy:8082/v2")); + codegen.preprocessOpenAPI(openAPI); + + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.HIDE_GENERATION_TIMESTAMP), Boolean.TRUE); + Assert.assertEquals(codegen.isHideGenerationTimestamp(), true); + Assert.assertEquals(codegen.modelPackage(), "xyz.yyyyy.mmmmm.model"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.MODEL_PACKAGE), "xyz.yyyyy.mmmmm.model"); + Assert.assertEquals(codegen.apiPackage(), "xyz.yyyyy.aaaaa.api"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.API_PACKAGE), "xyz.yyyyy.aaaaa.api"); + Assert.assertEquals(codegen.getInvokerPackage(), "xyz.yyyyy.iiii.invoker"); + Assert.assertEquals(codegen.additionalProperties().get(CodegenConstants.INVOKER_PACKAGE), "xyz.yyyyy.iiii.invoker"); + Assert.assertEquals(codegen.additionalProperties().get(AbstractJavaJAXRSServerCodegen.SERVER_PORT), "8088"); + Assert.assertEquals(codegen.getOpenApiSpecFileLocation(), "openapi.yml"); + Assert.assertEquals(codegen.additionalProperties().get(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION), "openapi.yml"); + } + /** * Test * {@link JavaJAXRSSpecServerCodegen#addOperationToGroup(String, String, Operation, CodegenOperation, Map)} for Resource with path "/" and set tag. @@ -33,14 +117,14 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { codegenOperation.operationId = "findPrimaryresource"; Operation operation = new Operation(); Map> operationList = new HashMap<>(); - + codegen.addOperationToGroup("Primaryresource", "/", operation, codegenOperation, operationList); - + Assert.assertEquals(operationList.size(), 1); Assert.assertTrue(operationList.containsKey("")); Assert.assertEquals(codegenOperation.baseName, "Primaryresource"); } - + /** * Test * {@link JavaJAXRSSpecServerCodegen#addOperationToGroup(String, String, Operation, CodegenOperation, Map)} for Resource with path param. @@ -51,14 +135,14 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { codegenOperation.operationId = "getPrimaryresource"; Operation operation = new Operation(); Map> operationList = new HashMap<>(); - + codegen.addOperationToGroup("Primaryresource", "/{uuid}", operation, codegenOperation, operationList); - + Assert.assertEquals(operationList.size(), 1); Assert.assertTrue(operationList.containsKey("")); Assert.assertEquals(codegenOperation.baseName, "Primaryresource"); } - + /** * Test * {@link JavaJAXRSSpecServerCodegen#addOperationToGroup(String, String, @@ -70,14 +154,14 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { codegenOperation.path = "/subresource"; Operation operation = new Operation(); Map> operationList = new HashMap<>(); - + codegen.addOperationToGroup("Default", "/subresource", operation, codegenOperation, operationList); - + Assert.assertEquals(codegenOperation.baseName, "subresource"); Assert.assertEquals(operationList.size(), 1); Assert.assertTrue(operationList.containsKey("subresource")); } - + /** * Test {@link JavaJAXRSSpecServerCodegen#toApiName(String)} with subresource. */ @@ -86,7 +170,7 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { final String subresource = codegen.toApiName("subresource"); Assert.assertEquals(subresource, "SubresourceApi"); } - + /** * Test {@link JavaJAXRSSpecServerCodegen#toApiName(String)} with primary resource. */ @@ -97,8 +181,103 @@ public class JavaJAXRSSpecServerCodegenTest extends JavaJaxrsBaseTest { Operation operation = new Operation(); Map> operationList = new HashMap<>(); codegen.addOperationToGroup("Primaryresource", "/", operation, codegenOperation, operationList); - + final String subresource = codegen.toApiName(""); Assert.assertEquals(subresource, "PrimaryresourceApi"); } + + @Test + public void testGeneratePingDefaultLocation() throws Exception { + Map properties = new HashMap<>(); + properties.put(JavaClientCodegen.JAVA8_MODE, true); + + File output = Files.createTempDirectory("test").toFile(); + + final CodegenConfigurator configurator = new CodegenConfigurator() + .setGeneratorName("jaxrs-spec") + .setAdditionalProperties(properties) + .setInputSpec("src/test/resources/3_0/ping.yaml") + .setOutputDir(output.getAbsolutePath().replace("\\", "/")); + + final ClientOptInput clientOptInput = configurator.toClientOptInput(); + MockDefaultGenerator generator = new MockDefaultGenerator(); + generator.opts(clientOptInput).generate(); + + Map generatedFiles = generator.getFiles(); + TestUtils.ensureContainsFile(generatedFiles, output, "src/main/openapi/openapi.yaml"); + + output.deleteOnExit(); + } + + @Test + public void testGeneratePingNoSpecFile() throws Exception { + Map properties = new HashMap<>(); + properties.put(JavaClientCodegen.JAVA8_MODE, true); + properties.put(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION, ""); + + File output = Files.createTempDirectory("test").toFile(); + + final CodegenConfigurator configurator = new CodegenConfigurator() + .setGeneratorName("jaxrs-spec") + .setAdditionalProperties(properties) + .setInputSpec("src/test/resources/3_0/ping.yaml") + .setOutputDir(output.getAbsolutePath().replace("\\", "/")); + + final ClientOptInput clientOptInput = configurator.toClientOptInput(); + MockDefaultGenerator generator = new MockDefaultGenerator(); + generator.opts(clientOptInput).generate(); + + Map generatedFiles = generator.getFiles(); + TestUtils.ensureDoesNotContainsFile(generatedFiles, output, "src/main/openapi/openapi.yaml"); + + output.deleteOnExit(); + } + + @Test + public void testGeneratePingAlternativeLocation1() throws Exception { + Map properties = new HashMap<>(); + properties.put(JavaClientCodegen.JAVA8_MODE, true); + properties.put(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION, "src/main/resources/META-INF/openapi.yaml"); + + File output = Files.createTempDirectory("test").toFile(); + + final CodegenConfigurator configurator = new CodegenConfigurator() + .setGeneratorName("jaxrs-spec") + .setAdditionalProperties(properties) + .setInputSpec("src/test/resources/3_0/ping.yaml") + .setOutputDir(output.getAbsolutePath().replace("\\", "/")); + + final ClientOptInput clientOptInput = configurator.toClientOptInput(); + MockDefaultGenerator generator = new MockDefaultGenerator(); + generator.opts(clientOptInput).generate(); + + Map generatedFiles = generator.getFiles(); + TestUtils.ensureContainsFile(generatedFiles, output, "src/main/resources/META-INF/openapi.yaml"); + + output.deleteOnExit(); + } + + @Test + public void testGeneratePingAlternativeLocation2() throws Exception { + Map properties = new HashMap<>(); + properties.put(JavaClientCodegen.JAVA8_MODE, true); + properties.put(JavaJAXRSSpecServerCodegen.OPEN_API_SPEC_FILE_LOCATION, "openapi.yml"); + + File output = Files.createTempDirectory("test").toFile(); + + final CodegenConfigurator configurator = new CodegenConfigurator() + .setGeneratorName("jaxrs-spec") + .setAdditionalProperties(properties) + .setInputSpec("src/test/resources/3_0/ping.yaml") + .setOutputDir(output.getAbsolutePath().replace("\\", "/")); + + final ClientOptInput clientOptInput = configurator.toClientOptInput(); + MockDefaultGenerator generator = new MockDefaultGenerator(); + generator.opts(clientOptInput).generate(); + + Map generatedFiles = generator.getFiles(); + TestUtils.ensureContainsFile(generatedFiles, output, "openapi.yml"); + + output.deleteOnExit(); + } } From d117506b8a8a072cf99f9b6a90dcc17ba929cbfe Mon Sep 17 00:00:00 2001 From: hello-brsd Date: Mon, 15 Jul 2019 07:57:07 +0200 Subject: [PATCH 13/62] [typescript-fetch] fix collection formats reference (#3324) --- .../src/main/resources/typescript-fetch/apis.mustache | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache index f91cf183d7..8d0daf61ca 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache @@ -161,7 +161,7 @@ export class {{classname}} extends runtime.BaseAPI { }) {{/isCollectionFormatMulti}} {{^isCollectionFormatMulti}} - formData.append('{{baseName}}', requestParameters.{{paramName}}.join(COLLECTION_FORMATS["{{collectionFormat}}"])); + formData.append('{{baseName}}', requestParameters.{{paramName}}.join(runtime.COLLECTION_FORMATS["{{collectionFormat}}"])); {{/isCollectionFormatMulti}} } From 3eac8391f5d79a3e738b0380dc16e77d546ce435 Mon Sep 17 00:00:00 2001 From: hello-brsd Date: Mon, 15 Jul 2019 07:58:08 +0200 Subject: [PATCH 14/62] [typescript-fetch] support custom stringify for query string (#3327) * [typescript-fetch] support custom query stringify * [typescript-fetch] support custom query stringify --- .../src/main/resources/typescript-fetch/runtime.mustache | 7 ++++++- .../petstore/typescript-fetch/builds/default/runtime.ts | 7 ++++++- .../petstore/typescript-fetch/builds/es6-target/runtime.ts | 7 ++++++- .../typescript-fetch/builds/with-interfaces/runtime.ts | 7 ++++++- .../typescript-fetch/builds/with-npm-version/runtime.ts | 7 ++++++- 5 files changed, 30 insertions(+), 5 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache index cb7f747ea4..6878fd8495 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/runtime.mustache @@ -47,7 +47,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -116,6 +116,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -137,6 +138,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } diff --git a/samples/client/petstore/typescript-fetch/builds/default/runtime.ts b/samples/client/petstore/typescript-fetch/builds/default/runtime.ts index 5b07f81118..c95a101fba 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/runtime.ts @@ -58,7 +58,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -127,6 +127,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -148,6 +149,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/runtime.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/runtime.ts index 5b07f81118..c95a101fba 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/runtime.ts @@ -58,7 +58,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -127,6 +127,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -148,6 +149,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts index 5b07f81118..c95a101fba 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/runtime.ts @@ -58,7 +58,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -127,6 +127,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -148,6 +149,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/runtime.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/runtime.ts index 5b07f81118..c95a101fba 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/runtime.ts @@ -58,7 +58,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -127,6 +127,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -148,6 +149,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } From 2fbf0f33b3016422779990f81126ef129fed738f Mon Sep 17 00:00:00 2001 From: hello-brsd Date: Mon, 15 Jul 2019 07:59:01 +0200 Subject: [PATCH 15/62] [typescript-fetch] support additional properties (#3325) --- .../main/resources/typescript-fetch/modelGeneric.mustache | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/modelGeneric.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/modelGeneric.mustache index 8711fc7e59..af08282fac 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/modelGeneric.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/modelGeneric.mustache @@ -31,6 +31,9 @@ export interface {{classname}} {{#parent}}extends {{{parent}}} {{/parent}}{ export function {{classname}}FromJSON(json: any): {{classname}} { {{#hasVars}} return { + {{#additionalPropertiesType}} + ...json, + {{/additionalPropertiesType}} {{#vars}} {{#isPrimitiveType}} {{#isDate}} @@ -77,6 +80,9 @@ export function {{classname}}ToJSON(value?: {{classname}}): any { return undefined; } return { + {{#additionalPropertiesType}} + ...value, + {{/additionalPropertiesType}} {{#vars}} {{^isReadOnly}} {{#isPrimitiveType}} From 81e073df2cc8446865d4eb9355b45686f7cfb7af Mon Sep 17 00:00:00 2001 From: hello-brsd Date: Mon, 15 Jul 2019 08:03:09 +0200 Subject: [PATCH 16/62] [typescript-fetch] fix access token type (#3323) --- .../src/main/resources/typescript-fetch/apis.mustache | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache index 8d0daf61ca..b903769d8a 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache @@ -113,8 +113,8 @@ export class {{classname}} extends runtime.BaseAPI { } {{/isBasicBasic}} {{#isBasicBearer}} - if (this.configuration && (this.configuration.accessToken || this.configuration.apiKey)) { - const token = this.configuration.accessToken || this.configuration.apiKey; + if (this.configuration && this.configuration.accessToken) { + const token = this.configuration.accessToken; const tokenString = typeof token === 'function' ? token("{{name}}", [{{#scopes}}"{{{scope}}}"{{^-last}}, {{/-last}}{{/scopes}}]) : token; if (tokenString) { From a8185483fdaeb13a16c36091fe0c5c4f76a851e7 Mon Sep 17 00:00:00 2001 From: Akihito Nakano Date: Mon, 15 Jul 2019 17:46:01 +0900 Subject: [PATCH 17/62] Add Kurusugawa Computer Inc. (#3362) --- website/dynamic/users.yml | 5 +++++ website/static/img/companies/kurusugawa.png | Bin 0 -> 19252 bytes 2 files changed, 5 insertions(+) create mode 100644 website/static/img/companies/kurusugawa.png diff --git a/website/dynamic/users.yml b/website/dynamic/users.yml index 670b02df59..e2f6017fa2 100644 --- a/website/dynamic/users.yml +++ b/website/dynamic/users.yml @@ -53,6 +53,11 @@ image: "img/companies/klarna.svg" infoLink: "https://www.klarna.com/us/" pinned: false +- + caption: "Kurusugawa Computer Inc." + image: "img/companies/kurusugawa.png" + infoLink: "https://www.kurusugawa.jp/" + pinned: false - caption: Metaswitch image: "img/companies/metaswitch.svg" diff --git a/website/static/img/companies/kurusugawa.png b/website/static/img/companies/kurusugawa.png new file mode 100644 index 0000000000000000000000000000000000000000..49cb94bba131cc115a0871b3e1ff339cd38ee418 GIT binary patch literal 19252 zcmdSB_g7O-)IJ&zqzHo2qz9E2q)HK_2c<&@2`E)5(u-6np-GV0{HLRsLn`1x;!(Xj`(*wNUO$3x`aLDqb4U^B}6Dl76AY+ zqJY$-%a;#~6lA1pCd>cNKK{Jtue+O*`M$W^K-{|A>yO0c39ixsAushFNiO(?1wa5)7EOsMTJC1Os?=K4mH2o|- z)21-r6IPu=`);+V(vUt7qEs8z5}uJ%8+peh*l_iszVHL+vnId3?twx_qSOP_=s63i z6p%Bb@STL(2y&%2N2x(qaD}8Mjyi(Ymb~Egz-3}vYq{vr%^h5u_sd?E zj2n!k{widnP@^1$wDwvf5G~<`+((Ry0jKuWVQ=`nNi}Fi0Ud$;3uRUXz3)2>`?TqG z{`|4b5ZlGzb;e(kgcshAC>(5(O$tQhzd8^NM3{|wwguI-Wk>$Qz2jS;5R<)M(Ed>I z0M>jrY4j`ay(@+7DxRy$wX5;Z{((lHk>W_Nb41SSbalDBH+1EKnnvi>_-EvZRgg^Q zKd=>%3Pk=86c3Ch-7v-jg(QbgPuHYQp3lrnQ2+N#oiXiA16ufJI607RE6d&CoVB(;;Ur19V8+StXpGX~*Z4sqd-#Zzw+#3f z>G?->#>tduv=efo{_w)05it(}d~)5I?%u6ot6ehQ(@HJ;v9UQ({lzdb_d)%GfVIW$ z0YQVrwOfvF7S4GufY)kC17na&4Faw@tR}3duZHTD#9<BD>U@TN*qe#v#{Io2Rz6^sxFf+qL8}(Z`o489xt((SiC(s(dgfs*p0EwU}Zau z6cP$to0+c;tBAA}CRlbj$e8|X_X9OX=ECQe3?EeF9L1x_3(g<zfweykP^0; ziC|0<0YJZAp;XaB8G^l|(^P-v)cqYlH}cZSEac&n>Lr0quj|9>LJP7{hm6i7)?ao{ z;DP-DgmdD2h6gq;HR#i5dh)#u)GV9_$^}v}SA_ zzXTfV#(JQm0<1{y??~qWwYC6=3n~>KoPoO16$0+0lY|9QPd$H@^x4Pm&xuQ2yN6(> z!awU*q~n1VBT*3c3lofTOz-C3YR!M>SdlyhYNf8K5MJ|&h4|u|h{eOon5}U*K*Lb= z^o%aD`FH}ibfQLZBb8-#9#=~y2f~AinQZFa{=sMW80@Z)Oum(b^TuV~9HQDR{#yMb z2H+SxXQt70U9_f{q15_<}jSO))Q@7aq(1TUGbx@PV|^AyWF?8dDt!jjn*9MCx&mbgTWfl@JhFa#OtvxRP zkT?P9k;mxJz$1CwS}lV`8wXETL`(W37->NDOUwbay5gbquiLk(MA(RaJ0v(e?P(riTMk*1am`iiI5QacDs!?$_(*;|57ptYL! z1sQmkGVOklCUCjGq0RzE>L7|Q|0!qBm<9r*Si~|e@LZ!`<=o=BAsVMZaa82^0Ey(` z;FsLU8Mdry4q*lmWRm{P;V&PvQB>Z}tzvt`VlMY!GhSeBUOH_rN4)&nn%CTf_ns~b zWdg(b_B!X%fbXt`J^$318iU}I5C58b=dBpEj!do=%N(qRSihiixKf86=6a_^dn?oz ze;7^hqOz?Fq;KY}Bo82YjC*f?j|%ZmZR&8Y7Vkjwibph{wnrG8Xq(4-ov5w4(BSWg z_Vl{NK;7wl3L`%WN@dy7wUEQ(`9R&F9i5kSEQ)J%K;J(Xi`O`V!hi89xA+?~nB#oz zYfEw&gHL%DLvx6-w<{DKt)AsIbF(>!v)PudoPOgxQadHhkpm%hk=7fzeHO#>|J?Cn zt1QI!X<|S}W^2%O<#r^}WaO1)C@3^gz%pp;*!4)!9DcreXJBW{k96NM^%*a}Ac#+> z5)^`qLx!Jw%CbDji02i(j9=M5kgKVB?E>-oCTTk`a3t$y{l z9WhcazbpOC`_1$6-`Dc)ZxTO8VN|dmCr1zTMy5jluBdq7h7IW34xw`8bRYRu?o5dg zvtEy&JUj{?VU5L_Z-|sFDSn$wPD!{;9Vcujsq=|F8swRM$7e67>*$OF%n|4qc?j>D z3{VclPwp2faeVgNYY!QDrW7buDkU$Abg8J@mxm*1eJi98e&6vuN9}9RzRSxYy#{qUt7Xlca{4kMArS zrIs)c3PWp`Fm%$u&Q8RZSwRdzOENf!sNShr zyCu=YT?#9*9cGsmS^W!-rIC)FyBPI`-ijq{HneE2>;|08&OJA(j|RP|t5UNkY@krbsC+7>Rh&8a7wS5A-l)G(Wi9u4BXrn0 zeYCN{!?*YGCaUAp#b=_Qk=G)xdYoZGVd`viig4xhtIaAgdGh79Em8VMV3s`tiM!%y z`|JQf8hB)f?@FP9bFRJG@vCkswIuW$;?p~`IhnRv3gPI+Adw?Xr7KNLq8y(TWe zj!esbY*3n6t|<6ugeI;JbptB*!b@v+=Es7X5msyg7JI{{a;p1!w65-ECdk+VXL~X) z^pa0TCh>$vwQa!R1JtzEe^0X((q?A>2_f|%!o%88%%E2C61gK(di_~L!Fym@IDFPr zH=xITzM(YJ?On>6@4UVF>Xx_436e1TB*lUdlU($=&`{~fXPs$|@cLPTI>Xy!D6NM! zlwzA-Kx@Oy#M4SRUDC8dof{QXX7FyurR0yyEp8}-@~m$4@aqmOMkz=D*%7-W{vfH zK+wY<#{%bUB&3`0?WfCIn`q%e^mg)B=S_?E4%QwTrfg-#v=mQnxoaW!C;VsG z?@)5!ohn@%*&~GKg*l#k5BP>s3(HdLyoAPBK^kGmn8#YeQLWO#C30g}({5PXunqrMbc zu9l~yxzkedlV2n8SZCvY*#Z*c%9v&&wBWB2Ky+SKkfl|UR`*g`=n?3C^0QX%+a&5e zORlN2{f8#ncXfj|DDwWFR@hc-8F;Vi$dt*e!O!kt;p%D;FR^e__iO_DeTN1&OPMug zAcy__#!l;0i00tuwQ&wdV__+39ZBZerhYr^fBj>@&?<@N_?#hox7OupX8;)9qpr>{ zjuDvk7 zNuXr0{r|1C?s_Q|X4*lKJk`kBVhl^xZDN*fhab+_6<4df*xCSTt-KvNbYt_ivbi{7 z1h(i_kz*4cfVn4^37w>PzGM*Ww*PdZ#$YOQ%akT#1bG;sJ;HC0sqkb#e-nt zyREsA?*E4tRBEG#C%acHWwaxJ^+)$qzX z>VkZa2Tyu2j1)5WyMYzjy83w@;vUlNtq0(nR~1J1of}^yc_6rrAXak7X|1Py zhl>Tl1V!s-63tRS=S^ReU>#Ao`Dc*|^@csm#s%6E>}$SgE0c!lJ6dk1+Bj&kL=szc z$$pd<1kNFXWH=mlQsPbLH@5z86fdt)a4Rg;thV)y3Kud6uNBw$f4;6$NZUsKRd~>v zbKuEFs>ARH@^1p-)_}XtXrId-1lgCF%Ab;cR(0fWsR%uUrWx=e%uq&2#rgN-_ap(b z(4x=JCV^s0s=%NymA4{0a=sSMwSX2c>-kEb@;Z*TpNuX_!2Y=oS$d(GSI zKF1JMLB3lTv*FSCk4hm*I=)|FBeN}}XcUi(W)(9@S&U?A{hXM>l;9&gZ33qL^JZjp zKFlae7p+`*EaKyReUtdp#Qz}nxj;9A?-e=J_G=@Xr?vZE&b&MCDF_ef?E-}+tIM~H z!IV1G(KaAPgw|8xKO|J)R;p)8|4(C%`9GTeAAdr^^9$tu{a-EJ3thp4@U(^XPxBKu z6?(m;Cy%C0jJzXIwW~Mphx=2{3BZS^8tV9-ItA|Ct5Hd7U zQbRIF@U@xcqsB-1n)7>iU0i8-cTdvUD`%x9jRl#I*3{SsGl)m8fzWspcVh$Ixc~P3>pRXg- z=OtkSK922G!-j(aZdJ~gV4QKY86W*C@avUAK?Sm8r@D{8{mo9rGPQFLFW z^wqhQcoSUH!?9G>AC&Ogqae>#nyp?5h!-8_`grpSaCW|4ZUge`<*n@ggT)&MH9gau zC2sVTsyB1=9mSZL+hk=_ldKR_H9V(^F zv)6lJoeA>(!nG5l9}{4!cV4{O%{0!^U0iQKUx*(0Uw}g)i9gHmvEO5o&VcpQUm!NAwq)HR~^2)HBE6di_M9^oDs_)7n3zyS|g*8qk5(2PG)Q$sa ztwX|NG2*?F+jHYn%`wt)HDk<0c31fKGFn8L0kI8HZx@j(Kl6d2VL2;iWB_2fO+=ws z&1yr?mIYjZjWw=+<*ffJZ!yRP?e7pNw>?lb(_foO!!@!GG#^%6>?B^Z4Yr1!4bX zC^qDDI3{H60z(}4BLl1zzX1w8vd6gC-;X}$MwAobrPknRd^A(VzSOa*mNytr4x}ee zESF>A^o^@t%{%$jp)1VA^%KOpSXX~#{mH{+`pn`jg^YZ}Az!`Z(~jO)0q?Ayj?4T^ zluY9G*uAJd-&eYFc%ML6G{w5GZ0Hbp-c}KLDOd^d!qC{At>7!T^FFzr zB?4N~{VtDDcAi(q zB1y{t`KaMPT=2Y!6qYfjNqBAl8}sKA`geO5uHF|cb5=s~1x7BcjHZbLbmT94%e?Ig zD6%z)FqmDr7EV}$?#I^y51}V=bhSbn^-GKsgiKtVV(%+P-v?19gKi$;B ztB85>9wqQ_7baV-*VQZ4$YA9vSca5*g|^x*VP=o7QQ@0sVE(9PNM%=%(u-2 zUM1gtL=dCPL%$D!x2vObIcQ%HLFMwz?6eLg!^~7a6j^mC_d&NM)d%hD3dHLcn`YP~ zsrV@AYt9Bc9TrVh@634iJ@jRnCo4eNT%Hm_ok<^Or zjyj}29Ch{7_Q8^`-ecv(TP(REzc&LBk-Kb_AZrIEelE+rc38nva#7aptFQD=d3-EI zo?wVfYNJp8U%~zd2SnX${O33i2+hv#H*A;5tS~I zNmDW}zbEfr{-!cTUwuLCfCUH%!htd{0?sev1u+3fU zA6hp}I6JqFqj~+)U7{Tm^5E%yi~rC0y_DM4TNG-d6;gjT%k%wkJ=AnB!+T&)g1z7Z z|ECrzyLs>G#|*e!+1B7_OfRXTbGMDTqw|{fw{Yr+>_70x|0BI(;TQ9qiR*i!@~p;2 zaLO%YFiC6{4enOPg7%HOWnY(5tEKoXTUq{isVr>WL`7~~oQ;lz?4ohA>=S8{!@F9#<`Ld`sjcEP?#J- ze)Ow}CM+T7O8RV!)k#1~^Z4}u)~he{Zva$vNQ(SX9y}M9OZS48G`041t z*UZ#W(T=ATHhWt&a|k|c?H>~jRi{BEG?SRwxCH%YQfr^ae3IWk% z^44tGdjnPTCd2kakkFmnzQc`&>&NF)a%@nt^oG{WB^F|U?0Ft5Ywf|J;nMCDbQC^|j)pPdnC_RwA z`+!mv0O6QmlxW7LF^@5o7sBUwe z9b;7ndGX*6!eg-O;UtLrA4(I`$NaAaR0@s6nt)j#zm%un}Ogq^MjcKKh~?QmWPonU6CNbIvOWER~*g=9Frcsg#y(((Y1a z5=cKt8(64f+i^IexvJ4MfLidE$MHt~^23I>k01IQi?suijoH;8y(ZPE z4)~bhG#wT+X)6ojtS3uG#(uNS6qi}OOG8I+c?|xfu5^p9>IYGX5t@~QZ!?mLg#17d z;EUvJi{{drOOAH-t4VL7JgV)C)>&tCz-w?YZNHJp}k7-UX)kOpIKkr%81C{tq&D&qwRyPZPLo zYE!x9@i|3KQh@eB1$&)pS5Bvgvlrpp|UX42aRG3oT z%o!+6XMlB%E4baAx6B+rFTsGx}w}9*VzG#CVGt0N6itiHdFqN zN@ld`;~X73I)r;wJx;PKpr^#ea|tUiLJF8M-*2i(%=*HMugO&h`mD2D*rrvP%2RSX zl!_3>j$4%Wj9F>9O1Buj0hzCF-@Nn21L~46E@<2R;rEW0poBk5_6g@e-pswKNug8q z3B-pK7j-wBkDfF|c|0j0G;sF{a%Ri23(5R#MxAN1y5G=sme;!>5)x3YAa+xM4UTO$ z99&mAp4;ktj706!Fr6*cX1g2mPRRdD^!V0QCb&QQ*J(WP2}E%NR+HPq3Q z@HkXH*c|KnieKyHXWbA$Q>hEz;g3{QScyL4-Fhq%V;YXVHGsRaH3GlNhEh=uB)a7! zmPSUzptjHk8wa~6eE-zhGiA(9O|egV!DT1IVry!ph^c({f~_}PU7h92e_FOBY9@@f ztf6o*wPR)2U~|cl?-so!^f*a68p<$GYfz9P71GTkXb0aWU&iy-Cc0~9_W_xOx0??4 zO}6a6<_@k(fNb7LU-t~jsOHzxN-RgWklN?A-m;S4y_YyUjMxCaH|8q}kuUL6Tq_)` zzTS@47d{GZ)^Dpb^o{=hChMKy)1l{kDGb-k$^}cY6jBI`dK}PB?WJ{3oady~F%k&2 z*0!`^C7D1W7|`Ye@186Tn!&lv<)OyCZppr#FZ9?pkLIHHA>8ef551Nni6(b~T1fG6 z4pA9M1yy-f#@A9>FFfG;n>_21$1H9hdS6UZss=qcOgI}y+BPs{2j*98JPP{5%Z^^0s?y(WcH^1KlM;%dAlJidNTRJ3o-_&4R2y%|2jhGhOoMtM~@zy?w=uytC7NzuX z9@1B1ssPKy-z*cK>qy-FHeM@2jehQ&qLP?)OR=YLSH{mRpg?5qyN+M=!4+ z$6NiiBuAJi-?;^i0e&F^o#&lyYE@@$d)`dFxc`fk)o$W3%r|po{h(0USQH7}=oyEk zR<%*dBCtw^Dx6bZ>`v$TIGnXn5ft3r+h4JMDz{Nfdkl*(KEZ~eAu#W6QMIr3M*t#(W~ zvR1y&S1)0-UQMBG#4Wuj0_fD3pIGB;`3~u`n4wIowIRTD=lCaUPRfJF+MRA%anFpM zBKO*#ClUSrWGk!A*@f$JQ)o}9YO#nMnWZV%!RdAC=SkUBeG!dH74Zy6)Cc`G9sZW^ zkJ@`LOpy-S{{?jlm_4p zwO~vu+Gitv*)Wci=QH;FaVCvs=P)6B*L``Q8|^2db{fy#1EZx>HY<^mhV{NMbI_#@ zqoY*UkG@&c|LfikN{L6)zty6xEEubDc<0pCPO*>$5+T_c(u=X+>Ygl=0{RkTPt zkA>e5wNPcEDNYZ+C4g2b;>j2%2X+lsI;Jc_(CW10EG6EHcVsAMBcL{h2}J;%gVFt`#iyRxwl&cLcoVJ4Pe3gwjNBOZ zI7Ze7m=PzSR*qkMQo}v@ahwEZ!qlHq_NFYTXW=oV6wX^tyFv15 zJf8>}dvkT-K5)%!;t0NvxZ*fqmpRpFO|OslHB~Jk-XlEmfm`@JFe<5wSc(FPSAC-^ zb!w>uA?%EF-sP3)PZ!K=Kd#51FI$#-I?87>-)@Eaw0V>oJvH%)lkHRX5e221xzcVY zD>rma8S%qvlHBU-DKGIf`UviF=Kko(L*=xy12198hZY-8IOL6OIsX?hDGgoeP^VB5 z-ES!n2`S5lRa;q$I&`q9smZ>DZ&c#HMeuCYLYty{kpv_|_ zoBX}NY^yp?;Lk^dn$9S9Pe~n4tjF5<#?>VOfE0K@C!kQa^kb(GrXj9 zFNK9kTn`LUVwGp!O&suV_du%BUg*Ax;$Zac@Vk8R2HVW$<}c@#WdFFJm0BxHG1j|Up8T*@i%rN6N!t$Ebz3{X_2R-XmWDA~ zs?&m0XEZmR{__g4vvQuo%-D-74o{0opl z(#Iu7s@WR^s~IYTUh{|vab~!CxdrODRt?fE+7_KdMv_3=7(NGOT4s#jmS}O-C6n&@ zFQ$-8OpHs*cU49Nye6Y2ncc zcRFld1K|(mT2LI$kAn8!dXn9nddGBOk}L`JfaE-X1lKWpxDiXSx;-38W@8*Uli641 z78IgE_BAu6BdWr53&VN*VXfJRy`ehnX>Ya_A1vU+a{-}G7-y!BR*jv;{gL|?6@5gn zHUd3bb`J5}ZanO4&JmEbu}O%dkGT7&^mjeB=iyxgHb@1(ovY6T>fv*SaI>e;`7X#k zk9ijx-C5n~H1{u-(S=n~WnWauzH+&*akLbE6R`}8lCJds?wu%ANzP&(Fpl=Qj^*43 z@zWo5ww}M$XcxaHNG;Ww)KK1Y_r9dGUG8(wE@1^~ow2W_tk}%m?@)Tn&b`;s+NF5< zn>F0hb{{J~I9XPzEBaJVJJg|3@V#ize$rCN{I>fq%b=+13!ZsI))xi@;tXxtF4CCO zD^4m+g4x;|1qKi5YULI#1s~x<&nnA{*Z;87hB;Dmn!FQka3j$pTh0D9#q*6{FQ0MO z&O4J%W0iayH(6d^X>D8i$cklr0b0`i9_k*gKR&UALS1&9n%8@keRo%1eLDNuh9?4? zjs+oI>Ya49M%UlMajVWUcaJt5iu;oe(Mo*(hRx13x8BTgq4k^IZ}B{((QUcl9AEkk zb{`=dpKit@g|Xwx`sL9-D|z@=V3h+fcE|#1$Hq$$HSPW;z5Pq~f}KqXW)w`R@;ENW ze1a+@p)9?b8A{RaJa(Qz+81M#GBX>h59&-d_@bB7I4EKxY`7m<`i_O;AV3=6sdOMumTh!xzv7`dDMR+;HB4 z?{_cx2Xp8x<-BPk;&`qL2A;IAJ1^@<+EvEFSh#$t%5xQKsMKkEf}z9oH}wUEA%@iY9LX;glksW-~sX(k2Ks_>qw zR@|0{v7eb^xfp0hqZcOTBW`F^&Y@HF7K_gY=?)%I-yDXzEn`?Q+-EMdj_QO|KSrg5t?H_{cEk$ic6ly7;nuds23p6Omzohzi37(WdVq(>O z`V4CPvD%KqOiQL)(z}u_3hLi8%Gg-XpbJRO2N~>gz^aI`3(dyLdG(jTY{e2!IGcla>!sKWUrBSGcHcEW5NWjXOVyGz-G~M?tc+1Z7nYTeG=|@4|WwE1ncF;};bJ z@o6N&gwFmr0dW(cQ%3v+Q8GeM59Q?Rp4&-#MVNzt4`5@`tKA&9k8bh_6Z=~7{7 zY&OKRQ^BTB!v-BSBlB+SEDR3(SgkmXrVaxPE~b$KU+x|3x`>fTilzO`f*jLnwmXHB z*XD)8jDeGO^HZFwoaz)ERM(X<>~58DeY#K}h?0njcG9Syo<$}BL(STf0fuND>yD%M zOT~X--r5!%d%-`Vx13{oE3XlLc6Df-Em}r*RbDg6nz!)VkAPJPyqYd8I5N6TRl|`N zA*H-1H$GWHl4va1Pg>#(Hycq}ghL9LKUES0>{BRmvObjSfgW4WVx@C+MR-Tl`sqU3 z){rE&=NFGAwdBYK4VibvQC2L@Zr)YT;ovOYmb^5j#Bu&cUXsXh_QhOaPIP!_(NRqH zV7(IuV z)`7+u4^R1$6n{v?05D_RJpU0}uPWLce?#w)Qb++>*3yHYWD$xJ!FbnfM!ROGQs{L~ zpp)0A;*BFkVTd+2U8U*TJaHsM_UoCJ1rmVXvwB1-FMU52s5LoP%V%Bbm}%C}XQW(p zR|F#23CTEBr!8S-1f7h1Y{Fnwvg4+He>?KIRunhfm1|-}VyfMW9~+@*D7BdAzU7=4 zf4rJy>!De5RQ$tZz?5UrQCl1{P)yGMUxU^!yKFB6g}{550yrA(3L0Nh!!4 zVMbRkS5m7ckNk=Nj(sdk+k9IZsY>m1bOR9EAKQP8WLCd)mb{v5X~eEnU6~HPsqdDF zHCb{5FFEiZKU%**Q0wgbA^#!u+k*b+z-z`eqV|qF$V;Ek*6awj;D2#2)Lp>)w{!WL%2R9jHYtZcHiFq-){R#= z?=Td{5UOo=lgJ8hrP4=epk;-z3{ujOIxJ57B41t!h3ypkLng0iDC{?4ey4(~^MP%_ zq+=%;%IYM^=^Xc&PlP^7Vtwh(EiDTpH^)v*MtZIP&L?rCGdiy7=BPtVc z5QY${-1hTm>hip|`lqMG!9j7p$`N@sQAOfvDno=uIHW%cMh~yJJnM}yacVOXXr!*v zzLuZO+PZV+JI|eFa_8>}NIp*vTB>Kk%mAk+)r(bi0ra$f%p0(w)3Kvkz@|CT!%`;9 z;;{rp;j>2S2x&ubS2~G0ud#KrvS>&V+2DAQ6u1Q~*Og=bD@6U(M&=l&2ViNwDZ)-3 z_VR4p(0YauAY9=jRZnEv!!^^s0TjYWQZ&Mo1!`T$gLq+MCQ;@r9(0Ci?*i-mq)8e^ zx(15;@}CS<670S;-vB*oXw>mX0ZJ8GXTUR^7fckf0=3ne6?LTTusi%Sks~llqLHM) z`k6YwC*Le?2cXr-P}A|{)A>Q@=fGVYs?2E;An_>GQt*3uolK-FM_~CQ^DK#ik$;gd z#YyA+E4EcGWTz+73J?L{gw2Pa9@eKDb8Q9PC4MTnGEedF3f>o>wKu6LG6yT^fyujx))bEGWItfvK74R#>zdh$F0ZBai;yW71Y0pF317T@tG!c6QPFezmM>p)N)2@5Qu9FA{%-Jvv&kXK#wxkHf4p zwfnoxdAQ~Df5BmRT+~0>*jwnk6U5=QHl_o^d*X7tyOJ zK0Ed)A*u62U<4hd0OFWBwxM@SBrOJ-?qV>_hAj{T^lK@puJM&pc@JJ`xjW})k7-Di z|0H+G=h)6{fj=>UQ`p0eKoaL4c}@buwmRIiEzU3T>m!Quf%8ZH1t-{YlY(MWR(||+ zvi=%;^iWmKXRum%;Du>0%dgXl2AhiUwN$SH=*N+_AX9x%uI0uF$P>o@xpraeBy;7* z`?@kc1qV66P2H>67&-vKKkQ8+aS9r1zHER7wW6Ah#Y@$a& z9|IkI_#J?Pp`3;>JA{8zgm-c4@8ekmF^@ykrs?AEm=dbo>8DaGfacvw{!s()2O7LH zauH)6e}L`sdM)c#Y-YN1*jEM1pN}9=mfn|Bvn3wb(rgYELu}mIu5&z-ym$8 z92I#fgSl^S8KD_=UyjyG&KIu~#(mi1 zI;oJcBuJ!d63@Jh&q6ob8tIi#0!MkyH(FbD=~Z6jH0`+U2|IMGxIS}e*vi@)?btC1 zY4?AwrNDZ8THi+akZA?n$q=3g?J3}PPvx-T#~u1W7#@Msq!*iek*+HzieBV&BTpAN zl-qT@Zh7U{e}kuX&uQFPMSyf#>Kldn-d?~v-60kz$nD7F;}>TRS`do`h#KEW&>Z9f zk{32kM!eur4HP;*@11^(eT2cES(`k7(KLw2SjI5>98Fp0dc@v$ssAMUM_}u{#{(00 z5Q87&gHBS*m>65ty*c)t1=gV_XF&(2?);YPBiFyfO%OO+hU$HI#SmteSo|F3s|Q5l zlGst{UIi$~Y@^5}EniC#gk&YUIBnm9M%zkx;ty(SWUS8sn?ssok% z={lJX{ruwG=d)}&*~mG#SMwkup$x57xM&U^5pBWY1pfrjSO$!2%^cXc z`>Sg!&v#5*?jHvw70(?v&w&s69S*I_rtoLY9s&=h_Hw?Ixu4`Ng44XHwYQahe_Dgj;i7!g@{!oTKTXn4{sHX_;ebK7>w|21rrI)bZBq(k5q zl>d@+LQ_7z2D9ELhf|Q-7BwA75;E$+N?q-;wPToQ8~?ogomjdh zO)UF`eM!~i)`P5!XlKwwwvye!km{9GOV%n7Z0#h+s`zcq1t-(eC-h@C5erK~r6?iy zFu<~%Wk$eWv$lPs$oo>ZkKe}fn0WEt*K~uhc(5SN=oOS7EDL*OewR&HdtT~UL6U%d z(F>`TGBd8x zg=lo~O>usoGYHweWv>)DX8_^RaeUPYk-pctt2ElB6P~Pn&3sPMPXy?0|B<0eI_t|9 z1JRm{ykpt-i`9^+26r?4p#Y=OZ!o=u{9=0aWBR~w=$^6pE>~eyp#)2iRzYIuM1yx* z`sjD=9=WEn%E(rk1wy4~j4z13sqJd8c>7J`Ux{F=&Iq%`)#g22rbEYG((_wV0qmJ!q;D_A2|$myv;5+kX^Qptn-N3zJv)je-O%K!k{m4E*WAZMU& zBMW;vKKiL%sBQeYRK+ZVpwcH8pX^qJbii*ypMiJY%JVAQ!n9hyXN6%JOhH4sv-#PH zL^;t>h1z4tjfZ{Vi)J1dZkG#xJ8sOQa9HK$pI7f7uB!R{XgH6MMn{mCCY>&QgmVio zT%#`O@a=P`BZG{z4tSLr=%|$$sF?ijT&kQ;JZD}`9 z!?|P*Mm^=#B6~MqT-fi0jbiWpPRGCmpVap(gtg+;?$^m~w^1LzY@P_2?}Fmj>@)NE z2!yS}Hbb{raEi@+{pRNkXqP$f2q(`N>$$CoZy5C~7NexCM4*rsi>2H3g*${8lwG1WctI9e5f|=T-itrexNI8u>7F7|sy%@Q1W_ee~`P z=ZCV^*)8Plm1)LTsr(9^7+&7L^b_2fuWT3^SOD6%F63vG*#m}V3EQ&R#YskrN6<%44<3=uk=qb7XR~;2Q{LoI zf3Y?y^j(OrJ|Zx1(zX=ohTkz7Eo(FQ$6Q0?8|JmwqEb#(Vk^AdTTA5fdPiTlUNXw< zB3q4F?2Z_3NxGCAqK9@p;{?#gyTJh7pqZ?QBnWHe3_|8Gt8Bd|IOD?QxOZr&c`lj| zsHf-gZt)KD#I;F+a&u|esB)dP(!SRUKrZ^>VXd?B`w{UF;=K1|VjjdA6!az~iQ7?E zXuuMO4K)QhSoQ<5S28^`7$?Kl;w#pH4#%Hv;rXGE5+JxUTHtz!`>8eMV_FT;KMDAW zcWvl>EZ&7MCQiDSup9)A7mOwr&OY_Z2!r)v+sE{GI*()yjU>`#C>+p7Wf~IiJ__eqLTHe=u-kuv)hp=w?1|ZDK|BSW-f$ z!jq4?qTYyn3!26iNd|!6hL$F=*s~)myv)AgiQVlpcAM|F)}GQ|UkkjHQIX*RJ!t-8 z`0|KVI>W`Q6hj13G|P+sFsTL7`|{?)9i}Spg-U?~^ll|~GcK%dAwHj(M>T?Vbt9L^6TH@b<<86!KZT`9nU-TDkCI^c$pK;?3 zqtM<^I@|#kR6E$|m+bRX>i(Ni1q)YYV)Nww&Lu#Du~rvu)Kp|x^RRaXH!EQ!toZA% zS_a|b$!{($)+`^TaJ+)|Z?MYd)Q`D4Ol`gN(NQ~jt}JF(i&5U9M)&I@=XN{ZtF=x9jHS$WQW}y6v>S1 znNlU=>7w>$`PtP`eY=DcQWj3^ufI3CRY}g0BkRK!nSye{Fn8Hv8kNYl>~l@8wl3%X z(9ec2szPhGYi5v{Obl+eJ(3e@Ta{Z6rh->e@#4ufj zK^Zq;&96n!%afkWaV9~gq>H0Rl#MCep)zQH~)#WSx;!I-+k95 z6h+}9Y-MHGXN0(F_&;@Zb_f#!N_eYe`;9oy!gO@fh94+s+TJglIf9Rn|E6W(79hOj z@ls6l)oMLwv&y9mC-ZU4I_aw_$@6sfV2Z5E2l7dtwAxaiwCEpjX3$3D$ch~FA|r}4 zyO-NjAPNlqL*<9dX9tk-*gJC{AA!#?)2$X?b(_8}k)yoQ8Eo6qOFhL({)b0sZyzvg zJ4N`3M@`$0p`b!`%TVfU6gj7ae*8vv9-h=|lYKq6xZ?d>EYnn|WcgKc|HAhn+L-~A zR;kMQg1uEG!wfn0^68cfTwiAZe=NSh&ue64{N89b$k&Qe2HjI}_1%|j8ITYnwi>ZQ z_1Y2*ucVEuTw5}$QUCQAT;(sni?v@*7&&<(^d6FVE;4ltjHIkFG759C96KH)5i^>m z0=fsr5%(poj|(S$DKmQjUDBTLm+)vop`P;^-Wf}-=6a37FVJw+rJQrFoX>zTrfhxM zr~7u|zdld#?<(+Z@Vv#)Xq^e#!&2?EB>&c`?G-8M8s1=Xr@UeGac<8e(pC|-j|zGJAC6#0nxbL56fK}vHy#}kzOz; z&!|e?+JA3;S(|-cX#}v}=mWi6xO;0IHXf&7((V%a^_}2AL3*7Ans@5nxhpLZjWi67 zyAJ0>>x^t!8-%3)X8V*Lox7HEXnlp(O=tqdI!`(399T4Y^I+7_sczOb7UfcL6&u2N zw15S<9`IEr(!X@rTxC5iDc>{r91Yo(0df})HP6YLf>zC2uofiLFL+OKqpIq9uz~~p zbnyBA^}e9!<9*vEYW6X+6X#b@joX~6GQ+2 literal 0 HcmV?d00001 From 244eefcec428809351c5401a0843afe5d5d087c9 Mon Sep 17 00:00:00 2001 From: Akihito Nakano Date: Mon, 15 Jul 2019 17:46:26 +0900 Subject: [PATCH 18/62] Add a link to the article by CAM, Inc. (#3355) --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index ab8bce4e67..8c56937a88 100644 --- a/README.md +++ b/README.md @@ -595,6 +595,7 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - 2019-06-28 [Codewind OpenAPI Tools](https://marketplace.eclipse.org/content/codewind-openapi-tools) in [Eclipse Marketplace](https://marketplace.eclipse.org/) by IBM - 2019-06-29 [Codewind OpenAPI Tools](https://marketplace.visualstudio.com/items?itemName=IBM.codewind-openapi-tools) in [Visual Studio Marketplace](https://marketplace.visualstudio.com/) by IBM - 2019-07-04 - [REST API のためのコード生成入門 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh), [和田拓朗](https://github.com/taxpon) +- 2019-07-08 - [OpenAPI Generator にコントリビュートしたら社名が載った話。(CAM) - CAM TECH BLOG](https://tech.cam-inc.co.jp/entry/2019/07/08/140000) by [CAM, Inc.](https://www.cam-inc.co.jp/) - 2019-07-14 - [OpenAPI GeneratorでPythonのクライアントライブラリを作成した](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) ## [6 - About Us](#table-of-contents) From 8417c5bed0e23764dc841816c2322cf7dc4e9b0d Mon Sep 17 00:00:00 2001 From: christof-vollrath-spring-media <38937331+christof-vollrath-spring-media@users.noreply.github.com> Date: Mon, 15 Jul 2019 15:41:40 +0200 Subject: [PATCH 19/62] [typescript-node] fixed enum generator for top level enums #665 (#2266) * [typescript-node] fixed enum generator for top level enums #665 * [typescript-node] fixed enum generator for top level enums in models.mustache #665 * Remove wrong copyright line --- .../resources/typescript-node/model.mustache | 11 + .../resources/typescript-node/models.mustache | 5 + .../TypescriptNodeEnumIntegrationTest.java | 50 +++++ .../objectsWithEnums-expected/.gitignore | 3 + .../.openapi-generator-ignore | 23 +++ .../.openapi-generator/VERSION | 1 + .../objectsWithEnums-expected/api.ts | 3 + .../objectsWithEnums-expected/api/apis.ts | 3 + .../api/defaultApi.ts | 171 ++++++++++++++++ .../objectsWithEnums-expected/git_push.sh | 52 +++++ .../model/externalEnum.ts | 17 ++ .../objectsWithEnums-expected/model/models.ts | 191 ++++++++++++++++++ .../model/objectWithEnums.ts | 43 ++++ .../objectsWithEnums-expected/package.json | 26 +++ .../objectsWithEnums-expected/tsconfig.json | 20 ++ .../typescript/objectsWithEnums-spec.json | 91 +++++++++ 16 files changed, 710 insertions(+) create mode 100644 modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/typescriptnode/TypescriptNodeEnumIntegrationTest.java create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.gitignore create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator-ignore create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator/VERSION create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/apis.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/defaultApi.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/git_push.sh create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/externalEnum.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/models.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/objectWithEnums.ts create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/package.json create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/tsconfig.json create mode 100644 modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-spec.json diff --git a/modules/openapi-generator/src/main/resources/typescript-node/model.mustache b/modules/openapi-generator/src/main/resources/typescript-node/model.mustache index 0b3ca75891..c9ef8ebbc0 100644 --- a/modules/openapi-generator/src/main/resources/typescript-node/model.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-node/model.mustache @@ -10,6 +10,7 @@ import { {{classname}} } from './{{filename}}'; * {{{description}}} */ {{/description}} +{{^isEnum}} export class {{classname}} {{#parent}}extends {{{parent}}} {{/parent}}{ {{#vars}} {{#description}} @@ -65,5 +66,15 @@ export namespace {{classname}} { {{/vars}} } {{/hasEnums}} +{{/isEnum}} +{{#isEnum}} +export enum {{classname}} { + {{#allowableValues}} + {{#enumVars}} + {{name}} = {{{value}}}{{^-last}},{{/-last}} + {{/enumVars}} + {{/allowableValues}} +} +{{/isEnum}} {{/model}} {{/models}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/typescript-node/models.mustache b/modules/openapi-generator/src/main/resources/typescript-node/models.mustache index f7f1d2e0a8..39c7da727e 100644 --- a/modules/openapi-generator/src/main/resources/typescript-node/models.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-node/models.mustache @@ -34,6 +34,9 @@ let enumsMap: {[index: string]: any} = { {{/isEnum}} {{/vars}} {{/hasEnums}} + {{#isEnum}} + "{{classname}}": {{classname}}, + {{/isEnum}} {{/model}} {{/models}} } @@ -41,7 +44,9 @@ let enumsMap: {[index: string]: any} = { let typeMap: {[index: string]: any} = { {{#models}} {{#model}} + {{^isEnum}} "{{classname}}": {{classname}}, + {{/isEnum}} {{/model}} {{/models}} } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/typescriptnode/TypescriptNodeEnumIntegrationTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/typescriptnode/TypescriptNodeEnumIntegrationTest.java new file mode 100644 index 0000000000..dbba7f0427 --- /dev/null +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/typescriptnode/TypescriptNodeEnumIntegrationTest.java @@ -0,0 +1,50 @@ +/* + * Copyright 2018 OpenAPI-Generator Contributors (https://openapi-generator.tech) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.openapitools.codegen.typescript.typescriptnode; + +import org.openapitools.codegen.AbstractIntegrationTest; +import org.openapitools.codegen.CodegenConfig; +import org.openapitools.codegen.languages.TypeScriptFetchClientCodegen; +import org.openapitools.codegen.languages.TypeScriptNodeClientCodegen; +import org.openapitools.codegen.testutils.IntegrationTestPathsConfig; + +import java.util.HashMap; +import java.util.Map; + +public class TypescriptNodeEnumIntegrationTest extends AbstractIntegrationTest { + + @Override + protected CodegenConfig getCodegenConfig() { + return new TypeScriptNodeClientCodegen(); + } + + @Override + protected Map configProperties() { + Map properties = new HashMap<>(); + properties.put("npmName", "node-es6-test"); + properties.put("npmVersion", "1.0.3"); + properties.put("snapshot", "false"); + properties.put("supportsES6", "false"); + + return properties; + } + + @Override + protected IntegrationTestPathsConfig getIntegrationTestPathsConfig() { + return new IntegrationTestPathsConfig("typescript/objectsWithEnums"); + } +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.gitignore b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.gitignore new file mode 100644 index 0000000000..35e2fb2b02 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.gitignore @@ -0,0 +1,3 @@ +wwwroot/*.js +node_modules +typings diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator-ignore b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator-ignore new file mode 100644 index 0000000000..7484ee590a --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator/VERSION b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator/VERSION new file mode 100644 index 0000000000..717311e32e --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/.openapi-generator/VERSION @@ -0,0 +1 @@ +unset \ No newline at end of file diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api.ts new file mode 100644 index 0000000000..4b76122d80 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api.ts @@ -0,0 +1,3 @@ +// This is the entrypoint for the package +export * from './api/apis'; +export * from './model/models'; \ No newline at end of file diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/apis.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/apis.ts new file mode 100644 index 0000000000..8a6789d357 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/apis.ts @@ -0,0 +1,3 @@ +export * from './defaultApi'; +import { DefaultApi } from './defaultApi'; +export const APIS = [DefaultApi]; diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/defaultApi.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/defaultApi.ts new file mode 100644 index 0000000000..899c76592a --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/api/defaultApi.ts @@ -0,0 +1,171 @@ +/** + * OpenAPI enums + * Tests generation of enums with open opi + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import localVarRequest = require('request'); +import http = require('http'); +import Promise = require('bluebird'); + +/* tslint:disable:no-unused-locals */ +import { ObjectWithEnums } from '../model/objectWithEnums'; + +import { ObjectSerializer, Authentication, HttpBasicAuth, ApiKeyAuth, OAuth, VoidAuth } from '../model/models'; + +let defaultBasePath = 'http://enums.openapi3'; + +// =============================================== +// This file is autogenerated - Please do not edit +// =============================================== + +export enum DefaultApiApiKeys { +} + +export class DefaultApi { + protected _basePath = defaultBasePath; + protected defaultHeaders : any = {}; + protected _useQuerystring : boolean = false; + + protected authentications = { + 'default': new VoidAuth(), + } + + constructor(basePath?: string); + constructor(basePathOrUsername: string, password?: string, basePath?: string) { + if (password) { + if (basePath) { + this.basePath = basePath; + } + } else { + if (basePathOrUsername) { + this.basePath = basePathOrUsername + } + } + } + + set useQuerystring(value: boolean) { + this._useQuerystring = value; + } + + set basePath(basePath: string) { + this._basePath = basePath; + } + + get basePath() { + return this._basePath; + } + + public setDefaultAuthentication(auth: Authentication) { + this.authentications.default = auth; + } + + public setApiKey(key: DefaultApiApiKeys, value: string) { + (this.authentications as any)[DefaultApiApiKeys[key]].apiKey = value; + } + + /** + * + */ + public getObjectWithEnums (options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.ClientResponse; body: Array; }> { + const localVarPath = this.basePath + '/getobjectwithenums'; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign({}, this.defaultHeaders); + let localVarFormParams: any = {}; + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + let localVarRequestOptions: localVarRequest.Options = { + method: 'GET', + qs: localVarQueryParameters, + headers: localVarHeaderParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + }; + + this.authentications.default.applyToRequest(localVarRequestOptions); + + if (Object.keys(localVarFormParams).length) { + if (localVarUseFormData) { + (localVarRequestOptions).formData = localVarFormParams; + } else { + localVarRequestOptions.form = localVarFormParams; + } + } + return new Promise<{ response: http.ClientResponse; body: Array; }>((resolve, reject) => { + localVarRequest(localVarRequestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + body = ObjectSerializer.deserialize(body, "Array"); + if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } + /** + * + * @param objectWithEnums + */ + public postObjectWithEnums (objectWithEnums: ObjectWithEnums, options: {headers: {[name: string]: string}} = {headers: {}}) : Promise<{ response: http.ClientResponse; body?: any; }> { + const localVarPath = this.basePath + '/postobjectwithenums'; + let localVarQueryParameters: any = {}; + let localVarHeaderParams: any = (Object).assign({}, this.defaultHeaders); + let localVarFormParams: any = {}; + + // verify required parameter 'objectWithEnums' is not null or undefined + if (objectWithEnums === null || objectWithEnums === undefined) { + throw new Error('Required parameter objectWithEnums was null or undefined when calling postObjectWithEnums.'); + } + + (Object).assign(localVarHeaderParams, options.headers); + + let localVarUseFormData = false; + + let localVarRequestOptions: localVarRequest.Options = { + method: 'POST', + qs: localVarQueryParameters, + headers: localVarHeaderParams, + uri: localVarPath, + useQuerystring: this._useQuerystring, + json: true, + body: ObjectSerializer.serialize(objectWithEnums, "ObjectWithEnums") + }; + + this.authentications.default.applyToRequest(localVarRequestOptions); + + if (Object.keys(localVarFormParams).length) { + if (localVarUseFormData) { + (localVarRequestOptions).formData = localVarFormParams; + } else { + localVarRequestOptions.form = localVarFormParams; + } + } + return new Promise<{ response: http.ClientResponse; body?: any; }>((resolve, reject) => { + localVarRequest(localVarRequestOptions, (error, response, body) => { + if (error) { + reject(error); + } else { + if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) { + resolve({ response: response, body: body }); + } else { + reject({ response: response, body: body }); + } + } + }); + }); + } +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/git_push.sh b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/git_push.sh new file mode 100644 index 0000000000..26bdd7ca69 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/git_push.sh @@ -0,0 +1,52 @@ +#!/bin/sh +# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ +# +# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" + +git_user_id=$1 +git_repo_id=$2 +release_note=$3 + +if [ "$git_user_id" = "" ]; then + git_user_id="" + echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" +fi + +if [ "$git_repo_id" = "" ]; then + git_repo_id="" + echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" +fi + +if [ "$release_note" = "" ]; then + release_note="" + echo "[INFO] No command line input provided. Set \$release_note to $release_note" +fi + +# Initialize the local directory as a Git repository +git init + +# Adds the files in the local repository and stages them for commit. +git add . + +# Commits the tracked changes and prepares them to be pushed to a remote repository. +git commit -m "$release_note" + +# Sets the new remote +git_remote=`git remote` +if [ "$git_remote" = "" ]; then # git remote not defined + + if [ "$GIT_TOKEN" = "" ]; then + echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." + git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git + else + git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git + fi + +fi + +git pull origin master + +# Pushes (Forces) the changes in the local repository up to the remote repository +echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git" +git push origin master 2>&1 | grep -v 'To https' + diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/externalEnum.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/externalEnum.ts new file mode 100644 index 0000000000..39d91b9163 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/externalEnum.ts @@ -0,0 +1,17 @@ +/** + * OpenAPI enums + * Tests generation of enums with open opi + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export enum ExternalEnum { + Green = 'green', + Yellow = 'yellow' +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/models.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/models.ts new file mode 100644 index 0000000000..896cb58875 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/models.ts @@ -0,0 +1,191 @@ +export * from './externalEnum'; +export * from './objectWithEnums'; + +import localVarRequest = require('request'); + +import { ExternalEnum } from './externalEnum'; +import { ObjectWithEnums } from './objectWithEnums'; + +/* tslint:disable:no-unused-variable */ +let primitives = [ + "string", + "boolean", + "double", + "integer", + "long", + "float", + "number", + "any" + ]; + +let enumsMap: {[index: string]: any} = { + "ExternalEnum": ExternalEnum, + "ObjectWithEnums.EnumInObjectEnum": ObjectWithEnums.EnumInObjectEnum, +} + +let typeMap: {[index: string]: any} = { + "ObjectWithEnums": ObjectWithEnums, +} + +export class ObjectSerializer { + public static findCorrectType(data: any, expectedType: string) { + if (data == undefined) { + return expectedType; + } else if (primitives.indexOf(expectedType.toLowerCase()) !== -1) { + return expectedType; + } else if (expectedType === "Date") { + return expectedType; + } else { + if (enumsMap[expectedType]) { + return expectedType; + } + + if (!typeMap[expectedType]) { + return expectedType; // w/e we don't know the type + } + + // Check the discriminator + let discriminatorProperty = typeMap[expectedType].discriminator; + if (discriminatorProperty == null) { + return expectedType; // the type does not have a discriminator. use it. + } else { + if (data[discriminatorProperty]) { + var discriminatorType = data[discriminatorProperty]; + if(typeMap[discriminatorType]){ + return discriminatorType; // use the type given in the discriminator + } else { + return expectedType; // discriminator did not map to a type + } + } else { + return expectedType; // discriminator was not present (or an empty string) + } + } + } + } + + public static serialize(data: any, type: string) { + if (data == undefined) { + return data; + } else if (primitives.indexOf(type.toLowerCase()) !== -1) { + return data; + } else if (type.lastIndexOf("Array<", 0) === 0) { // string.startsWith pre es6 + let subType: string = type.replace("Array<", ""); // Array => Type> + subType = subType.substring(0, subType.length - 1); // Type> => Type + let transformedData: any[] = []; + for (let index in data) { + let date = data[index]; + transformedData.push(ObjectSerializer.serialize(date, subType)); + } + return transformedData; + } else if (type === "Date") { + return data.toISOString(); + } else { + if (enumsMap[type]) { + return data; + } + if (!typeMap[type]) { // in case we dont know the type + return data; + } + + // Get the actual type of this object + type = this.findCorrectType(data, type); + + // get the map for the correct type. + let attributeTypes = typeMap[type].getAttributeTypeMap(); + let instance: {[index: string]: any} = {}; + for (let index in attributeTypes) { + let attributeType = attributeTypes[index]; + instance[attributeType.baseName] = ObjectSerializer.serialize(data[attributeType.name], attributeType.type); + } + return instance; + } + } + + public static deserialize(data: any, type: string) { + // polymorphism may change the actual type. + type = ObjectSerializer.findCorrectType(data, type); + if (data == undefined) { + return data; + } else if (primitives.indexOf(type.toLowerCase()) !== -1) { + return data; + } else if (type.lastIndexOf("Array<", 0) === 0) { // string.startsWith pre es6 + let subType: string = type.replace("Array<", ""); // Array => Type> + subType = subType.substring(0, subType.length - 1); // Type> => Type + let transformedData: any[] = []; + for (let index in data) { + let date = data[index]; + transformedData.push(ObjectSerializer.deserialize(date, subType)); + } + return transformedData; + } else if (type === "Date") { + return new Date(data); + } else { + if (enumsMap[type]) {// is Enum + return data; + } + + if (!typeMap[type]) { // dont know the type + return data; + } + let instance = new typeMap[type](); + let attributeTypes = typeMap[type].getAttributeTypeMap(); + for (let index in attributeTypes) { + let attributeType = attributeTypes[index]; + instance[attributeType.name] = ObjectSerializer.deserialize(data[attributeType.baseName], attributeType.type); + } + return instance; + } + } +} + +export interface Authentication { + /** + * Apply authentication settings to header and query params. + */ + applyToRequest(requestOptions: localVarRequest.Options): void; +} + +export class HttpBasicAuth implements Authentication { + public username: string = ''; + public password: string = ''; + + applyToRequest(requestOptions: localVarRequest.Options): void { + requestOptions.auth = { + username: this.username, password: this.password + } + } +} + +export class ApiKeyAuth implements Authentication { + public apiKey: string = ''; + + constructor(private location: string, private paramName: string) { + } + + applyToRequest(requestOptions: localVarRequest.Options): void { + if (this.location == "query") { + (requestOptions.qs)[this.paramName] = this.apiKey; + } else if (this.location == "header" && requestOptions && requestOptions.headers) { + requestOptions.headers[this.paramName] = this.apiKey; + } + } +} + +export class OAuth implements Authentication { + public accessToken: string = ''; + + applyToRequest(requestOptions: localVarRequest.Options): void { + if (requestOptions && requestOptions.headers) { + requestOptions.headers["Authorization"] = "Bearer " + this.accessToken; + } + } +} + +export class VoidAuth implements Authentication { + public username: string = ''; + public password: string = ''; + + applyToRequest(_: localVarRequest.Options): void { + // Do nothing + } +} \ No newline at end of file diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/objectWithEnums.ts b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/objectWithEnums.ts new file mode 100644 index 0000000000..c6675fdafd --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/model/objectWithEnums.ts @@ -0,0 +1,43 @@ +/** + * OpenAPI enums + * Tests generation of enums with open opi + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { ExternalEnum } from './externalEnum'; + +export class ObjectWithEnums { + 'enumInObject'?: ObjectWithEnums.EnumInObjectEnum; + 'externalEnum'?: ExternalEnum; + + static discriminator: string | undefined = undefined; + + static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [ + { + "name": "enumInObject", + "baseName": "enumInObject", + "type": "ObjectWithEnums.EnumInObjectEnum" + }, + { + "name": "externalEnum", + "baseName": "externalEnum", + "type": "ExternalEnum" + } ]; + + static getAttributeTypeMap() { + return ObjectWithEnums.attributeTypeMap; + } +} + +export namespace ObjectWithEnums { + export enum EnumInObjectEnum { + Red = 'red', + Blue = 'blue' + } +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/package.json b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/package.json new file mode 100644 index 0000000000..18383fe4b8 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/package.json @@ -0,0 +1,26 @@ +{ + "name": "node-es6-test", + "version": "1.0.3", + "description": "NodeJS client for node-es6-test", + "repository": "/", + "main": "dist/api.js", + "types": "dist/api.d.ts", + "scripts": { + "clean": "rm -Rf node_modules/ *.js", + "build": "tsc", + "test": "npm run build && node dist/client.js" + }, + "author": "OpenAPI-Generator Contributors", + "license": "Unlicense", + "dependencies": { + "bluebird": "^3.5.0", + "request": "^2.81.0", + "@types/bluebird": "*", + "@types/request": "*", + "rewire": "^3.0.2" + }, + "devDependencies": { + "typescript": "^2.4.2", + "@types/node": "8.10.34" + } +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/tsconfig.json b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/tsconfig.json new file mode 100644 index 0000000000..ba2570a4be --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-expected/tsconfig.json @@ -0,0 +1,20 @@ +{ + "compilerOptions": { + "module": "commonjs", + "noImplicitAny": false, + "suppressImplicitAnyIndexErrors": true, + "target": "ES5", + "strict": true, + "moduleResolution": "node", + "removeComments": true, + "sourceMap": true, + "noLib": false, + "declaration": true, + "lib": ["dom", "es6", "es5", "dom.iterable", "scripthost"], + "outDir": "dist" + }, + "exclude": [ + "dist", + "node_modules" + ] +} diff --git a/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-spec.json b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-spec.json new file mode 100644 index 0000000000..cf5b2ddd75 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/integrationtests/typescript/objectsWithEnums-spec.json @@ -0,0 +1,91 @@ +{ + "openapi" : "3.0.0", + "info" : { + "title" : "OpenAPI enums", + "description" : "Tests generation of enums with open opi", + "version" : "1.0.0" + }, + "servers" : [ { + "url" : "http://enums.openapi3" + } ], + "paths" : { + "/postobjectwithenums" : { + "post" : { + "operationId" : "postObjectWithEnums", + "requestBody" : { + "$ref" : "#/components/requestBodies/ObjectWithEnums" + }, + "responses" : { + "405" : { + "description" : "Invalid input" + } + } + } + }, + "/getobjectwithenums" : { + "get" : { + "operationId" : "getObjectWithEnums", + "responses" : { + "200" : { + "description" : "successful operation", + "content" : { + "application/xml" : { + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/ObjectWithEnums" + } + } + }, + "application/json" : { + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/ObjectWithEnums" + } + } + } + } + } + } + } + } + }, + "components" : { + "schemas" : { + "ObjectWithEnums" : { + "type" : "object", + "properties" : { + "enumInObject" : { + "type" : "string", + "enum" : [ "red", "blue" ] + }, + "externalEnum" : { + "$ref" : "#/components/schemas/ExternalEnum" + } + } + }, + "ExternalEnum" : { + "type" : "string", + "enum" : [ "green", "yellow" ] + } + }, + "requestBodies" : { + "ObjectWithEnums" : { + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ObjectWithEnums" + } + }, + "application/xml" : { + "schema" : { + "$ref" : "#/components/schemas/ObjectWithEnums" + } + } + }, + "required" : true + } + } + } +} \ No newline at end of file From 610ca28681c4dc1b1a6a002c87c6ab12fef5fda7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-Fran=C3=A7ois=20C=C3=B4t=C3=A9?= Date: Wed, 17 Jul 2019 16:30:27 -0400 Subject: [PATCH 20/62] Fix #3349 : [typescript-fetch] Proposition to follow spec (#3351) * Fix 3349 : Proposition to follow spec closely * Fix #3349 : Changes suggested by code review. Add an option for the single request parameter. * Fix #3349 : Add sample with the use of the single request parameter * Fix #3349 : Small fix that wasn't passing the tests * Fix #3349 : Remove cariage return that might create an error * Fix #3349 : Add chmod to make new sh file executable and fix the CircleCI issue * Fix #3349 : Add windows sample generation * Fix #3349 : Rename everything because of default value change * Fix #3349 : Indentation fix * Fix #3349 : Add 755 to typescript-fetch-petstore-multiple-parameters.sh * Fix #3349 : Auto generation of the documentations * Fix #3349 : Revert back a change that was auto-generated. --- .../builds/multiple-parameters/pom.xml | 26 + bin/typescript-fetch-petstore-all.sh | 1 + ...pt-fetch-petstore-multiple-parameters.json | 4 + ...ript-fetch-petstore-multiple-parameters.sh | 34 + bin/windows/typescript-fetch-petstore-all.bat | 1 + ...ipt-fetch-petstore-multiple-parameters.bat | 12 + docs/generators/typescript-fetch.md | 1 + .../TypeScriptFetchClientCodegen.java | 20 +- .../resources/typescript-fetch/apis.mustache | 29 +- .../TypeScriptFetchClientOptionsProvider.java | 1 + .../typescript-fetch/builds/default/api.ts | 1928 ----------------- .../builds/default/apis/PetApi.ts | 54 +- .../builds/default/apis/StoreApi.ts | 30 +- .../builds/default/apis/UserApi.ts | 54 +- .../builds/default/models/ApiResponse.ts | 60 - .../builds/default/models/InlineObject.ts | 52 - .../builds/default/models/InlineObject1.ts | 52 - .../builds/es6-target/apis/PetApi.ts | 54 +- .../builds/es6-target/apis/StoreApi.ts | 30 +- .../builds/es6-target/apis/UserApi.ts | 54 +- .../builds/es6-target/models/InlineObject1.ts | 52 - .../builds/multiple-parameters/.gitignore | 4 + .../.openapi-generator-ignore | 23 + .../.openapi-generator/VERSION | 1 + .../builds/multiple-parameters/apis/PetApi.ts | 424 ++++ .../multiple-parameters/apis/StoreApi.ts | 167 ++ .../multiple-parameters/apis/UserApi.ts | 321 +++ .../builds/multiple-parameters/apis/index.ts | 3 + .../builds/multiple-parameters/index.ts | 3 + .../models/Category.ts} | 30 +- .../models/ModelApiResponse.ts} | 18 +- .../multiple-parameters/models/Order.ts | 94 + .../builds/multiple-parameters/models/Pet.ts | 103 + .../models/Tag.ts} | 30 +- .../builds/multiple-parameters/models/User.ts | 100 + .../multiple-parameters/models/index.ts | 6 + .../builds/multiple-parameters/pom.xml | 26 + .../builds/multiple-parameters/runtime.ts | 284 +++ .../builds/multiple-parameters/tsconfig.json | 21 + .../builds/with-interfaces/apis/PetApi.ts | 54 +- .../builds/with-interfaces/apis/StoreApi.ts | 30 +- .../builds/with-interfaces/apis/UserApi.ts | 54 +- .../with-interfaces/models/ApiResponse.ts | 60 - .../with-interfaces/models/InlineObject1.ts | 52 - .../builds/with-npm-version/apis/PetApi.ts | 54 +- .../builds/with-npm-version/apis/StoreApi.ts | 30 +- .../builds/with-npm-version/apis/UserApi.ts | 54 +- .../with-npm-version/models/ApiResponse.ts | 60 - .../with-npm-version/models/InlineObject.ts | 52 - .../with-npm-version/models/InlineObject1.ts | 52 - .../builds/with-npm-version/package-lock.json | 14 - .../tests/default/package-lock.json | 52 +- .../tests/default/package.json | 1 + 53 files changed, 2048 insertions(+), 2778 deletions(-) create mode 100644 CI/samples.ci/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml create mode 100644 bin/typescript-fetch-petstore-multiple-parameters.json create mode 100755 bin/typescript-fetch-petstore-multiple-parameters.sh create mode 100644 bin/windows/typescript-fetch-petstore-multiple-parameters.bat delete mode 100644 samples/client/petstore/typescript-fetch/builds/default/api.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/default/models/ApiResponse.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/default/models/InlineObject.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/default/models/InlineObject1.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject1.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/.gitignore create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator-ignore create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator/VERSION create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/index.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/index.ts rename samples/client/petstore/typescript-fetch/builds/{es6-target/models/InlineObject.ts => multiple-parameters/models/Category.ts} (61%) rename samples/client/petstore/typescript-fetch/builds/{es6-target/models/ApiResponse.ts => multiple-parameters/models/ModelApiResponse.ts} (71%) create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts rename samples/client/petstore/typescript-fetch/builds/{with-interfaces/models/InlineObject.ts => multiple-parameters/models/Tag.ts} (61%) create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/index.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts create mode 100644 samples/client/petstore/typescript-fetch/builds/multiple-parameters/tsconfig.json delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ApiResponse.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject1.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-npm-version/models/ApiResponse.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject1.ts delete mode 100644 samples/client/petstore/typescript-fetch/builds/with-npm-version/package-lock.json diff --git a/CI/samples.ci/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml b/CI/samples.ci/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml new file mode 100644 index 0000000000..a6fc39c4f0 --- /dev/null +++ b/CI/samples.ci/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml @@ -0,0 +1,26 @@ + + 4.0.0 + org.openapitools + TypeScriptAngularBuildPestoreClientTests + pom + 1.0-SNAPSHOT + TS Fetch Multiple Parameters Petstore Client + + + + maven-dependency-plugin + + + package + + copy-dependencies + + + ${project.build.directory} + + + + + + + diff --git a/bin/typescript-fetch-petstore-all.sh b/bin/typescript-fetch-petstore-all.sh index 27cd5f104b..5611d4c6eb 100755 --- a/bin/typescript-fetch-petstore-all.sh +++ b/bin/typescript-fetch-petstore-all.sh @@ -4,3 +4,4 @@ ./bin/typescript-fetch-petstore-with-npm-version.sh ./bin/typescript-fetch-petstore-interfaces.sh ./bin/typescript-fetch-petstore.sh +./bin/typescript-fetch-petstore-multiple-parameters.sh \ No newline at end of file diff --git a/bin/typescript-fetch-petstore-multiple-parameters.json b/bin/typescript-fetch-petstore-multiple-parameters.json new file mode 100644 index 0000000000..c165a82a50 --- /dev/null +++ b/bin/typescript-fetch-petstore-multiple-parameters.json @@ -0,0 +1,4 @@ +{ + "snapshot" : false, + "useSingleRequestParameter": false +} \ No newline at end of file diff --git a/bin/typescript-fetch-petstore-multiple-parameters.sh b/bin/typescript-fetch-petstore-multiple-parameters.sh new file mode 100755 index 0000000000..6dfa018ef3 --- /dev/null +++ b/bin/typescript-fetch-petstore-multiple-parameters.sh @@ -0,0 +1,34 @@ +#!/bin/sh + +SCRIPT="$0" +echo "# START SCRIPT: $SCRIPT" + +while [ -h "$SCRIPT" ] ; do + ls=`ls -ld "$SCRIPT"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + SCRIPT="$link" + else + SCRIPT=`dirname "$SCRIPT"`/"$link" + fi +done + +if [ ! -d "${APP_DIR}" ]; then + APP_DIR=`dirname "$SCRIPT"`/.. + APP_DIR=`cd "${APP_DIR}"; pwd` +fi + +executable="./modules/openapi-generator-cli/target/openapi-generator-cli.jar" + +if [ ! -f "$executable" ] +then + mvn -B clean package +fi + +# if you've executed sbt assembly previously it will use that instead. +export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" +ags="generate -i modules/openapi-generator/src/test/resources/2_0/petstore.yaml -g typescript-fetch -c bin/typescript-fetch-petstore-multiple-parameters.json -o samples/client/petstore/typescript-fetch/builds/multiple-parameters $@" + +java $JAVA_OPTS -jar $executable $ags +cp CI/samples.ci/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml samples/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml +cp CI/samples.ci/client/petstore/typescript-fetch/tests/default/pom.xml samples/client/petstore/typescript-fetch/tests/default/pom.xml \ No newline at end of file diff --git a/bin/windows/typescript-fetch-petstore-all.bat b/bin/windows/typescript-fetch-petstore-all.bat index 69af38cf6a..c07605f175 100644 --- a/bin/windows/typescript-fetch-petstore-all.bat +++ b/bin/windows/typescript-fetch-petstore-all.bat @@ -4,3 +4,4 @@ call bin\windows\typescript-fetch-petstore.bat call bin\windows\typescript-fetch-petstore-target-es6.bat call bin\windows\typescript-fetch-petstore-with-npm-version.bat call bin\windows\typescript-fetch-petstore-interfaces.bat +call bin\windows\typescript-fetch-petstore-multiple-parameters.bat diff --git a/bin/windows/typescript-fetch-petstore-multiple-parameters.bat b/bin/windows/typescript-fetch-petstore-multiple-parameters.bat new file mode 100644 index 0000000000..095fdb3e5d --- /dev/null +++ b/bin/windows/typescript-fetch-petstore-multiple-parameters.bat @@ -0,0 +1,12 @@ +@ECHO OFF + +set executable=.\modules\openapi-generator-cli\target\openapi-generator-cli.jar + +If Not Exist %executable% ( + mvn clean package +) + +REM set JAVA_OPTS=%JAVA_OPTS% -Xmx1024M +set ags=generate -i modules\openapi-generator\src\test\resources\2_0\petstore.yaml -g typescript-fetch -c bin\typescript-fetch-petstore-multiple-parameters.json -o samples\client\petstore\typescript-fetch\builds\multiple-parameters + +java %JAVA_OPTS% -jar %executable% %ags% diff --git a/docs/generators/typescript-fetch.md b/docs/generators/typescript-fetch.md index 1ccb820eee..af45a95161 100644 --- a/docs/generators/typescript-fetch.md +++ b/docs/generators/typescript-fetch.md @@ -18,3 +18,4 @@ sidebar_label: typescript-fetch |snapshot|When setting this property to true, the version will be suffixed with -SNAPSHOT.yyyyMMddHHmm| |false| |npmRepository|Use this property to set an url your private npmRepo in the package.json| |null| |withInterfaces|Setting this property to true will generate interfaces next to the default class implementations.| |false| +|useSingleRequestParameter|Setting this property to true will generate functions with a single argument containing all API endpoint parameters instead of one argument per parameter.| |true| diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java index 4d80efd6a7..5521d72e7b 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java @@ -24,19 +24,18 @@ import org.openapitools.codegen.*; import org.openapitools.codegen.utils.ModelUtils; import java.io.File; -import java.text.SimpleDateFormat; import java.util.TreeSet; -import java.util.Date; import java.util.List; -import java.util.Locale; import java.util.Map; public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodegen { public static final String NPM_REPOSITORY = "npmRepository"; public static final String WITH_INTERFACES = "withInterfaces"; + public static final String USE_SINGLE_REQUEST_PARAMETER = "useSingleRequestParameter"; protected String npmRepository = null; + private boolean useSingleRequestParameter = true; public TypeScriptFetchClientCodegen() { super(); @@ -56,6 +55,7 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege this.cliOptions.add(new CliOption(NPM_REPOSITORY, "Use this property to set an url your private npmRepo in the package.json")); this.cliOptions.add(new CliOption(WITH_INTERFACES, "Setting this property to true will generate interfaces next to the default class implementations.", SchemaTypeUtil.BOOLEAN_TYPE).defaultValue(Boolean.FALSE.toString())); + this.cliOptions.add(new CliOption(USE_SINGLE_REQUEST_PARAMETER, "Setting this property to true will generate functions with a single argument containing all API endpoint parameters instead of one argument per parameter.", SchemaTypeUtil.BOOLEAN_TYPE).defaultValue(Boolean.TRUE.toString())); } @Override @@ -87,6 +87,12 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege supportingFiles.add(new SupportingFile("models.index.mustache", modelPackage().replace('.', File.separatorChar), "index.ts")); supportingFiles.add(new SupportingFile("tsconfig.mustache", "", "tsconfig.json")); supportingFiles.add(new SupportingFile("gitignore", "", ".gitignore")); + + if (additionalProperties.containsKey(USE_SINGLE_REQUEST_PARAMETER)) { + this.setUseSingleRequestParameter(convertPropertyToBoolean(USE_SINGLE_REQUEST_PARAMETER)); + } + writePropertyBack(USE_SINGLE_REQUEST_PARAMETER, getUseSingleRequestParameter()); + if (additionalProperties.containsKey(NPM_NAME)) { addNpmPackageGeneration(); } @@ -245,4 +251,12 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege this.reservedWords.add("BlobApiResponse"); this.reservedWords.add("TextApiResponse"); } + + private boolean getUseSingleRequestParameter() { + return useSingleRequestParameter; + } + + private void setUseSingleRequestParameter(boolean useSingleRequestParameter) { + this.useSingleRequestParameter = useSingleRequestParameter; + } } diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache index b903769d8a..662ec63b5b 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/apis.mustache @@ -229,14 +229,26 @@ export class {{classname}} extends runtime.BaseAPI { {{/returnType}} } - /** - {{#notes}} - * {{¬es}} - {{/notes}} - {{#summary}} - * {{&summary}} - {{/summary}} - */ + /** + {{#notes}} + * {{¬es}} + {{/notes}} + {{#summary}} + * {{&summary}} + {{/summary}} + */ + {{^useSingleRequestParameter}} + async {{nickname}}({{#allParams}}{{paramName}}{{^required}}?{{/required}}: {{#isEnum}}{{{datatypeWithEnum}}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{#hasMore}}, {{/hasMore}}{{/allParams}}): Promise<{{#returnType}}{{{returnType}}}{{/returnType}}{{^returnType}}void{{/returnType}}> { + {{#returnType}} + const response = await this.{{nickname}}Raw({{#allParams.0}}{ {{#allParams}}{{paramName}}: {{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}} }{{/allParams.0}}); + return await response.value(); + {{/returnType}} + {{^returnType}} + await this.{{nickname}}Raw({{#allParams.0}}{ {{#allParams}}{{paramName}}: {{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}} }{{/allParams.0}}); + {{/returnType}} + } + {{/useSingleRequestParameter}} + {{#useSingleRequestParameter}} async {{nickname}}({{#allParams.0}}requestParameters: {{operationIdCamelCase}}Request{{/allParams.0}}): Promise<{{#returnType}}{{{returnType}}}{{/returnType}}{{^returnType}}void{{/returnType}}> { {{#returnType}} const response = await this.{{nickname}}Raw({{#allParams.0}}requestParameters{{/allParams.0}}); @@ -246,6 +258,7 @@ export class {{classname}} extends runtime.BaseAPI { await this.{{nickname}}Raw({{#allParams.0}}requestParameters{{/allParams.0}}); {{/returnType}} } + {{/useSingleRequestParameter}} {{/operation}} } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/options/TypeScriptFetchClientOptionsProvider.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/options/TypeScriptFetchClientOptionsProvider.java index 46d991e03c..28cb997208 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/options/TypeScriptFetchClientOptionsProvider.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/options/TypeScriptFetchClientOptionsProvider.java @@ -51,6 +51,7 @@ public class TypeScriptFetchClientOptionsProvider implements OptionsProvider { .put(TypeScriptFetchClientCodegen.NPM_REPOSITORY, NPM_REPOSITORY) .put(TypeScriptFetchClientCodegen.SNAPSHOT, Boolean.FALSE.toString()) .put(TypeScriptFetchClientCodegen.WITH_INTERFACES, Boolean.FALSE.toString()) + .put(TypeScriptFetchClientCodegen.USE_SINGLE_REQUEST_PARAMETER, Boolean.FALSE.toString()) .put(CodegenConstants.ALLOW_UNICODE_IDENTIFIERS, ALLOW_UNICODE_IDENTIFIERS_VALUE) .put(CodegenConstants.PREPEND_FORM_OR_BODY_PARAMETERS, PREPEND_FORM_OR_BODY_PARAMETERS_VALUE) .build(); diff --git a/samples/client/petstore/typescript-fetch/builds/default/api.ts b/samples/client/petstore/typescript-fetch/builds/default/api.ts deleted file mode 100644 index 4a39a9c8b5..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/default/api.ts +++ /dev/null @@ -1,1928 +0,0 @@ -/// -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * OpenAPI spec version: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, ""); - -/** - * Describes the result of uploading an image resource - * @export - * @interface ApiResponse - */ -export interface ApiResponse { - /** - * - * @type {number} - * @memberof ApiResponse - */ - code?: number; - /** - * - * @type {string} - * @memberof ApiResponse - */ - type?: string; - /** - * - * @type {string} - * @memberof ApiResponse - */ - message?: string; -} - -/** - * A category for a pet - * @export - * @interface Category - */ -export interface Category { - /** - * - * @type {number} - * @memberof Category - */ - id?: number; - /** - * - * @type {string} - * @memberof Category - */ - name?: string; -} - -/** - * An order for a pets from the pet store - * @export - * @interface Order - */ -export interface Order { - /** - * - * @type {number} - * @memberof Order - */ - id?: number; - /** - * - * @type {number} - * @memberof Order - */ - petId?: number; - /** - * - * @type {number} - * @memberof Order - */ - quantity?: number; - /** - * - * @type {Date} - * @memberof Order - */ - shipDate?: Date; - /** - * Order Status - * @type {string} - * @memberof Order - */ - status?: Order.StatusEnum; - /** - * - * @type {boolean} - * @memberof Order - */ - complete?: boolean; -} - -/** - * @export - * @namespace Order - */ -export namespace Order { - /** - * @export - * @enum {string} - */ - export enum StatusEnum { - Placed = 'placed', - Approved = 'approved', - Delivered = 'delivered' - } -} - -/** - * A pet for sale in the pet store - * @export - * @interface Pet - */ -export interface Pet { - /** - * - * @type {number} - * @memberof Pet - */ - id?: number; - /** - * - * @type {Category} - * @memberof Pet - */ - category?: Category; - /** - * - * @type {string} - * @memberof Pet - */ - name: string; - /** - * - * @type {Array} - * @memberof Pet - */ - photoUrls: Array; - /** - * - * @type {Array} - * @memberof Pet - */ - tags?: Array; - /** - * pet status in the store - * @type {string} - * @memberof Pet - */ - status?: Pet.StatusEnum; -} - -/** - * @export - * @namespace Pet - */ -export namespace Pet { - /** - * @export - * @enum {string} - */ - export enum StatusEnum { - Available = 'available', - Pending = 'pending', - Sold = 'sold' - } -} - -/** - * A tag for a pet - * @export - * @interface Tag - */ -export interface Tag { - /** - * - * @type {number} - * @memberof Tag - */ - id?: number; - /** - * - * @type {string} - * @memberof Tag - */ - name?: string; -} - -/** - * A User who is purchasing from the pet store - * @export - * @interface User - */ -export interface User { - /** - * - * @type {number} - * @memberof User - */ - id?: number; - /** - * - * @type {string} - * @memberof User - */ - username?: string; - /** - * - * @type {string} - * @memberof User - */ - firstName?: string; - /** - * - * @type {string} - * @memberof User - */ - lastName?: string; - /** - * - * @type {string} - * @memberof User - */ - email?: string; - /** - * - * @type {string} - * @memberof User - */ - password?: string; - /** - * - * @type {string} - * @memberof User - */ - phone?: string; - /** - * User Status - * @type {number} - * @memberof User - */ - userStatus?: number; -} - - -/** - * PetApi - fetch parameter creator - * @export - */ -export const PetApiFetchParamCreator = function (configuration?: Configuration) { - return { - /** - * - * @summary Add a new pet to the store - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - addPet(pet: Pet, options: any = {}): FetchArgs { - // verify required parameter 'pet' is not null or undefined - if (pet === null || pet === undefined) { - throw new RequiredError('pet','Required parameter pet was null or undefined when calling addPet.'); - } - const localVarPath = `/pet`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("Pet" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(pet || {}) : (pet || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Deletes a pet - * @param {number} petId Pet id to delete - * @param {string} [apiKey] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deletePet(petId: number, apiKey?: string, options: any = {}): FetchArgs { - // verify required parameter 'petId' is not null or undefined - if (petId === null || petId === undefined) { - throw new RequiredError('petId','Required parameter petId was null or undefined when calling deletePet.'); - } - const localVarPath = `/pet/{petId}` - .replace(`{${"petId"}}`, encodeURIComponent(String(petId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'DELETE' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - if (apiKey !== undefined && apiKey !== null) { - localVarHeaderParameter['api_key'] = String(apiKey); - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * Multiple status values can be provided with comma separated strings - * @summary Finds Pets by status - * @param {Array<'available' | 'pending' | 'sold'>} status Status values that need to be considered for filter - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByStatus(status: Array<'available' | 'pending' | 'sold'>, options: any = {}): FetchArgs { - // verify required parameter 'status' is not null or undefined - if (status === null || status === undefined) { - throw new RequiredError('status','Required parameter status was null or undefined when calling findPetsByStatus.'); - } - const localVarPath = `/pet/findByStatus`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - if (status) { - localVarQueryParameter['status'] = status.join(COLLECTION_FORMATS["csv"]); - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * @summary Finds Pets by tags - * @param {Array} tags Tags to filter by - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByTags(tags: Array, options: any = {}): FetchArgs { - // verify required parameter 'tags' is not null or undefined - if (tags === null || tags === undefined) { - throw new RequiredError('tags','Required parameter tags was null or undefined when calling findPetsByTags.'); - } - const localVarPath = `/pet/findByTags`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - if (tags) { - localVarQueryParameter['tags'] = tags.join(COLLECTION_FORMATS["csv"]); - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * Returns a single pet - * @summary Find pet by ID - * @param {number} petId ID of pet to return - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getPetById(petId: number, options: any = {}): FetchArgs { - // verify required parameter 'petId' is not null or undefined - if (petId === null || petId === undefined) { - throw new RequiredError('petId','Required parameter petId was null or undefined when calling getPetById.'); - } - const localVarPath = `/pet/{petId}` - .replace(`{${"petId"}}`, encodeURIComponent(String(petId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication api_key required - if (configuration && configuration.apiKey) { - const localVarApiKeyValue = typeof configuration.apiKey === 'function' - ? configuration.apiKey("api_key") - : configuration.apiKey; - localVarHeaderParameter["api_key"] = localVarApiKeyValue; - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Update an existing pet - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePet(pet: Pet, options: any = {}): FetchArgs { - // verify required parameter 'pet' is not null or undefined - if (pet === null || pet === undefined) { - throw new RequiredError('pet','Required parameter pet was null or undefined when calling updatePet.'); - } - const localVarPath = `/pet`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'PUT' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("Pet" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(pet || {}) : (pet || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Updates a pet in the store with form data - * @param {number} petId ID of pet that needs to be updated - * @param {string} [name] Updated name of the pet - * @param {string} [status] Updated status of the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePetWithForm(petId: number, name?: string, status?: string, options: any = {}): FetchArgs { - // verify required parameter 'petId' is not null or undefined - if (petId === null || petId === undefined) { - throw new RequiredError('petId','Required parameter petId was null or undefined when calling updatePetWithForm.'); - } - const localVarPath = `/pet/{petId}` - .replace(`{${"petId"}}`, encodeURIComponent(String(petId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - const localVarFormParams = new url.URLSearchParams(); - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - if (name !== undefined) { - localVarFormParams.set('name', name as any); - } - - if (status !== undefined) { - localVarFormParams.set('status', status as any); - } - - localVarHeaderParameter['Content-Type'] = 'application/x-www-form-urlencoded'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - localVarRequestOptions.body = localVarFormParams.toString(); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary uploads an image - * @param {number} petId ID of pet to update - * @param {string} [additionalMetadata] Additional data to pass to server - * @param {any} [file] file to upload - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - uploadFile(petId: number, additionalMetadata?: string, file?: any, options: any = {}): FetchArgs { - // verify required parameter 'petId' is not null or undefined - if (petId === null || petId === undefined) { - throw new RequiredError('petId','Required parameter petId was null or undefined when calling uploadFile.'); - } - const localVarPath = `/pet/{petId}/uploadImage` - .replace(`{${"petId"}}`, encodeURIComponent(String(petId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - const localVarFormParams = new url.URLSearchParams(); - - // authentication petstore_auth required - // oauth required - if (configuration && configuration.accessToken) { - const localVarAccessTokenValue = typeof configuration.accessToken === 'function' - ? configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]) - : configuration.accessToken; - localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue; - } - - if (additionalMetadata !== undefined) { - localVarFormParams.set('additionalMetadata', additionalMetadata as any); - } - - if (file !== undefined) { - localVarFormParams.set('file', file as any); - } - - localVarHeaderParameter['Content-Type'] = 'application/x-www-form-urlencoded'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - localVarRequestOptions.body = localVarFormParams.toString(); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - } -}; - -/** - * PetApi - functional programming interface - * @export - */ -export const PetApiFp = function(configuration?: Configuration) { - return { - /** - * - * @summary Add a new pet to the store - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - addPet(pet: Pet, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).addPet(pet, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Deletes a pet - * @param {number} petId Pet id to delete - * @param {string} [apiKey] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deletePet(petId: number, apiKey?: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).deletePet(petId, apiKey, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * Multiple status values can be provided with comma separated strings - * @summary Finds Pets by status - * @param {Array<'available' | 'pending' | 'sold'>} status Status values that need to be considered for filter - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByStatus(status: Array<'available' | 'pending' | 'sold'>, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise> { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).findPetsByStatus(status, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * @summary Finds Pets by tags - * @param {Array} tags Tags to filter by - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByTags(tags: Array, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise> { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).findPetsByTags(tags, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * Returns a single pet - * @summary Find pet by ID - * @param {number} petId ID of pet to return - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getPetById(petId: number, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).getPetById(petId, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Update an existing pet - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePet(pet: Pet, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).updatePet(pet, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Updates a pet in the store with form data - * @param {number} petId ID of pet that needs to be updated - * @param {string} [name] Updated name of the pet - * @param {string} [status] Updated status of the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePetWithForm(petId: number, name?: string, status?: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).updatePetWithForm(petId, name, status, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary uploads an image - * @param {number} petId ID of pet to update - * @param {string} [additionalMetadata] Additional data to pass to server - * @param {any} [file] file to upload - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - uploadFile(petId: number, additionalMetadata?: string, file?: any, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = PetApiFetchParamCreator(configuration).uploadFile(petId, additionalMetadata, file, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - } -}; - -/** - * PetApi - factory interface - * @export - */ -export const PetApiFactory = function (configuration?: Configuration, fetch?: FetchAPI, basePath?: string) { - return { - /** - * - * @summary Add a new pet to the store - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - addPet(pet: Pet, options?: any) { - return PetApiFp(configuration).addPet(pet, options)(fetch, basePath); - }, - /** - * - * @summary Deletes a pet - * @param {number} petId Pet id to delete - * @param {string} [apiKey] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deletePet(petId: number, apiKey?: string, options?: any) { - return PetApiFp(configuration).deletePet(petId, apiKey, options)(fetch, basePath); - }, - /** - * Multiple status values can be provided with comma separated strings - * @summary Finds Pets by status - * @param {Array<'available' | 'pending' | 'sold'>} status Status values that need to be considered for filter - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByStatus(status: Array<'available' | 'pending' | 'sold'>, options?: any) { - return PetApiFp(configuration).findPetsByStatus(status, options)(fetch, basePath); - }, - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * @summary Finds Pets by tags - * @param {Array} tags Tags to filter by - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - findPetsByTags(tags: Array, options?: any) { - return PetApiFp(configuration).findPetsByTags(tags, options)(fetch, basePath); - }, - /** - * Returns a single pet - * @summary Find pet by ID - * @param {number} petId ID of pet to return - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getPetById(petId: number, options?: any) { - return PetApiFp(configuration).getPetById(petId, options)(fetch, basePath); - }, - /** - * - * @summary Update an existing pet - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePet(pet: Pet, options?: any) { - return PetApiFp(configuration).updatePet(pet, options)(fetch, basePath); - }, - /** - * - * @summary Updates a pet in the store with form data - * @param {number} petId ID of pet that needs to be updated - * @param {string} [name] Updated name of the pet - * @param {string} [status] Updated status of the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updatePetWithForm(petId: number, name?: string, status?: string, options?: any) { - return PetApiFp(configuration).updatePetWithForm(petId, name, status, options)(fetch, basePath); - }, - /** - * - * @summary uploads an image - * @param {number} petId ID of pet to update - * @param {string} [additionalMetadata] Additional data to pass to server - * @param {any} [file] file to upload - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - uploadFile(petId: number, additionalMetadata?: string, file?: any, options?: any) { - return PetApiFp(configuration).uploadFile(petId, additionalMetadata, file, options)(fetch, basePath); - }, - }; -}; - -/** - * PetApi - object-oriented interface - * @export - * @class PetApi - * @extends {BaseAPI} - */ -export class PetApi extends BaseAPI { - /** - * - * @summary Add a new pet to the store - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public addPet(pet: Pet, options?: any) { - return PetApiFp(this.configuration).addPet(pet, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Deletes a pet - * @param {number} petId Pet id to delete - * @param {string} [apiKey] - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public deletePet(petId: number, apiKey?: string, options?: any) { - return PetApiFp(this.configuration).deletePet(petId, apiKey, options)(this.fetch, this.basePath); - } - - /** - * Multiple status values can be provided with comma separated strings - * @summary Finds Pets by status - * @param {Array<'available' | 'pending' | 'sold'>} status Status values that need to be considered for filter - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public findPetsByStatus(status: Array<'available' | 'pending' | 'sold'>, options?: any) { - return PetApiFp(this.configuration).findPetsByStatus(status, options)(this.fetch, this.basePath); - } - - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * @summary Finds Pets by tags - * @param {Array} tags Tags to filter by - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public findPetsByTags(tags: Array, options?: any) { - return PetApiFp(this.configuration).findPetsByTags(tags, options)(this.fetch, this.basePath); - } - - /** - * Returns a single pet - * @summary Find pet by ID - * @param {number} petId ID of pet to return - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public getPetById(petId: number, options?: any) { - return PetApiFp(this.configuration).getPetById(petId, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Update an existing pet - * @param {Pet} pet Pet object that needs to be added to the store - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public updatePet(pet: Pet, options?: any) { - return PetApiFp(this.configuration).updatePet(pet, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Updates a pet in the store with form data - * @param {number} petId ID of pet that needs to be updated - * @param {string} [name] Updated name of the pet - * @param {string} [status] Updated status of the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public updatePetWithForm(petId: number, name?: string, status?: string, options?: any) { - return PetApiFp(this.configuration).updatePetWithForm(petId, name, status, options)(this.fetch, this.basePath); - } - - /** - * - * @summary uploads an image - * @param {number} petId ID of pet to update - * @param {string} [additionalMetadata] Additional data to pass to server - * @param {any} [file] file to upload - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof PetApi - */ - public uploadFile(petId: number, additionalMetadata?: string, file?: any, options?: any) { - return PetApiFp(this.configuration).uploadFile(petId, additionalMetadata, file, options)(this.fetch, this.basePath); - } - -} - -/** - * StoreApi - fetch parameter creator - * @export - */ -export const StoreApiFetchParamCreator = function (configuration?: Configuration) { - return { - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * @summary Delete purchase order by ID - * @param {string} orderId ID of the order that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteOrder(orderId: string, options: any = {}): FetchArgs { - // verify required parameter 'orderId' is not null or undefined - if (orderId === null || orderId === undefined) { - throw new RequiredError('orderId','Required parameter orderId was null or undefined when calling deleteOrder.'); - } - const localVarPath = `/store/order/{orderId}` - .replace(`{${"orderId"}}`, encodeURIComponent(String(orderId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'DELETE' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * Returns a map of status codes to quantities - * @summary Returns pet inventories by status - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getInventory(options: any = {}): FetchArgs { - const localVarPath = `/store/inventory`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - // authentication api_key required - if (configuration && configuration.apiKey) { - const localVarApiKeyValue = typeof configuration.apiKey === 'function' - ? configuration.apiKey("api_key") - : configuration.apiKey; - localVarHeaderParameter["api_key"] = localVarApiKeyValue; - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * @summary Find purchase order by ID - * @param {number} orderId ID of pet that needs to be fetched - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getOrderById(orderId: number, options: any = {}): FetchArgs { - // verify required parameter 'orderId' is not null or undefined - if (orderId === null || orderId === undefined) { - throw new RequiredError('orderId','Required parameter orderId was null or undefined when calling getOrderById.'); - } - const localVarPath = `/store/order/{orderId}` - .replace(`{${"orderId"}}`, encodeURIComponent(String(orderId))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Place an order for a pet - * @param {Order} order order placed for purchasing the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - placeOrder(order: Order, options: any = {}): FetchArgs { - // verify required parameter 'order' is not null or undefined - if (order === null || order === undefined) { - throw new RequiredError('order','Required parameter order was null or undefined when calling placeOrder.'); - } - const localVarPath = `/store/order`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("Order" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(order || {}) : (order || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - } -}; - -/** - * StoreApi - functional programming interface - * @export - */ -export const StoreApiFp = function(configuration?: Configuration) { - return { - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * @summary Delete purchase order by ID - * @param {string} orderId ID of the order that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteOrder(orderId: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = StoreApiFetchParamCreator(configuration).deleteOrder(orderId, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * Returns a map of status codes to quantities - * @summary Returns pet inventories by status - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getInventory(options?: any): (fetch?: FetchAPI, basePath?: string) => Promise<{ [key: string]: number; }> { - const localVarFetchArgs = StoreApiFetchParamCreator(configuration).getInventory(options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * @summary Find purchase order by ID - * @param {number} orderId ID of pet that needs to be fetched - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getOrderById(orderId: number, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = StoreApiFetchParamCreator(configuration).getOrderById(orderId, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Place an order for a pet - * @param {Order} order order placed for purchasing the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - placeOrder(order: Order, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = StoreApiFetchParamCreator(configuration).placeOrder(order, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - } -}; - -/** - * StoreApi - factory interface - * @export - */ -export const StoreApiFactory = function (configuration?: Configuration, fetch?: FetchAPI, basePath?: string) { - return { - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * @summary Delete purchase order by ID - * @param {string} orderId ID of the order that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteOrder(orderId: string, options?: any) { - return StoreApiFp(configuration).deleteOrder(orderId, options)(fetch, basePath); - }, - /** - * Returns a map of status codes to quantities - * @summary Returns pet inventories by status - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getInventory(options?: any) { - return StoreApiFp(configuration).getInventory(options)(fetch, basePath); - }, - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * @summary Find purchase order by ID - * @param {number} orderId ID of pet that needs to be fetched - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getOrderById(orderId: number, options?: any) { - return StoreApiFp(configuration).getOrderById(orderId, options)(fetch, basePath); - }, - /** - * - * @summary Place an order for a pet - * @param {Order} order order placed for purchasing the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - placeOrder(order: Order, options?: any) { - return StoreApiFp(configuration).placeOrder(order, options)(fetch, basePath); - }, - }; -}; - -/** - * StoreApi - object-oriented interface - * @export - * @class StoreApi - * @extends {BaseAPI} - */ -export class StoreApi extends BaseAPI { - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * @summary Delete purchase order by ID - * @param {string} orderId ID of the order that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof StoreApi - */ - public deleteOrder(orderId: string, options?: any) { - return StoreApiFp(this.configuration).deleteOrder(orderId, options)(this.fetch, this.basePath); - } - - /** - * Returns a map of status codes to quantities - * @summary Returns pet inventories by status - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof StoreApi - */ - public getInventory(options?: any) { - return StoreApiFp(this.configuration).getInventory(options)(this.fetch, this.basePath); - } - - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * @summary Find purchase order by ID - * @param {number} orderId ID of pet that needs to be fetched - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof StoreApi - */ - public getOrderById(orderId: number, options?: any) { - return StoreApiFp(this.configuration).getOrderById(orderId, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Place an order for a pet - * @param {Order} order order placed for purchasing the pet - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof StoreApi - */ - public placeOrder(order: Order, options?: any) { - return StoreApiFp(this.configuration).placeOrder(order, options)(this.fetch, this.basePath); - } - -} - -/** - * UserApi - fetch parameter creator - * @export - */ -export const UserApiFetchParamCreator = function (configuration?: Configuration) { - return { - /** - * This can only be done by the logged in user. - * @summary Create user - * @param {User} user Created user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUser(user: User, options: any = {}): FetchArgs { - // verify required parameter 'user' is not null or undefined - if (user === null || user === undefined) { - throw new RequiredError('user','Required parameter user was null or undefined when calling createUser.'); - } - const localVarPath = `/user`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("User" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(user || {}) : (user || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithArrayInput(user: Array, options: any = {}): FetchArgs { - // verify required parameter 'user' is not null or undefined - if (user === null || user === undefined) { - throw new RequiredError('user','Required parameter user was null or undefined when calling createUsersWithArrayInput.'); - } - const localVarPath = `/user/createWithArray`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("Array<User>" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(user || {}) : (user || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithListInput(user: Array, options: any = {}): FetchArgs { - // verify required parameter 'user' is not null or undefined - if (user === null || user === undefined) { - throw new RequiredError('user','Required parameter user was null or undefined when calling createUsersWithListInput.'); - } - const localVarPath = `/user/createWithList`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'POST' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("Array<User>" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(user || {}) : (user || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * This can only be done by the logged in user. - * @summary Delete user - * @param {string} username The name that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteUser(username: string, options: any = {}): FetchArgs { - // verify required parameter 'username' is not null or undefined - if (username === null || username === undefined) { - throw new RequiredError('username','Required parameter username was null or undefined when calling deleteUser.'); - } - const localVarPath = `/user/{username}` - .replace(`{${"username"}}`, encodeURIComponent(String(username))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'DELETE' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Get user by user name - * @param {string} username The name that needs to be fetched. Use user1 for testing. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getUserByName(username: string, options: any = {}): FetchArgs { - // verify required parameter 'username' is not null or undefined - if (username === null || username === undefined) { - throw new RequiredError('username','Required parameter username was null or undefined when calling getUserByName.'); - } - const localVarPath = `/user/{username}` - .replace(`{${"username"}}`, encodeURIComponent(String(username))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Logs user into the system - * @param {string} username The user name for login - * @param {string} password The password for login in clear text - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - loginUser(username: string, password: string, options: any = {}): FetchArgs { - // verify required parameter 'username' is not null or undefined - if (username === null || username === undefined) { - throw new RequiredError('username','Required parameter username was null or undefined when calling loginUser.'); - } - // verify required parameter 'password' is not null or undefined - if (password === null || password === undefined) { - throw new RequiredError('password','Required parameter password was null or undefined when calling loginUser.'); - } - const localVarPath = `/user/login`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - if (username !== undefined) { - localVarQueryParameter['username'] = username; - } - - if (password !== undefined) { - localVarQueryParameter['password'] = password; - } - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * - * @summary Logs out current logged in user session - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - logoutUser(options: any = {}): FetchArgs { - const localVarPath = `/user/logout`; - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'GET' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - /** - * This can only be done by the logged in user. - * @summary Updated user - * @param {string} username name that need to be deleted - * @param {User} user Updated user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updateUser(username: string, user: User, options: any = {}): FetchArgs { - // verify required parameter 'username' is not null or undefined - if (username === null || username === undefined) { - throw new RequiredError('username','Required parameter username was null or undefined when calling updateUser.'); - } - // verify required parameter 'user' is not null or undefined - if (user === null || user === undefined) { - throw new RequiredError('user','Required parameter user was null or undefined when calling updateUser.'); - } - const localVarPath = `/user/{username}` - .replace(`{${"username"}}`, encodeURIComponent(String(username))); - const localVarUrlObj = url.parse(localVarPath, true); - const localVarRequestOptions = Object.assign({ method: 'PUT' }, options); - const localVarHeaderParameter = {} as any; - const localVarQueryParameter = {} as any; - - localVarHeaderParameter['Content-Type'] = 'application/json'; - - localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query); - // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943 - delete localVarUrlObj.search; - localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers); - const needsSerialization = ("User" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json'; - localVarRequestOptions.body = needsSerialization ? JSON.stringify(user || {}) : (user || ""); - - return { - url: url.format(localVarUrlObj), - options: localVarRequestOptions, - }; - }, - } -}; - -/** - * UserApi - functional programming interface - * @export - */ -export const UserApiFp = function(configuration?: Configuration) { - return { - /** - * This can only be done by the logged in user. - * @summary Create user - * @param {User} user Created user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUser(user: User, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).createUser(user, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithArrayInput(user: Array, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).createUsersWithArrayInput(user, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithListInput(user: Array, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).createUsersWithListInput(user, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * This can only be done by the logged in user. - * @summary Delete user - * @param {string} username The name that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteUser(username: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).deleteUser(username, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Get user by user name - * @param {string} username The name that needs to be fetched. Use user1 for testing. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getUserByName(username: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).getUserByName(username, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Logs user into the system - * @param {string} username The user name for login - * @param {string} password The password for login in clear text - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - loginUser(username: string, password: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).loginUser(username, password, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response.json(); - } else { - throw response; - } - }); - }; - }, - /** - * - * @summary Logs out current logged in user session - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - logoutUser(options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).logoutUser(options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - /** - * This can only be done by the logged in user. - * @summary Updated user - * @param {string} username name that need to be deleted - * @param {User} user Updated user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updateUser(username: string, user: User, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise { - const localVarFetchArgs = UserApiFetchParamCreator(configuration).updateUser(username, user, options); - return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => { - return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => { - if (response.status >= 200 && response.status < 300) { - return response; - } else { - throw response; - } - }); - }; - }, - } -}; - -/** - * UserApi - factory interface - * @export - */ -export const UserApiFactory = function (configuration?: Configuration, fetch?: FetchAPI, basePath?: string) { - return { - /** - * This can only be done by the logged in user. - * @summary Create user - * @param {User} user Created user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUser(user: User, options?: any) { - return UserApiFp(configuration).createUser(user, options)(fetch, basePath); - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithArrayInput(user: Array, options?: any) { - return UserApiFp(configuration).createUsersWithArrayInput(user, options)(fetch, basePath); - }, - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - createUsersWithListInput(user: Array, options?: any) { - return UserApiFp(configuration).createUsersWithListInput(user, options)(fetch, basePath); - }, - /** - * This can only be done by the logged in user. - * @summary Delete user - * @param {string} username The name that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - deleteUser(username: string, options?: any) { - return UserApiFp(configuration).deleteUser(username, options)(fetch, basePath); - }, - /** - * - * @summary Get user by user name - * @param {string} username The name that needs to be fetched. Use user1 for testing. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - getUserByName(username: string, options?: any) { - return UserApiFp(configuration).getUserByName(username, options)(fetch, basePath); - }, - /** - * - * @summary Logs user into the system - * @param {string} username The user name for login - * @param {string} password The password for login in clear text - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - loginUser(username: string, password: string, options?: any) { - return UserApiFp(configuration).loginUser(username, password, options)(fetch, basePath); - }, - /** - * - * @summary Logs out current logged in user session - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - logoutUser(options?: any) { - return UserApiFp(configuration).logoutUser(options)(fetch, basePath); - }, - /** - * This can only be done by the logged in user. - * @summary Updated user - * @param {string} username name that need to be deleted - * @param {User} user Updated user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - */ - updateUser(username: string, user: User, options?: any) { - return UserApiFp(configuration).updateUser(username, user, options)(fetch, basePath); - }, - }; -}; - -/** - * UserApi - object-oriented interface - * @export - * @class UserApi - * @extends {BaseAPI} - */ -export class UserApi extends BaseAPI { - /** - * This can only be done by the logged in user. - * @summary Create user - * @param {User} user Created user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public createUser(user: User, options?: any) { - return UserApiFp(this.configuration).createUser(user, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public createUsersWithArrayInput(user: Array, options?: any) { - return UserApiFp(this.configuration).createUsersWithArrayInput(user, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Creates list of users with given input array - * @param {Array} user List of user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public createUsersWithListInput(user: Array, options?: any) { - return UserApiFp(this.configuration).createUsersWithListInput(user, options)(this.fetch, this.basePath); - } - - /** - * This can only be done by the logged in user. - * @summary Delete user - * @param {string} username The name that needs to be deleted - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public deleteUser(username: string, options?: any) { - return UserApiFp(this.configuration).deleteUser(username, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Get user by user name - * @param {string} username The name that needs to be fetched. Use user1 for testing. - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public getUserByName(username: string, options?: any) { - return UserApiFp(this.configuration).getUserByName(username, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Logs user into the system - * @param {string} username The user name for login - * @param {string} password The password for login in clear text - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public loginUser(username: string, password: string, options?: any) { - return UserApiFp(this.configuration).loginUser(username, password, options)(this.fetch, this.basePath); - } - - /** - * - * @summary Logs out current logged in user session - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public logoutUser(options?: any) { - return UserApiFp(this.configuration).logoutUser(options)(this.fetch, this.basePath); - } - - /** - * This can only be done by the logged in user. - * @summary Updated user - * @param {string} username name that need to be deleted - * @param {User} user Updated user object - * @param {*} [options] Override http request option. - * @throws {RequiredError} - * @memberof UserApi - */ - public updateUser(username: string, user: User, options?: any) { - return UserApiFp(this.configuration).updateUser(username, user, options)(this.fetch, this.basePath); - } - -} - diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts index 1fcb27ef1c..e43896cc29 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts @@ -98,9 +98,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Add a new pet to the store - */ + /** + * Add a new pet to the store + */ async addPet(requestParameters: AddPetRequest): Promise { await this.addPetRaw(requestParameters); } @@ -140,9 +140,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Deletes a pet - */ + /** + * Deletes a pet + */ async deletePet(requestParameters: DeletePetRequest): Promise { await this.deletePetRaw(requestParameters); } @@ -183,10 +183,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple status values can be provided with comma separated strings - * Finds Pets by status - */ + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ async findPetsByStatus(requestParameters: FindPetsByStatusRequest): Promise> { const response = await this.findPetsByStatusRaw(requestParameters); return await response.value(); @@ -228,10 +228,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * Finds Pets by tags - */ + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ async findPetsByTags(requestParameters: FindPetsByTagsRequest): Promise> { const response = await this.findPetsByTagsRaw(requestParameters); return await response.value(); @@ -264,10 +264,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => PetFromJSON(jsonValue)); } - /** - * Returns a single pet - * Find pet by ID - */ + /** + * Returns a single pet + * Find pet by ID + */ async getPetById(requestParameters: GetPetByIdRequest): Promise { const response = await this.getPetByIdRaw(requestParameters); return await response.value(); @@ -307,9 +307,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Update an existing pet - */ + /** + * Update an existing pet + */ async updatePet(requestParameters: UpdatePetRequest): Promise { await this.updatePetRaw(requestParameters); } @@ -355,9 +355,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Updates a pet in the store with form data - */ + /** + * Updates a pet in the store with form data + */ async updatePetWithForm(requestParameters: UpdatePetWithFormRequest): Promise { await this.updatePetWithFormRaw(requestParameters); } @@ -403,9 +403,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => ModelApiResponseFromJSON(jsonValue)); } - /** - * uploads an image - */ + /** + * uploads an image + */ async uploadFile(requestParameters: UploadFileRequest): Promise { const response = await this.uploadFileRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts index 4b645dea98..9166609816 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts @@ -59,10 +59,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * Delete purchase order by ID - */ + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ async deleteOrder(requestParameters: DeleteOrderRequest): Promise { await this.deleteOrderRaw(requestParameters); } @@ -90,10 +90,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response); } - /** - * Returns a map of status codes to quantities - * Returns pet inventories by status - */ + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ async getInventory(): Promise<{ [key: string]: number; }> { const response = await this.getInventoryRaw(); return await response.value(); @@ -122,10 +122,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * Find purchase order by ID - */ + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ async getOrderById(requestParameters: GetOrderByIdRequest): Promise { const response = await this.getOrderByIdRaw(requestParameters); return await response.value(); @@ -156,9 +156,9 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * Place an order for a pet - */ + /** + * Place an order for a pet + */ async placeOrder(requestParameters: PlaceOrderRequest): Promise { const response = await this.placeOrderRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts index 4126b817ee..1696b600f5 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts @@ -80,10 +80,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Create user - */ + /** + * This can only be done by the logged in user. + * Create user + */ async createUser(requestParameters: CreateUserRequest): Promise { await this.createUserRaw(requestParameters); } @@ -113,9 +113,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithArrayInput(requestParameters: CreateUsersWithArrayInputRequest): Promise { await this.createUsersWithArrayInputRaw(requestParameters); } @@ -145,9 +145,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithListInput(requestParameters: CreateUsersWithListInputRequest): Promise { await this.createUsersWithListInputRaw(requestParameters); } @@ -175,10 +175,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Delete user - */ + /** + * This can only be done by the logged in user. + * Delete user + */ async deleteUser(requestParameters: DeleteUserRequest): Promise { await this.deleteUserRaw(requestParameters); } @@ -205,9 +205,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => UserFromJSON(jsonValue)); } - /** - * Get user by user name - */ + /** + * Get user by user name + */ async getUserByName(requestParameters: GetUserByNameRequest): Promise { const response = await this.getUserByNameRaw(requestParameters); return await response.value(); @@ -247,9 +247,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.TextApiResponse(response); } - /** - * Logs user into the system - */ + /** + * Logs user into the system + */ async loginUser(requestParameters: LoginUserRequest): Promise { const response = await this.loginUserRaw(requestParameters); return await response.value(); @@ -273,9 +273,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Logs out current logged in user session - */ + /** + * Logs out current logged in user session + */ async logoutUser(): Promise { await this.logoutUserRaw(); } @@ -310,10 +310,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Updated user - */ + /** + * This can only be done by the logged in user. + * Updated user + */ async updateUser(requestParameters: UpdateUserRequest): Promise { await this.updateUserRaw(requestParameters); } diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/ApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/default/models/ApiResponse.ts deleted file mode 100644 index 2275473e61..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/default/models/ApiResponse.ts +++ /dev/null @@ -1,60 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * OpenAPI spec version: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists } from '../runtime'; -/** - * Describes the result of uploading an image resource - * @export - * @interface ApiResponse - */ -export interface ApiResponse { - /** - * - * @type {number} - * @memberof ApiResponse - */ - code?: number; - /** - * - * @type {string} - * @memberof ApiResponse - */ - type?: string; - /** - * - * @type {string} - * @memberof ApiResponse - */ - message?: string; -} - -export function ApiResponseFromJSON(json: any): ApiResponse { - return { - 'code': !exists(json, 'code') ? undefined : json['code'], - 'type': !exists(json, 'type') ? undefined : json['type'], - 'message': !exists(json, 'message') ? undefined : json['message'], - }; -} - -export function ApiResponseToJSON(value?: ApiResponse): any { - if (value === undefined) { - return undefined; - } - return { - 'code': value.code, - 'type': value.type, - 'message': value.message, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject.ts b/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject.ts deleted file mode 100644 index 2998b1463c..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject - */ -export interface InlineObject { - /** - * Updated name of the pet - * @type {string} - * @memberof InlineObject - */ - name?: string; - /** - * Updated status of the pet - * @type {string} - * @memberof InlineObject - */ - status?: string; -} - -export function InlineObjectFromJSON(json: any): InlineObject { - return { - 'name': !exists(json, 'name') ? undefined : json['name'], - 'status': !exists(json, 'status') ? undefined : json['status'], - }; -} - -export function InlineObjectToJSON(value?: InlineObject): any { - if (value === undefined) { - return undefined; - } - return { - 'name': value.name, - 'status': value.status, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject1.ts b/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject1.ts deleted file mode 100644 index 4cd90b1379..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/default/models/InlineObject1.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject1 - */ -export interface InlineObject1 { - /** - * Additional data to pass to server - * @type {string} - * @memberof InlineObject1 - */ - additionalMetadata?: string; - /** - * file to upload - * @type {Blob} - * @memberof InlineObject1 - */ - file?: Blob; -} - -export function InlineObject1FromJSON(json: any): InlineObject1 { - return { - 'additionalMetadata': !exists(json, 'additionalMetadata') ? undefined : json['additionalMetadata'], - 'file': !exists(json, 'file') ? undefined : json['file'], - }; -} - -export function InlineObject1ToJSON(value?: InlineObject1): any { - if (value === undefined) { - return undefined; - } - return { - 'additionalMetadata': value.additionalMetadata, - 'file': value.file, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/PetApi.ts index 1fcb27ef1c..e43896cc29 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/PetApi.ts @@ -98,9 +98,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Add a new pet to the store - */ + /** + * Add a new pet to the store + */ async addPet(requestParameters: AddPetRequest): Promise { await this.addPetRaw(requestParameters); } @@ -140,9 +140,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Deletes a pet - */ + /** + * Deletes a pet + */ async deletePet(requestParameters: DeletePetRequest): Promise { await this.deletePetRaw(requestParameters); } @@ -183,10 +183,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple status values can be provided with comma separated strings - * Finds Pets by status - */ + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ async findPetsByStatus(requestParameters: FindPetsByStatusRequest): Promise> { const response = await this.findPetsByStatusRaw(requestParameters); return await response.value(); @@ -228,10 +228,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * Finds Pets by tags - */ + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ async findPetsByTags(requestParameters: FindPetsByTagsRequest): Promise> { const response = await this.findPetsByTagsRaw(requestParameters); return await response.value(); @@ -264,10 +264,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => PetFromJSON(jsonValue)); } - /** - * Returns a single pet - * Find pet by ID - */ + /** + * Returns a single pet + * Find pet by ID + */ async getPetById(requestParameters: GetPetByIdRequest): Promise { const response = await this.getPetByIdRaw(requestParameters); return await response.value(); @@ -307,9 +307,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Update an existing pet - */ + /** + * Update an existing pet + */ async updatePet(requestParameters: UpdatePetRequest): Promise { await this.updatePetRaw(requestParameters); } @@ -355,9 +355,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Updates a pet in the store with form data - */ + /** + * Updates a pet in the store with form data + */ async updatePetWithForm(requestParameters: UpdatePetWithFormRequest): Promise { await this.updatePetWithFormRaw(requestParameters); } @@ -403,9 +403,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => ModelApiResponseFromJSON(jsonValue)); } - /** - * uploads an image - */ + /** + * uploads an image + */ async uploadFile(requestParameters: UploadFileRequest): Promise { const response = await this.uploadFileRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/StoreApi.ts index 4b645dea98..9166609816 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/StoreApi.ts @@ -59,10 +59,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * Delete purchase order by ID - */ + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ async deleteOrder(requestParameters: DeleteOrderRequest): Promise { await this.deleteOrderRaw(requestParameters); } @@ -90,10 +90,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response); } - /** - * Returns a map of status codes to quantities - * Returns pet inventories by status - */ + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ async getInventory(): Promise<{ [key: string]: number; }> { const response = await this.getInventoryRaw(); return await response.value(); @@ -122,10 +122,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * Find purchase order by ID - */ + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ async getOrderById(requestParameters: GetOrderByIdRequest): Promise { const response = await this.getOrderByIdRaw(requestParameters); return await response.value(); @@ -156,9 +156,9 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * Place an order for a pet - */ + /** + * Place an order for a pet + */ async placeOrder(requestParameters: PlaceOrderRequest): Promise { const response = await this.placeOrderRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/UserApi.ts index 4126b817ee..1696b600f5 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/apis/UserApi.ts @@ -80,10 +80,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Create user - */ + /** + * This can only be done by the logged in user. + * Create user + */ async createUser(requestParameters: CreateUserRequest): Promise { await this.createUserRaw(requestParameters); } @@ -113,9 +113,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithArrayInput(requestParameters: CreateUsersWithArrayInputRequest): Promise { await this.createUsersWithArrayInputRaw(requestParameters); } @@ -145,9 +145,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithListInput(requestParameters: CreateUsersWithListInputRequest): Promise { await this.createUsersWithListInputRaw(requestParameters); } @@ -175,10 +175,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Delete user - */ + /** + * This can only be done by the logged in user. + * Delete user + */ async deleteUser(requestParameters: DeleteUserRequest): Promise { await this.deleteUserRaw(requestParameters); } @@ -205,9 +205,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => UserFromJSON(jsonValue)); } - /** - * Get user by user name - */ + /** + * Get user by user name + */ async getUserByName(requestParameters: GetUserByNameRequest): Promise { const response = await this.getUserByNameRaw(requestParameters); return await response.value(); @@ -247,9 +247,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.TextApiResponse(response); } - /** - * Logs user into the system - */ + /** + * Logs user into the system + */ async loginUser(requestParameters: LoginUserRequest): Promise { const response = await this.loginUserRaw(requestParameters); return await response.value(); @@ -273,9 +273,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Logs out current logged in user session - */ + /** + * Logs out current logged in user session + */ async logoutUser(): Promise { await this.logoutUserRaw(); } @@ -310,10 +310,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Updated user - */ + /** + * This can only be done by the logged in user. + * Updated user + */ async updateUser(requestParameters: UpdateUserRequest): Promise { await this.updateUserRaw(requestParameters); } diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject1.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject1.ts deleted file mode 100644 index 4cd90b1379..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject1.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject1 - */ -export interface InlineObject1 { - /** - * Additional data to pass to server - * @type {string} - * @memberof InlineObject1 - */ - additionalMetadata?: string; - /** - * file to upload - * @type {Blob} - * @memberof InlineObject1 - */ - file?: Blob; -} - -export function InlineObject1FromJSON(json: any): InlineObject1 { - return { - 'additionalMetadata': !exists(json, 'additionalMetadata') ? undefined : json['additionalMetadata'], - 'file': !exists(json, 'file') ? undefined : json['file'], - }; -} - -export function InlineObject1ToJSON(value?: InlineObject1): any { - if (value === undefined) { - return undefined; - } - return { - 'additionalMetadata': value.additionalMetadata, - 'file': value.file, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.gitignore b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.gitignore new file mode 100644 index 0000000000..149b576547 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.gitignore @@ -0,0 +1,4 @@ +wwwroot/*.js +node_modules +typings +dist diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator-ignore b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator-ignore new file mode 100644 index 0000000000..7484ee590a --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator/VERSION b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator/VERSION new file mode 100644 index 0000000000..83a328a922 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/.openapi-generator/VERSION @@ -0,0 +1 @@ +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts new file mode 100644 index 0000000000..e3501ab3f2 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts @@ -0,0 +1,424 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + ModelApiResponse, + ModelApiResponseFromJSON, + ModelApiResponseToJSON, + Pet, + PetFromJSON, + PetToJSON, +} from '../models'; + +export interface AddPetRequest { + body: Pet; +} + +export interface DeletePetRequest { + petId: number; + apiKey?: string; +} + +export interface FindPetsByStatusRequest { + status: Array; +} + +export interface FindPetsByTagsRequest { + tags: Array; +} + +export interface GetPetByIdRequest { + petId: number; +} + +export interface UpdatePetRequest { + body: Pet; +} + +export interface UpdatePetWithFormRequest { + petId: number; + name?: string; + status?: string; +} + +export interface UploadFileRequest { + petId: number; + additionalMetadata?: string; + file?: Blob; +} + +/** + * no description + */ +export class PetApi extends runtime.BaseAPI { + + /** + * Add a new pet to the store + */ + async addPetRaw(requestParameters: AddPetRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling addPet.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const response = await this.request({ + path: `/pet`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: PetToJSON(requestParameters.body), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Add a new pet to the store + */ + async addPet(body: Pet): Promise { + await this.addPetRaw({ body: body }); + } + + /** + * Deletes a pet + */ + async deletePetRaw(requestParameters: DeletePetRequest): Promise> { + if (requestParameters.petId === null || requestParameters.petId === undefined) { + throw new runtime.RequiredError('petId','Required parameter requestParameters.petId was null or undefined when calling deletePet.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + if (requestParameters.apiKey !== undefined && requestParameters.apiKey !== null) { + headerParameters['api_key'] = String(requestParameters.apiKey); + } + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const response = await this.request({ + path: `/pet/{petId}`.replace(`{${"petId"}}`, encodeURIComponent(String(requestParameters.petId))), + method: 'DELETE', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Deletes a pet + */ + async deletePet(petId: number, apiKey?: string): Promise { + await this.deletePetRaw({ petId: petId, apiKey: apiKey }); + } + + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ + async findPetsByStatusRaw(requestParameters: FindPetsByStatusRequest): Promise>> { + if (requestParameters.status === null || requestParameters.status === undefined) { + throw new runtime.RequiredError('status','Required parameter requestParameters.status was null or undefined when calling findPetsByStatus.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + if (requestParameters.status) { + queryParameters['status'] = requestParameters.status.join(runtime.COLLECTION_FORMATS["csv"]); + } + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const response = await this.request({ + path: `/pet/findByStatus`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); + } + + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ + async findPetsByStatus(status: Array): Promise> { + const response = await this.findPetsByStatusRaw({ status: status }); + return await response.value(); + } + + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ + async findPetsByTagsRaw(requestParameters: FindPetsByTagsRequest): Promise>> { + if (requestParameters.tags === null || requestParameters.tags === undefined) { + throw new runtime.RequiredError('tags','Required parameter requestParameters.tags was null or undefined when calling findPetsByTags.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + if (requestParameters.tags) { + queryParameters['tags'] = requestParameters.tags.join(runtime.COLLECTION_FORMATS["csv"]); + } + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const response = await this.request({ + path: `/pet/findByTags`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); + } + + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ + async findPetsByTags(tags: Array): Promise> { + const response = await this.findPetsByTagsRaw({ tags: tags }); + return await response.value(); + } + + /** + * Returns a single pet + * Find pet by ID + */ + async getPetByIdRaw(requestParameters: GetPetByIdRequest): Promise> { + if (requestParameters.petId === null || requestParameters.petId === undefined) { + throw new runtime.RequiredError('petId','Required parameter requestParameters.petId was null or undefined when calling getPetById.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.apiKey) { + headerParameters["api_key"] = this.configuration.apiKey("api_key"); // api_key authentication + } + + const response = await this.request({ + path: `/pet/{petId}`.replace(`{${"petId"}}`, encodeURIComponent(String(requestParameters.petId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => PetFromJSON(jsonValue)); + } + + /** + * Returns a single pet + * Find pet by ID + */ + async getPetById(petId: number): Promise { + const response = await this.getPetByIdRaw({ petId: petId }); + return await response.value(); + } + + /** + * Update an existing pet + */ + async updatePetRaw(requestParameters: UpdatePetRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updatePet.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const response = await this.request({ + path: `/pet`, + method: 'PUT', + headers: headerParameters, + query: queryParameters, + body: PetToJSON(requestParameters.body), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Update an existing pet + */ + async updatePet(body: Pet): Promise { + await this.updatePetRaw({ body: body }); + } + + /** + * Updates a pet in the store with form data + */ + async updatePetWithFormRaw(requestParameters: UpdatePetWithFormRequest): Promise> { + if (requestParameters.petId === null || requestParameters.petId === undefined) { + throw new runtime.RequiredError('petId','Required parameter requestParameters.petId was null or undefined when calling updatePetWithForm.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const formData = new FormData(); + if (requestParameters.name !== undefined) { + formData.append('name', requestParameters.name as any); + } + + if (requestParameters.status !== undefined) { + formData.append('status', requestParameters.status as any); + } + + const response = await this.request({ + path: `/pet/{petId}`.replace(`{${"petId"}}`, encodeURIComponent(String(requestParameters.petId))), + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: formData, + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Updates a pet in the store with form data + */ + async updatePetWithForm(petId: number, name?: string, status?: string): Promise { + await this.updatePetWithFormRaw({ petId: petId, name: name, status: status }); + } + + /** + * uploads an image + */ + async uploadFileRaw(requestParameters: UploadFileRequest): Promise> { + if (requestParameters.petId === null || requestParameters.petId === undefined) { + throw new runtime.RequiredError('petId','Required parameter requestParameters.petId was null or undefined when calling uploadFile.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.accessToken) { + // oauth required + if (typeof this.configuration.accessToken === 'function') { + headerParameters["Authorization"] = this.configuration.accessToken("petstore_auth", ["write:pets", "read:pets"]); + } else { + headerParameters["Authorization"] = this.configuration.accessToken; + } + } + + const formData = new FormData(); + if (requestParameters.additionalMetadata !== undefined) { + formData.append('additionalMetadata', requestParameters.additionalMetadata as any); + } + + if (requestParameters.file !== undefined) { + formData.append('file', requestParameters.file as any); + } + + const response = await this.request({ + path: `/pet/{petId}/uploadImage`.replace(`{${"petId"}}`, encodeURIComponent(String(requestParameters.petId))), + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: formData, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => ModelApiResponseFromJSON(jsonValue)); + } + + /** + * uploads an image + */ + async uploadFile(petId: number, additionalMetadata?: string, file?: Blob): Promise { + const response = await this.uploadFileRaw({ petId: petId, additionalMetadata: additionalMetadata, file: file }); + return await response.value(); + } + +} + +/** + * @export + * @enum {string} + */ +export enum FindPetsByStatusStatusEnum { + Available = 'available', + Pending = 'pending', + Sold = 'sold' +} diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts new file mode 100644 index 0000000000..5b3424aafb --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts @@ -0,0 +1,167 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + Order, + OrderFromJSON, + OrderToJSON, +} from '../models'; + +export interface DeleteOrderRequest { + orderId: string; +} + +export interface GetOrderByIdRequest { + orderId: number; +} + +export interface PlaceOrderRequest { + body: Order; +} + +/** + * no description + */ +export class StoreApi extends runtime.BaseAPI { + + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ + async deleteOrderRaw(requestParameters: DeleteOrderRequest): Promise> { + if (requestParameters.orderId === null || requestParameters.orderId === undefined) { + throw new runtime.RequiredError('orderId','Required parameter requestParameters.orderId was null or undefined when calling deleteOrder.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/store/order/{orderId}`.replace(`{${"orderId"}}`, encodeURIComponent(String(requestParameters.orderId))), + method: 'DELETE', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ + async deleteOrder(orderId: string): Promise { + await this.deleteOrderRaw({ orderId: orderId }); + } + + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ + async getInventoryRaw(): Promise> { + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + if (this.configuration && this.configuration.apiKey) { + headerParameters["api_key"] = this.configuration.apiKey("api_key"); // api_key authentication + } + + const response = await this.request({ + path: `/store/inventory`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response); + } + + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ + async getInventory(): Promise<{ [key: string]: number; }> { + const response = await this.getInventoryRaw(); + return await response.value(); + } + + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ + async getOrderByIdRaw(requestParameters: GetOrderByIdRequest): Promise> { + if (requestParameters.orderId === null || requestParameters.orderId === undefined) { + throw new runtime.RequiredError('orderId','Required parameter requestParameters.orderId was null or undefined when calling getOrderById.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/store/order/{orderId}`.replace(`{${"orderId"}}`, encodeURIComponent(String(requestParameters.orderId))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); + } + + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ + async getOrderById(orderId: number): Promise { + const response = await this.getOrderByIdRaw({ orderId: orderId }); + return await response.value(); + } + + /** + * Place an order for a pet + */ + async placeOrderRaw(requestParameters: PlaceOrderRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling placeOrder.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/store/order`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: OrderToJSON(requestParameters.body), + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); + } + + /** + * Place an order for a pet + */ + async placeOrder(body: Order): Promise { + const response = await this.placeOrderRaw({ body: body }); + return await response.value(); + } + +} diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts new file mode 100644 index 0000000000..443e52fe2c --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts @@ -0,0 +1,321 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +import * as runtime from '../runtime'; +import { + User, + UserFromJSON, + UserToJSON, +} from '../models'; + +export interface CreateUserRequest { + body: User; +} + +export interface CreateUsersWithArrayInputRequest { + body: Array; +} + +export interface CreateUsersWithListInputRequest { + body: Array; +} + +export interface DeleteUserRequest { + username: string; +} + +export interface GetUserByNameRequest { + username: string; +} + +export interface LoginUserRequest { + username: string; + password: string; +} + +export interface UpdateUserRequest { + username: string; + body: User; +} + +/** + * no description + */ +export class UserApi extends runtime.BaseAPI { + + /** + * This can only be done by the logged in user. + * Create user + */ + async createUserRaw(requestParameters: CreateUserRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUser.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/user`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: UserToJSON(requestParameters.body), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * This can only be done by the logged in user. + * Create user + */ + async createUser(body: User): Promise { + await this.createUserRaw({ body: body }); + } + + /** + * Creates list of users with given input array + */ + async createUsersWithArrayInputRaw(requestParameters: CreateUsersWithArrayInputRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithArrayInput.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/user/createWithArray`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: requestParameters.body.map(UserToJSON), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Creates list of users with given input array + */ + async createUsersWithArrayInput(body: Array): Promise { + await this.createUsersWithArrayInputRaw({ body: body }); + } + + /** + * Creates list of users with given input array + */ + async createUsersWithListInputRaw(requestParameters: CreateUsersWithListInputRequest): Promise> { + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling createUsersWithListInput.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/user/createWithList`, + method: 'POST', + headers: headerParameters, + query: queryParameters, + body: requestParameters.body.map(UserToJSON), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Creates list of users with given input array + */ + async createUsersWithListInput(body: Array): Promise { + await this.createUsersWithListInputRaw({ body: body }); + } + + /** + * This can only be done by the logged in user. + * Delete user + */ + async deleteUserRaw(requestParameters: DeleteUserRequest): Promise> { + if (requestParameters.username === null || requestParameters.username === undefined) { + throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling deleteUser.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/user/{username}`.replace(`{${"username"}}`, encodeURIComponent(String(requestParameters.username))), + method: 'DELETE', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * This can only be done by the logged in user. + * Delete user + */ + async deleteUser(username: string): Promise { + await this.deleteUserRaw({ username: username }); + } + + /** + * Get user by user name + */ + async getUserByNameRaw(requestParameters: GetUserByNameRequest): Promise> { + if (requestParameters.username === null || requestParameters.username === undefined) { + throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling getUserByName.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/user/{username}`.replace(`{${"username"}}`, encodeURIComponent(String(requestParameters.username))), + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.JSONApiResponse(response, (jsonValue) => UserFromJSON(jsonValue)); + } + + /** + * Get user by user name + */ + async getUserByName(username: string): Promise { + const response = await this.getUserByNameRaw({ username: username }); + return await response.value(); + } + + /** + * Logs user into the system + */ + async loginUserRaw(requestParameters: LoginUserRequest): Promise> { + if (requestParameters.username === null || requestParameters.username === undefined) { + throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling loginUser.'); + } + + if (requestParameters.password === null || requestParameters.password === undefined) { + throw new runtime.RequiredError('password','Required parameter requestParameters.password was null or undefined when calling loginUser.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + if (requestParameters.username !== undefined) { + queryParameters['username'] = requestParameters.username; + } + + if (requestParameters.password !== undefined) { + queryParameters['password'] = requestParameters.password; + } + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/user/login`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.TextApiResponse(response); + } + + /** + * Logs user into the system + */ + async loginUser(username: string, password: string): Promise { + const response = await this.loginUserRaw({ username: username, password: password }); + return await response.value(); + } + + /** + * Logs out current logged in user session + */ + async logoutUserRaw(): Promise> { + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + const response = await this.request({ + path: `/user/logout`, + method: 'GET', + headers: headerParameters, + query: queryParameters, + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * Logs out current logged in user session + */ + async logoutUser(): Promise { + await this.logoutUserRaw(); + } + + /** + * This can only be done by the logged in user. + * Updated user + */ + async updateUserRaw(requestParameters: UpdateUserRequest): Promise> { + if (requestParameters.username === null || requestParameters.username === undefined) { + throw new runtime.RequiredError('username','Required parameter requestParameters.username was null or undefined when calling updateUser.'); + } + + if (requestParameters.body === null || requestParameters.body === undefined) { + throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling updateUser.'); + } + + const queryParameters: runtime.HTTPQuery = {}; + + const headerParameters: runtime.HTTPHeaders = {}; + + headerParameters['Content-Type'] = 'application/json'; + + const response = await this.request({ + path: `/user/{username}`.replace(`{${"username"}}`, encodeURIComponent(String(requestParameters.username))), + method: 'PUT', + headers: headerParameters, + query: queryParameters, + body: UserToJSON(requestParameters.body), + }); + + return new runtime.VoidApiResponse(response); + } + + /** + * This can only be done by the logged in user. + * Updated user + */ + async updateUser(username: string, body: User): Promise { + await this.updateUserRaw({ username: username, body: body }); + } + +} diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/index.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/index.ts new file mode 100644 index 0000000000..056206bfac --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/index.ts @@ -0,0 +1,3 @@ +export * from './PetApi'; +export * from './StoreApi'; +export * from './UserApi'; diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/index.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/index.ts new file mode 100644 index 0000000000..848ecfa4d1 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/index.ts @@ -0,0 +1,3 @@ +export * from './runtime'; +export * from './apis'; +export * from './models'; diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts similarity index 61% rename from samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject.ts rename to samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts index 2998b1463c..f8809dccbe 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/models/InlineObject.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Category.ts @@ -13,39 +13,39 @@ import { exists, mapValues } from '../runtime'; /** - * + * A category for a pet * @export - * @interface InlineObject + * @interface Category */ -export interface InlineObject { +export interface Category { /** - * Updated name of the pet + * + * @type {number} + * @memberof Category + */ + id?: number; + /** + * * @type {string} - * @memberof InlineObject + * @memberof Category */ name?: string; - /** - * Updated status of the pet - * @type {string} - * @memberof InlineObject - */ - status?: string; } -export function InlineObjectFromJSON(json: any): InlineObject { +export function CategoryFromJSON(json: any): Category { return { + 'id': !exists(json, 'id') ? undefined : json['id'], 'name': !exists(json, 'name') ? undefined : json['name'], - 'status': !exists(json, 'status') ? undefined : json['status'], }; } -export function InlineObjectToJSON(value?: InlineObject): any { +export function CategoryToJSON(value?: Category): any { if (value === undefined) { return undefined; } return { + 'id': value.id, 'name': value.name, - 'status': value.status, }; } diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/models/ApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts similarity index 71% rename from samples/client/petstore/typescript-fetch/builds/es6-target/models/ApiResponse.ts rename to samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts index 2275473e61..8b8e2c45fe 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/models/ApiResponse.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/ModelApiResponse.ts @@ -3,7 +3,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * - * OpenAPI spec version: 1.0.0 + * The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -11,34 +11,34 @@ * Do not edit the class manually. */ -import { exists } from '../runtime'; +import { exists, mapValues } from '../runtime'; /** * Describes the result of uploading an image resource * @export - * @interface ApiResponse + * @interface ModelApiResponse */ -export interface ApiResponse { +export interface ModelApiResponse { /** * * @type {number} - * @memberof ApiResponse + * @memberof ModelApiResponse */ code?: number; /** * * @type {string} - * @memberof ApiResponse + * @memberof ModelApiResponse */ type?: string; /** * * @type {string} - * @memberof ApiResponse + * @memberof ModelApiResponse */ message?: string; } -export function ApiResponseFromJSON(json: any): ApiResponse { +export function ModelApiResponseFromJSON(json: any): ModelApiResponse { return { 'code': !exists(json, 'code') ? undefined : json['code'], 'type': !exists(json, 'type') ? undefined : json['type'], @@ -46,7 +46,7 @@ export function ApiResponseFromJSON(json: any): ApiResponse { }; } -export function ApiResponseToJSON(value?: ApiResponse): any { +export function ModelApiResponseToJSON(value?: ModelApiResponse): any { if (value === undefined) { return undefined; } diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts new file mode 100644 index 0000000000..6ce0496794 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Order.ts @@ -0,0 +1,94 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * An order for a pets from the pet store + * @export + * @interface Order + */ +export interface Order { + /** + * + * @type {number} + * @memberof Order + */ + id?: number; + /** + * + * @type {number} + * @memberof Order + */ + petId?: number; + /** + * + * @type {number} + * @memberof Order + */ + quantity?: number; + /** + * + * @type {Date} + * @memberof Order + */ + shipDate?: Date; + /** + * Order Status + * @type {string} + * @memberof Order + */ + status?: OrderStatusEnum; + /** + * + * @type {boolean} + * @memberof Order + */ + complete?: boolean; +} + +export function OrderFromJSON(json: any): Order { + return { + 'id': !exists(json, 'id') ? undefined : json['id'], + 'petId': !exists(json, 'petId') ? undefined : json['petId'], + 'quantity': !exists(json, 'quantity') ? undefined : json['quantity'], + 'shipDate': !exists(json, 'shipDate') ? undefined : new Date(json['shipDate']), + 'status': !exists(json, 'status') ? undefined : json['status'], + 'complete': !exists(json, 'complete') ? undefined : json['complete'], + }; +} + +export function OrderToJSON(value?: Order): any { + if (value === undefined) { + return undefined; + } + return { + 'id': value.id, + 'petId': value.petId, + 'quantity': value.quantity, + 'shipDate': value.shipDate === undefined ? undefined : value.shipDate.toISOString(), + 'status': value.status, + 'complete': value.complete, + }; +} + +/** +* @export +* @enum {string} +*/ +export enum OrderStatusEnum { + Placed = 'placed', + Approved = 'approved', + Delivered = 'delivered' +} + + diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts new file mode 100644 index 0000000000..770f991b89 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Pet.ts @@ -0,0 +1,103 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +import { + Category, + CategoryFromJSON, + CategoryToJSON, + Tag, + TagFromJSON, + TagToJSON, +} from './'; + +/** + * A pet for sale in the pet store + * @export + * @interface Pet + */ +export interface Pet { + /** + * + * @type {number} + * @memberof Pet + */ + id?: number; + /** + * + * @type {Category} + * @memberof Pet + */ + category?: Category; + /** + * + * @type {string} + * @memberof Pet + */ + name: string; + /** + * + * @type {Array} + * @memberof Pet + */ + photoUrls: Array; + /** + * + * @type {Array} + * @memberof Pet + */ + tags?: Array; + /** + * pet status in the store + * @type {string} + * @memberof Pet + */ + status?: PetStatusEnum; +} + +export function PetFromJSON(json: any): Pet { + return { + 'id': !exists(json, 'id') ? undefined : json['id'], + 'category': !exists(json, 'category') ? undefined : CategoryFromJSON(json['category']), + 'name': json['name'], + 'photoUrls': json['photoUrls'], + 'tags': !exists(json, 'tags') ? undefined : (json['tags'] as Array).map(TagFromJSON), + 'status': !exists(json, 'status') ? undefined : json['status'], + }; +} + +export function PetToJSON(value?: Pet): any { + if (value === undefined) { + return undefined; + } + return { + 'id': value.id, + 'category': CategoryToJSON(value.category), + 'name': value.name, + 'photoUrls': value.photoUrls, + 'tags': value.tags === undefined ? undefined : (value.tags as Array).map(TagToJSON), + 'status': value.status, + }; +} + +/** +* @export +* @enum {string} +*/ +export enum PetStatusEnum { + Available = 'available', + Pending = 'pending', + Sold = 'sold' +} + + diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts similarity index 61% rename from samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject.ts rename to samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts index 2998b1463c..7c8098f6dc 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/Tag.ts @@ -13,39 +13,39 @@ import { exists, mapValues } from '../runtime'; /** - * + * A tag for a pet * @export - * @interface InlineObject + * @interface Tag */ -export interface InlineObject { +export interface Tag { /** - * Updated name of the pet + * + * @type {number} + * @memberof Tag + */ + id?: number; + /** + * * @type {string} - * @memberof InlineObject + * @memberof Tag */ name?: string; - /** - * Updated status of the pet - * @type {string} - * @memberof InlineObject - */ - status?: string; } -export function InlineObjectFromJSON(json: any): InlineObject { +export function TagFromJSON(json: any): Tag { return { + 'id': !exists(json, 'id') ? undefined : json['id'], 'name': !exists(json, 'name') ? undefined : json['name'], - 'status': !exists(json, 'status') ? undefined : json['status'], }; } -export function InlineObjectToJSON(value?: InlineObject): any { +export function TagToJSON(value?: Tag): any { if (value === undefined) { return undefined; } return { + 'id': value.id, 'name': value.name, - 'status': value.status, }; } diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts new file mode 100644 index 0000000000..fd7430063f --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/User.ts @@ -0,0 +1,100 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * A User who is purchasing from the pet store + * @export + * @interface User + */ +export interface User { + /** + * + * @type {number} + * @memberof User + */ + id?: number; + /** + * + * @type {string} + * @memberof User + */ + username?: string; + /** + * + * @type {string} + * @memberof User + */ + firstName?: string; + /** + * + * @type {string} + * @memberof User + */ + lastName?: string; + /** + * + * @type {string} + * @memberof User + */ + email?: string; + /** + * + * @type {string} + * @memberof User + */ + password?: string; + /** + * + * @type {string} + * @memberof User + */ + phone?: string; + /** + * User Status + * @type {number} + * @memberof User + */ + userStatus?: number; +} + +export function UserFromJSON(json: any): User { + return { + 'id': !exists(json, 'id') ? undefined : json['id'], + 'username': !exists(json, 'username') ? undefined : json['username'], + 'firstName': !exists(json, 'firstName') ? undefined : json['firstName'], + 'lastName': !exists(json, 'lastName') ? undefined : json['lastName'], + 'email': !exists(json, 'email') ? undefined : json['email'], + 'password': !exists(json, 'password') ? undefined : json['password'], + 'phone': !exists(json, 'phone') ? undefined : json['phone'], + 'userStatus': !exists(json, 'userStatus') ? undefined : json['userStatus'], + }; +} + +export function UserToJSON(value?: User): any { + if (value === undefined) { + return undefined; + } + return { + 'id': value.id, + 'username': value.username, + 'firstName': value.firstName, + 'lastName': value.lastName, + 'email': value.email, + 'password': value.password, + 'phone': value.phone, + 'userStatus': value.userStatus, + }; +} + + diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/index.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/index.ts new file mode 100644 index 0000000000..b07ddc8446 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/models/index.ts @@ -0,0 +1,6 @@ +export * from './Category'; +export * from './ModelApiResponse'; +export * from './Order'; +export * from './Pet'; +export * from './Tag'; +export * from './User'; diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml new file mode 100644 index 0000000000..a6fc39c4f0 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/pom.xml @@ -0,0 +1,26 @@ + + 4.0.0 + org.openapitools + TypeScriptAngularBuildPestoreClientTests + pom + 1.0-SNAPSHOT + TS Fetch Multiple Parameters Petstore Client + + + + maven-dependency-plugin + + + package + + copy-dependencies + + + ${project.build.directory} + + + + + + + diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts new file mode 100644 index 0000000000..5b07f81118 --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts @@ -0,0 +1,284 @@ +// tslint:disable +/** + * OpenAPI Petstore + * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. + * + * The version of the OpenAPI document: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, ""); + +const isBlob = (value: any) => typeof Blob !== 'undefined' && value instanceof Blob; + +/** + * This is the base class for all generated API classes. + */ +export class BaseAPI { + + private middleware: Middleware[]; + + constructor(protected configuration = new Configuration()) { + this.middleware = configuration.middleware; + } + + withMiddleware(this: T, ...middlewares: Middleware[]) { + const next = this.clone(); + next.middleware = next.middleware.concat(...middlewares); + return next; + } + + withPreMiddleware(this: T, ...preMiddlewares: Array) { + const middlewares = preMiddlewares.map((pre) => ({ pre })); + return this.withMiddleware(...middlewares); + } + + withPostMiddleware(this: T, ...postMiddlewares: Array) { + const middlewares = postMiddlewares.map((post) => ({ post })); + return this.withMiddleware(...middlewares); + } + + protected async request(context: RequestOpts): Promise { + const { url, init } = this.createFetchParams(context); + const response = await this.fetchApi(url, init); + if (response.status >= 200 && response.status < 300) { + return response; + } + throw response; + } + + private createFetchParams(context: RequestOpts) { + let url = this.configuration.basePath + context.path; + if (context.query !== undefined && Object.keys(context.query).length !== 0) { + // only add the querystring to the URL if there are query parameters. + // this is done to avoid urls ending with a "?" character which buggy webservers + // do not handle correctly sometimes. + url += '?' + querystring(context.query); + } + const body = (context.body instanceof FormData || isBlob(context.body)) + ? context.body + : JSON.stringify(context.body); + const init = { + method: context.method, + headers: context.headers, + body, + }; + return { url, init }; + } + + private fetchApi = async (url: string, init: RequestInit) => { + let fetchParams = { url, init }; + for (const middleware of this.middleware) { + if (middleware.pre) { + fetchParams = await middleware.pre({ + fetch: this.fetchApi, + ...fetchParams, + }) || fetchParams; + } + } + let response = await this.configuration.fetchApi(fetchParams.url, fetchParams.init); + for (const middleware of this.middleware) { + if (middleware.post) { + response = await middleware.post({ + fetch: this.fetchApi, + url, + init, + response: response.clone(), + }) || response; + } + } + return response; + } + + /** + * Create a shallow clone of `this` by constructing a new instance + * and then shallow cloning data members. + */ + private clone(this: T): T { + const constructor = this.constructor as any; + const next = new constructor(this.configuration); + next.middleware = this.middleware.slice(); + return next; + } +}; + +export class RequiredError extends Error { + name: "RequiredError" = "RequiredError"; + constructor(public field: string, msg?: string) { + super(msg); + } +} + +export const COLLECTION_FORMATS = { + csv: ",", + ssv: " ", + tsv: "\t", + pipes: "|", +}; + +export type FetchAPI = GlobalFetch['fetch']; + +export interface ConfigurationParameters { + basePath?: string; // override base path + fetchApi?: FetchAPI; // override for fetch implementation + middleware?: Middleware[]; // middleware to apply before/after fetch requests + username?: string; // parameter for basic security + password?: string; // parameter for basic security + apiKey?: string | ((name: string) => string); // parameter for apiKey security + accessToken?: string | ((name: string, scopes?: string[]) => string); // parameter for oauth2 security +} + +export class Configuration { + constructor(private configuration: ConfigurationParameters = {}) {} + + get basePath(): string { + return this.configuration.basePath || BASE_PATH; + } + + get fetchApi(): FetchAPI { + return this.configuration.fetchApi || window.fetch.bind(window); + } + + get middleware(): Middleware[] { + return this.configuration.middleware || []; + } + + get username(): string | undefined { + return this.configuration.username; + } + + get password(): string | undefined { + return this.configuration.password; + } + + get apiKey(): ((name: string) => string) | undefined { + const apiKey = this.configuration.apiKey; + if (apiKey) { + return typeof apiKey === 'function' ? apiKey : () => apiKey; + } + return undefined; + } + + get accessToken(): ((name: string, scopes?: string[]) => string) | undefined { + const accessToken = this.configuration.accessToken; + if (accessToken) { + return typeof accessToken === 'function' ? accessToken : () => accessToken; + } + return undefined; + } +} + +export type Json = any; +export type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS'; +export type HTTPHeaders = { [key: string]: string }; +export type HTTPQuery = { [key: string]: string | number | null | boolean | Array | HTTPQuery }; +export type HTTPBody = Json | FormData; +export type ModelPropertyNaming = 'camelCase' | 'snake_case' | 'PascalCase' | 'original'; + +export interface FetchParams { + url: string; + init: RequestInit; +} + +export interface RequestOpts { + path: string; + method: HTTPMethod; + headers: HTTPHeaders; + query?: HTTPQuery; + body?: HTTPBody; +} + +export function exists(json: any, key: string) { + const value = json[key]; + return value !== null && value !== undefined; +} + +export function querystring(params: HTTPQuery, prefix: string = ''): string { + return Object.keys(params) + .map((key) => { + const fullKey = prefix + (prefix.length ? `[${key}]` : key); + const value = params[key]; + if (value instanceof Array) { + const multiValue = value.map(singleValue => encodeURIComponent(String(singleValue))) + .join(`&${encodeURIComponent(fullKey)}=`); + return `${encodeURIComponent(fullKey)}=${multiValue}`; + } + if (value instanceof Object) { + return querystring(value as HTTPQuery, fullKey); + } + return `${encodeURIComponent(fullKey)}=${encodeURIComponent(String(value))}`; + }) + .filter(part => part.length > 0) + .join('&'); +} + +export function mapValues(data: any, fn: (item: any) => any) { + return Object.keys(data).reduce( + (acc, key) => ({ ...acc, [key]: fn(data[key]) }), + {} + ); +} + +export interface RequestContext { + fetch: FetchAPI; + url: string; + init: RequestInit; +} + +export interface ResponseContext { + fetch: FetchAPI; + url: string; + init: RequestInit; + response: Response; +} + +export interface Middleware { + pre?(context: RequestContext): Promise; + post?(context: ResponseContext): Promise; +} + +export interface ApiResponse { + raw: Response; + value(): Promise; +} + +export interface ResponseTransformer { + (json: any): T; +} + +export class JSONApiResponse { + constructor(public raw: Response, private transformer: ResponseTransformer = (jsonValue: any) => jsonValue) {} + + async value() { + return this.transformer(await this.raw.json()); + } +} + +export class VoidApiResponse { + constructor(public raw: Response) {} + + async value() { + return undefined; + } +} + +export class BlobApiResponse { + constructor(public raw: Response) {} + + async value() { + return await this.raw.blob(); + }; +} + +export class TextApiResponse { + constructor(public raw: Response) {} + + async value() { + return await this.raw.text(); + }; +} diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/tsconfig.json b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/tsconfig.json new file mode 100644 index 0000000000..d65f2a95af --- /dev/null +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "declaration": true, + "target": "es5", + "module": "commonjs", + "moduleResolution": "node", + "outDir": "dist", + "rootDir": ".", + "lib": [ + "es6", + "dom" + ], + "typeRoots": [ + "node_modules/@types" + ] + }, + "exclude": [ + "dist", + "node_modules" + ] +} diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts index 1fcb27ef1c..e43896cc29 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts @@ -98,9 +98,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Add a new pet to the store - */ + /** + * Add a new pet to the store + */ async addPet(requestParameters: AddPetRequest): Promise { await this.addPetRaw(requestParameters); } @@ -140,9 +140,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Deletes a pet - */ + /** + * Deletes a pet + */ async deletePet(requestParameters: DeletePetRequest): Promise { await this.deletePetRaw(requestParameters); } @@ -183,10 +183,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple status values can be provided with comma separated strings - * Finds Pets by status - */ + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ async findPetsByStatus(requestParameters: FindPetsByStatusRequest): Promise> { const response = await this.findPetsByStatusRaw(requestParameters); return await response.value(); @@ -228,10 +228,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * Finds Pets by tags - */ + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ async findPetsByTags(requestParameters: FindPetsByTagsRequest): Promise> { const response = await this.findPetsByTagsRaw(requestParameters); return await response.value(); @@ -264,10 +264,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => PetFromJSON(jsonValue)); } - /** - * Returns a single pet - * Find pet by ID - */ + /** + * Returns a single pet + * Find pet by ID + */ async getPetById(requestParameters: GetPetByIdRequest): Promise { const response = await this.getPetByIdRaw(requestParameters); return await response.value(); @@ -307,9 +307,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Update an existing pet - */ + /** + * Update an existing pet + */ async updatePet(requestParameters: UpdatePetRequest): Promise { await this.updatePetRaw(requestParameters); } @@ -355,9 +355,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Updates a pet in the store with form data - */ + /** + * Updates a pet in the store with form data + */ async updatePetWithForm(requestParameters: UpdatePetWithFormRequest): Promise { await this.updatePetWithFormRaw(requestParameters); } @@ -403,9 +403,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => ModelApiResponseFromJSON(jsonValue)); } - /** - * uploads an image - */ + /** + * uploads an image + */ async uploadFile(requestParameters: UploadFileRequest): Promise { const response = await this.uploadFileRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts index 4b645dea98..9166609816 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts @@ -59,10 +59,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * Delete purchase order by ID - */ + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ async deleteOrder(requestParameters: DeleteOrderRequest): Promise { await this.deleteOrderRaw(requestParameters); } @@ -90,10 +90,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response); } - /** - * Returns a map of status codes to quantities - * Returns pet inventories by status - */ + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ async getInventory(): Promise<{ [key: string]: number; }> { const response = await this.getInventoryRaw(); return await response.value(); @@ -122,10 +122,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * Find purchase order by ID - */ + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ async getOrderById(requestParameters: GetOrderByIdRequest): Promise { const response = await this.getOrderByIdRaw(requestParameters); return await response.value(); @@ -156,9 +156,9 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * Place an order for a pet - */ + /** + * Place an order for a pet + */ async placeOrder(requestParameters: PlaceOrderRequest): Promise { const response = await this.placeOrderRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts index 4126b817ee..1696b600f5 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts @@ -80,10 +80,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Create user - */ + /** + * This can only be done by the logged in user. + * Create user + */ async createUser(requestParameters: CreateUserRequest): Promise { await this.createUserRaw(requestParameters); } @@ -113,9 +113,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithArrayInput(requestParameters: CreateUsersWithArrayInputRequest): Promise { await this.createUsersWithArrayInputRaw(requestParameters); } @@ -145,9 +145,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithListInput(requestParameters: CreateUsersWithListInputRequest): Promise { await this.createUsersWithListInputRaw(requestParameters); } @@ -175,10 +175,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Delete user - */ + /** + * This can only be done by the logged in user. + * Delete user + */ async deleteUser(requestParameters: DeleteUserRequest): Promise { await this.deleteUserRaw(requestParameters); } @@ -205,9 +205,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => UserFromJSON(jsonValue)); } - /** - * Get user by user name - */ + /** + * Get user by user name + */ async getUserByName(requestParameters: GetUserByNameRequest): Promise { const response = await this.getUserByNameRaw(requestParameters); return await response.value(); @@ -247,9 +247,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.TextApiResponse(response); } - /** - * Logs user into the system - */ + /** + * Logs user into the system + */ async loginUser(requestParameters: LoginUserRequest): Promise { const response = await this.loginUserRaw(requestParameters); return await response.value(); @@ -273,9 +273,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Logs out current logged in user session - */ + /** + * Logs out current logged in user session + */ async logoutUser(): Promise { await this.logoutUserRaw(); } @@ -310,10 +310,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Updated user - */ + /** + * This can only be done by the logged in user. + * Updated user + */ async updateUser(requestParameters: UpdateUserRequest): Promise { await this.updateUserRaw(requestParameters); } diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ApiResponse.ts deleted file mode 100644 index 2275473e61..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/ApiResponse.ts +++ /dev/null @@ -1,60 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * OpenAPI spec version: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists } from '../runtime'; -/** - * Describes the result of uploading an image resource - * @export - * @interface ApiResponse - */ -export interface ApiResponse { - /** - * - * @type {number} - * @memberof ApiResponse - */ - code?: number; - /** - * - * @type {string} - * @memberof ApiResponse - */ - type?: string; - /** - * - * @type {string} - * @memberof ApiResponse - */ - message?: string; -} - -export function ApiResponseFromJSON(json: any): ApiResponse { - return { - 'code': !exists(json, 'code') ? undefined : json['code'], - 'type': !exists(json, 'type') ? undefined : json['type'], - 'message': !exists(json, 'message') ? undefined : json['message'], - }; -} - -export function ApiResponseToJSON(value?: ApiResponse): any { - if (value === undefined) { - return undefined; - } - return { - 'code': value.code, - 'type': value.type, - 'message': value.message, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject1.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject1.ts deleted file mode 100644 index 4cd90b1379..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/models/InlineObject1.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject1 - */ -export interface InlineObject1 { - /** - * Additional data to pass to server - * @type {string} - * @memberof InlineObject1 - */ - additionalMetadata?: string; - /** - * file to upload - * @type {Blob} - * @memberof InlineObject1 - */ - file?: Blob; -} - -export function InlineObject1FromJSON(json: any): InlineObject1 { - return { - 'additionalMetadata': !exists(json, 'additionalMetadata') ? undefined : json['additionalMetadata'], - 'file': !exists(json, 'file') ? undefined : json['file'], - }; -} - -export function InlineObject1ToJSON(value?: InlineObject1): any { - if (value === undefined) { - return undefined; - } - return { - 'additionalMetadata': value.additionalMetadata, - 'file': value.file, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/PetApi.ts index 1fcb27ef1c..e43896cc29 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/PetApi.ts @@ -98,9 +98,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Add a new pet to the store - */ + /** + * Add a new pet to the store + */ async addPet(requestParameters: AddPetRequest): Promise { await this.addPetRaw(requestParameters); } @@ -140,9 +140,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Deletes a pet - */ + /** + * Deletes a pet + */ async deletePet(requestParameters: DeletePetRequest): Promise { await this.deletePetRaw(requestParameters); } @@ -183,10 +183,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple status values can be provided with comma separated strings - * Finds Pets by status - */ + /** + * Multiple status values can be provided with comma separated strings + * Finds Pets by status + */ async findPetsByStatus(requestParameters: FindPetsByStatusRequest): Promise> { const response = await this.findPetsByStatusRaw(requestParameters); return await response.value(); @@ -228,10 +228,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PetFromJSON)); } - /** - * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - * Finds Pets by tags - */ + /** + * Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. + * Finds Pets by tags + */ async findPetsByTags(requestParameters: FindPetsByTagsRequest): Promise> { const response = await this.findPetsByTagsRaw(requestParameters); return await response.value(); @@ -264,10 +264,10 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => PetFromJSON(jsonValue)); } - /** - * Returns a single pet - * Find pet by ID - */ + /** + * Returns a single pet + * Find pet by ID + */ async getPetById(requestParameters: GetPetByIdRequest): Promise { const response = await this.getPetByIdRaw(requestParameters); return await response.value(); @@ -307,9 +307,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Update an existing pet - */ + /** + * Update an existing pet + */ async updatePet(requestParameters: UpdatePetRequest): Promise { await this.updatePetRaw(requestParameters); } @@ -355,9 +355,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Updates a pet in the store with form data - */ + /** + * Updates a pet in the store with form data + */ async updatePetWithForm(requestParameters: UpdatePetWithFormRequest): Promise { await this.updatePetWithFormRaw(requestParameters); } @@ -403,9 +403,9 @@ export class PetApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => ModelApiResponseFromJSON(jsonValue)); } - /** - * uploads an image - */ + /** + * uploads an image + */ async uploadFile(requestParameters: UploadFileRequest): Promise { const response = await this.uploadFileRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/StoreApi.ts index 4b645dea98..9166609816 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/StoreApi.ts @@ -59,10 +59,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - * Delete purchase order by ID - */ + /** + * For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors + * Delete purchase order by ID + */ async deleteOrder(requestParameters: DeleteOrderRequest): Promise { await this.deleteOrderRaw(requestParameters); } @@ -90,10 +90,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response); } - /** - * Returns a map of status codes to quantities - * Returns pet inventories by status - */ + /** + * Returns a map of status codes to quantities + * Returns pet inventories by status + */ async getInventory(): Promise<{ [key: string]: number; }> { const response = await this.getInventoryRaw(); return await response.value(); @@ -122,10 +122,10 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - * Find purchase order by ID - */ + /** + * For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions + * Find purchase order by ID + */ async getOrderById(requestParameters: GetOrderByIdRequest): Promise { const response = await this.getOrderByIdRaw(requestParameters); return await response.value(); @@ -156,9 +156,9 @@ export class StoreApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => OrderFromJSON(jsonValue)); } - /** - * Place an order for a pet - */ + /** + * Place an order for a pet + */ async placeOrder(requestParameters: PlaceOrderRequest): Promise { const response = await this.placeOrderRaw(requestParameters); return await response.value(); diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/UserApi.ts index 4126b817ee..1696b600f5 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/apis/UserApi.ts @@ -80,10 +80,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Create user - */ + /** + * This can only be done by the logged in user. + * Create user + */ async createUser(requestParameters: CreateUserRequest): Promise { await this.createUserRaw(requestParameters); } @@ -113,9 +113,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithArrayInput(requestParameters: CreateUsersWithArrayInputRequest): Promise { await this.createUsersWithArrayInputRaw(requestParameters); } @@ -145,9 +145,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Creates list of users with given input array - */ + /** + * Creates list of users with given input array + */ async createUsersWithListInput(requestParameters: CreateUsersWithListInputRequest): Promise { await this.createUsersWithListInputRaw(requestParameters); } @@ -175,10 +175,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Delete user - */ + /** + * This can only be done by the logged in user. + * Delete user + */ async deleteUser(requestParameters: DeleteUserRequest): Promise { await this.deleteUserRaw(requestParameters); } @@ -205,9 +205,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.JSONApiResponse(response, (jsonValue) => UserFromJSON(jsonValue)); } - /** - * Get user by user name - */ + /** + * Get user by user name + */ async getUserByName(requestParameters: GetUserByNameRequest): Promise { const response = await this.getUserByNameRaw(requestParameters); return await response.value(); @@ -247,9 +247,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.TextApiResponse(response); } - /** - * Logs user into the system - */ + /** + * Logs user into the system + */ async loginUser(requestParameters: LoginUserRequest): Promise { const response = await this.loginUserRaw(requestParameters); return await response.value(); @@ -273,9 +273,9 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * Logs out current logged in user session - */ + /** + * Logs out current logged in user session + */ async logoutUser(): Promise { await this.logoutUserRaw(); } @@ -310,10 +310,10 @@ export class UserApi extends runtime.BaseAPI { return new runtime.VoidApiResponse(response); } - /** - * This can only be done by the logged in user. - * Updated user - */ + /** + * This can only be done by the logged in user. + * Updated user + */ async updateUser(requestParameters: UpdateUserRequest): Promise { await this.updateUserRaw(requestParameters); } diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/ApiResponse.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/ApiResponse.ts deleted file mode 100644 index 2275473e61..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/ApiResponse.ts +++ /dev/null @@ -1,60 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * OpenAPI spec version: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists } from '../runtime'; -/** - * Describes the result of uploading an image resource - * @export - * @interface ApiResponse - */ -export interface ApiResponse { - /** - * - * @type {number} - * @memberof ApiResponse - */ - code?: number; - /** - * - * @type {string} - * @memberof ApiResponse - */ - type?: string; - /** - * - * @type {string} - * @memberof ApiResponse - */ - message?: string; -} - -export function ApiResponseFromJSON(json: any): ApiResponse { - return { - 'code': !exists(json, 'code') ? undefined : json['code'], - 'type': !exists(json, 'type') ? undefined : json['type'], - 'message': !exists(json, 'message') ? undefined : json['message'], - }; -} - -export function ApiResponseToJSON(value?: ApiResponse): any { - if (value === undefined) { - return undefined; - } - return { - 'code': value.code, - 'type': value.type, - 'message': value.message, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject.ts deleted file mode 100644 index 2998b1463c..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject - */ -export interface InlineObject { - /** - * Updated name of the pet - * @type {string} - * @memberof InlineObject - */ - name?: string; - /** - * Updated status of the pet - * @type {string} - * @memberof InlineObject - */ - status?: string; -} - -export function InlineObjectFromJSON(json: any): InlineObject { - return { - 'name': !exists(json, 'name') ? undefined : json['name'], - 'status': !exists(json, 'status') ? undefined : json['status'], - }; -} - -export function InlineObjectToJSON(value?: InlineObject): any { - if (value === undefined) { - return undefined; - } - return { - 'name': value.name, - 'status': value.status, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject1.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject1.ts deleted file mode 100644 index 4cd90b1379..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/models/InlineObject1.ts +++ /dev/null @@ -1,52 +0,0 @@ -// tslint:disable -/** - * OpenAPI Petstore - * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. - * - * The version of the OpenAPI document: 1.0.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface InlineObject1 - */ -export interface InlineObject1 { - /** - * Additional data to pass to server - * @type {string} - * @memberof InlineObject1 - */ - additionalMetadata?: string; - /** - * file to upload - * @type {Blob} - * @memberof InlineObject1 - */ - file?: Blob; -} - -export function InlineObject1FromJSON(json: any): InlineObject1 { - return { - 'additionalMetadata': !exists(json, 'additionalMetadata') ? undefined : json['additionalMetadata'], - 'file': !exists(json, 'file') ? undefined : json['file'], - }; -} - -export function InlineObject1ToJSON(value?: InlineObject1): any { - if (value === undefined) { - return undefined; - } - return { - 'additionalMetadata': value.additionalMetadata, - 'file': value.file, - }; -} - - diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/package-lock.json b/samples/client/petstore/typescript-fetch/builds/with-npm-version/package-lock.json deleted file mode 100644 index e8dc0d00b2..0000000000 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/package-lock.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "name": "@swagger/typescript-fetch-petstore", - "version": "1.0.0", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "typescript": { - "version": "2.9.2", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.9.2.tgz", - "integrity": "sha512-Gr4p6nFNaoufRIY4NMdpQRNmgxVIGMs4Fcu/ujdYk3nAZqk7supzBE9idmvfZIlH/Cuj//dvi+019qEue9lV0w==", - "dev": true - } - } -} diff --git a/samples/client/petstore/typescript-fetch/tests/default/package-lock.json b/samples/client/petstore/typescript-fetch/tests/default/package-lock.json index 5310ef1dfb..400cf1276d 100644 --- a/samples/client/petstore/typescript-fetch/tests/default/package-lock.json +++ b/samples/client/petstore/typescript-fetch/tests/default/package-lock.json @@ -4,14 +4,11 @@ "lockfileVersion": 1, "requires": true, "dependencies": { + "@openapitools/typescript-fetch-petstore": { + "version": "file:../../builds/with-npm-version" + }, "@swagger/typescript-fetch-petstore": { - "version": "file:../../builds/with-npm-version", - "dependencies": { - "typescript": { - "version": "2.9.2", - "bundled": true - } - } + "version": "file:../../builds/with-npm-version" }, "@types/chai": { "version": "4.1.6", @@ -1505,7 +1502,8 @@ "ansi-regex": { "version": "2.1.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "aproba": { "version": "1.2.0", @@ -1526,12 +1524,14 @@ "balanced-match": { "version": "1.0.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "brace-expansion": { "version": "1.1.11", "bundled": true, "dev": true, + "optional": true, "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -1546,17 +1546,20 @@ "code-point-at": { "version": "1.1.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "concat-map": { "version": "0.0.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "console-control-strings": { "version": "1.1.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "core-util-is": { "version": "1.0.2", @@ -1673,7 +1676,8 @@ "inherits": { "version": "2.0.3", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "ini": { "version": "1.3.5", @@ -1685,6 +1689,7 @@ "version": "1.0.0", "bundled": true, "dev": true, + "optional": true, "requires": { "number-is-nan": "^1.0.0" } @@ -1699,6 +1704,7 @@ "version": "3.0.4", "bundled": true, "dev": true, + "optional": true, "requires": { "brace-expansion": "^1.1.7" } @@ -1706,12 +1712,14 @@ "minimist": { "version": "0.0.8", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "minipass": { "version": "2.2.4", "bundled": true, "dev": true, + "optional": true, "requires": { "safe-buffer": "^5.1.1", "yallist": "^3.0.0" @@ -1730,6 +1738,7 @@ "version": "0.5.1", "bundled": true, "dev": true, + "optional": true, "requires": { "minimist": "0.0.8" } @@ -1810,7 +1819,8 @@ "number-is-nan": { "version": "1.0.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "object-assign": { "version": "4.1.1", @@ -1822,6 +1832,7 @@ "version": "1.4.0", "bundled": true, "dev": true, + "optional": true, "requires": { "wrappy": "1" } @@ -1907,7 +1918,8 @@ "safe-buffer": { "version": "5.1.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "safer-buffer": { "version": "2.1.2", @@ -1943,6 +1955,7 @@ "version": "1.0.2", "bundled": true, "dev": true, + "optional": true, "requires": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -1962,6 +1975,7 @@ "version": "3.0.1", "bundled": true, "dev": true, + "optional": true, "requires": { "ansi-regex": "^2.0.0" } @@ -2005,12 +2019,14 @@ "wrappy": { "version": "1.0.2", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "yallist": { "version": "3.0.2", "bundled": true, - "dev": true + "dev": true, + "optional": true } } }, diff --git a/samples/client/petstore/typescript-fetch/tests/default/package.json b/samples/client/petstore/typescript-fetch/tests/default/package.json index fee4a03b85..906804784f 100644 --- a/samples/client/petstore/typescript-fetch/tests/default/package.json +++ b/samples/client/petstore/typescript-fetch/tests/default/package.json @@ -1,6 +1,7 @@ { "private": true, "dependencies": { + "@openapitools/typescript-fetch-petstore": "file:../../builds/with-npm-version", "@swagger/typescript-fetch-petstore": "file:../../builds/with-npm-version", "chai": "^4.1.0", "ts-node": "^3.3.0" From a85bd0f8f9785b6d7f215da56085bafb8c647016 Mon Sep 17 00:00:00 2001 From: Michal Foksa Date: Thu, 18 Jul 2019 06:28:40 +0200 Subject: [PATCH 21/62] Include common lambdas in generators (#3368) * Include commonly used Mustache lambdas in DefaultCodegen. * Use or extend common Mustache lambdas from DefaultCodegen. * Extract OnChangeLambda to own file. * Javadoc fixed in addMustacheLambdas(). --- .../openapitools/codegen/DefaultCodegen.java | 55 +++++++++++++++- .../languages/AbstractCSharpCodegen.java | 33 +++------- .../codegen/languages/AbstractCppCodegen.java | 31 +++------- .../languages/AbstractFSharpCodegen.java | 35 +++-------- .../languages/KotlinServerCodegen.java | 27 -------- .../languages/KotlinSpringServerCodegen.java | 21 +++---- .../languages/OpenAPIYamlGenerator.java | 62 +++---------------- .../ScalaPlayFrameworkServerCodegen.java | 16 +++-- .../templating/mustache/OnChangeLambda.java | 40 ++++++++++++ 9 files changed, 141 insertions(+), 179 deletions(-) create mode 100644 modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/mustache/OnChangeLambda.java diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java index 5373b99e93..639f8448c3 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java @@ -19,7 +19,11 @@ package org.openapitools.codegen; import com.fasterxml.jackson.core.JsonProcessingException; import com.google.common.base.CaseFormat; +import com.google.common.collect.ImmutableMap; +import com.samskivert.mustache.Mustache; import com.samskivert.mustache.Mustache.Compiler; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.core.util.Json; import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.Operation; @@ -48,6 +52,11 @@ import org.openapitools.codegen.meta.GeneratorMetadata; import org.openapitools.codegen.meta.Stability; import org.openapitools.codegen.serializer.SerializerUtils; import org.openapitools.codegen.templating.MustacheEngineAdapter; +import org.openapitools.codegen.templating.mustache.CamelCaseLambda; +import org.openapitools.codegen.templating.mustache.IndentedLambda; +import org.openapitools.codegen.templating.mustache.LowercaseLambda; +import org.openapitools.codegen.templating.mustache.TitlecaseLambda; +import org.openapitools.codegen.templating.mustache.UppercaseLambda; import org.openapitools.codegen.utils.ModelUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -199,6 +208,47 @@ public class DefaultCodegen implements CodegenConfig { } } + /*** + * Preset map builder with commonly used Mustache lambdas. + * + * To extend the map, override addMustacheLambdas(), call parent method + * first and then add additional lambdas to the returned builder. + * + * If common lambdas are not desired, override addMustacheLambdas() method + * and return empty builder. + * + * @return preinitialized map builder with common lambdas + */ + protected ImmutableMap.Builder addMustacheLambdas() { + + return new ImmutableMap.Builder() + .put("lowercase", new LowercaseLambda().generator(this)) + .put("uppercase", new UppercaseLambda()) + .put("titlecase", new TitlecaseLambda()) + .put("camelcase", new CamelCaseLambda().generator(this)) + .put("indented", new IndentedLambda()) + .put("indented_8", new IndentedLambda(8, " ")) + .put("indented_12", new IndentedLambda(12, " ")) + .put("indented_16", new IndentedLambda(16, " ")); + } + + private void registerMustacheLambdas() { + ImmutableMap lambdas = addMustacheLambdas().build(); + + if (lambdas.size() == 0) { + return; + } + + if (additionalProperties.containsKey("lambda")) { + LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + + "You'll likely need to use a custom template, " + + "see https://github.com/OpenAPITools/openapi-generator/blob/master/docs/templating.md. "); + additionalProperties.put("_lambda", lambdas); + } else { + additionalProperties.put("lambda", lambdas); + } + } + // override with any special post-processing for all models @SuppressWarnings({"static-method", "unchecked"}) public Map postProcessAllModels(Map objs) { @@ -1060,6 +1110,9 @@ public class DefaultCodegen implements CodegenConfig { // initialize special character mapping initalizeSpecialCharacterMapping(); + + // Register common Mustache lambdas. + registerMustacheLambdas(); } /** @@ -1523,7 +1576,7 @@ public class DefaultCodegen implements CodegenConfig { // If the format matches a typeMapping (supplied with the --typeMappings flag) // then treat the format as a primitive type. // This allows the typeMapping flag to add a new custom type which can then - // be used in the format field. + // be used in the format field. return schema.getFormat(); } return "string"; diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCSharpCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCSharpCodegen.java index 1e7a454007..d39c6c07ab 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCSharpCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCSharpCodegen.java @@ -17,8 +17,9 @@ package org.openapitools.codegen.languages; -import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; +import com.google.common.collect.ImmutableMap.Builder; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.core.util.Json; import io.swagger.v3.oas.models.media.ArraySchema; import io.swagger.v3.oas.models.media.Schema; @@ -359,32 +360,12 @@ public abstract class AbstractCSharpCodegen extends DefaultCodegen implements Co // This either updates additionalProperties with the above fixes, or sets the default if the option was not specified. additionalProperties.put(CodegenConstants.INTERFACE_PREFIX, interfacePrefix); - - addMustacheLambdas(additionalProperties); } - private void addMustacheLambdas(Map objs) { - - Map lambdas = new ImmutableMap.Builder() - .put("lowercase", new LowercaseLambda().generator(this)) - .put("uppercase", new UppercaseLambda()) - .put("titlecase", new TitlecaseLambda()) - .put("camelcase", new CamelCaseLambda().generator(this)) - .put("camelcase_param", new CamelCaseLambda().generator(this).escapeAsParamName(true)) - .put("indented", new IndentedLambda()) - .put("indented_8", new IndentedLambda(8, " ")) - .put("indented_12", new IndentedLambda(12, " ")) - .put("indented_16", new IndentedLambda(16, " ")) - .build(); - - if (objs.containsKey("lambda")) { - LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + - "You'll likely need to use a custom template, " + - "see https://github.com/swagger-api/swagger-codegen#modifying-the-client-library-format. "); - objs.put("_lambda", lambdas); - } else { - objs.put("lambda", lambdas); - } + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("camelcase_param", new CamelCaseLambda().generator(this).escapeAsParamName(true)); } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCppCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCppCodegen.java index 65105e467a..afbbae6684 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCppCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractCppCodegen.java @@ -17,8 +17,8 @@ package org.openapitools.codegen.languages; -import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; +import com.google.common.collect.ImmutableMap.Builder; +import com.samskivert.mustache.Mustache.Lambda; import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.media.Schema; @@ -35,7 +35,6 @@ import org.slf4j.LoggerFactory; import java.io.File; import java.net.URL; import java.util.Arrays; -import java.util.Map; abstract public class AbstractCppCodegen extends DefaultCodegen implements CodegenConfig { private static final Logger LOGGER = LoggerFactory.getLogger(AbstractCppCodegen.class); @@ -260,22 +259,12 @@ abstract public class AbstractCppCodegen extends DefaultCodegen implements Codeg LOGGER.info("Environment variable CPP_POST_PROCESS_FILE not defined so the C++ code may not be properly formatted. To define it, try 'export CPP_POST_PROCESS_FILE=\"/usr/local/bin/clang-format -i\"' (Linux/Mac)"); LOGGER.info("NOTE: To enable file post-processing, 'enablePostProcessFile' must be set to `true` (--enable-post-process-file for CLI)."); } - - addMustacheLambdas(additionalProperties); } - private void addMustacheLambdas(Map objs) { - - Map lambdas = new ImmutableMap.Builder() - .put("multiline_comment_4", new IndentedLambda(4, " ", "///")) - .build(); - - if (objs.containsKey("lambda")) { - LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'."); - objs.put("_lambda", lambdas); - } else { - objs.put("lambda", lambdas); - } + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("multiline_comment_4", new IndentedLambda(4, " ", "///")); } @Override @@ -304,17 +293,17 @@ abstract public class AbstractCppCodegen extends DefaultCodegen implements Codeg } } } - + @Override public void preprocessOpenAPI(OpenAPI openAPI) { URL url = URLPathUtils.getServerURL(openAPI); String port = URLPathUtils.getPort(url, ""); String host = url.getHost(); if(!port.isEmpty()) { - this.additionalProperties.put("serverPort", port); + this.additionalProperties.put("serverPort", port); } if(!host.isEmpty()) { - this.additionalProperties.put("serverHost", host); - } + this.additionalProperties.put("serverHost", host); + } } } diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractFSharpCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractFSharpCodegen.java index 9d82448ffb..04a626eac7 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractFSharpCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractFSharpCodegen.java @@ -16,8 +16,9 @@ package org.openapitools.codegen.languages; -import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; +import com.google.common.collect.ImmutableMap.Builder; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.core.util.Json; import io.swagger.v3.oas.models.media.ArraySchema; import io.swagger.v3.oas.models.media.Schema; @@ -67,7 +68,7 @@ public abstract class AbstractFSharpCodegen extends DefaultCodegen implements Co protected Set collectionTypes; protected Set mapTypes; - // true if nullable types will be supported (as option) + // true if nullable types will be supported (as option) protected boolean supportNullable = Boolean.TRUE; protected Set nullableType = new HashSet(); @@ -329,32 +330,12 @@ public abstract class AbstractFSharpCodegen extends DefaultCodegen implements Co // This either updates additionalProperties with the above fixes, or sets the default if the option was not specified. additionalProperties.put(CodegenConstants.INTERFACE_PREFIX, interfacePrefix); - - addMustacheLambdas(additionalProperties); } - private void addMustacheLambdas(Map objs) { - - Map lambdas = new ImmutableMap.Builder() - .put("lowercase", new LowercaseLambda().generator(this)) - .put("uppercase", new UppercaseLambda()) - .put("titlecase", new TitlecaseLambda()) - .put("camelcase", new CamelCaseLambda().generator(this)) - .put("camelcase_param", new CamelCaseLambda().generator(this).escapeAsParamName(true)) - .put("indented", new IndentedLambda()) - .put("indented_8", new IndentedLambda(8, " ")) - .put("indented_12", new IndentedLambda(12, " ")) - .put("indented_16", new IndentedLambda(16, " ")) - .build(); - - if (objs.containsKey("lambda")) { - LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + - "You'll likely need to use a custom template, " + - "see https://github.com/swagger-api/swagger-codegen#modifying-the-client-library-format. "); - objs.put("_lambda", lambdas); - } else { - objs.put("lambda", lambdas); - } + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("camelcase_param", new CamelCaseLambda().generator(this).escapeAsParamName(true)); } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinServerCodegen.java index 80e48bf0bc..4bd48eb218 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinServerCodegen.java @@ -18,13 +18,11 @@ package org.openapitools.codegen.languages; import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; import org.apache.commons.lang3.StringUtils; import org.openapitools.codegen.CliOption; import org.openapitools.codegen.CodegenConstants; import org.openapitools.codegen.CodegenType; import org.openapitools.codegen.SupportingFile; -import org.openapitools.codegen.templating.mustache.*; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -211,31 +209,6 @@ public class KotlinServerCodegen extends AbstractKotlinCodegen { final String infrastructureFolder = (sourceFolder + File.separator + packageName + File.separator + "infrastructure").replace(".", File.separator); supportingFiles.add(new SupportingFile("ApiKeyAuth.kt.mustache", infrastructureFolder, "ApiKeyAuth.kt")); - - addMustacheLambdas(additionalProperties); - } - - private void addMustacheLambdas(Map objs) { - - Map lambdas = new ImmutableMap.Builder() - .put("lowercase", new LowercaseLambda().generator(this)) - .put("uppercase", new UppercaseLambda()) - .put("titlecase", new TitlecaseLambda()) - .put("camelcase", new CamelCaseLambda().generator(this)) - .put("indented", new IndentedLambda()) - .put("indented_8", new IndentedLambda(8, " ")) - .put("indented_12", new IndentedLambda(12, " ")) - .put("indented_16", new IndentedLambda(16, " ")) - .build(); - - if (objs.containsKey("lambda")) { - LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + - "You'll likely need to use a custom template, " + - "see https://github.com/OpenAPITools/openapi-generator/blob/master/docs/templating.md. "); - objs.put("_lambda", lambdas); - } else { - objs.put("lambda", lambdas); - } } public static class Constants { diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java index 28e45eb7af..36c99c39a7 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java @@ -16,9 +16,11 @@ package org.openapitools.codegen.languages; -import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; import com.samskivert.mustache.Mustache; import com.samskivert.mustache.Template; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.media.Schema; import org.openapitools.codegen.*; @@ -51,7 +53,6 @@ public class KotlinSpringServerCodegen extends AbstractKotlinCodegen )); public static final String TITLE = "title"; - public static final String LAMBDA = "lambda"; public static final String SERVER_PORT = "serverPort"; public static final String BASE_PACKAGE = "basePackage"; public static final String SPRING_BOOT = "spring-boot"; @@ -370,22 +371,14 @@ public class KotlinSpringServerCodegen extends AbstractKotlinCodegen sanitizeDirectory(sourceFolder + File.separator + basePackage), "Application.kt")); } - addMustacheLambdas(additionalProperties); - // spring uses the jackson lib, and we disallow configuration. additionalProperties.put("jackson", "true"); } - private void addMustacheLambdas(final Map objs) { - Map lambdas = - new ImmutableMap.Builder() - .put("escapeDoubleQuote", new EscapeLambda("\"", "\\\"")) - .build(); - - if (objs.containsKey(LAMBDA)) { - LOGGER.warn("The lambda property is a reserved word, and will be overwritten!"); - } - objs.put(LAMBDA, lambdas); + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("escapeDoubleQuote", new EscapeLambda("\"", "\\\"")); } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java index 5c46567fd9..ca1e910266 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/OpenAPIYamlGenerator.java @@ -18,21 +18,15 @@ package org.openapitools.codegen.languages; import org.openapitools.codegen.*; -import org.openapitools.codegen.templating.mustache.CamelCaseLambda; -import org.openapitools.codegen.templating.mustache.IndentedLambda; -import org.openapitools.codegen.templating.mustache.LowercaseLambda; -import org.openapitools.codegen.templating.mustache.TitlecaseLambda; -import org.openapitools.codegen.templating.mustache.UppercaseLambda; +import org.openapitools.codegen.templating.mustache.OnChangeLambda; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; -import com.samskivert.mustache.Template; +import com.google.common.collect.ImmutableMap.Builder; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.oas.models.Operation; -import java.io.IOException; -import java.io.Writer; import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -75,32 +69,12 @@ public class OpenAPIYamlGenerator extends DefaultCodegen implements CodegenConfi } LOGGER.info("Output file [outputFile={}]", outputFile); supportingFiles.add(new SupportingFile("openapi.mustache", outputFile)); - - addMustacheLambdas(additionalProperties); } - private void addMustacheLambdas(Map objs) { - - Map lambdas = new ImmutableMap.Builder() - .put("lowercase", new LowercaseLambda().generator(this)) - .put("uppercase", new UppercaseLambda()) - .put("titlecase", new TitlecaseLambda()) - .put("camelcase", new CamelCaseLambda().generator(this)) - .put("indented", new IndentedLambda()) - .put("indented_8", new IndentedLambda(8, " ")) - .put("indented_12", new IndentedLambda(12, " ")) - .put("indented_16", new IndentedLambda(16, " ")) - .put("onchange", new OnChangeLambda()) - .build(); - - if (objs.containsKey("lambda")) { - LOGGER.warn("A property named 'lambda' already exists. Mustache lambdas renamed from 'lambda' to '_lambda'. " + - "You'll likely need to use a custom template, " + - "see https://github.com/OpenAPITools/openapi-generator/blob/master/docs/templating.md. "); - objs.put("_lambda", lambdas); - } else { - objs.put("lambda", lambdas); - } + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("onchange", new OnChangeLambda()); } /** @@ -133,24 +107,4 @@ public class OpenAPIYamlGenerator extends DefaultCodegen implements CodegenConfi return input; } - /** - * Lambda writes current fragment to the output when it is different than - * previous fragment. - */ - public static class OnChangeLambda implements Mustache.Lambda { - private static final Logger LOGGER = LoggerFactory.getLogger(OnChangeLambda.class); - - private String lastVal = null; - - @Override - public void execute(Template.Fragment frag, Writer out) throws IOException { - String curVal = frag.execute(); - LOGGER.debug("[lastVal={}, curVal={}]", lastVal, curVal); - if (curVal != null && !curVal.equals(lastVal)) { - out.write(curVal); - lastVal = curVal; - } - } - } - } diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java index a30f0bd797..1f02cc989f 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/ScalaPlayFrameworkServerCodegen.java @@ -16,8 +16,9 @@ package org.openapitools.codegen.languages; -import com.google.common.collect.ImmutableMap; -import com.samskivert.mustache.Mustache; +import com.google.common.collect.ImmutableMap.Builder; +import com.samskivert.mustache.Mustache.Lambda; + import io.swagger.v3.oas.models.media.ArraySchema; import io.swagger.v3.oas.models.media.Schema; import org.openapitools.codegen.*; @@ -192,15 +193,12 @@ public class ScalaPlayFrameworkServerCodegen extends AbstractScalaCodegen implem supportingFiles.add(new SupportingFile("public/openapi.json.mustache", "public", "openapi.json")); supportingFiles.add(new SupportingFile("app/apiDocController.scala.mustache", String.format(Locale.ROOT, "app/%s", apiPackage.replace(".", File.separator)), "ApiDocController.scala")); } - addMustacheLambdas(additionalProperties); } - private void addMustacheLambdas(Map objs) { - Map lambdas = new ImmutableMap.Builder() - .put("indented_4", new IndentedLambda(4, " ")) - .put("indented_8", new IndentedLambda(8, " ")) - .build(); - objs.put("lambda", lambdas); + @Override + protected Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("indented_4", new IndentedLambda(4, " ")); } @SuppressWarnings("unchecked") diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/mustache/OnChangeLambda.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/mustache/OnChangeLambda.java new file mode 100644 index 0000000000..11efbfae5b --- /dev/null +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/mustache/OnChangeLambda.java @@ -0,0 +1,40 @@ +package org.openapitools.codegen.templating.mustache; + +import java.io.IOException; +import java.io.Writer; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import com.samskivert.mustache.Mustache; +import com.samskivert.mustache.Template; + +/** + * Lambda writes current fragment to the output when it is different than + * the previous fragment. + * + * Register: + *

+ * additionalProperties.put("onchange", new OnChangeLambda());
+ * 
+ * + * Use: + *
+ * {{#onchange}}{{name}}{{/onchange}}
+ * 
+ */ +public class OnChangeLambda implements Mustache.Lambda { + private static final Logger LOGGER = LoggerFactory.getLogger(OnChangeLambda.class); + + private String lastVal = null; + + @Override + public void execute(Template.Fragment frag, Writer out) throws IOException { + String curVal = frag.execute(); + LOGGER.debug("[lastVal={}, curVal={}]", lastVal, curVal); + if (curVal != null && !curVal.equals(lastVal)) { + out.write(curVal); + lastVal = curVal; + } + } +} \ No newline at end of file From 29a85d54a287dfae06fea83aa1c2ebc56f3ef702 Mon Sep 17 00:00:00 2001 From: james-beer <48411570+james-beer@users.noreply.github.com> Date: Thu, 18 Jul 2019 06:22:12 +0100 Subject: [PATCH 22/62] Adds default property values in ASP .NET Core models (#3369) * Fixes docker-entrypoint.sh * Adds default property values to C# model templates (#3359). --- docker-entrypoint.sh | 2 +- .../src/main/resources/aspnetcore/2.0/model.mustache | 4 ++-- .../src/main/resources/aspnetcore/2.1/model.mustache | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index 4decc3de64..3b993a1be3 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -19,7 +19,7 @@ if [[ -f "${codegen}" && -n "$(java ${JAVA_OPTS} -jar "${codegen}" completion | command=$1 shift exec java ${JAVA_OPTS} -jar "${codegen}" "${command}" "$@" -elif [[ -n "$(echo commands | tr ',' '\n' | grep "^$1\$" )" ]]; then +elif [[ -n "$(echo $commands | tr ',' '\n' | grep "^$1\$" )" ]]; then # If CLI jar does not exist, and $1 is a known CLI command, build the CLI jar and run that command. if [[ ! -f "${codegen}" ]]; then (cd "${GEN_DIR}" && exec mvn -am -pl "modules/openapi-generator-cli" -Duser.home=$(dirname $MAVEN_CONFIG) package) diff --git a/modules/openapi-generator/src/main/resources/aspnetcore/2.0/model.mustache b/modules/openapi-generator/src/main/resources/aspnetcore/2.0/model.mustache index 8cbfaf0efd..101e95cbfc 100644 --- a/modules/openapi-generator/src/main/resources/aspnetcore/2.0/model.mustache +++ b/modules/openapi-generator/src/main/resources/aspnetcore/2.0/model.mustache @@ -28,10 +28,10 @@ namespace {{packageName}}.Models {{/required}} [DataMember(Name="{{baseName}}", EmitDefaultValue={{#isNullable}}true{{/isNullable}}{{^isNullable}}false{{/isNullable}})] {{#isEnum}} - public {{{datatypeWithEnum}}}{{#isEnum}}{{^isContainer}}?{{/isContainer}}{{/isEnum}} {{name}} { get; set; } + public {{{datatypeWithEnum}}}{{#isEnum}}{{^isContainer}}?{{/isContainer}}{{/isEnum}} {{name}} { get; set; }{{#defaultValue}} = {{{defaultValue}}};{{/defaultValue}} {{/isEnum}} {{^isEnum}} - public {{{dataType}}} {{name}} { get; {{#isReadOnly}}private {{/isReadOnly}}set; } + public {{{dataType}}} {{name}} { get; {{#isReadOnly}}private {{/isReadOnly}}set; }{{#defaultValue}} = {{{defaultValue}}};{{/defaultValue}} {{/isEnum}} {{#hasMore}} {{/hasMore}} diff --git a/modules/openapi-generator/src/main/resources/aspnetcore/2.1/model.mustache b/modules/openapi-generator/src/main/resources/aspnetcore/2.1/model.mustache index e4be72baec..e198e2447e 100644 --- a/modules/openapi-generator/src/main/resources/aspnetcore/2.1/model.mustache +++ b/modules/openapi-generator/src/main/resources/aspnetcore/2.1/model.mustache @@ -31,10 +31,10 @@ namespace {{modelPackage}} {{/pattern}} [DataMember(Name="{{baseName}}", EmitDefaultValue={{#isNullable}}true{{/isNullable}}{{^isNullable}}false{{/isNullable}})] {{#isEnum}} - public {{{datatypeWithEnum}}}{{#isEnum}}{{^isContainer}}?{{/isContainer}}{{/isEnum}} {{name}} { get; set; } + public {{{datatypeWithEnum}}}{{#isEnum}}{{^isContainer}}?{{/isContainer}}{{/isEnum}} {{name}} { get; set; }{{#defaultValue}} = {{{defaultValue}}};{{/defaultValue}} {{/isEnum}} {{^isEnum}} - public {{{dataType}}} {{name}} { get; {{#isReadOnly}}private {{/isReadOnly}}set; } + public {{{dataType}}} {{name}} { get; {{#isReadOnly}}private {{/isReadOnly}}set; }{{#defaultValue}} = {{{defaultValue}}};{{/defaultValue}} {{/isEnum}} {{#hasMore}} {{/hasMore}} From 4223743ee0c628eba162894166cf400b849e7c42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Bresson?= Date: Thu, 18 Jul 2019 07:46:44 +0200 Subject: [PATCH 23/62] [java rest-assured] prevent reqSpec reuse between requests (#3375) * [java rest-assured] prevent reqSpec reuse between requests * Update sample --- .../libraries/rest-assured/ApiClient.mustache | 6 +- .../Java/libraries/rest-assured/api.mustache | 45 +-- .../org/openapitools/client/ApiClient.java | 16 +- .../client/api/AnotherFakeApi.java | 45 +-- .../org/openapitools/client/api/FakeApi.java | 261 +++++++++--------- .../client/api/FakeClassnameTags123Api.java | 45 +-- .../org/openapitools/client/api/PetApi.java | 189 +++++++------ .../org/openapitools/client/api/StoreApi.java | 99 ++++--- .../org/openapitools/client/api/UserApi.java | 171 ++++++------ 9 files changed, 470 insertions(+), 407 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/ApiClient.mustache b/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/ApiClient.mustache index 42bdf68613..19ab0fa98c 100644 --- a/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/ApiClient.mustache +++ b/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/ApiClient.mustache @@ -34,13 +34,13 @@ public class ApiClient { {{#apiInfo}} {{#apis}} public {{classname}} {{classVarName}}() { - return {{classname}}.{{classVarName}}(config.baseReqSpec.get()); + return {{classname}}.{{classVarName}}(config.reqSpecSupplier); } {{/apis}} {{/apiInfo}} public static class Config { - private Supplier baseReqSpec = () -> new RequestSpecBuilder() + private Supplier reqSpecSupplier = () -> new RequestSpecBuilder() {{#basePath}}.setBaseUri(BASE_URI){{/basePath}} .setConfig(config().objectMapperConfig(objectMapperConfig().defaultObjectMapper(gson()))); @@ -50,7 +50,7 @@ public class ApiClient { * @return configuration */ public Config reqSpecSupplier(Supplier supplier) { - this.baseReqSpec = supplier; + this.reqSpecSupplier = supplier; return this; } diff --git a/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/api.mustache b/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/api.mustache index 75c3a373ae..75ea07db60 100644 --- a/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/api.mustache +++ b/modules/openapi-generator/src/main/resources/Java/libraries/rest-assured/api.mustache @@ -31,14 +31,23 @@ import static io.restassured.http.Method.*; @Api(value = "{{{baseName}}}") public class {{classname}} { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private {{classname}}(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private {{classname}}(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static {{classname}} {{classVarName}}(RequestSpecBuilder reqSpec) { - return new {{classname}}(reqSpec); + public static {{classname}} {{classVarName}}(Supplier reqSpecSupplier) { + return new {{classname}}(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } {{#operations}} @@ -54,18 +63,18 @@ public class {{classname}} { @Deprecated {{/isDeprecated}} public {{operationIdCamelCase}}Oper {{operationId}}() { - return new {{operationIdCamelCase}}Oper(reqSpec); + return new {{operationIdCamelCase}}Oper(createReqSpec()); } {{/operation}} {{/operations}} /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public {{classname}} reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public {{classname}} reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -216,22 +225,22 @@ public class {{classname}} { {{/formParams}} /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public {{operationIdCamelCase}}Oper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public {{operationIdCamelCase}}Oper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public {{operationIdCamelCase}}Oper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public {{operationIdCamelCase}}Oper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/ApiClient.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/ApiClient.java index f5cc4b49c8..ec1d9a433c 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/ApiClient.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/ApiClient.java @@ -37,26 +37,26 @@ public class ApiClient { } public AnotherFakeApi anotherFake() { - return AnotherFakeApi.anotherFake(config.baseReqSpec.get()); + return AnotherFakeApi.anotherFake(config.reqSpecSupplier); } public FakeApi fake() { - return FakeApi.fake(config.baseReqSpec.get()); + return FakeApi.fake(config.reqSpecSupplier); } public FakeClassnameTags123Api fakeClassnameTags123() { - return FakeClassnameTags123Api.fakeClassnameTags123(config.baseReqSpec.get()); + return FakeClassnameTags123Api.fakeClassnameTags123(config.reqSpecSupplier); } public PetApi pet() { - return PetApi.pet(config.baseReqSpec.get()); + return PetApi.pet(config.reqSpecSupplier); } public StoreApi store() { - return StoreApi.store(config.baseReqSpec.get()); + return StoreApi.store(config.reqSpecSupplier); } public UserApi user() { - return UserApi.user(config.baseReqSpec.get()); + return UserApi.user(config.reqSpecSupplier); } public static class Config { - private Supplier baseReqSpec = () -> new RequestSpecBuilder() + private Supplier reqSpecSupplier = () -> new RequestSpecBuilder() .setBaseUri(BASE_URI) .setConfig(config().objectMapperConfig(objectMapperConfig().defaultObjectMapper(gson()))); @@ -66,7 +66,7 @@ public class ApiClient { * @return configuration */ public Config reqSpecSupplier(Supplier supplier) { - this.baseReqSpec = supplier; + this.reqSpecSupplier = supplier; return this; } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/AnotherFakeApi.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/AnotherFakeApi.java index 719824b840..13de1523a6 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/AnotherFakeApi.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/AnotherFakeApi.java @@ -39,14 +39,23 @@ import static io.restassured.http.Method.*; @Api(value = "AnotherFake") public class AnotherFakeApi { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private AnotherFakeApi(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private AnotherFakeApi(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static AnotherFakeApi anotherFake(RequestSpecBuilder reqSpec) { - return new AnotherFakeApi(reqSpec); + public static AnotherFakeApi anotherFake(Supplier reqSpecSupplier) { + return new AnotherFakeApi(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -57,16 +66,16 @@ public class AnotherFakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public Call123testSpecialTagsOper call123testSpecialTags() { - return new Call123testSpecialTagsOper(reqSpec); + return new Call123testSpecialTagsOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public AnotherFakeApi reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public AnotherFakeApi reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -122,22 +131,22 @@ public class AnotherFakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public Call123testSpecialTagsOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public Call123testSpecialTagsOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public Call123testSpecialTagsOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public Call123testSpecialTagsOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeApi.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeApi.java index c6b7bd7615..7ba6b4294a 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeApi.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeApi.java @@ -47,14 +47,23 @@ import static io.restassured.http.Method.*; @Api(value = "Fake") public class FakeApi { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private FakeApi(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private FakeApi(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static FakeApi fake(RequestSpecBuilder reqSpec) { - return new FakeApi(reqSpec); + public static FakeApi fake(Supplier reqSpecSupplier) { + return new FakeApi(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -65,7 +74,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public CreateXmlItemOper createXmlItem() { - return new CreateXmlItemOper(reqSpec); + return new CreateXmlItemOper(createReqSpec()); } @ApiOperation(value = "", @@ -75,7 +84,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Output boolean") }) public FakeOuterBooleanSerializeOper fakeOuterBooleanSerialize() { - return new FakeOuterBooleanSerializeOper(reqSpec); + return new FakeOuterBooleanSerializeOper(createReqSpec()); } @ApiOperation(value = "", @@ -85,7 +94,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Output composite") }) public FakeOuterCompositeSerializeOper fakeOuterCompositeSerialize() { - return new FakeOuterCompositeSerializeOper(reqSpec); + return new FakeOuterCompositeSerializeOper(createReqSpec()); } @ApiOperation(value = "", @@ -95,7 +104,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Output number") }) public FakeOuterNumberSerializeOper fakeOuterNumberSerialize() { - return new FakeOuterNumberSerializeOper(reqSpec); + return new FakeOuterNumberSerializeOper(createReqSpec()); } @ApiOperation(value = "", @@ -105,7 +114,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Output string") }) public FakeOuterStringSerializeOper fakeOuterStringSerialize() { - return new FakeOuterStringSerializeOper(reqSpec); + return new FakeOuterStringSerializeOper(createReqSpec()); } @ApiOperation(value = "", @@ -115,7 +124,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Success") }) public TestBodyWithFileSchemaOper testBodyWithFileSchema() { - return new TestBodyWithFileSchemaOper(reqSpec); + return new TestBodyWithFileSchemaOper(createReqSpec()); } @ApiOperation(value = "", @@ -125,7 +134,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "Success") }) public TestBodyWithQueryParamsOper testBodyWithQueryParams() { - return new TestBodyWithQueryParamsOper(reqSpec); + return new TestBodyWithQueryParamsOper(createReqSpec()); } @ApiOperation(value = "To test \"client\" model", @@ -135,7 +144,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public TestClientModelOper testClientModel() { - return new TestClientModelOper(reqSpec); + return new TestClientModelOper(createReqSpec()); } @ApiOperation(value = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", @@ -146,7 +155,7 @@ public class FakeApi { @ApiResponse(code = 400, message = "Invalid username supplied") , @ApiResponse(code = 404, message = "User not found") }) public TestEndpointParametersOper testEndpointParameters() { - return new TestEndpointParametersOper(reqSpec); + return new TestEndpointParametersOper(createReqSpec()); } @ApiOperation(value = "To test enum parameters", @@ -157,7 +166,7 @@ public class FakeApi { @ApiResponse(code = 400, message = "Invalid request") , @ApiResponse(code = 404, message = "Not found") }) public TestEnumParametersOper testEnumParameters() { - return new TestEnumParametersOper(reqSpec); + return new TestEnumParametersOper(createReqSpec()); } @ApiOperation(value = "Fake endpoint to test group parameters (optional)", @@ -167,7 +176,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 400, message = "Someting wrong") }) public TestGroupParametersOper testGroupParameters() { - return new TestGroupParametersOper(reqSpec); + return new TestGroupParametersOper(createReqSpec()); } @ApiOperation(value = "test inline additionalProperties", @@ -177,7 +186,7 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public TestInlineAdditionalPropertiesOper testInlineAdditionalProperties() { - return new TestInlineAdditionalPropertiesOper(reqSpec); + return new TestInlineAdditionalPropertiesOper(createReqSpec()); } @ApiOperation(value = "test json serialization of form data", @@ -187,16 +196,16 @@ public class FakeApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public TestJsonFormDataOper testJsonFormData() { - return new TestJsonFormDataOper(reqSpec); + return new TestJsonFormDataOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public FakeApi reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeApi reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -241,22 +250,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public CreateXmlItemOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public CreateXmlItemOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public CreateXmlItemOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public CreateXmlItemOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -312,22 +321,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FakeOuterBooleanSerializeOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeOuterBooleanSerializeOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FakeOuterBooleanSerializeOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FakeOuterBooleanSerializeOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -383,22 +392,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FakeOuterCompositeSerializeOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeOuterCompositeSerializeOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FakeOuterCompositeSerializeOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FakeOuterCompositeSerializeOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -454,22 +463,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FakeOuterNumberSerializeOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeOuterNumberSerializeOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FakeOuterNumberSerializeOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FakeOuterNumberSerializeOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -525,22 +534,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FakeOuterStringSerializeOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeOuterStringSerializeOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FakeOuterStringSerializeOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FakeOuterStringSerializeOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -585,22 +594,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestBodyWithFileSchemaOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestBodyWithFileSchemaOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestBodyWithFileSchemaOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestBodyWithFileSchemaOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -657,22 +666,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestBodyWithQueryParamsOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestBodyWithQueryParamsOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestBodyWithQueryParamsOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestBodyWithQueryParamsOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -728,22 +737,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestClientModelOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestClientModelOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestClientModelOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestClientModelOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -946,22 +955,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestEndpointParametersOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestEndpointParametersOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestEndpointParametersOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestEndpointParametersOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -1092,22 +1101,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestEnumParametersOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestEnumParametersOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestEnumParametersOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestEnumParametersOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -1213,22 +1222,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestGroupParametersOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestGroupParametersOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestGroupParametersOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestGroupParametersOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -1273,22 +1282,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestInlineAdditionalPropertiesOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestInlineAdditionalPropertiesOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestInlineAdditionalPropertiesOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestInlineAdditionalPropertiesOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -1347,22 +1356,22 @@ public class FakeApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestJsonFormDataOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestJsonFormDataOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestJsonFormDataOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestJsonFormDataOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeClassnameTags123Api.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeClassnameTags123Api.java index 69ae6841c0..f7130fef3c 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeClassnameTags123Api.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/FakeClassnameTags123Api.java @@ -39,14 +39,23 @@ import static io.restassured.http.Method.*; @Api(value = "FakeClassnameTags123") public class FakeClassnameTags123Api { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private FakeClassnameTags123Api(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private FakeClassnameTags123Api(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static FakeClassnameTags123Api fakeClassnameTags123(RequestSpecBuilder reqSpec) { - return new FakeClassnameTags123Api(reqSpec); + public static FakeClassnameTags123Api fakeClassnameTags123(Supplier reqSpecSupplier) { + return new FakeClassnameTags123Api(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -57,16 +66,16 @@ public class FakeClassnameTags123Api { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public TestClassnameOper testClassname() { - return new TestClassnameOper(reqSpec); + return new TestClassnameOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public FakeClassnameTags123Api reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FakeClassnameTags123Api reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -122,22 +131,22 @@ public class FakeClassnameTags123Api { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public TestClassnameOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public TestClassnameOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public TestClassnameOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public TestClassnameOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/PetApi.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/PetApi.java index d64370cf3d..cc8a389d94 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/PetApi.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/PetApi.java @@ -41,14 +41,23 @@ import static io.restassured.http.Method.*; @Api(value = "Pet") public class PetApi { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private PetApi(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private PetApi(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static PetApi pet(RequestSpecBuilder reqSpec) { - return new PetApi(reqSpec); + public static PetApi pet(Supplier reqSpecSupplier) { + return new PetApi(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -60,7 +69,7 @@ public class PetApi { @ApiResponse(code = 200, message = "successful operation") , @ApiResponse(code = 405, message = "Invalid input") }) public AddPetOper addPet() { - return new AddPetOper(reqSpec); + return new AddPetOper(createReqSpec()); } @ApiOperation(value = "Deletes a pet", @@ -71,7 +80,7 @@ public class PetApi { @ApiResponse(code = 200, message = "successful operation") , @ApiResponse(code = 400, message = "Invalid pet value") }) public DeletePetOper deletePet() { - return new DeletePetOper(reqSpec); + return new DeletePetOper(createReqSpec()); } @ApiOperation(value = "Finds Pets by status", @@ -82,7 +91,7 @@ public class PetApi { @ApiResponse(code = 200, message = "successful operation") , @ApiResponse(code = 400, message = "Invalid status value") }) public FindPetsByStatusOper findPetsByStatus() { - return new FindPetsByStatusOper(reqSpec); + return new FindPetsByStatusOper(createReqSpec()); } @ApiOperation(value = "Finds Pets by tags", @@ -94,7 +103,7 @@ public class PetApi { @ApiResponse(code = 400, message = "Invalid tag value") }) @Deprecated public FindPetsByTagsOper findPetsByTags() { - return new FindPetsByTagsOper(reqSpec); + return new FindPetsByTagsOper(createReqSpec()); } @ApiOperation(value = "Find pet by ID", @@ -106,7 +115,7 @@ public class PetApi { @ApiResponse(code = 400, message = "Invalid ID supplied") , @ApiResponse(code = 404, message = "Pet not found") }) public GetPetByIdOper getPetById() { - return new GetPetByIdOper(reqSpec); + return new GetPetByIdOper(createReqSpec()); } @ApiOperation(value = "Update an existing pet", @@ -119,7 +128,7 @@ public class PetApi { @ApiResponse(code = 404, message = "Pet not found") , @ApiResponse(code = 405, message = "Validation exception") }) public UpdatePetOper updatePet() { - return new UpdatePetOper(reqSpec); + return new UpdatePetOper(createReqSpec()); } @ApiOperation(value = "Updates a pet in the store with form data", @@ -129,7 +138,7 @@ public class PetApi { @ApiResponses(value = { @ApiResponse(code = 405, message = "Invalid input") }) public UpdatePetWithFormOper updatePetWithForm() { - return new UpdatePetWithFormOper(reqSpec); + return new UpdatePetWithFormOper(createReqSpec()); } @ApiOperation(value = "uploads an image", @@ -139,7 +148,7 @@ public class PetApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public UploadFileOper uploadFile() { - return new UploadFileOper(reqSpec); + return new UploadFileOper(createReqSpec()); } @ApiOperation(value = "uploads an image (required)", @@ -149,16 +158,16 @@ public class PetApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public UploadFileWithRequiredFileOper uploadFileWithRequiredFile() { - return new UploadFileWithRequiredFileOper(reqSpec); + return new UploadFileWithRequiredFileOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public PetApi reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public PetApi reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -203,22 +212,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public AddPetOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public AddPetOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public AddPetOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public AddPetOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -276,22 +285,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public DeletePetOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public DeletePetOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public DeletePetOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public DeletePetOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -348,22 +357,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FindPetsByStatusOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FindPetsByStatusOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FindPetsByStatusOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FindPetsByStatusOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -422,22 +431,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public FindPetsByTagsOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public FindPetsByTagsOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public FindPetsByTagsOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public FindPetsByTagsOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -494,22 +503,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public GetPetByIdOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public GetPetByIdOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public GetPetByIdOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public GetPetByIdOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -554,22 +563,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public UpdatePetOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UpdatePetOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public UpdatePetOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public UpdatePetOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -640,22 +649,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public UpdatePetWithFormOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UpdatePetWithFormOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public UpdatePetWithFormOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public UpdatePetWithFormOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -737,22 +746,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public UploadFileOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UploadFileOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public UploadFileOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public UploadFileOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -834,22 +843,22 @@ public class PetApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public UploadFileWithRequiredFileOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UploadFileWithRequiredFileOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public UploadFileWithRequiredFileOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public UploadFileWithRequiredFileOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/StoreApi.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/StoreApi.java index b1426680b6..83591c7169 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/StoreApi.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/StoreApi.java @@ -39,14 +39,23 @@ import static io.restassured.http.Method.*; @Api(value = "Store") public class StoreApi { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private StoreApi(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private StoreApi(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static StoreApi store(RequestSpecBuilder reqSpec) { - return new StoreApi(reqSpec); + public static StoreApi store(Supplier reqSpecSupplier) { + return new StoreApi(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -58,7 +67,7 @@ public class StoreApi { @ApiResponse(code = 400, message = "Invalid ID supplied") , @ApiResponse(code = 404, message = "Order not found") }) public DeleteOrderOper deleteOrder() { - return new DeleteOrderOper(reqSpec); + return new DeleteOrderOper(createReqSpec()); } @ApiOperation(value = "Returns pet inventories by status", @@ -68,7 +77,7 @@ public class StoreApi { @ApiResponses(value = { @ApiResponse(code = 200, message = "successful operation") }) public GetInventoryOper getInventory() { - return new GetInventoryOper(reqSpec); + return new GetInventoryOper(createReqSpec()); } @ApiOperation(value = "Find purchase order by ID", @@ -80,7 +89,7 @@ public class StoreApi { @ApiResponse(code = 400, message = "Invalid ID supplied") , @ApiResponse(code = 404, message = "Order not found") }) public GetOrderByIdOper getOrderById() { - return new GetOrderByIdOper(reqSpec); + return new GetOrderByIdOper(createReqSpec()); } @ApiOperation(value = "Place an order for a pet", @@ -91,16 +100,16 @@ public class StoreApi { @ApiResponse(code = 200, message = "successful operation") , @ApiResponse(code = 400, message = "Invalid Order") }) public PlaceOrderOper placeOrder() { - return new PlaceOrderOper(reqSpec); + return new PlaceOrderOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public StoreApi reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public StoreApi reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -146,22 +155,22 @@ public class StoreApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public DeleteOrderOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public DeleteOrderOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public DeleteOrderOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public DeleteOrderOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -206,22 +215,22 @@ public class StoreApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public GetInventoryOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public GetInventoryOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public GetInventoryOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public GetInventoryOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -278,22 +287,22 @@ public class StoreApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public GetOrderByIdOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public GetOrderByIdOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public GetOrderByIdOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public GetOrderByIdOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -349,22 +358,22 @@ public class StoreApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public PlaceOrderOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public PlaceOrderOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public PlaceOrderOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public PlaceOrderOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } diff --git a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/UserApi.java b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/UserApi.java index e132c70e18..3ab3025c92 100644 --- a/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/UserApi.java +++ b/samples/client/petstore/java/rest-assured/src/main/java/org/openapitools/client/api/UserApi.java @@ -39,14 +39,23 @@ import static io.restassured.http.Method.*; @Api(value = "User") public class UserApi { - private RequestSpecBuilder reqSpec; + private Supplier reqSpecSupplier; + private Consumer reqSpecCustomizer; - private UserApi(RequestSpecBuilder reqSpec) { - this.reqSpec = reqSpec; + private UserApi(Supplier reqSpecSupplier) { + this.reqSpecSupplier = reqSpecSupplier; } - public static UserApi user(RequestSpecBuilder reqSpec) { - return new UserApi(reqSpec); + public static UserApi user(Supplier reqSpecSupplier) { + return new UserApi(reqSpecSupplier); + } + + private RequestSpecBuilder createReqSpec() { + RequestSpecBuilder reqSpec = reqSpecSupplier.get(); + if(reqSpecCustomizer != null) { + reqSpecCustomizer.accept(reqSpec); + } + return reqSpec; } @@ -57,7 +66,7 @@ public class UserApi { @ApiResponses(value = { @ApiResponse(code = 0, message = "successful operation") }) public CreateUserOper createUser() { - return new CreateUserOper(reqSpec); + return new CreateUserOper(createReqSpec()); } @ApiOperation(value = "Creates list of users with given input array", @@ -67,7 +76,7 @@ public class UserApi { @ApiResponses(value = { @ApiResponse(code = 0, message = "successful operation") }) public CreateUsersWithArrayInputOper createUsersWithArrayInput() { - return new CreateUsersWithArrayInputOper(reqSpec); + return new CreateUsersWithArrayInputOper(createReqSpec()); } @ApiOperation(value = "Creates list of users with given input array", @@ -77,7 +86,7 @@ public class UserApi { @ApiResponses(value = { @ApiResponse(code = 0, message = "successful operation") }) public CreateUsersWithListInputOper createUsersWithListInput() { - return new CreateUsersWithListInputOper(reqSpec); + return new CreateUsersWithListInputOper(createReqSpec()); } @ApiOperation(value = "Delete user", @@ -88,7 +97,7 @@ public class UserApi { @ApiResponse(code = 400, message = "Invalid username supplied") , @ApiResponse(code = 404, message = "User not found") }) public DeleteUserOper deleteUser() { - return new DeleteUserOper(reqSpec); + return new DeleteUserOper(createReqSpec()); } @ApiOperation(value = "Get user by user name", @@ -100,7 +109,7 @@ public class UserApi { @ApiResponse(code = 400, message = "Invalid username supplied") , @ApiResponse(code = 404, message = "User not found") }) public GetUserByNameOper getUserByName() { - return new GetUserByNameOper(reqSpec); + return new GetUserByNameOper(createReqSpec()); } @ApiOperation(value = "Logs user into the system", @@ -111,7 +120,7 @@ public class UserApi { @ApiResponse(code = 200, message = "successful operation") , @ApiResponse(code = 400, message = "Invalid username/password supplied") }) public LoginUserOper loginUser() { - return new LoginUserOper(reqSpec); + return new LoginUserOper(createReqSpec()); } @ApiOperation(value = "Logs out current logged in user session", @@ -121,7 +130,7 @@ public class UserApi { @ApiResponses(value = { @ApiResponse(code = 0, message = "successful operation") }) public LogoutUserOper logoutUser() { - return new LogoutUserOper(reqSpec); + return new LogoutUserOper(createReqSpec()); } @ApiOperation(value = "Updated user", @@ -132,16 +141,16 @@ public class UserApi { @ApiResponse(code = 400, message = "Invalid user supplied") , @ApiResponse(code = 404, message = "User not found") }) public UpdateUserOper updateUser() { - return new UpdateUserOper(reqSpec); + return new UpdateUserOper(createReqSpec()); } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return api */ - public UserApi reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UserApi reqSpec(Consumer reqSpecCustomizer) { + this.reqSpecCustomizer = reqSpecCustomizer; return this; } @@ -186,22 +195,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public CreateUserOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public CreateUserOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public CreateUserOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public CreateUserOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -246,22 +255,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public CreateUsersWithArrayInputOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public CreateUsersWithArrayInputOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public CreateUsersWithArrayInputOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public CreateUsersWithArrayInputOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -306,22 +315,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public CreateUsersWithListInputOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public CreateUsersWithListInputOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public CreateUsersWithListInputOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public CreateUsersWithListInputOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -367,22 +376,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public DeleteUserOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public DeleteUserOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public DeleteUserOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public DeleteUserOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -439,22 +448,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public GetUserByNameOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public GetUserByNameOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public GetUserByNameOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public GetUserByNameOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -523,22 +532,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public LoginUserOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public LoginUserOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public LoginUserOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public LoginUserOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -572,22 +581,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public LogoutUserOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public LogoutUserOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public LogoutUserOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public LogoutUserOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } @@ -644,22 +653,22 @@ public class UserApi { } /** - * Customise request specification - * @param consumer consumer + * Customize request specification + * @param reqSpecCustomizer consumer to modify the RequestSpecBuilder * @return operation */ - public UpdateUserOper reqSpec(Consumer consumer) { - consumer.accept(reqSpec); + public UpdateUserOper reqSpec(Consumer reqSpecCustomizer) { + reqSpecCustomizer.accept(reqSpec); return this; } /** - * Customise response specification - * @param consumer consumer + * Customize response specification + * @param respSpecCustomizer consumer to modify the ResponseSpecBuilder * @return operation */ - public UpdateUserOper respSpec(Consumer consumer) { - consumer.accept(respSpec); + public UpdateUserOper respSpec(Consumer respSpecCustomizer) { + respSpecCustomizer.accept(respSpec); return this; } } From 1e735c69faccf00c7b600d6fc797966bd82383d5 Mon Sep 17 00:00:00 2001 From: Akihito Nakano Date: Thu, 18 Jul 2019 15:04:27 +0900 Subject: [PATCH 24/62] Add `Logs` section to the Debugging page. (#3357) --- docs/debugging.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/docs/debugging.md b/docs/debugging.md index 99c47c658e..783a6012be 100644 --- a/docs/debugging.md +++ b/docs/debugging.md @@ -62,3 +62,26 @@ The steps are shown here for a specific version of the generator, but apply the Listening for transport dt_socket at address: 5005 ``` * Set breakpoints in code, and then attach your remote debugger from your IDE (see above). The generator will automatically unblock once the remote debugger is attached. You can now step through the code. + +## Logs + +You can try to enable debugging log with `-Dlog.level=debug` option to the `JAVA_OPTS` environment variable to see more information: + +```bash +export JAVA_OPTS="${JAVA_OPTS} -Dlog.level=debug" +``` + +Set the option then DEBUG logs are printed out: + +```bash +openapi-generator generate -g go ... + +... +... +[main] DEBUG o.o.codegen.DefaultCodegen - debugging fromProperty for files : class Schema { + type: null + format: null + $ref: #/components/schemas/File +... +... +``` From 1aa8a2bec4c6f49626f58db96cb44e38a9b886e9 Mon Sep 17 00:00:00 2001 From: Josh Burton Date: Thu, 18 Jul 2019 18:28:15 +1200 Subject: [PATCH 25/62] [dart-jaguar] Fixes error accessing default converters (#3361) `this.converters` was causing errors as the default converters are declared outside of the API client. --- .../src/main/resources/dart-jaguar/apilib.mustache | 6 +++--- .../flutter_petstore/openapi/.openapi-generator/VERSION | 2 +- .../dart-jaguar/flutter_petstore/openapi/README.md | 1 - .../dart-jaguar/flutter_petstore/openapi/lib/api.dart | 8 ++++---- .../openapi/.openapi-generator/VERSION | 2 +- .../dart-jaguar/flutter_proto_petstore/openapi/README.md | 1 - .../flutter_proto_petstore/openapi/lib/api.dart | 8 ++++---- .../dart-jaguar/openapi/.openapi-generator/VERSION | 2 +- samples/client/petstore/dart-jaguar/openapi/README.md | 1 - samples/client/petstore/dart-jaguar/openapi/lib/api.dart | 8 ++++---- .../dart-jaguar/openapi_proto/.openapi-generator/VERSION | 2 +- .../client/petstore/dart-jaguar/openapi_proto/README.md | 1 - .../petstore/dart-jaguar/openapi_proto/lib/api.dart | 8 ++++---- 13 files changed, 23 insertions(+), 27 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache b/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache index 8571ea0a19..1fd657ea1d 100644 --- a/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache +++ b/modules/openapi-generator/src/main/resources/dart-jaguar/apilib.mustache @@ -21,7 +21,7 @@ import 'package:jaguar_mimetype/jaguar_mimetype.dart'; final _jsonJaguarRepo = JsonRepo() {{#models}}{{#model}}..add({{classname}}Serializer()) {{/model}}{{/models}}; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, }; {{/jsonFormat}} @@ -33,7 +33,7 @@ final _protoJaguarRepo = ProtoCodecRepo() final _jsonJaguarRepo = ProtoCodecRepo(isJsonFormatEnabled: true) {{#models}}{{#model}}..add((data) => {{classname}}.fromBuffer(List.from(data))) {{/model}}{{/models}}; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, MimeTypes.binary: _protoJaguarRepo, }; @@ -91,7 +91,7 @@ class {{clientName}} { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return {{classname}}(base: base, converters: converters, timeout: timeout); } diff --git a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/.openapi-generator/VERSION b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/.openapi-generator/VERSION +++ b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md index 291b60d7e6..693df464eb 100644 --- a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/README.md @@ -4,7 +4,6 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T09:47:15.495+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements diff --git a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart index b787b0405d..d077b86fe9 100644 --- a/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/flutter_petstore/openapi/lib/api.dart @@ -29,7 +29,7 @@ final _jsonJaguarRepo = JsonRepo() ..add(TagSerializer()) ..add(UserSerializer()) ; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, }; @@ -86,7 +86,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return PetApi(base: base, converters: converters, timeout: timeout); } @@ -101,7 +101,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return StoreApi(base: base, converters: converters, timeout: timeout); } @@ -116,7 +116,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return UserApi(base: base, converters: converters, timeout: timeout); } diff --git a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/.openapi-generator/VERSION b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/.openapi-generator/VERSION +++ b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md index 8277867842..693df464eb 100644 --- a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/README.md @@ -4,7 +4,6 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T09:47:16.421+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements diff --git a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart index 12dcdff72f..60148b8f58 100644 --- a/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/flutter_proto_petstore/openapi/lib/api.dart @@ -39,7 +39,7 @@ final _jsonJaguarRepo = ProtoCodecRepo(isJsonFormatEnabled: true) ..add((data) => Tag.fromBuffer(List.from(data))) ..add((data) => User.fromBuffer(List.from(data))) ; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, MimeTypes.binary: _protoJaguarRepo, }; @@ -96,7 +96,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return PetApi(base: base, converters: converters, timeout: timeout); } @@ -111,7 +111,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return StoreApi(base: base, converters: converters, timeout: timeout); } @@ -126,7 +126,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return UserApi(base: base, converters: converters, timeout: timeout); } diff --git a/samples/client/petstore/dart-jaguar/openapi/.openapi-generator/VERSION b/samples/client/petstore/dart-jaguar/openapi/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/dart-jaguar/openapi/.openapi-generator/VERSION +++ b/samples/client/petstore/dart-jaguar/openapi/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/dart-jaguar/openapi/README.md b/samples/client/petstore/dart-jaguar/openapi/README.md index 7f45064333..693df464eb 100644 --- a/samples/client/petstore/dart-jaguar/openapi/README.md +++ b/samples/client/petstore/dart-jaguar/openapi/README.md @@ -4,7 +4,6 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T09:47:14.533+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements diff --git a/samples/client/petstore/dart-jaguar/openapi/lib/api.dart b/samples/client/petstore/dart-jaguar/openapi/lib/api.dart index b787b0405d..d077b86fe9 100644 --- a/samples/client/petstore/dart-jaguar/openapi/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/openapi/lib/api.dart @@ -29,7 +29,7 @@ final _jsonJaguarRepo = JsonRepo() ..add(TagSerializer()) ..add(UserSerializer()) ; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, }; @@ -86,7 +86,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return PetApi(base: base, converters: converters, timeout: timeout); } @@ -101,7 +101,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return StoreApi(base: base, converters: converters, timeout: timeout); } @@ -116,7 +116,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return UserApi(base: base, converters: converters, timeout: timeout); } diff --git a/samples/client/petstore/dart-jaguar/openapi_proto/.openapi-generator/VERSION b/samples/client/petstore/dart-jaguar/openapi_proto/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/dart-jaguar/openapi_proto/.openapi-generator/VERSION +++ b/samples/client/petstore/dart-jaguar/openapi_proto/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/dart-jaguar/openapi_proto/README.md b/samples/client/petstore/dart-jaguar/openapi_proto/README.md index 84be8a47c9..693df464eb 100644 --- a/samples/client/petstore/dart-jaguar/openapi_proto/README.md +++ b/samples/client/petstore/dart-jaguar/openapi_proto/README.md @@ -4,7 +4,6 @@ This is a sample server Petstore server. For this sample, you can use the api ke This Dart package is automatically generated by the [Open API Codegen](https://github.com/OpenAPITools/openapi-generator) project: - API version: 1.0.0 -- Build date: 2019-06-29T09:47:17.358+12:00[Pacific/Auckland] - Build package: org.openapitools.codegen.languages.DartJaguarClientCodegen ## Requirements diff --git a/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart b/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart index 12dcdff72f..60148b8f58 100644 --- a/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart +++ b/samples/client/petstore/dart-jaguar/openapi_proto/lib/api.dart @@ -39,7 +39,7 @@ final _jsonJaguarRepo = ProtoCodecRepo(isJsonFormatEnabled: true) ..add((data) => Tag.fromBuffer(List.from(data))) ..add((data) => User.fromBuffer(List.from(data))) ; -final Map converters = { +final Map defaultConverters = { MimeTypes.json: _jsonJaguarRepo, MimeTypes.binary: _protoJaguarRepo, }; @@ -96,7 +96,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return PetApi(base: base, converters: converters, timeout: timeout); } @@ -111,7 +111,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return StoreApi(base: base, converters: converters, timeout: timeout); } @@ -126,7 +126,7 @@ class Openapi { base = _baseRoute; } if(converters == null) { - converters = this.converters; + converters = defaultConverters; } return UserApi(base: base, converters: converters, timeout: timeout); } From 0fec25e92e933114a34245c2ceaf4a9e9677c6f4 Mon Sep 17 00:00:00 2001 From: Slavek Kabrda Date: Thu, 18 Jul 2019 02:52:37 -0400 Subject: [PATCH 26/62] [Go][experimental-client]: make struct members pointers, provide custom marshalling (#3371) * [Go][experimental-client] Properly define packageName for go-experimental sample client * [Go][experimental-client] make structure members pointers, provide custom marshalling. --- bin/go-experimental-petstore.sh | 2 +- .../GoClientExperimentalCodegen.java | 39 + .../resources/go-experimental/README.mustache | 16 + .../resources/go-experimental/model.mustache | 88 +- .../go-experimental/model_doc.mustache | 43 +- .../resources/go-experimental/utils.mustache | 31 + .../petstore/go-experimental/auth_test.go | 30 +- .../petstore/go-experimental/fake_api_test.go | 4 +- .../go-petstore/.openapi-generator/VERSION | 2 +- .../go-experimental/go-petstore/README.md | 16 + .../docs/AdditionalPropertiesAnyType.md | 30 +- .../docs/AdditionalPropertiesArray.md | 30 +- .../docs/AdditionalPropertiesBoolean.md | 30 +- .../docs/AdditionalPropertiesClass.md | 300 ++++- .../docs/AdditionalPropertiesInteger.md | 30 +- .../docs/AdditionalPropertiesNumber.md | 30 +- .../docs/AdditionalPropertiesObject.md | 30 +- .../docs/AdditionalPropertiesString.md | 30 +- .../go-petstore/docs/Animal.md | 57 +- .../go-petstore/docs/ApiResponse.md | 84 +- .../docs/ArrayOfArrayOfNumberOnly.md | 30 +- .../go-petstore/docs/ArrayOfNumberOnly.md | 30 +- .../go-petstore/docs/ArrayTest.md | 84 +- .../go-petstore/docs/Capitalization.md | 165 ++- .../go-experimental/go-petstore/docs/Cat.md | 84 +- .../go-petstore/docs/CatAllOf.md | 30 +- .../go-petstore/docs/Category.md | 57 +- .../go-petstore/docs/ClassModel.md | 30 +- .../go-petstore/docs/Client.md | 30 +- .../go-experimental/go-petstore/docs/Dog.md | 84 +- .../go-petstore/docs/DogAllOf.md | 30 +- .../go-petstore/docs/EnumArrays.md | 57 +- .../go-petstore/docs/EnumClass.md | 1 + .../go-petstore/docs/EnumTest.md | 138 +- .../go-experimental/go-petstore/docs/File.md | 30 +- .../go-petstore/docs/FileSchemaTestClass.md | 57 +- .../go-petstore/docs/FormatTest.md | 354 ++++- .../go-petstore/docs/HasOnlyReadOnly.md | 57 +- .../go-experimental/go-petstore/docs/List.md | 30 +- .../go-petstore/docs/MapTest.md | 111 +- ...dPropertiesAndAdditionalPropertiesClass.md | 84 +- .../go-petstore/docs/Model200Response.md | 57 +- .../go-experimental/go-petstore/docs/Name.md | 111 +- .../go-petstore/docs/NumberOnly.md | 30 +- .../go-experimental/go-petstore/docs/Order.md | 165 ++- .../go-petstore/docs/OuterComposite.md | 84 +- .../go-petstore/docs/OuterEnum.md | 1 + .../go-experimental/go-petstore/docs/Pet.md | 165 ++- .../go-petstore/docs/ReadOnlyFirst.md | 57 +- .../go-petstore/docs/Return.md | 30 +- .../go-petstore/docs/SpecialModelName.md | 30 +- .../go-experimental/go-petstore/docs/Tag.md | 57 +- .../go-petstore/docs/TypeHolderDefault.md | 138 +- .../go-petstore/docs/TypeHolderExample.md | 138 +- .../go-experimental/go-petstore/docs/User.md | 219 +++- .../go-petstore/docs/XmlItem.md | 786 +++++++++++- .../go-petstore/model_200_response.go | 89 +- .../model_additional_properties_any_type.go | 50 +- .../model_additional_properties_array.go | 50 +- .../model_additional_properties_boolean.go | 50 +- .../model_additional_properties_class.go | 440 ++++++- .../model_additional_properties_integer.go | 50 +- .../model_additional_properties_number.go | 50 +- .../model_additional_properties_object.go | 50 +- .../model_additional_properties_string.go | 50 +- .../go-petstore/model_animal.go | 93 +- .../go-petstore/model_api_response.go | 128 +- .../model_array_of_array_of_number_only.go | 50 +- .../go-petstore/model_array_of_number_only.go | 50 +- .../go-petstore/model_array_test_.go | 128 +- .../go-petstore/model_capitalization.go | 245 +++- .../go-experimental/go-petstore/model_cat.go | 132 +- .../go-petstore/model_cat_all_of.go | 50 +- .../go-petstore/model_category.go | 93 +- .../go-petstore/model_class_model.go | 50 +- .../go-petstore/model_client.go | 50 +- .../go-experimental/go-petstore/model_dog.go | 132 +- .../go-petstore/model_dog_all_of.go | 50 +- .../go-petstore/model_enum_arrays.go | 89 +- .../go-petstore/model_enum_class.go | 3 +- .../go-petstore/model_enum_test_.go | 210 ++- .../go-experimental/go-petstore/model_file.go | 50 +- .../model_file_schema_test_class.go | 89 +- .../go-petstore/model_format_test_.go | 529 +++++++- .../go-petstore/model_has_only_read_only.go | 89 +- .../go-experimental/go-petstore/model_list.go | 50 +- .../go-petstore/model_map_test_.go | 167 ++- ...perties_and_additional_properties_class.go | 126 +- .../go-experimental/go-petstore/model_name.go | 171 ++- .../go-petstore/model_number_only.go | 50 +- .../go-petstore/model_order.go | 243 +++- .../go-petstore/model_outer_composite.go | 128 +- .../go-petstore/model_outer_enum.go | 3 +- .../go-experimental/go-petstore/model_pet.go | 252 +++- .../go-petstore/model_read_only_first.go | 89 +- .../go-petstore/model_return.go | 50 +- .../go-petstore/model_special_model_name.go | 50 +- .../go-experimental/go-petstore/model_tag.go | 89 +- .../go-petstore/model_type_holder_default.go | 222 +++- .../go-petstore/model_type_holder_example.go | 222 +++- .../go-experimental/go-petstore/model_user.go | 323 ++++- .../go-petstore/model_xml_item.go | 1142 ++++++++++++++++- .../go-experimental/go-petstore/utils.go | 39 + .../petstore/go-experimental/pet_api_test.go | 22 +- .../go-experimental/store_api_test.go | 12 +- .../petstore/go-experimental/user_api_test.go | 76 +- 106 files changed, 10895 insertions(+), 383 deletions(-) create mode 100644 modules/openapi-generator/src/main/resources/go-experimental/utils.mustache create mode 100644 samples/client/petstore/go-experimental/go-petstore/utils.go diff --git a/bin/go-experimental-petstore.sh b/bin/go-experimental-petstore.sh index d4eabb177c..ea7d839795 100755 --- a/bin/go-experimental-petstore.sh +++ b/bin/go-experimental-petstore.sh @@ -34,6 +34,6 @@ rm -rf $STUB_DIR # if you've executed sbt assembly previously it will use that instead. export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" -ags="generate -t modules/openapi-generator/src/main/resources/$GENERATOR -i $SPEC -g $GENERATOR -o $STUB_DIR -DpackageName=petstore $@" +ags="generate -t modules/openapi-generator/src/main/resources/$GENERATOR -i $SPEC -g $GENERATOR -o $STUB_DIR --additional-properties packageName=petstore $@" java $JAVA_OPTS -jar $executable $ags diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientExperimentalCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientExperimentalCodegen.java index 14148714e6..ff0aafe24c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientExperimentalCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/GoClientExperimentalCodegen.java @@ -16,15 +16,23 @@ package org.openapitools.codegen.languages; +import org.openapitools.codegen.CodegenModel; +import org.openapitools.codegen.CodegenProperty; +import org.openapitools.codegen.SupportingFile; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import java.util.List; +import java.util.Map; + public class GoClientExperimentalCodegen extends GoClientCodegen { private static final Logger LOGGER = LoggerFactory.getLogger(GoClientExperimentalCodegen.class); public GoClientExperimentalCodegen() { super(); + outputFolder = "generated-code/go-experimental"; + embeddedTemplateDir = templateDir = "go-experimental"; } /** @@ -49,4 +57,35 @@ public class GoClientExperimentalCodegen extends GoClientCodegen { return "Generates a Go client library (experimental and may subject to breaking changes without further notice)."; } + @Override + public void processOpts() { + super.processOpts(); + supportingFiles.add(new SupportingFile("utils.mustache", "", "utils.go")); + } + + @Override + public Map postProcessModels(Map objs) { + objs = super.postProcessModels(objs); + List> imports = (List>) objs.get("imports"); + + boolean addedErrorsImport = false; + List> models = (List>) objs.get("models"); + for (Map m : models) { + Object v = m.get("model"); + if (v instanceof CodegenModel) { + CodegenModel model = (CodegenModel) v; + if (!model.isEnum) { + imports.add(createMapping("import", "encoding/json")); + } + for (CodegenProperty param : model.vars) { + if (!addedErrorsImport && param.required) { + imports.add(createMapping("import", "errors")); + addedErrorsImport = true; + } + } + } + } + + return objs; + } } diff --git a/modules/openapi-generator/src/main/resources/go-experimental/README.mustache b/modules/openapi-generator/src/main/resources/go-experimental/README.mustache index 5c9639022a..869443a26e 100644 --- a/modules/openapi-generator/src/main/resources/go-experimental/README.mustache +++ b/modules/openapi-generator/src/main/resources/go-experimental/README.mustache @@ -113,6 +113,22 @@ r, err := client.Service.Operation(auth, args) {{/isOAuth}} {{/authMethods}} +## Documentation for Utility Methods + +Due to the fact that model structure members are all pointers, this package contains +a number of utility functions to easily obtain pointers to values of basic types. +Each of these functions takes a value of the given basic type and returns a pointer to it: + +* `PtrBool` +* `PtrInt` +* `PtrInt32` +* `PtrInt64` +* `PtrFloat` +* `PtrFloat32` +* `PtrFloat64` +* `PtrString` +* `PtrTime` + ## Author {{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}} diff --git a/modules/openapi-generator/src/main/resources/go-experimental/model.mustache b/modules/openapi-generator/src/main/resources/go-experimental/model.mustache index 1a9f8d1c5a..17833f918b 100644 --- a/modules/openapi-generator/src/main/resources/go-experimental/model.mustache +++ b/modules/openapi-generator/src/main/resources/go-experimental/model.mustache @@ -35,9 +35,95 @@ type {{classname}} struct { {{#description}} // {{{description}}} {{/description}} - {{name}} {{#isNullable}}*{{/isNullable}}{{{dataType}}} `json:"{{baseName}}{{^required}},omitempty{{/required}}"{{#withXml}} xml:"{{baseName}}{{#isXmlAttribute}},attr{{/isXmlAttribute}}"{{/withXml}}{{#vendorExtensions.x-go-custom-tag}} {{{.}}}{{/vendorExtensions.x-go-custom-tag}}` + {{name}} *{{{dataType}}} `json:"{{baseName}},omitempty"{{#withXml}} xml:"{{baseName}}{{#isXmlAttribute}},attr{{/isXmlAttribute}}"{{/withXml}}{{#vendorExtensions.x-go-custom-tag}} {{{.}}}{{/vendorExtensions.x-go-custom-tag}}` +{{#isNullable}} isExplicitNull{{name}} bool `json:"-"{{#withXml}} xml:"-"{{/withXml}}`{{/isNullable}} {{/vars}} } {{/isEnum}} + +{{^isEnum}} +{{#vars}} +// Get{{name}} returns the {{name}} field if non-nil, zero value otherwise. +func (o *{{classname}}) Get{{name}}() {{dataType}} { + if o == nil || o.{{name}} == nil { + var ret {{dataType}} + return ret + } + return *o.{{name}} +} + +// Get{{name}}Ok returns a tuple with the {{name}} field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *{{classname}}) Get{{name}}Ok() ({{dataType}}, bool) { + if o == nil || o.{{name}} == nil { + var ret {{dataType}} + return ret, false + } + return *o.{{name}}, true +} + +// Has{{name}} returns a boolean if a field has been set. +func (o *{{classname}}) Has{{name}}() bool { + if o != nil && o.{{name}} != nil { + return true + } + + return false +} + +// Set{{name}} gets a reference to the given {{dataType}} and assigns it to the {{name}} field. +func (o *{{classname}}) Set{{name}}(v {{dataType}}) { + o.{{name}} = &v +} + +{{#isNullable}} +// Set{{name}}ExplicitNull (un)sets {{name}} to be considered as explicit "null" value +// when serializing to JSON (pass true as argument to set this, false to unset) +// The {{name}} value is set to nil even if false is passed +func (o *{{classname}}) Set{{name}}ExplicitNull(b bool) { + o.{{name}} = nil + o.isExplicitNull{{name}} = b +} +{{/isNullable}} +{{/vars}} + +func (o {{classname}}) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + {{#vars}} + {{#required}} + {{! if argument is required and not nullable, it can't be nil}} + {{^isNullable}} + if o.{{name}} == nil { + return nil, errors.New("{{name}} is required and not nullable, but was not set on {{classname}}") + }{{/isNullable}} + {{! if argument is required and nullable, it *must* have isExplicitNull set to true when it's nil}} + {{#isNullable}} + if o.{{name}} == nil && !o.isExplicitNull{{name}} { + return nil, errors.New("{{name}} is required and nullable, but it wasn't set to be explicit null") + } + {{/isNullable}} + {{/required}} + {{! if argument is nullable, only serialize it if it is nil *and* was explicitly set to nil}} + {{#isNullable}} + if o.{{name}} == nil { + if o.isExplicitNull{{name}} { + toSerialize["{{baseName}}"] = o.{{name}} + } + } else { + toSerialize["{{baseName}}"] = o.{{name}} + } + {{/isNullable}} + {{! if argument is not nullable, don't set it if it is nil}} + {{^isNullable}} + if o.{{name}} != nil { + toSerialize["{{baseName}}"] = o.{{name}} + } + {{/isNullable}} + {{/vars}} + return json.Marshal(toSerialize) +} + +{{/isEnum}} + {{/model}} {{/models}} diff --git a/modules/openapi-generator/src/main/resources/go-experimental/model_doc.mustache b/modules/openapi-generator/src/main/resources/go-experimental/model_doc.mustache index 546238243b..98040dcb25 100644 --- a/modules/openapi-generator/src/main/resources/go-experimental/model_doc.mustache +++ b/modules/openapi-generator/src/main/resources/go-experimental/model_doc.mustache @@ -4,9 +4,50 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -{{#vars}}**{{name}}** | {{#isNullable}}Pointer to {{/isNullable}}{{#isPrimitiveType}}**{{{dataType}}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{{dataType}}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}}[optional] {{/required}}{{#readOnly}}[readonly] {{/readOnly}}{{#defaultValue}}[default to {{{.}}}]{{/defaultValue}} +{{#vars}}**{{name}}** | Pointer to {{#isPrimitiveType}}**{{{dataType}}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{{dataType}}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}}[optional] {{/required}}{{#readOnly}}[readonly] {{/readOnly}}{{#defaultValue}}[default to {{{.}}}]{{/defaultValue}} {{/vars}} +{{^isEnum}} +## Methods + +{{#vars}} +### Get{{name}} + +`func (o *{{classname}}) Get{{name}}() {{dataType}}` + +Get{{name}} returns the {{name}} field if non-nil, zero value otherwise. + +### Get{{name}}Ok + +`func (o *{{classname}}) Get{{name}}Ok() ({{dataType}}, bool)` + +Get{{name}}Ok returns a tuple with the {{name}} field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### Has{{name}} + +`func (o *{{classname}}) Has{{name}}() bool` + +Has{{name}} returns a boolean if a field has been set. + +### Set{{name}} + +`func (o *{{classname}}) Set{{name}}(v {{dataType}})` + +Set{{name}} gets a reference to the given {{dataType}} and assigns it to the {{name}} field. + +{{#isNullable}} +### Set{{name}}ExplicitNull + +`func (o *{{classname}}) Set{{name}}ExplicitNull(b bool)` + +Set{{name}}ExplicitNull (un)sets {{name}} to be considered as explicit "null" value +when serializing to JSON (pass true as argument to set this, false to unset) +The {{name}} value is set to nil even if false is passed +{{/isNullable}} +{{/vars}} +{{/isEnum}} + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) {{/model}}{{/models}} diff --git a/modules/openapi-generator/src/main/resources/go-experimental/utils.mustache b/modules/openapi-generator/src/main/resources/go-experimental/utils.mustache new file mode 100644 index 0000000000..e3598373cb --- /dev/null +++ b/modules/openapi-generator/src/main/resources/go-experimental/utils.mustache @@ -0,0 +1,31 @@ +{{>partial_header}} +package {{packageName}} + +import "time" + +// PtrBool is a helper routine that returns a pointer to given integer value. +func PtrBool(v bool) *bool { return &v } + +// PtrInt is a helper routine that returns a pointer to given integer value. +func PtrInt(v int) *int { return &v } + +// PtrInt32 is a helper routine that returns a pointer to given integer value. +func PtrInt32(v int32) *int32 { return &v } + +// PtrInt64 is a helper routine that returns a pointer to given integer value. +func PtrInt64(v int64) *int64 { return &v } + +// PtrFloat is a helper routine that returns a pointer to given float value. +func PtrFloat(v float32) *float32 { return &v } + +// PtrFloat32 is a helper routine that returns a pointer to given float value. +func PtrFloat32(v float32) *float32 { return &v } + +// PtrFloat64 is a helper routine that returns a pointer to given float value. +func PtrFloat64(v float64) *float64 { return &v } + +// PtrString is a helper routine that returns a pointer to given string value. +func PtrString(v string) *string { return &v } + +// PtrTime is helper routine that returns a pointer to given Time value. +func PtrTime(v time.Time) *time.Time { return &v } \ No newline at end of file diff --git a/samples/client/petstore/go-experimental/auth_test.go b/samples/client/petstore/go-experimental/auth_test.go index 5f817703a8..7da448adce 100644 --- a/samples/client/petstore/go-experimental/auth_test.go +++ b/samples/client/petstore/go-experimental/auth_test.go @@ -37,8 +37,9 @@ func TestOAuth2(t *testing.T) { tokenSource := cfg.TokenSource(createContext(nil), &tok) auth := context.WithValue(context.Background(), sw.ContextOAuth2, tokenSource) - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(context.Background(), newPet) @@ -71,8 +72,9 @@ func TestBasicAuth(t *testing.T) { Password: "f4k3p455", }) - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(auth, newPet) @@ -100,8 +102,9 @@ func TestBasicAuth(t *testing.T) { func TestAccessToken(t *testing.T) { auth := context.WithValue(context.Background(), sw.ContextAccessToken, "TESTFAKEACCESSTOKENISFAKE") - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(nil, newPet) @@ -129,8 +132,9 @@ func TestAccessToken(t *testing.T) { func TestAPIKeyNoPrefix(t *testing.T) { auth := context.WithValue(context.Background(), sw.ContextAPIKey, sw.APIKey{Key: "TEST123"}) - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(context.Background(), newPet) @@ -163,8 +167,9 @@ func TestAPIKeyNoPrefix(t *testing.T) { func TestAPIKeyWithPrefix(t *testing.T) { auth := context.WithValue(context.Background(), sw.ContextAPIKey, sw.APIKey{Key: "TEST123", Prefix: "Bearer"}) - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(nil, newPet) @@ -196,8 +201,9 @@ func TestAPIKeyWithPrefix(t *testing.T) { func TestDefaultHeader(t *testing.T) { - newPet := (sw.Pet{Id: 12992, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12992), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(context.Background(), newPet) diff --git a/samples/client/petstore/go-experimental/fake_api_test.go b/samples/client/petstore/go-experimental/fake_api_test.go index f4242b5048..e97bcb4846 100644 --- a/samples/client/petstore/go-experimental/fake_api_test.go +++ b/samples/client/petstore/go-experimental/fake_api_test.go @@ -14,8 +14,8 @@ func TestPutBodyWithFileSchema(t *testing.T) { return // early return to test compilation schema := sw.FileSchemaTestClass{ - File: sw.File{SourceURI: "https://example.com/image.png"}, - Files: []sw.File{{SourceURI: "https://example.com/image.png"}}} + File: &sw.File{SourceURI: sw.PtrString("https://example.com/image.png")}, + Files: &[]sw.File{{SourceURI: sw.PtrString("https://example.com/image.png")}}} r, err := client.FakeApi.TestBodyWithFileSchema(context.Background(), schema) diff --git a/samples/client/petstore/go-experimental/go-petstore/.openapi-generator/VERSION b/samples/client/petstore/go-experimental/go-petstore/.openapi-generator/VERSION index 479c313e87..83a328a922 100644 --- a/samples/client/petstore/go-experimental/go-petstore/.openapi-generator/VERSION +++ b/samples/client/petstore/go-experimental/go-petstore/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.3-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/go-experimental/go-petstore/README.md b/samples/client/petstore/go-experimental/go-petstore/README.md index 025ee80f2e..f9cf57d259 100644 --- a/samples/client/petstore/go-experimental/go-petstore/README.md +++ b/samples/client/petstore/go-experimental/go-petstore/README.md @@ -199,6 +199,22 @@ r, err := client.Service.Operation(auth, args) ``` +## Documentation for Utility Methods + +Due to the fact that model structure members are all pointers, this package contains +a number of utility functions to easily obtain pointers to values of basic types. +Each of these functions takes a value of the given basic type and returns a pointer to it: + +* `PtrBool` +* `PtrInt` +* `PtrInt32` +* `PtrInt64` +* `PtrFloat` +* `PtrFloat32` +* `PtrFloat64` +* `PtrString` +* `PtrTime` + ## Author diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesAnyType.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesAnyType.md index eadec3142c..47b71f2a71 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesAnyType.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesAnyType.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesAnyType) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesAnyType) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesAnyType) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesAnyType) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesArray.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesArray.md index 0c37598aeb..b8d3d2e343 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesArray.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesArray.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesArray) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesArray) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesArray) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesArray) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesBoolean.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesBoolean.md index 7190fe8429..2c27fcebb9 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesBoolean.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesBoolean.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesBoolean) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesBoolean) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesBoolean) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesBoolean) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesClass.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesClass.md index 877a5d45a3..a676667ed7 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesClass.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesClass.md @@ -4,17 +4,295 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MapString** | **map[string]string** | | [optional] -**MapNumber** | **map[string]float32** | | [optional] -**MapInteger** | **map[string]int32** | | [optional] -**MapBoolean** | **map[string]bool** | | [optional] -**MapArrayInteger** | [**map[string][]int32**](array.md) | | [optional] -**MapArrayAnytype** | [**map[string][]map[string]interface{}**](array.md) | | [optional] -**MapMapString** | [**map[string]map[string]string**](map.md) | | [optional] -**MapMapAnytype** | [**map[string]map[string]map[string]interface{}**](map.md) | | [optional] -**Anytype1** | [**map[string]interface{}**](.md) | | [optional] -**Anytype2** | [**map[string]interface{}**](.md) | | [optional] -**Anytype3** | [**map[string]interface{}**](.md) | | [optional] +**MapString** | Pointer to **map[string]string** | | [optional] +**MapNumber** | Pointer to **map[string]float32** | | [optional] +**MapInteger** | Pointer to **map[string]int32** | | [optional] +**MapBoolean** | Pointer to **map[string]bool** | | [optional] +**MapArrayInteger** | Pointer to [**map[string][]int32**](array.md) | | [optional] +**MapArrayAnytype** | Pointer to [**map[string][]map[string]interface{}**](array.md) | | [optional] +**MapMapString** | Pointer to [**map[string]map[string]string**](map.md) | | [optional] +**MapMapAnytype** | Pointer to [**map[string]map[string]map[string]interface{}**](map.md) | | [optional] +**Anytype1** | Pointer to [**map[string]interface{}**](.md) | | [optional] +**Anytype2** | Pointer to [**map[string]interface{}**](.md) | | [optional] +**Anytype3** | Pointer to [**map[string]interface{}**](.md) | | [optional] + +## Methods + +### GetMapString + +`func (o *AdditionalPropertiesClass) GetMapString() map[string]string` + +GetMapString returns the MapString field if non-nil, zero value otherwise. + +### GetMapStringOk + +`func (o *AdditionalPropertiesClass) GetMapStringOk() (map[string]string, bool)` + +GetMapStringOk returns a tuple with the MapString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapString + +`func (o *AdditionalPropertiesClass) HasMapString() bool` + +HasMapString returns a boolean if a field has been set. + +### SetMapString + +`func (o *AdditionalPropertiesClass) SetMapString(v map[string]string)` + +SetMapString gets a reference to the given map[string]string and assigns it to the MapString field. + +### GetMapNumber + +`func (o *AdditionalPropertiesClass) GetMapNumber() map[string]float32` + +GetMapNumber returns the MapNumber field if non-nil, zero value otherwise. + +### GetMapNumberOk + +`func (o *AdditionalPropertiesClass) GetMapNumberOk() (map[string]float32, bool)` + +GetMapNumberOk returns a tuple with the MapNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapNumber + +`func (o *AdditionalPropertiesClass) HasMapNumber() bool` + +HasMapNumber returns a boolean if a field has been set. + +### SetMapNumber + +`func (o *AdditionalPropertiesClass) SetMapNumber(v map[string]float32)` + +SetMapNumber gets a reference to the given map[string]float32 and assigns it to the MapNumber field. + +### GetMapInteger + +`func (o *AdditionalPropertiesClass) GetMapInteger() map[string]int32` + +GetMapInteger returns the MapInteger field if non-nil, zero value otherwise. + +### GetMapIntegerOk + +`func (o *AdditionalPropertiesClass) GetMapIntegerOk() (map[string]int32, bool)` + +GetMapIntegerOk returns a tuple with the MapInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapInteger + +`func (o *AdditionalPropertiesClass) HasMapInteger() bool` + +HasMapInteger returns a boolean if a field has been set. + +### SetMapInteger + +`func (o *AdditionalPropertiesClass) SetMapInteger(v map[string]int32)` + +SetMapInteger gets a reference to the given map[string]int32 and assigns it to the MapInteger field. + +### GetMapBoolean + +`func (o *AdditionalPropertiesClass) GetMapBoolean() map[string]bool` + +GetMapBoolean returns the MapBoolean field if non-nil, zero value otherwise. + +### GetMapBooleanOk + +`func (o *AdditionalPropertiesClass) GetMapBooleanOk() (map[string]bool, bool)` + +GetMapBooleanOk returns a tuple with the MapBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapBoolean + +`func (o *AdditionalPropertiesClass) HasMapBoolean() bool` + +HasMapBoolean returns a boolean if a field has been set. + +### SetMapBoolean + +`func (o *AdditionalPropertiesClass) SetMapBoolean(v map[string]bool)` + +SetMapBoolean gets a reference to the given map[string]bool and assigns it to the MapBoolean field. + +### GetMapArrayInteger + +`func (o *AdditionalPropertiesClass) GetMapArrayInteger() map[string][]int32` + +GetMapArrayInteger returns the MapArrayInteger field if non-nil, zero value otherwise. + +### GetMapArrayIntegerOk + +`func (o *AdditionalPropertiesClass) GetMapArrayIntegerOk() (map[string][]int32, bool)` + +GetMapArrayIntegerOk returns a tuple with the MapArrayInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapArrayInteger + +`func (o *AdditionalPropertiesClass) HasMapArrayInteger() bool` + +HasMapArrayInteger returns a boolean if a field has been set. + +### SetMapArrayInteger + +`func (o *AdditionalPropertiesClass) SetMapArrayInteger(v map[string][]int32)` + +SetMapArrayInteger gets a reference to the given map[string][]int32 and assigns it to the MapArrayInteger field. + +### GetMapArrayAnytype + +`func (o *AdditionalPropertiesClass) GetMapArrayAnytype() map[string][]map[string]interface{}` + +GetMapArrayAnytype returns the MapArrayAnytype field if non-nil, zero value otherwise. + +### GetMapArrayAnytypeOk + +`func (o *AdditionalPropertiesClass) GetMapArrayAnytypeOk() (map[string][]map[string]interface{}, bool)` + +GetMapArrayAnytypeOk returns a tuple with the MapArrayAnytype field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapArrayAnytype + +`func (o *AdditionalPropertiesClass) HasMapArrayAnytype() bool` + +HasMapArrayAnytype returns a boolean if a field has been set. + +### SetMapArrayAnytype + +`func (o *AdditionalPropertiesClass) SetMapArrayAnytype(v map[string][]map[string]interface{})` + +SetMapArrayAnytype gets a reference to the given map[string][]map[string]interface{} and assigns it to the MapArrayAnytype field. + +### GetMapMapString + +`func (o *AdditionalPropertiesClass) GetMapMapString() map[string]map[string]string` + +GetMapMapString returns the MapMapString field if non-nil, zero value otherwise. + +### GetMapMapStringOk + +`func (o *AdditionalPropertiesClass) GetMapMapStringOk() (map[string]map[string]string, bool)` + +GetMapMapStringOk returns a tuple with the MapMapString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapMapString + +`func (o *AdditionalPropertiesClass) HasMapMapString() bool` + +HasMapMapString returns a boolean if a field has been set. + +### SetMapMapString + +`func (o *AdditionalPropertiesClass) SetMapMapString(v map[string]map[string]string)` + +SetMapMapString gets a reference to the given map[string]map[string]string and assigns it to the MapMapString field. + +### GetMapMapAnytype + +`func (o *AdditionalPropertiesClass) GetMapMapAnytype() map[string]map[string]map[string]interface{}` + +GetMapMapAnytype returns the MapMapAnytype field if non-nil, zero value otherwise. + +### GetMapMapAnytypeOk + +`func (o *AdditionalPropertiesClass) GetMapMapAnytypeOk() (map[string]map[string]map[string]interface{}, bool)` + +GetMapMapAnytypeOk returns a tuple with the MapMapAnytype field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapMapAnytype + +`func (o *AdditionalPropertiesClass) HasMapMapAnytype() bool` + +HasMapMapAnytype returns a boolean if a field has been set. + +### SetMapMapAnytype + +`func (o *AdditionalPropertiesClass) SetMapMapAnytype(v map[string]map[string]map[string]interface{})` + +SetMapMapAnytype gets a reference to the given map[string]map[string]map[string]interface{} and assigns it to the MapMapAnytype field. + +### GetAnytype1 + +`func (o *AdditionalPropertiesClass) GetAnytype1() map[string]interface{}` + +GetAnytype1 returns the Anytype1 field if non-nil, zero value otherwise. + +### GetAnytype1Ok + +`func (o *AdditionalPropertiesClass) GetAnytype1Ok() (map[string]interface{}, bool)` + +GetAnytype1Ok returns a tuple with the Anytype1 field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAnytype1 + +`func (o *AdditionalPropertiesClass) HasAnytype1() bool` + +HasAnytype1 returns a boolean if a field has been set. + +### SetAnytype1 + +`func (o *AdditionalPropertiesClass) SetAnytype1(v map[string]interface{})` + +SetAnytype1 gets a reference to the given map[string]interface{} and assigns it to the Anytype1 field. + +### GetAnytype2 + +`func (o *AdditionalPropertiesClass) GetAnytype2() map[string]interface{}` + +GetAnytype2 returns the Anytype2 field if non-nil, zero value otherwise. + +### GetAnytype2Ok + +`func (o *AdditionalPropertiesClass) GetAnytype2Ok() (map[string]interface{}, bool)` + +GetAnytype2Ok returns a tuple with the Anytype2 field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAnytype2 + +`func (o *AdditionalPropertiesClass) HasAnytype2() bool` + +HasAnytype2 returns a boolean if a field has been set. + +### SetAnytype2 + +`func (o *AdditionalPropertiesClass) SetAnytype2(v map[string]interface{})` + +SetAnytype2 gets a reference to the given map[string]interface{} and assigns it to the Anytype2 field. + +### GetAnytype3 + +`func (o *AdditionalPropertiesClass) GetAnytype3() map[string]interface{}` + +GetAnytype3 returns the Anytype3 field if non-nil, zero value otherwise. + +### GetAnytype3Ok + +`func (o *AdditionalPropertiesClass) GetAnytype3Ok() (map[string]interface{}, bool)` + +GetAnytype3Ok returns a tuple with the Anytype3 field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAnytype3 + +`func (o *AdditionalPropertiesClass) HasAnytype3() bool` + +HasAnytype3 returns a boolean if a field has been set. + +### SetAnytype3 + +`func (o *AdditionalPropertiesClass) SetAnytype3(v map[string]interface{})` + +SetAnytype3 gets a reference to the given map[string]interface{} and assigns it to the Anytype3 field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesInteger.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesInteger.md index 34e6fca8fb..5db6d8671d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesInteger.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesInteger.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesInteger) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesInteger) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesInteger) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesInteger) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesNumber.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesNumber.md index 6d41fd2315..585ee57005 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesNumber.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesNumber.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesNumber) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesNumber) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesNumber) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesNumber) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesObject.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesObject.md index b856de693b..d71afb4943 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesObject.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesObject.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesObject) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesObject) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesObject) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesObject) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesString.md b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesString.md index 69ad206568..72bbc5d7fd 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesString.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/AdditionalPropertiesString.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **string** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *AdditionalPropertiesString) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *AdditionalPropertiesString) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *AdditionalPropertiesString) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *AdditionalPropertiesString) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Animal.md b/samples/client/petstore/go-experimental/go-petstore/docs/Animal.md index 02d23377da..55133b2974 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Animal.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Animal.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ClassName** | **string** | | -**Color** | **string** | | [optional] [default to red] +**ClassName** | Pointer to **string** | | +**Color** | Pointer to **string** | | [optional] [default to red] + +## Methods + +### GetClassName + +`func (o *Animal) GetClassName() string` + +GetClassName returns the ClassName field if non-nil, zero value otherwise. + +### GetClassNameOk + +`func (o *Animal) GetClassNameOk() (string, bool)` + +GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClassName + +`func (o *Animal) HasClassName() bool` + +HasClassName returns a boolean if a field has been set. + +### SetClassName + +`func (o *Animal) SetClassName(v string)` + +SetClassName gets a reference to the given string and assigns it to the ClassName field. + +### GetColor + +`func (o *Animal) GetColor() string` + +GetColor returns the Color field if non-nil, zero value otherwise. + +### GetColorOk + +`func (o *Animal) GetColorOk() (string, bool)` + +GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasColor + +`func (o *Animal) HasColor() bool` + +HasColor returns a boolean if a field has been set. + +### SetColor + +`func (o *Animal) SetColor(v string)` + +SetColor gets a reference to the given string and assigns it to the Color field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ApiResponse.md b/samples/client/petstore/go-experimental/go-petstore/docs/ApiResponse.md index 41d28fb578..3dd402a331 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ApiResponse.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ApiResponse.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Code** | **int32** | | [optional] -**Type** | **string** | | [optional] -**Message** | **string** | | [optional] +**Code** | Pointer to **int32** | | [optional] +**Type** | Pointer to **string** | | [optional] +**Message** | Pointer to **string** | | [optional] + +## Methods + +### GetCode + +`func (o *ApiResponse) GetCode() int32` + +GetCode returns the Code field if non-nil, zero value otherwise. + +### GetCodeOk + +`func (o *ApiResponse) GetCodeOk() (int32, bool)` + +GetCodeOk returns a tuple with the Code field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasCode + +`func (o *ApiResponse) HasCode() bool` + +HasCode returns a boolean if a field has been set. + +### SetCode + +`func (o *ApiResponse) SetCode(v int32)` + +SetCode gets a reference to the given int32 and assigns it to the Code field. + +### GetType + +`func (o *ApiResponse) GetType() string` + +GetType returns the Type field if non-nil, zero value otherwise. + +### GetTypeOk + +`func (o *ApiResponse) GetTypeOk() (string, bool)` + +GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasType + +`func (o *ApiResponse) HasType() bool` + +HasType returns a boolean if a field has been set. + +### SetType + +`func (o *ApiResponse) SetType(v string)` + +SetType gets a reference to the given string and assigns it to the Type field. + +### GetMessage + +`func (o *ApiResponse) GetMessage() string` + +GetMessage returns the Message field if non-nil, zero value otherwise. + +### GetMessageOk + +`func (o *ApiResponse) GetMessageOk() (string, bool)` + +GetMessageOk returns a tuple with the Message field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMessage + +`func (o *ApiResponse) HasMessage() bool` + +HasMessage returns a boolean if a field has been set. + +### SetMessage + +`func (o *ApiResponse) SetMessage(v string)` + +SetMessage gets a reference to the given string and assigns it to the Message field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfArrayOfNumberOnly.md b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfArrayOfNumberOnly.md index 555213013b..6e776c78ba 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfArrayOfNumberOnly.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfArrayOfNumberOnly.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ArrayArrayNumber** | [**[][]float32**](array.md) | | [optional] +**ArrayArrayNumber** | Pointer to [**[][]float32**](array.md) | | [optional] + +## Methods + +### GetArrayArrayNumber + +`func (o *ArrayOfArrayOfNumberOnly) GetArrayArrayNumber() [][]float32` + +GetArrayArrayNumber returns the ArrayArrayNumber field if non-nil, zero value otherwise. + +### GetArrayArrayNumberOk + +`func (o *ArrayOfArrayOfNumberOnly) GetArrayArrayNumberOk() ([][]float32, bool)` + +GetArrayArrayNumberOk returns a tuple with the ArrayArrayNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayArrayNumber + +`func (o *ArrayOfArrayOfNumberOnly) HasArrayArrayNumber() bool` + +HasArrayArrayNumber returns a boolean if a field has been set. + +### SetArrayArrayNumber + +`func (o *ArrayOfArrayOfNumberOnly) SetArrayArrayNumber(v [][]float32)` + +SetArrayArrayNumber gets a reference to the given [][]float32 and assigns it to the ArrayArrayNumber field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfNumberOnly.md b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfNumberOnly.md index 56618756dd..af74787e38 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfNumberOnly.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayOfNumberOnly.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ArrayNumber** | **[]float32** | | [optional] +**ArrayNumber** | Pointer to **[]float32** | | [optional] + +## Methods + +### GetArrayNumber + +`func (o *ArrayOfNumberOnly) GetArrayNumber() []float32` + +GetArrayNumber returns the ArrayNumber field if non-nil, zero value otherwise. + +### GetArrayNumberOk + +`func (o *ArrayOfNumberOnly) GetArrayNumberOk() ([]float32, bool)` + +GetArrayNumberOk returns a tuple with the ArrayNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayNumber + +`func (o *ArrayOfNumberOnly) HasArrayNumber() bool` + +HasArrayNumber returns a boolean if a field has been set. + +### SetArrayNumber + +`func (o *ArrayOfNumberOnly) SetArrayNumber(v []float32)` + +SetArrayNumber gets a reference to the given []float32 and assigns it to the ArrayNumber field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayTest.md b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayTest.md index 0da0bc52d2..7c25df85ff 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ArrayTest.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ArrayTest.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ArrayOfString** | **[]string** | | [optional] -**ArrayArrayOfInteger** | [**[][]int64**](array.md) | | [optional] -**ArrayArrayOfModel** | [**[][]ReadOnlyFirst**](array.md) | | [optional] +**ArrayOfString** | Pointer to **[]string** | | [optional] +**ArrayArrayOfInteger** | Pointer to [**[][]int64**](array.md) | | [optional] +**ArrayArrayOfModel** | Pointer to [**[][]ReadOnlyFirst**](array.md) | | [optional] + +## Methods + +### GetArrayOfString + +`func (o *ArrayTest) GetArrayOfString() []string` + +GetArrayOfString returns the ArrayOfString field if non-nil, zero value otherwise. + +### GetArrayOfStringOk + +`func (o *ArrayTest) GetArrayOfStringOk() ([]string, bool)` + +GetArrayOfStringOk returns a tuple with the ArrayOfString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayOfString + +`func (o *ArrayTest) HasArrayOfString() bool` + +HasArrayOfString returns a boolean if a field has been set. + +### SetArrayOfString + +`func (o *ArrayTest) SetArrayOfString(v []string)` + +SetArrayOfString gets a reference to the given []string and assigns it to the ArrayOfString field. + +### GetArrayArrayOfInteger + +`func (o *ArrayTest) GetArrayArrayOfInteger() [][]int64` + +GetArrayArrayOfInteger returns the ArrayArrayOfInteger field if non-nil, zero value otherwise. + +### GetArrayArrayOfIntegerOk + +`func (o *ArrayTest) GetArrayArrayOfIntegerOk() ([][]int64, bool)` + +GetArrayArrayOfIntegerOk returns a tuple with the ArrayArrayOfInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayArrayOfInteger + +`func (o *ArrayTest) HasArrayArrayOfInteger() bool` + +HasArrayArrayOfInteger returns a boolean if a field has been set. + +### SetArrayArrayOfInteger + +`func (o *ArrayTest) SetArrayArrayOfInteger(v [][]int64)` + +SetArrayArrayOfInteger gets a reference to the given [][]int64 and assigns it to the ArrayArrayOfInteger field. + +### GetArrayArrayOfModel + +`func (o *ArrayTest) GetArrayArrayOfModel() [][]ReadOnlyFirst` + +GetArrayArrayOfModel returns the ArrayArrayOfModel field if non-nil, zero value otherwise. + +### GetArrayArrayOfModelOk + +`func (o *ArrayTest) GetArrayArrayOfModelOk() ([][]ReadOnlyFirst, bool)` + +GetArrayArrayOfModelOk returns a tuple with the ArrayArrayOfModel field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayArrayOfModel + +`func (o *ArrayTest) HasArrayArrayOfModel() bool` + +HasArrayArrayOfModel returns a boolean if a field has been set. + +### SetArrayArrayOfModel + +`func (o *ArrayTest) SetArrayArrayOfModel(v [][]ReadOnlyFirst)` + +SetArrayArrayOfModel gets a reference to the given [][]ReadOnlyFirst and assigns it to the ArrayArrayOfModel field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Capitalization.md b/samples/client/petstore/go-experimental/go-petstore/docs/Capitalization.md index 426b8eabd9..fd856f743e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Capitalization.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Capitalization.md @@ -4,12 +4,165 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**SmallCamel** | **string** | | [optional] -**CapitalCamel** | **string** | | [optional] -**SmallSnake** | **string** | | [optional] -**CapitalSnake** | **string** | | [optional] -**SCAETHFlowPoints** | **string** | | [optional] -**ATT_NAME** | **string** | Name of the pet | [optional] +**SmallCamel** | Pointer to **string** | | [optional] +**CapitalCamel** | Pointer to **string** | | [optional] +**SmallSnake** | Pointer to **string** | | [optional] +**CapitalSnake** | Pointer to **string** | | [optional] +**SCAETHFlowPoints** | Pointer to **string** | | [optional] +**ATT_NAME** | Pointer to **string** | Name of the pet | [optional] + +## Methods + +### GetSmallCamel + +`func (o *Capitalization) GetSmallCamel() string` + +GetSmallCamel returns the SmallCamel field if non-nil, zero value otherwise. + +### GetSmallCamelOk + +`func (o *Capitalization) GetSmallCamelOk() (string, bool)` + +GetSmallCamelOk returns a tuple with the SmallCamel field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSmallCamel + +`func (o *Capitalization) HasSmallCamel() bool` + +HasSmallCamel returns a boolean if a field has been set. + +### SetSmallCamel + +`func (o *Capitalization) SetSmallCamel(v string)` + +SetSmallCamel gets a reference to the given string and assigns it to the SmallCamel field. + +### GetCapitalCamel + +`func (o *Capitalization) GetCapitalCamel() string` + +GetCapitalCamel returns the CapitalCamel field if non-nil, zero value otherwise. + +### GetCapitalCamelOk + +`func (o *Capitalization) GetCapitalCamelOk() (string, bool)` + +GetCapitalCamelOk returns a tuple with the CapitalCamel field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasCapitalCamel + +`func (o *Capitalization) HasCapitalCamel() bool` + +HasCapitalCamel returns a boolean if a field has been set. + +### SetCapitalCamel + +`func (o *Capitalization) SetCapitalCamel(v string)` + +SetCapitalCamel gets a reference to the given string and assigns it to the CapitalCamel field. + +### GetSmallSnake + +`func (o *Capitalization) GetSmallSnake() string` + +GetSmallSnake returns the SmallSnake field if non-nil, zero value otherwise. + +### GetSmallSnakeOk + +`func (o *Capitalization) GetSmallSnakeOk() (string, bool)` + +GetSmallSnakeOk returns a tuple with the SmallSnake field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSmallSnake + +`func (o *Capitalization) HasSmallSnake() bool` + +HasSmallSnake returns a boolean if a field has been set. + +### SetSmallSnake + +`func (o *Capitalization) SetSmallSnake(v string)` + +SetSmallSnake gets a reference to the given string and assigns it to the SmallSnake field. + +### GetCapitalSnake + +`func (o *Capitalization) GetCapitalSnake() string` + +GetCapitalSnake returns the CapitalSnake field if non-nil, zero value otherwise. + +### GetCapitalSnakeOk + +`func (o *Capitalization) GetCapitalSnakeOk() (string, bool)` + +GetCapitalSnakeOk returns a tuple with the CapitalSnake field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasCapitalSnake + +`func (o *Capitalization) HasCapitalSnake() bool` + +HasCapitalSnake returns a boolean if a field has been set. + +### SetCapitalSnake + +`func (o *Capitalization) SetCapitalSnake(v string)` + +SetCapitalSnake gets a reference to the given string and assigns it to the CapitalSnake field. + +### GetSCAETHFlowPoints + +`func (o *Capitalization) GetSCAETHFlowPoints() string` + +GetSCAETHFlowPoints returns the SCAETHFlowPoints field if non-nil, zero value otherwise. + +### GetSCAETHFlowPointsOk + +`func (o *Capitalization) GetSCAETHFlowPointsOk() (string, bool)` + +GetSCAETHFlowPointsOk returns a tuple with the SCAETHFlowPoints field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSCAETHFlowPoints + +`func (o *Capitalization) HasSCAETHFlowPoints() bool` + +HasSCAETHFlowPoints returns a boolean if a field has been set. + +### SetSCAETHFlowPoints + +`func (o *Capitalization) SetSCAETHFlowPoints(v string)` + +SetSCAETHFlowPoints gets a reference to the given string and assigns it to the SCAETHFlowPoints field. + +### GetATT_NAME + +`func (o *Capitalization) GetATT_NAME() string` + +GetATT_NAME returns the ATT_NAME field if non-nil, zero value otherwise. + +### GetATT_NAMEOk + +`func (o *Capitalization) GetATT_NAMEOk() (string, bool)` + +GetATT_NAMEOk returns a tuple with the ATT_NAME field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasATT_NAME + +`func (o *Capitalization) HasATT_NAME() bool` + +HasATT_NAME returns a boolean if a field has been set. + +### SetATT_NAME + +`func (o *Capitalization) SetATT_NAME(v string)` + +SetATT_NAME gets a reference to the given string and assigns it to the ATT_NAME field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Cat.md b/samples/client/petstore/go-experimental/go-petstore/docs/Cat.md index 1ef1f095e9..262e3d04f6 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Cat.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Cat.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ClassName** | **string** | | -**Color** | **string** | | [optional] [default to red] -**Declawed** | **bool** | | [optional] +**ClassName** | Pointer to **string** | | +**Color** | Pointer to **string** | | [optional] [default to red] +**Declawed** | Pointer to **bool** | | [optional] + +## Methods + +### GetClassName + +`func (o *Cat) GetClassName() string` + +GetClassName returns the ClassName field if non-nil, zero value otherwise. + +### GetClassNameOk + +`func (o *Cat) GetClassNameOk() (string, bool)` + +GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClassName + +`func (o *Cat) HasClassName() bool` + +HasClassName returns a boolean if a field has been set. + +### SetClassName + +`func (o *Cat) SetClassName(v string)` + +SetClassName gets a reference to the given string and assigns it to the ClassName field. + +### GetColor + +`func (o *Cat) GetColor() string` + +GetColor returns the Color field if non-nil, zero value otherwise. + +### GetColorOk + +`func (o *Cat) GetColorOk() (string, bool)` + +GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasColor + +`func (o *Cat) HasColor() bool` + +HasColor returns a boolean if a field has been set. + +### SetColor + +`func (o *Cat) SetColor(v string)` + +SetColor gets a reference to the given string and assigns it to the Color field. + +### GetDeclawed + +`func (o *Cat) GetDeclawed() bool` + +GetDeclawed returns the Declawed field if non-nil, zero value otherwise. + +### GetDeclawedOk + +`func (o *Cat) GetDeclawedOk() (bool, bool)` + +GetDeclawedOk returns a tuple with the Declawed field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDeclawed + +`func (o *Cat) HasDeclawed() bool` + +HasDeclawed returns a boolean if a field has been set. + +### SetDeclawed + +`func (o *Cat) SetDeclawed(v bool)` + +SetDeclawed gets a reference to the given bool and assigns it to the Declawed field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/CatAllOf.md b/samples/client/petstore/go-experimental/go-petstore/docs/CatAllOf.md index c978cee041..a89f0b29fa 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/CatAllOf.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/CatAllOf.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Declawed** | **bool** | | [optional] +**Declawed** | Pointer to **bool** | | [optional] + +## Methods + +### GetDeclawed + +`func (o *CatAllOf) GetDeclawed() bool` + +GetDeclawed returns the Declawed field if non-nil, zero value otherwise. + +### GetDeclawedOk + +`func (o *CatAllOf) GetDeclawedOk() (bool, bool)` + +GetDeclawedOk returns a tuple with the Declawed field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDeclawed + +`func (o *CatAllOf) HasDeclawed() bool` + +HasDeclawed returns a boolean if a field has been set. + +### SetDeclawed + +`func (o *CatAllOf) SetDeclawed(v bool)` + +SetDeclawed gets a reference to the given bool and assigns it to the Declawed field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Category.md b/samples/client/petstore/go-experimental/go-petstore/docs/Category.md index 01e8344bd0..b8ef18163b 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Category.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Category.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **int64** | | [optional] -**Name** | **string** | | [default to default-name] +**Id** | Pointer to **int64** | | [optional] +**Name** | Pointer to **string** | | [default to default-name] + +## Methods + +### GetId + +`func (o *Category) GetId() int64` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Category) GetIdOk() (int64, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasId + +`func (o *Category) HasId() bool` + +HasId returns a boolean if a field has been set. + +### SetId + +`func (o *Category) SetId(v int64)` + +SetId gets a reference to the given int64 and assigns it to the Id field. + +### GetName + +`func (o *Category) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Category) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *Category) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *Category) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ClassModel.md b/samples/client/petstore/go-experimental/go-petstore/docs/ClassModel.md index 0b925cebb1..9ceae1f3d0 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ClassModel.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ClassModel.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Class** | **string** | | [optional] +**Class** | Pointer to **string** | | [optional] + +## Methods + +### GetClass + +`func (o *ClassModel) GetClass() string` + +GetClass returns the Class field if non-nil, zero value otherwise. + +### GetClassOk + +`func (o *ClassModel) GetClassOk() (string, bool)` + +GetClassOk returns a tuple with the Class field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClass + +`func (o *ClassModel) HasClass() bool` + +HasClass returns a boolean if a field has been set. + +### SetClass + +`func (o *ClassModel) SetClass(v string)` + +SetClass gets a reference to the given string and assigns it to the Class field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Client.md b/samples/client/petstore/go-experimental/go-petstore/docs/Client.md index 551da852ee..9787127b16 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Client.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Client.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Client** | **string** | | [optional] +**Client** | Pointer to **string** | | [optional] + +## Methods + +### GetClient + +`func (o *Client) GetClient() string` + +GetClient returns the Client field if non-nil, zero value otherwise. + +### GetClientOk + +`func (o *Client) GetClientOk() (string, bool)` + +GetClientOk returns a tuple with the Client field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClient + +`func (o *Client) HasClient() bool` + +HasClient returns a boolean if a field has been set. + +### SetClient + +`func (o *Client) SetClient(v string)` + +SetClient gets a reference to the given string and assigns it to the Client field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Dog.md b/samples/client/petstore/go-experimental/go-petstore/docs/Dog.md index ff35dd5cdc..591ab03c6a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Dog.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Dog.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**ClassName** | **string** | | -**Color** | **string** | | [optional] [default to red] -**Breed** | **string** | | [optional] +**ClassName** | Pointer to **string** | | +**Color** | Pointer to **string** | | [optional] [default to red] +**Breed** | Pointer to **string** | | [optional] + +## Methods + +### GetClassName + +`func (o *Dog) GetClassName() string` + +GetClassName returns the ClassName field if non-nil, zero value otherwise. + +### GetClassNameOk + +`func (o *Dog) GetClassNameOk() (string, bool)` + +GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClassName + +`func (o *Dog) HasClassName() bool` + +HasClassName returns a boolean if a field has been set. + +### SetClassName + +`func (o *Dog) SetClassName(v string)` + +SetClassName gets a reference to the given string and assigns it to the ClassName field. + +### GetColor + +`func (o *Dog) GetColor() string` + +GetColor returns the Color field if non-nil, zero value otherwise. + +### GetColorOk + +`func (o *Dog) GetColorOk() (string, bool)` + +GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasColor + +`func (o *Dog) HasColor() bool` + +HasColor returns a boolean if a field has been set. + +### SetColor + +`func (o *Dog) SetColor(v string)` + +SetColor gets a reference to the given string and assigns it to the Color field. + +### GetBreed + +`func (o *Dog) GetBreed() string` + +GetBreed returns the Breed field if non-nil, zero value otherwise. + +### GetBreedOk + +`func (o *Dog) GetBreedOk() (string, bool)` + +GetBreedOk returns a tuple with the Breed field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBreed + +`func (o *Dog) HasBreed() bool` + +HasBreed returns a boolean if a field has been set. + +### SetBreed + +`func (o *Dog) SetBreed(v string)` + +SetBreed gets a reference to the given string and assigns it to the Breed field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/DogAllOf.md b/samples/client/petstore/go-experimental/go-petstore/docs/DogAllOf.md index b87153e926..e5103c4975 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/DogAllOf.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/DogAllOf.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Breed** | **string** | | [optional] +**Breed** | Pointer to **string** | | [optional] + +## Methods + +### GetBreed + +`func (o *DogAllOf) GetBreed() string` + +GetBreed returns the Breed field if non-nil, zero value otherwise. + +### GetBreedOk + +`func (o *DogAllOf) GetBreedOk() (string, bool)` + +GetBreedOk returns a tuple with the Breed field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBreed + +`func (o *DogAllOf) HasBreed() bool` + +HasBreed returns a boolean if a field has been set. + +### SetBreed + +`func (o *DogAllOf) SetBreed(v string)` + +SetBreed gets a reference to the given string and assigns it to the Breed field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/EnumArrays.md b/samples/client/petstore/go-experimental/go-petstore/docs/EnumArrays.md index 3021f88183..6d6028e966 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/EnumArrays.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/EnumArrays.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**JustSymbol** | **string** | | [optional] -**ArrayEnum** | **[]string** | | [optional] +**JustSymbol** | Pointer to **string** | | [optional] +**ArrayEnum** | Pointer to **[]string** | | [optional] + +## Methods + +### GetJustSymbol + +`func (o *EnumArrays) GetJustSymbol() string` + +GetJustSymbol returns the JustSymbol field if non-nil, zero value otherwise. + +### GetJustSymbolOk + +`func (o *EnumArrays) GetJustSymbolOk() (string, bool)` + +GetJustSymbolOk returns a tuple with the JustSymbol field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasJustSymbol + +`func (o *EnumArrays) HasJustSymbol() bool` + +HasJustSymbol returns a boolean if a field has been set. + +### SetJustSymbol + +`func (o *EnumArrays) SetJustSymbol(v string)` + +SetJustSymbol gets a reference to the given string and assigns it to the JustSymbol field. + +### GetArrayEnum + +`func (o *EnumArrays) GetArrayEnum() []string` + +GetArrayEnum returns the ArrayEnum field if non-nil, zero value otherwise. + +### GetArrayEnumOk + +`func (o *EnumArrays) GetArrayEnumOk() ([]string, bool)` + +GetArrayEnumOk returns a tuple with the ArrayEnum field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayEnum + +`func (o *EnumArrays) HasArrayEnum() bool` + +HasArrayEnum returns a boolean if a field has been set. + +### SetArrayEnum + +`func (o *EnumArrays) SetArrayEnum(v []string)` + +SetArrayEnum gets a reference to the given []string and assigns it to the ArrayEnum field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/EnumClass.md b/samples/client/petstore/go-experimental/go-petstore/docs/EnumClass.md index c6932388c0..e231f94bd7 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/EnumClass.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/EnumClass.md @@ -5,6 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/EnumTest.md b/samples/client/petstore/go-experimental/go-petstore/docs/EnumTest.md index eeec09b66b..f396e0e32a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/EnumTest.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/EnumTest.md @@ -4,11 +4,139 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**EnumString** | **string** | | [optional] -**EnumStringRequired** | **string** | | -**EnumInteger** | **int32** | | [optional] -**EnumNumber** | **float64** | | [optional] -**OuterEnum** | [**OuterEnum**](OuterEnum.md) | | [optional] +**EnumString** | Pointer to **string** | | [optional] +**EnumStringRequired** | Pointer to **string** | | +**EnumInteger** | Pointer to **int32** | | [optional] +**EnumNumber** | Pointer to **float64** | | [optional] +**OuterEnum** | Pointer to [**OuterEnum**](OuterEnum.md) | | [optional] + +## Methods + +### GetEnumString + +`func (o *EnumTest) GetEnumString() string` + +GetEnumString returns the EnumString field if non-nil, zero value otherwise. + +### GetEnumStringOk + +`func (o *EnumTest) GetEnumStringOk() (string, bool)` + +GetEnumStringOk returns a tuple with the EnumString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasEnumString + +`func (o *EnumTest) HasEnumString() bool` + +HasEnumString returns a boolean if a field has been set. + +### SetEnumString + +`func (o *EnumTest) SetEnumString(v string)` + +SetEnumString gets a reference to the given string and assigns it to the EnumString field. + +### GetEnumStringRequired + +`func (o *EnumTest) GetEnumStringRequired() string` + +GetEnumStringRequired returns the EnumStringRequired field if non-nil, zero value otherwise. + +### GetEnumStringRequiredOk + +`func (o *EnumTest) GetEnumStringRequiredOk() (string, bool)` + +GetEnumStringRequiredOk returns a tuple with the EnumStringRequired field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasEnumStringRequired + +`func (o *EnumTest) HasEnumStringRequired() bool` + +HasEnumStringRequired returns a boolean if a field has been set. + +### SetEnumStringRequired + +`func (o *EnumTest) SetEnumStringRequired(v string)` + +SetEnumStringRequired gets a reference to the given string and assigns it to the EnumStringRequired field. + +### GetEnumInteger + +`func (o *EnumTest) GetEnumInteger() int32` + +GetEnumInteger returns the EnumInteger field if non-nil, zero value otherwise. + +### GetEnumIntegerOk + +`func (o *EnumTest) GetEnumIntegerOk() (int32, bool)` + +GetEnumIntegerOk returns a tuple with the EnumInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasEnumInteger + +`func (o *EnumTest) HasEnumInteger() bool` + +HasEnumInteger returns a boolean if a field has been set. + +### SetEnumInteger + +`func (o *EnumTest) SetEnumInteger(v int32)` + +SetEnumInteger gets a reference to the given int32 and assigns it to the EnumInteger field. + +### GetEnumNumber + +`func (o *EnumTest) GetEnumNumber() float64` + +GetEnumNumber returns the EnumNumber field if non-nil, zero value otherwise. + +### GetEnumNumberOk + +`func (o *EnumTest) GetEnumNumberOk() (float64, bool)` + +GetEnumNumberOk returns a tuple with the EnumNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasEnumNumber + +`func (o *EnumTest) HasEnumNumber() bool` + +HasEnumNumber returns a boolean if a field has been set. + +### SetEnumNumber + +`func (o *EnumTest) SetEnumNumber(v float64)` + +SetEnumNumber gets a reference to the given float64 and assigns it to the EnumNumber field. + +### GetOuterEnum + +`func (o *EnumTest) GetOuterEnum() OuterEnum` + +GetOuterEnum returns the OuterEnum field if non-nil, zero value otherwise. + +### GetOuterEnumOk + +`func (o *EnumTest) GetOuterEnumOk() (OuterEnum, bool)` + +GetOuterEnumOk returns a tuple with the OuterEnum field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasOuterEnum + +`func (o *EnumTest) HasOuterEnum() bool` + +HasOuterEnum returns a boolean if a field has been set. + +### SetOuterEnum + +`func (o *EnumTest) SetOuterEnum(v OuterEnum)` + +SetOuterEnum gets a reference to the given OuterEnum and assigns it to the OuterEnum field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/File.md b/samples/client/petstore/go-experimental/go-petstore/docs/File.md index a113b0312c..07d269cd88 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/File.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/File.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**SourceURI** | **string** | Test capitalization | [optional] +**SourceURI** | Pointer to **string** | Test capitalization | [optional] + +## Methods + +### GetSourceURI + +`func (o *File) GetSourceURI() string` + +GetSourceURI returns the SourceURI field if non-nil, zero value otherwise. + +### GetSourceURIOk + +`func (o *File) GetSourceURIOk() (string, bool)` + +GetSourceURIOk returns a tuple with the SourceURI field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSourceURI + +`func (o *File) HasSourceURI() bool` + +HasSourceURI returns a boolean if a field has been set. + +### SetSourceURI + +`func (o *File) SetSourceURI(v string)` + +SetSourceURI gets a reference to the given string and assigns it to the SourceURI field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/FileSchemaTestClass.md b/samples/client/petstore/go-experimental/go-petstore/docs/FileSchemaTestClass.md index ae51414dd6..4a12b7f6d5 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/FileSchemaTestClass.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/FileSchemaTestClass.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**File** | [**File**](File.md) | | [optional] -**Files** | [**[]File**](File.md) | | [optional] +**File** | Pointer to [**File**](File.md) | | [optional] +**Files** | Pointer to [**[]File**](File.md) | | [optional] + +## Methods + +### GetFile + +`func (o *FileSchemaTestClass) GetFile() File` + +GetFile returns the File field if non-nil, zero value otherwise. + +### GetFileOk + +`func (o *FileSchemaTestClass) GetFileOk() (File, bool)` + +GetFileOk returns a tuple with the File field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasFile + +`func (o *FileSchemaTestClass) HasFile() bool` + +HasFile returns a boolean if a field has been set. + +### SetFile + +`func (o *FileSchemaTestClass) SetFile(v File)` + +SetFile gets a reference to the given File and assigns it to the File field. + +### GetFiles + +`func (o *FileSchemaTestClass) GetFiles() []File` + +GetFiles returns the Files field if non-nil, zero value otherwise. + +### GetFilesOk + +`func (o *FileSchemaTestClass) GetFilesOk() ([]File, bool)` + +GetFilesOk returns a tuple with the Files field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasFiles + +`func (o *FileSchemaTestClass) HasFiles() bool` + +HasFiles returns a boolean if a field has been set. + +### SetFiles + +`func (o *FileSchemaTestClass) SetFiles(v []File)` + +SetFiles gets a reference to the given []File and assigns it to the Files field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/FormatTest.md b/samples/client/petstore/go-experimental/go-petstore/docs/FormatTest.md index ee089a03cd..7b0c3d451c 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/FormatTest.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/FormatTest.md @@ -4,19 +4,347 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Integer** | **int32** | | [optional] -**Int32** | **int32** | | [optional] -**Int64** | **int64** | | [optional] -**Number** | **float32** | | -**Float** | **float32** | | [optional] -**Double** | **float64** | | [optional] -**String** | **string** | | [optional] -**Byte** | **string** | | -**Binary** | [***os.File**](*os.File.md) | | [optional] -**Date** | **string** | | -**DateTime** | [**time.Time**](time.Time.md) | | [optional] -**Uuid** | **string** | | [optional] -**Password** | **string** | | +**Integer** | Pointer to **int32** | | [optional] +**Int32** | Pointer to **int32** | | [optional] +**Int64** | Pointer to **int64** | | [optional] +**Number** | Pointer to **float32** | | +**Float** | Pointer to **float32** | | [optional] +**Double** | Pointer to **float64** | | [optional] +**String** | Pointer to **string** | | [optional] +**Byte** | Pointer to **string** | | +**Binary** | Pointer to [***os.File**](*os.File.md) | | [optional] +**Date** | Pointer to **string** | | +**DateTime** | Pointer to [**time.Time**](time.Time.md) | | [optional] +**Uuid** | Pointer to **string** | | [optional] +**Password** | Pointer to **string** | | + +## Methods + +### GetInteger + +`func (o *FormatTest) GetInteger() int32` + +GetInteger returns the Integer field if non-nil, zero value otherwise. + +### GetIntegerOk + +`func (o *FormatTest) GetIntegerOk() (int32, bool)` + +GetIntegerOk returns a tuple with the Integer field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasInteger + +`func (o *FormatTest) HasInteger() bool` + +HasInteger returns a boolean if a field has been set. + +### SetInteger + +`func (o *FormatTest) SetInteger(v int32)` + +SetInteger gets a reference to the given int32 and assigns it to the Integer field. + +### GetInt32 + +`func (o *FormatTest) GetInt32() int32` + +GetInt32 returns the Int32 field if non-nil, zero value otherwise. + +### GetInt32Ok + +`func (o *FormatTest) GetInt32Ok() (int32, bool)` + +GetInt32Ok returns a tuple with the Int32 field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasInt32 + +`func (o *FormatTest) HasInt32() bool` + +HasInt32 returns a boolean if a field has been set. + +### SetInt32 + +`func (o *FormatTest) SetInt32(v int32)` + +SetInt32 gets a reference to the given int32 and assigns it to the Int32 field. + +### GetInt64 + +`func (o *FormatTest) GetInt64() int64` + +GetInt64 returns the Int64 field if non-nil, zero value otherwise. + +### GetInt64Ok + +`func (o *FormatTest) GetInt64Ok() (int64, bool)` + +GetInt64Ok returns a tuple with the Int64 field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasInt64 + +`func (o *FormatTest) HasInt64() bool` + +HasInt64 returns a boolean if a field has been set. + +### SetInt64 + +`func (o *FormatTest) SetInt64(v int64)` + +SetInt64 gets a reference to the given int64 and assigns it to the Int64 field. + +### GetNumber + +`func (o *FormatTest) GetNumber() float32` + +GetNumber returns the Number field if non-nil, zero value otherwise. + +### GetNumberOk + +`func (o *FormatTest) GetNumberOk() (float32, bool)` + +GetNumberOk returns a tuple with the Number field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNumber + +`func (o *FormatTest) HasNumber() bool` + +HasNumber returns a boolean if a field has been set. + +### SetNumber + +`func (o *FormatTest) SetNumber(v float32)` + +SetNumber gets a reference to the given float32 and assigns it to the Number field. + +### GetFloat + +`func (o *FormatTest) GetFloat() float32` + +GetFloat returns the Float field if non-nil, zero value otherwise. + +### GetFloatOk + +`func (o *FormatTest) GetFloatOk() (float32, bool)` + +GetFloatOk returns a tuple with the Float field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasFloat + +`func (o *FormatTest) HasFloat() bool` + +HasFloat returns a boolean if a field has been set. + +### SetFloat + +`func (o *FormatTest) SetFloat(v float32)` + +SetFloat gets a reference to the given float32 and assigns it to the Float field. + +### GetDouble + +`func (o *FormatTest) GetDouble() float64` + +GetDouble returns the Double field if non-nil, zero value otherwise. + +### GetDoubleOk + +`func (o *FormatTest) GetDoubleOk() (float64, bool)` + +GetDoubleOk returns a tuple with the Double field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDouble + +`func (o *FormatTest) HasDouble() bool` + +HasDouble returns a boolean if a field has been set. + +### SetDouble + +`func (o *FormatTest) SetDouble(v float64)` + +SetDouble gets a reference to the given float64 and assigns it to the Double field. + +### GetString + +`func (o *FormatTest) GetString() string` + +GetString returns the String field if non-nil, zero value otherwise. + +### GetStringOk + +`func (o *FormatTest) GetStringOk() (string, bool)` + +GetStringOk returns a tuple with the String field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasString + +`func (o *FormatTest) HasString() bool` + +HasString returns a boolean if a field has been set. + +### SetString + +`func (o *FormatTest) SetString(v string)` + +SetString gets a reference to the given string and assigns it to the String field. + +### GetByte + +`func (o *FormatTest) GetByte() string` + +GetByte returns the Byte field if non-nil, zero value otherwise. + +### GetByteOk + +`func (o *FormatTest) GetByteOk() (string, bool)` + +GetByteOk returns a tuple with the Byte field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasByte + +`func (o *FormatTest) HasByte() bool` + +HasByte returns a boolean if a field has been set. + +### SetByte + +`func (o *FormatTest) SetByte(v string)` + +SetByte gets a reference to the given string and assigns it to the Byte field. + +### GetBinary + +`func (o *FormatTest) GetBinary() *os.File` + +GetBinary returns the Binary field if non-nil, zero value otherwise. + +### GetBinaryOk + +`func (o *FormatTest) GetBinaryOk() (*os.File, bool)` + +GetBinaryOk returns a tuple with the Binary field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBinary + +`func (o *FormatTest) HasBinary() bool` + +HasBinary returns a boolean if a field has been set. + +### SetBinary + +`func (o *FormatTest) SetBinary(v *os.File)` + +SetBinary gets a reference to the given *os.File and assigns it to the Binary field. + +### GetDate + +`func (o *FormatTest) GetDate() string` + +GetDate returns the Date field if non-nil, zero value otherwise. + +### GetDateOk + +`func (o *FormatTest) GetDateOk() (string, bool)` + +GetDateOk returns a tuple with the Date field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDate + +`func (o *FormatTest) HasDate() bool` + +HasDate returns a boolean if a field has been set. + +### SetDate + +`func (o *FormatTest) SetDate(v string)` + +SetDate gets a reference to the given string and assigns it to the Date field. + +### GetDateTime + +`func (o *FormatTest) GetDateTime() time.Time` + +GetDateTime returns the DateTime field if non-nil, zero value otherwise. + +### GetDateTimeOk + +`func (o *FormatTest) GetDateTimeOk() (time.Time, bool)` + +GetDateTimeOk returns a tuple with the DateTime field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDateTime + +`func (o *FormatTest) HasDateTime() bool` + +HasDateTime returns a boolean if a field has been set. + +### SetDateTime + +`func (o *FormatTest) SetDateTime(v time.Time)` + +SetDateTime gets a reference to the given time.Time and assigns it to the DateTime field. + +### GetUuid + +`func (o *FormatTest) GetUuid() string` + +GetUuid returns the Uuid field if non-nil, zero value otherwise. + +### GetUuidOk + +`func (o *FormatTest) GetUuidOk() (string, bool)` + +GetUuidOk returns a tuple with the Uuid field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasUuid + +`func (o *FormatTest) HasUuid() bool` + +HasUuid returns a boolean if a field has been set. + +### SetUuid + +`func (o *FormatTest) SetUuid(v string)` + +SetUuid gets a reference to the given string and assigns it to the Uuid field. + +### GetPassword + +`func (o *FormatTest) GetPassword() string` + +GetPassword returns the Password field if non-nil, zero value otherwise. + +### GetPasswordOk + +`func (o *FormatTest) GetPasswordOk() (string, bool)` + +GetPasswordOk returns a tuple with the Password field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPassword + +`func (o *FormatTest) HasPassword() bool` + +HasPassword returns a boolean if a field has been set. + +### SetPassword + +`func (o *FormatTest) SetPassword(v string)` + +SetPassword gets a reference to the given string and assigns it to the Password field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/HasOnlyReadOnly.md b/samples/client/petstore/go-experimental/go-petstore/docs/HasOnlyReadOnly.md index 9e2f495735..33cc010f3a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/HasOnlyReadOnly.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/HasOnlyReadOnly.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Bar** | **string** | | [optional] -**Foo** | **string** | | [optional] +**Bar** | Pointer to **string** | | [optional] +**Foo** | Pointer to **string** | | [optional] + +## Methods + +### GetBar + +`func (o *HasOnlyReadOnly) GetBar() string` + +GetBar returns the Bar field if non-nil, zero value otherwise. + +### GetBarOk + +`func (o *HasOnlyReadOnly) GetBarOk() (string, bool)` + +GetBarOk returns a tuple with the Bar field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBar + +`func (o *HasOnlyReadOnly) HasBar() bool` + +HasBar returns a boolean if a field has been set. + +### SetBar + +`func (o *HasOnlyReadOnly) SetBar(v string)` + +SetBar gets a reference to the given string and assigns it to the Bar field. + +### GetFoo + +`func (o *HasOnlyReadOnly) GetFoo() string` + +GetFoo returns the Foo field if non-nil, zero value otherwise. + +### GetFooOk + +`func (o *HasOnlyReadOnly) GetFooOk() (string, bool)` + +GetFooOk returns a tuple with the Foo field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasFoo + +`func (o *HasOnlyReadOnly) HasFoo() bool` + +HasFoo returns a boolean if a field has been set. + +### SetFoo + +`func (o *HasOnlyReadOnly) SetFoo(v string)` + +SetFoo gets a reference to the given string and assigns it to the Foo field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/List.md b/samples/client/petstore/go-experimental/go-petstore/docs/List.md index bba2e52990..53784dd47a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/List.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/List.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Var123List** | **string** | | [optional] +**Var123List** | Pointer to **string** | | [optional] + +## Methods + +### GetVar123List + +`func (o *List) GetVar123List() string` + +GetVar123List returns the Var123List field if non-nil, zero value otherwise. + +### GetVar123ListOk + +`func (o *List) GetVar123ListOk() (string, bool)` + +GetVar123ListOk returns a tuple with the Var123List field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasVar123List + +`func (o *List) HasVar123List() bool` + +HasVar123List returns a boolean if a field has been set. + +### SetVar123List + +`func (o *List) SetVar123List(v string)` + +SetVar123List gets a reference to the given string and assigns it to the Var123List field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/MapTest.md b/samples/client/petstore/go-experimental/go-petstore/docs/MapTest.md index 6645e04465..6994b17ec5 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/MapTest.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/MapTest.md @@ -4,10 +4,113 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional] -**MapOfEnumString** | **map[string]string** | | [optional] -**DirectMap** | **map[string]bool** | | [optional] -**IndirectMap** | **map[string]bool** | | [optional] +**MapMapOfString** | Pointer to [**map[string]map[string]string**](map.md) | | [optional] +**MapOfEnumString** | Pointer to **map[string]string** | | [optional] +**DirectMap** | Pointer to **map[string]bool** | | [optional] +**IndirectMap** | Pointer to **map[string]bool** | | [optional] + +## Methods + +### GetMapMapOfString + +`func (o *MapTest) GetMapMapOfString() map[string]map[string]string` + +GetMapMapOfString returns the MapMapOfString field if non-nil, zero value otherwise. + +### GetMapMapOfStringOk + +`func (o *MapTest) GetMapMapOfStringOk() (map[string]map[string]string, bool)` + +GetMapMapOfStringOk returns a tuple with the MapMapOfString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapMapOfString + +`func (o *MapTest) HasMapMapOfString() bool` + +HasMapMapOfString returns a boolean if a field has been set. + +### SetMapMapOfString + +`func (o *MapTest) SetMapMapOfString(v map[string]map[string]string)` + +SetMapMapOfString gets a reference to the given map[string]map[string]string and assigns it to the MapMapOfString field. + +### GetMapOfEnumString + +`func (o *MapTest) GetMapOfEnumString() map[string]string` + +GetMapOfEnumString returns the MapOfEnumString field if non-nil, zero value otherwise. + +### GetMapOfEnumStringOk + +`func (o *MapTest) GetMapOfEnumStringOk() (map[string]string, bool)` + +GetMapOfEnumStringOk returns a tuple with the MapOfEnumString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMapOfEnumString + +`func (o *MapTest) HasMapOfEnumString() bool` + +HasMapOfEnumString returns a boolean if a field has been set. + +### SetMapOfEnumString + +`func (o *MapTest) SetMapOfEnumString(v map[string]string)` + +SetMapOfEnumString gets a reference to the given map[string]string and assigns it to the MapOfEnumString field. + +### GetDirectMap + +`func (o *MapTest) GetDirectMap() map[string]bool` + +GetDirectMap returns the DirectMap field if non-nil, zero value otherwise. + +### GetDirectMapOk + +`func (o *MapTest) GetDirectMapOk() (map[string]bool, bool)` + +GetDirectMapOk returns a tuple with the DirectMap field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDirectMap + +`func (o *MapTest) HasDirectMap() bool` + +HasDirectMap returns a boolean if a field has been set. + +### SetDirectMap + +`func (o *MapTest) SetDirectMap(v map[string]bool)` + +SetDirectMap gets a reference to the given map[string]bool and assigns it to the DirectMap field. + +### GetIndirectMap + +`func (o *MapTest) GetIndirectMap() map[string]bool` + +GetIndirectMap returns the IndirectMap field if non-nil, zero value otherwise. + +### GetIndirectMapOk + +`func (o *MapTest) GetIndirectMapOk() (map[string]bool, bool)` + +GetIndirectMapOk returns a tuple with the IndirectMap field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasIndirectMap + +`func (o *MapTest) HasIndirectMap() bool` + +HasIndirectMap returns a boolean if a field has been set. + +### SetIndirectMap + +`func (o *MapTest) SetIndirectMap(v map[string]bool)` + +SetIndirectMap gets a reference to the given map[string]bool and assigns it to the IndirectMap field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/client/petstore/go-experimental/go-petstore/docs/MixedPropertiesAndAdditionalPropertiesClass.md index a2ce1068b2..f12ed969af 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/MixedPropertiesAndAdditionalPropertiesClass.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/MixedPropertiesAndAdditionalPropertiesClass.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Uuid** | **string** | | [optional] -**DateTime** | [**time.Time**](time.Time.md) | | [optional] -**Map** | [**map[string]Animal**](Animal.md) | | [optional] +**Uuid** | Pointer to **string** | | [optional] +**DateTime** | Pointer to [**time.Time**](time.Time.md) | | [optional] +**Map** | Pointer to [**map[string]Animal**](Animal.md) | | [optional] + +## Methods + +### GetUuid + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetUuid() string` + +GetUuid returns the Uuid field if non-nil, zero value otherwise. + +### GetUuidOk + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetUuidOk() (string, bool)` + +GetUuidOk returns a tuple with the Uuid field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasUuid + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) HasUuid() bool` + +HasUuid returns a boolean if a field has been set. + +### SetUuid + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) SetUuid(v string)` + +SetUuid gets a reference to the given string and assigns it to the Uuid field. + +### GetDateTime + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetDateTime() time.Time` + +GetDateTime returns the DateTime field if non-nil, zero value otherwise. + +### GetDateTimeOk + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetDateTimeOk() (time.Time, bool)` + +GetDateTimeOk returns a tuple with the DateTime field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasDateTime + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) HasDateTime() bool` + +HasDateTime returns a boolean if a field has been set. + +### SetDateTime + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) SetDateTime(v time.Time)` + +SetDateTime gets a reference to the given time.Time and assigns it to the DateTime field. + +### GetMap + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetMap() map[string]Animal` + +GetMap returns the Map field if non-nil, zero value otherwise. + +### GetMapOk + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) GetMapOk() (map[string]Animal, bool)` + +GetMapOk returns a tuple with the Map field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMap + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) HasMap() bool` + +HasMap returns a boolean if a field has been set. + +### SetMap + +`func (o *MixedPropertiesAndAdditionalPropertiesClass) SetMap(v map[string]Animal)` + +SetMap gets a reference to the given map[string]Animal and assigns it to the Map field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Model200Response.md b/samples/client/petstore/go-experimental/go-petstore/docs/Model200Response.md index 27b93bd154..b0fbf5369e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Model200Response.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Model200Response.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **int32** | | [optional] -**Class** | **string** | | [optional] +**Name** | Pointer to **int32** | | [optional] +**Class** | Pointer to **string** | | [optional] + +## Methods + +### GetName + +`func (o *Model200Response) GetName() int32` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Model200Response) GetNameOk() (int32, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *Model200Response) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *Model200Response) SetName(v int32)` + +SetName gets a reference to the given int32 and assigns it to the Name field. + +### GetClass + +`func (o *Model200Response) GetClass() string` + +GetClass returns the Class field if non-nil, zero value otherwise. + +### GetClassOk + +`func (o *Model200Response) GetClassOk() (string, bool)` + +GetClassOk returns a tuple with the Class field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasClass + +`func (o *Model200Response) HasClass() bool` + +HasClass returns a boolean if a field has been set. + +### SetClass + +`func (o *Model200Response) SetClass(v string)` + +SetClass gets a reference to the given string and assigns it to the Class field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Name.md b/samples/client/petstore/go-experimental/go-petstore/docs/Name.md index 453e54d985..3b1d29f518 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Name.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Name.md @@ -4,10 +4,113 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Name** | **int32** | | -**SnakeCase** | **int32** | | [optional] -**Property** | **string** | | [optional] -**Var123Number** | **int32** | | [optional] +**Name** | Pointer to **int32** | | +**SnakeCase** | Pointer to **int32** | | [optional] +**Property** | Pointer to **string** | | [optional] +**Var123Number** | Pointer to **int32** | | [optional] + +## Methods + +### GetName + +`func (o *Name) GetName() int32` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Name) GetNameOk() (int32, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *Name) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *Name) SetName(v int32)` + +SetName gets a reference to the given int32 and assigns it to the Name field. + +### GetSnakeCase + +`func (o *Name) GetSnakeCase() int32` + +GetSnakeCase returns the SnakeCase field if non-nil, zero value otherwise. + +### GetSnakeCaseOk + +`func (o *Name) GetSnakeCaseOk() (int32, bool)` + +GetSnakeCaseOk returns a tuple with the SnakeCase field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSnakeCase + +`func (o *Name) HasSnakeCase() bool` + +HasSnakeCase returns a boolean if a field has been set. + +### SetSnakeCase + +`func (o *Name) SetSnakeCase(v int32)` + +SetSnakeCase gets a reference to the given int32 and assigns it to the SnakeCase field. + +### GetProperty + +`func (o *Name) GetProperty() string` + +GetProperty returns the Property field if non-nil, zero value otherwise. + +### GetPropertyOk + +`func (o *Name) GetPropertyOk() (string, bool)` + +GetPropertyOk returns a tuple with the Property field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasProperty + +`func (o *Name) HasProperty() bool` + +HasProperty returns a boolean if a field has been set. + +### SetProperty + +`func (o *Name) SetProperty(v string)` + +SetProperty gets a reference to the given string and assigns it to the Property field. + +### GetVar123Number + +`func (o *Name) GetVar123Number() int32` + +GetVar123Number returns the Var123Number field if non-nil, zero value otherwise. + +### GetVar123NumberOk + +`func (o *Name) GetVar123NumberOk() (int32, bool)` + +GetVar123NumberOk returns a tuple with the Var123Number field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasVar123Number + +`func (o *Name) HasVar123Number() bool` + +HasVar123Number returns a boolean if a field has been set. + +### SetVar123Number + +`func (o *Name) SetVar123Number(v int32)` + +SetVar123Number gets a reference to the given int32 and assigns it to the Var123Number field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/NumberOnly.md b/samples/client/petstore/go-experimental/go-petstore/docs/NumberOnly.md index 604cf37eed..3521b8b2d0 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/NumberOnly.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/NumberOnly.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**JustNumber** | **float32** | | [optional] +**JustNumber** | Pointer to **float32** | | [optional] + +## Methods + +### GetJustNumber + +`func (o *NumberOnly) GetJustNumber() float32` + +GetJustNumber returns the JustNumber field if non-nil, zero value otherwise. + +### GetJustNumberOk + +`func (o *NumberOnly) GetJustNumberOk() (float32, bool)` + +GetJustNumberOk returns a tuple with the JustNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasJustNumber + +`func (o *NumberOnly) HasJustNumber() bool` + +HasJustNumber returns a boolean if a field has been set. + +### SetJustNumber + +`func (o *NumberOnly) SetJustNumber(v float32)` + +SetJustNumber gets a reference to the given float32 and assigns it to the JustNumber field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Order.md b/samples/client/petstore/go-experimental/go-petstore/docs/Order.md index eeef097100..982f9f591c 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Order.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Order.md @@ -4,12 +4,165 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **int64** | | [optional] -**PetId** | **int64** | | [optional] -**Quantity** | **int32** | | [optional] -**ShipDate** | [**time.Time**](time.Time.md) | | [optional] -**Status** | **string** | Order Status | [optional] -**Complete** | **bool** | | [optional] [default to false] +**Id** | Pointer to **int64** | | [optional] +**PetId** | Pointer to **int64** | | [optional] +**Quantity** | Pointer to **int32** | | [optional] +**ShipDate** | Pointer to [**time.Time**](time.Time.md) | | [optional] +**Status** | Pointer to **string** | Order Status | [optional] +**Complete** | Pointer to **bool** | | [optional] [default to false] + +## Methods + +### GetId + +`func (o *Order) GetId() int64` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Order) GetIdOk() (int64, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasId + +`func (o *Order) HasId() bool` + +HasId returns a boolean if a field has been set. + +### SetId + +`func (o *Order) SetId(v int64)` + +SetId gets a reference to the given int64 and assigns it to the Id field. + +### GetPetId + +`func (o *Order) GetPetId() int64` + +GetPetId returns the PetId field if non-nil, zero value otherwise. + +### GetPetIdOk + +`func (o *Order) GetPetIdOk() (int64, bool)` + +GetPetIdOk returns a tuple with the PetId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPetId + +`func (o *Order) HasPetId() bool` + +HasPetId returns a boolean if a field has been set. + +### SetPetId + +`func (o *Order) SetPetId(v int64)` + +SetPetId gets a reference to the given int64 and assigns it to the PetId field. + +### GetQuantity + +`func (o *Order) GetQuantity() int32` + +GetQuantity returns the Quantity field if non-nil, zero value otherwise. + +### GetQuantityOk + +`func (o *Order) GetQuantityOk() (int32, bool)` + +GetQuantityOk returns a tuple with the Quantity field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasQuantity + +`func (o *Order) HasQuantity() bool` + +HasQuantity returns a boolean if a field has been set. + +### SetQuantity + +`func (o *Order) SetQuantity(v int32)` + +SetQuantity gets a reference to the given int32 and assigns it to the Quantity field. + +### GetShipDate + +`func (o *Order) GetShipDate() time.Time` + +GetShipDate returns the ShipDate field if non-nil, zero value otherwise. + +### GetShipDateOk + +`func (o *Order) GetShipDateOk() (time.Time, bool)` + +GetShipDateOk returns a tuple with the ShipDate field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasShipDate + +`func (o *Order) HasShipDate() bool` + +HasShipDate returns a boolean if a field has been set. + +### SetShipDate + +`func (o *Order) SetShipDate(v time.Time)` + +SetShipDate gets a reference to the given time.Time and assigns it to the ShipDate field. + +### GetStatus + +`func (o *Order) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *Order) GetStatusOk() (string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasStatus + +`func (o *Order) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + +### SetStatus + +`func (o *Order) SetStatus(v string)` + +SetStatus gets a reference to the given string and assigns it to the Status field. + +### GetComplete + +`func (o *Order) GetComplete() bool` + +GetComplete returns the Complete field if non-nil, zero value otherwise. + +### GetCompleteOk + +`func (o *Order) GetCompleteOk() (bool, bool)` + +GetCompleteOk returns a tuple with the Complete field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasComplete + +`func (o *Order) HasComplete() bool` + +HasComplete returns a boolean if a field has been set. + +### SetComplete + +`func (o *Order) SetComplete(v bool)` + +SetComplete gets a reference to the given bool and assigns it to the Complete field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/OuterComposite.md b/samples/client/petstore/go-experimental/go-petstore/docs/OuterComposite.md index df9bce1bd9..30a345dc8d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/OuterComposite.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/OuterComposite.md @@ -4,9 +4,87 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**MyNumber** | **float32** | | [optional] -**MyString** | **string** | | [optional] -**MyBoolean** | **bool** | | [optional] +**MyNumber** | Pointer to **float32** | | [optional] +**MyString** | Pointer to **string** | | [optional] +**MyBoolean** | Pointer to **bool** | | [optional] + +## Methods + +### GetMyNumber + +`func (o *OuterComposite) GetMyNumber() float32` + +GetMyNumber returns the MyNumber field if non-nil, zero value otherwise. + +### GetMyNumberOk + +`func (o *OuterComposite) GetMyNumberOk() (float32, bool)` + +GetMyNumberOk returns a tuple with the MyNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMyNumber + +`func (o *OuterComposite) HasMyNumber() bool` + +HasMyNumber returns a boolean if a field has been set. + +### SetMyNumber + +`func (o *OuterComposite) SetMyNumber(v float32)` + +SetMyNumber gets a reference to the given float32 and assigns it to the MyNumber field. + +### GetMyString + +`func (o *OuterComposite) GetMyString() string` + +GetMyString returns the MyString field if non-nil, zero value otherwise. + +### GetMyStringOk + +`func (o *OuterComposite) GetMyStringOk() (string, bool)` + +GetMyStringOk returns a tuple with the MyString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMyString + +`func (o *OuterComposite) HasMyString() bool` + +HasMyString returns a boolean if a field has been set. + +### SetMyString + +`func (o *OuterComposite) SetMyString(v string)` + +SetMyString gets a reference to the given string and assigns it to the MyString field. + +### GetMyBoolean + +`func (o *OuterComposite) GetMyBoolean() bool` + +GetMyBoolean returns the MyBoolean field if non-nil, zero value otherwise. + +### GetMyBooleanOk + +`func (o *OuterComposite) GetMyBooleanOk() (bool, bool)` + +GetMyBooleanOk returns a tuple with the MyBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasMyBoolean + +`func (o *OuterComposite) HasMyBoolean() bool` + +HasMyBoolean returns a boolean if a field has been set. + +### SetMyBoolean + +`func (o *OuterComposite) SetMyBoolean(v bool)` + +SetMyBoolean gets a reference to the given bool and assigns it to the MyBoolean field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/OuterEnum.md b/samples/client/petstore/go-experimental/go-petstore/docs/OuterEnum.md index c97466159c..13bed2d17f 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/OuterEnum.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/OuterEnum.md @@ -5,6 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Pet.md b/samples/client/petstore/go-experimental/go-petstore/docs/Pet.md index c48104c639..81a4ec294e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Pet.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Pet.md @@ -4,12 +4,165 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **int64** | | [optional] -**Category** | [**Category**](Category.md) | | [optional] -**Name** | **string** | | -**PhotoUrls** | **[]string** | | -**Tags** | [**[]Tag**](Tag.md) | | [optional] -**Status** | **string** | pet status in the store | [optional] +**Id** | Pointer to **int64** | | [optional] +**Category** | Pointer to [**Category**](Category.md) | | [optional] +**Name** | Pointer to **string** | | +**PhotoUrls** | Pointer to **[]string** | | +**Tags** | Pointer to [**[]Tag**](Tag.md) | | [optional] +**Status** | Pointer to **string** | pet status in the store | [optional] + +## Methods + +### GetId + +`func (o *Pet) GetId() int64` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Pet) GetIdOk() (int64, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasId + +`func (o *Pet) HasId() bool` + +HasId returns a boolean if a field has been set. + +### SetId + +`func (o *Pet) SetId(v int64)` + +SetId gets a reference to the given int64 and assigns it to the Id field. + +### GetCategory + +`func (o *Pet) GetCategory() Category` + +GetCategory returns the Category field if non-nil, zero value otherwise. + +### GetCategoryOk + +`func (o *Pet) GetCategoryOk() (Category, bool)` + +GetCategoryOk returns a tuple with the Category field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasCategory + +`func (o *Pet) HasCategory() bool` + +HasCategory returns a boolean if a field has been set. + +### SetCategory + +`func (o *Pet) SetCategory(v Category)` + +SetCategory gets a reference to the given Category and assigns it to the Category field. + +### GetName + +`func (o *Pet) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Pet) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *Pet) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *Pet) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + +### GetPhotoUrls + +`func (o *Pet) GetPhotoUrls() []string` + +GetPhotoUrls returns the PhotoUrls field if non-nil, zero value otherwise. + +### GetPhotoUrlsOk + +`func (o *Pet) GetPhotoUrlsOk() ([]string, bool)` + +GetPhotoUrlsOk returns a tuple with the PhotoUrls field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPhotoUrls + +`func (o *Pet) HasPhotoUrls() bool` + +HasPhotoUrls returns a boolean if a field has been set. + +### SetPhotoUrls + +`func (o *Pet) SetPhotoUrls(v []string)` + +SetPhotoUrls gets a reference to the given []string and assigns it to the PhotoUrls field. + +### GetTags + +`func (o *Pet) GetTags() []Tag` + +GetTags returns the Tags field if non-nil, zero value otherwise. + +### GetTagsOk + +`func (o *Pet) GetTagsOk() ([]Tag, bool)` + +GetTagsOk returns a tuple with the Tags field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasTags + +`func (o *Pet) HasTags() bool` + +HasTags returns a boolean if a field has been set. + +### SetTags + +`func (o *Pet) SetTags(v []Tag)` + +SetTags gets a reference to the given []Tag and assigns it to the Tags field. + +### GetStatus + +`func (o *Pet) GetStatus() string` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *Pet) GetStatusOk() (string, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasStatus + +`func (o *Pet) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + +### SetStatus + +`func (o *Pet) SetStatus(v string)` + +SetStatus gets a reference to the given string and assigns it to the Status field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/ReadOnlyFirst.md b/samples/client/petstore/go-experimental/go-petstore/docs/ReadOnlyFirst.md index 3fee799f29..e490a0fc96 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/ReadOnlyFirst.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/ReadOnlyFirst.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Bar** | **string** | | [optional] -**Baz** | **string** | | [optional] +**Bar** | Pointer to **string** | | [optional] +**Baz** | Pointer to **string** | | [optional] + +## Methods + +### GetBar + +`func (o *ReadOnlyFirst) GetBar() string` + +GetBar returns the Bar field if non-nil, zero value otherwise. + +### GetBarOk + +`func (o *ReadOnlyFirst) GetBarOk() (string, bool)` + +GetBarOk returns a tuple with the Bar field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBar + +`func (o *ReadOnlyFirst) HasBar() bool` + +HasBar returns a boolean if a field has been set. + +### SetBar + +`func (o *ReadOnlyFirst) SetBar(v string)` + +SetBar gets a reference to the given string and assigns it to the Bar field. + +### GetBaz + +`func (o *ReadOnlyFirst) GetBaz() string` + +GetBaz returns the Baz field if non-nil, zero value otherwise. + +### GetBazOk + +`func (o *ReadOnlyFirst) GetBazOk() (string, bool)` + +GetBazOk returns a tuple with the Baz field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBaz + +`func (o *ReadOnlyFirst) HasBaz() bool` + +HasBaz returns a boolean if a field has been set. + +### SetBaz + +`func (o *ReadOnlyFirst) SetBaz(v string)` + +SetBaz gets a reference to the given string and assigns it to the Baz field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Return.md b/samples/client/petstore/go-experimental/go-petstore/docs/Return.md index 11be0b27c5..5c586fcbc6 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Return.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Return.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Return** | **int32** | | [optional] +**Return** | Pointer to **int32** | | [optional] + +## Methods + +### GetReturn + +`func (o *Return) GetReturn() int32` + +GetReturn returns the Return field if non-nil, zero value otherwise. + +### GetReturnOk + +`func (o *Return) GetReturnOk() (int32, bool)` + +GetReturnOk returns a tuple with the Return field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasReturn + +`func (o *Return) HasReturn() bool` + +HasReturn returns a boolean if a field has been set. + +### SetReturn + +`func (o *Return) SetReturn(v int32)` + +SetReturn gets a reference to the given int32 and assigns it to the Return field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/SpecialModelName.md b/samples/client/petstore/go-experimental/go-petstore/docs/SpecialModelName.md index 96d7a28a40..9e7d3f377d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/SpecialModelName.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/SpecialModelName.md @@ -4,7 +4,35 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**SpecialPropertyName** | **int64** | | [optional] +**SpecialPropertyName** | Pointer to **int64** | | [optional] + +## Methods + +### GetSpecialPropertyName + +`func (o *SpecialModelName) GetSpecialPropertyName() int64` + +GetSpecialPropertyName returns the SpecialPropertyName field if non-nil, zero value otherwise. + +### GetSpecialPropertyNameOk + +`func (o *SpecialModelName) GetSpecialPropertyNameOk() (int64, bool)` + +GetSpecialPropertyNameOk returns a tuple with the SpecialPropertyName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasSpecialPropertyName + +`func (o *SpecialModelName) HasSpecialPropertyName() bool` + +HasSpecialPropertyName returns a boolean if a field has been set. + +### SetSpecialPropertyName + +`func (o *SpecialModelName) SetSpecialPropertyName(v int64)` + +SetSpecialPropertyName gets a reference to the given int64 and assigns it to the SpecialPropertyName field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/Tag.md b/samples/client/petstore/go-experimental/go-petstore/docs/Tag.md index d6b3cc117b..570126bd5f 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/Tag.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/Tag.md @@ -4,8 +4,61 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **int64** | | [optional] -**Name** | **string** | | [optional] +**Id** | Pointer to **int64** | | [optional] +**Name** | Pointer to **string** | | [optional] + +## Methods + +### GetId + +`func (o *Tag) GetId() int64` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *Tag) GetIdOk() (int64, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasId + +`func (o *Tag) HasId() bool` + +HasId returns a boolean if a field has been set. + +### SetId + +`func (o *Tag) SetId(v int64)` + +SetId gets a reference to the given int64 and assigns it to the Id field. + +### GetName + +`func (o *Tag) GetName() string` + +GetName returns the Name field if non-nil, zero value otherwise. + +### GetNameOk + +`func (o *Tag) GetNameOk() (string, bool)` + +GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasName + +`func (o *Tag) HasName() bool` + +HasName returns a boolean if a field has been set. + +### SetName + +`func (o *Tag) SetName(v string)` + +SetName gets a reference to the given string and assigns it to the Name field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderDefault.md b/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderDefault.md index 1b9f077c30..09347e6175 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderDefault.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderDefault.md @@ -4,11 +4,139 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**StringItem** | **string** | | [default to what] -**NumberItem** | **float32** | | -**IntegerItem** | **int32** | | -**BoolItem** | **bool** | | [default to true] -**ArrayItem** | **[]int32** | | +**StringItem** | Pointer to **string** | | [default to what] +**NumberItem** | Pointer to **float32** | | +**IntegerItem** | Pointer to **int32** | | +**BoolItem** | Pointer to **bool** | | [default to true] +**ArrayItem** | Pointer to **[]int32** | | + +## Methods + +### GetStringItem + +`func (o *TypeHolderDefault) GetStringItem() string` + +GetStringItem returns the StringItem field if non-nil, zero value otherwise. + +### GetStringItemOk + +`func (o *TypeHolderDefault) GetStringItemOk() (string, bool)` + +GetStringItemOk returns a tuple with the StringItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasStringItem + +`func (o *TypeHolderDefault) HasStringItem() bool` + +HasStringItem returns a boolean if a field has been set. + +### SetStringItem + +`func (o *TypeHolderDefault) SetStringItem(v string)` + +SetStringItem gets a reference to the given string and assigns it to the StringItem field. + +### GetNumberItem + +`func (o *TypeHolderDefault) GetNumberItem() float32` + +GetNumberItem returns the NumberItem field if non-nil, zero value otherwise. + +### GetNumberItemOk + +`func (o *TypeHolderDefault) GetNumberItemOk() (float32, bool)` + +GetNumberItemOk returns a tuple with the NumberItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNumberItem + +`func (o *TypeHolderDefault) HasNumberItem() bool` + +HasNumberItem returns a boolean if a field has been set. + +### SetNumberItem + +`func (o *TypeHolderDefault) SetNumberItem(v float32)` + +SetNumberItem gets a reference to the given float32 and assigns it to the NumberItem field. + +### GetIntegerItem + +`func (o *TypeHolderDefault) GetIntegerItem() int32` + +GetIntegerItem returns the IntegerItem field if non-nil, zero value otherwise. + +### GetIntegerItemOk + +`func (o *TypeHolderDefault) GetIntegerItemOk() (int32, bool)` + +GetIntegerItemOk returns a tuple with the IntegerItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasIntegerItem + +`func (o *TypeHolderDefault) HasIntegerItem() bool` + +HasIntegerItem returns a boolean if a field has been set. + +### SetIntegerItem + +`func (o *TypeHolderDefault) SetIntegerItem(v int32)` + +SetIntegerItem gets a reference to the given int32 and assigns it to the IntegerItem field. + +### GetBoolItem + +`func (o *TypeHolderDefault) GetBoolItem() bool` + +GetBoolItem returns the BoolItem field if non-nil, zero value otherwise. + +### GetBoolItemOk + +`func (o *TypeHolderDefault) GetBoolItemOk() (bool, bool)` + +GetBoolItemOk returns a tuple with the BoolItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBoolItem + +`func (o *TypeHolderDefault) HasBoolItem() bool` + +HasBoolItem returns a boolean if a field has been set. + +### SetBoolItem + +`func (o *TypeHolderDefault) SetBoolItem(v bool)` + +SetBoolItem gets a reference to the given bool and assigns it to the BoolItem field. + +### GetArrayItem + +`func (o *TypeHolderDefault) GetArrayItem() []int32` + +GetArrayItem returns the ArrayItem field if non-nil, zero value otherwise. + +### GetArrayItemOk + +`func (o *TypeHolderDefault) GetArrayItemOk() ([]int32, bool)` + +GetArrayItemOk returns a tuple with the ArrayItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayItem + +`func (o *TypeHolderDefault) HasArrayItem() bool` + +HasArrayItem returns a boolean if a field has been set. + +### SetArrayItem + +`func (o *TypeHolderDefault) SetArrayItem(v []int32)` + +SetArrayItem gets a reference to the given []int32 and assigns it to the ArrayItem field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderExample.md b/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderExample.md index abe85f9799..f9a276c529 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderExample.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/TypeHolderExample.md @@ -4,11 +4,139 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**StringItem** | **string** | | -**NumberItem** | **float32** | | -**IntegerItem** | **int32** | | -**BoolItem** | **bool** | | -**ArrayItem** | **[]int32** | | +**StringItem** | Pointer to **string** | | +**NumberItem** | Pointer to **float32** | | +**IntegerItem** | Pointer to **int32** | | +**BoolItem** | Pointer to **bool** | | +**ArrayItem** | Pointer to **[]int32** | | + +## Methods + +### GetStringItem + +`func (o *TypeHolderExample) GetStringItem() string` + +GetStringItem returns the StringItem field if non-nil, zero value otherwise. + +### GetStringItemOk + +`func (o *TypeHolderExample) GetStringItemOk() (string, bool)` + +GetStringItemOk returns a tuple with the StringItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasStringItem + +`func (o *TypeHolderExample) HasStringItem() bool` + +HasStringItem returns a boolean if a field has been set. + +### SetStringItem + +`func (o *TypeHolderExample) SetStringItem(v string)` + +SetStringItem gets a reference to the given string and assigns it to the StringItem field. + +### GetNumberItem + +`func (o *TypeHolderExample) GetNumberItem() float32` + +GetNumberItem returns the NumberItem field if non-nil, zero value otherwise. + +### GetNumberItemOk + +`func (o *TypeHolderExample) GetNumberItemOk() (float32, bool)` + +GetNumberItemOk returns a tuple with the NumberItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNumberItem + +`func (o *TypeHolderExample) HasNumberItem() bool` + +HasNumberItem returns a boolean if a field has been set. + +### SetNumberItem + +`func (o *TypeHolderExample) SetNumberItem(v float32)` + +SetNumberItem gets a reference to the given float32 and assigns it to the NumberItem field. + +### GetIntegerItem + +`func (o *TypeHolderExample) GetIntegerItem() int32` + +GetIntegerItem returns the IntegerItem field if non-nil, zero value otherwise. + +### GetIntegerItemOk + +`func (o *TypeHolderExample) GetIntegerItemOk() (int32, bool)` + +GetIntegerItemOk returns a tuple with the IntegerItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasIntegerItem + +`func (o *TypeHolderExample) HasIntegerItem() bool` + +HasIntegerItem returns a boolean if a field has been set. + +### SetIntegerItem + +`func (o *TypeHolderExample) SetIntegerItem(v int32)` + +SetIntegerItem gets a reference to the given int32 and assigns it to the IntegerItem field. + +### GetBoolItem + +`func (o *TypeHolderExample) GetBoolItem() bool` + +GetBoolItem returns the BoolItem field if non-nil, zero value otherwise. + +### GetBoolItemOk + +`func (o *TypeHolderExample) GetBoolItemOk() (bool, bool)` + +GetBoolItemOk returns a tuple with the BoolItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasBoolItem + +`func (o *TypeHolderExample) HasBoolItem() bool` + +HasBoolItem returns a boolean if a field has been set. + +### SetBoolItem + +`func (o *TypeHolderExample) SetBoolItem(v bool)` + +SetBoolItem gets a reference to the given bool and assigns it to the BoolItem field. + +### GetArrayItem + +`func (o *TypeHolderExample) GetArrayItem() []int32` + +GetArrayItem returns the ArrayItem field if non-nil, zero value otherwise. + +### GetArrayItemOk + +`func (o *TypeHolderExample) GetArrayItemOk() ([]int32, bool)` + +GetArrayItemOk returns a tuple with the ArrayItem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasArrayItem + +`func (o *TypeHolderExample) HasArrayItem() bool` + +HasArrayItem returns a boolean if a field has been set. + +### SetArrayItem + +`func (o *TypeHolderExample) SetArrayItem(v []int32)` + +SetArrayItem gets a reference to the given []int32 and assigns it to the ArrayItem field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/User.md b/samples/client/petstore/go-experimental/go-petstore/docs/User.md index 7675d7ff70..4f05d3b473 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/User.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/User.md @@ -4,14 +4,217 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Id** | **int64** | | [optional] -**Username** | **string** | | [optional] -**FirstName** | **string** | | [optional] -**LastName** | **string** | | [optional] -**Email** | **string** | | [optional] -**Password** | **string** | | [optional] -**Phone** | **string** | | [optional] -**UserStatus** | **int32** | User Status | [optional] +**Id** | Pointer to **int64** | | [optional] +**Username** | Pointer to **string** | | [optional] +**FirstName** | Pointer to **string** | | [optional] +**LastName** | Pointer to **string** | | [optional] +**Email** | Pointer to **string** | | [optional] +**Password** | Pointer to **string** | | [optional] +**Phone** | Pointer to **string** | | [optional] +**UserStatus** | Pointer to **int32** | User Status | [optional] + +## Methods + +### GetId + +`func (o *User) GetId() int64` + +GetId returns the Id field if non-nil, zero value otherwise. + +### GetIdOk + +`func (o *User) GetIdOk() (int64, bool)` + +GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasId + +`func (o *User) HasId() bool` + +HasId returns a boolean if a field has been set. + +### SetId + +`func (o *User) SetId(v int64)` + +SetId gets a reference to the given int64 and assigns it to the Id field. + +### GetUsername + +`func (o *User) GetUsername() string` + +GetUsername returns the Username field if non-nil, zero value otherwise. + +### GetUsernameOk + +`func (o *User) GetUsernameOk() (string, bool)` + +GetUsernameOk returns a tuple with the Username field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasUsername + +`func (o *User) HasUsername() bool` + +HasUsername returns a boolean if a field has been set. + +### SetUsername + +`func (o *User) SetUsername(v string)` + +SetUsername gets a reference to the given string and assigns it to the Username field. + +### GetFirstName + +`func (o *User) GetFirstName() string` + +GetFirstName returns the FirstName field if non-nil, zero value otherwise. + +### GetFirstNameOk + +`func (o *User) GetFirstNameOk() (string, bool)` + +GetFirstNameOk returns a tuple with the FirstName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasFirstName + +`func (o *User) HasFirstName() bool` + +HasFirstName returns a boolean if a field has been set. + +### SetFirstName + +`func (o *User) SetFirstName(v string)` + +SetFirstName gets a reference to the given string and assigns it to the FirstName field. + +### GetLastName + +`func (o *User) GetLastName() string` + +GetLastName returns the LastName field if non-nil, zero value otherwise. + +### GetLastNameOk + +`func (o *User) GetLastNameOk() (string, bool)` + +GetLastNameOk returns a tuple with the LastName field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasLastName + +`func (o *User) HasLastName() bool` + +HasLastName returns a boolean if a field has been set. + +### SetLastName + +`func (o *User) SetLastName(v string)` + +SetLastName gets a reference to the given string and assigns it to the LastName field. + +### GetEmail + +`func (o *User) GetEmail() string` + +GetEmail returns the Email field if non-nil, zero value otherwise. + +### GetEmailOk + +`func (o *User) GetEmailOk() (string, bool)` + +GetEmailOk returns a tuple with the Email field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasEmail + +`func (o *User) HasEmail() bool` + +HasEmail returns a boolean if a field has been set. + +### SetEmail + +`func (o *User) SetEmail(v string)` + +SetEmail gets a reference to the given string and assigns it to the Email field. + +### GetPassword + +`func (o *User) GetPassword() string` + +GetPassword returns the Password field if non-nil, zero value otherwise. + +### GetPasswordOk + +`func (o *User) GetPasswordOk() (string, bool)` + +GetPasswordOk returns a tuple with the Password field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPassword + +`func (o *User) HasPassword() bool` + +HasPassword returns a boolean if a field has been set. + +### SetPassword + +`func (o *User) SetPassword(v string)` + +SetPassword gets a reference to the given string and assigns it to the Password field. + +### GetPhone + +`func (o *User) GetPhone() string` + +GetPhone returns the Phone field if non-nil, zero value otherwise. + +### GetPhoneOk + +`func (o *User) GetPhoneOk() (string, bool)` + +GetPhoneOk returns a tuple with the Phone field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPhone + +`func (o *User) HasPhone() bool` + +HasPhone returns a boolean if a field has been set. + +### SetPhone + +`func (o *User) SetPhone(v string)` + +SetPhone gets a reference to the given string and assigns it to the Phone field. + +### GetUserStatus + +`func (o *User) GetUserStatus() int32` + +GetUserStatus returns the UserStatus field if non-nil, zero value otherwise. + +### GetUserStatusOk + +`func (o *User) GetUserStatusOk() (int32, bool)` + +GetUserStatusOk returns a tuple with the UserStatus field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasUserStatus + +`func (o *User) HasUserStatus() bool` + +HasUserStatus returns a boolean if a field has been set. + +### SetUserStatus + +`func (o *User) SetUserStatus(v int32)` + +SetUserStatus gets a reference to the given int32 and assigns it to the UserStatus field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/docs/XmlItem.md b/samples/client/petstore/go-experimental/go-petstore/docs/XmlItem.md index 8a9c2dc0b5..cdee2ad0dd 100644 --- a/samples/client/petstore/go-experimental/go-petstore/docs/XmlItem.md +++ b/samples/client/petstore/go-experimental/go-petstore/docs/XmlItem.md @@ -4,35 +4,763 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**AttributeString** | **string** | | [optional] -**AttributeNumber** | **float32** | | [optional] -**AttributeInteger** | **int32** | | [optional] -**AttributeBoolean** | **bool** | | [optional] -**WrappedArray** | **[]int32** | | [optional] -**NameString** | **string** | | [optional] -**NameNumber** | **float32** | | [optional] -**NameInteger** | **int32** | | [optional] -**NameBoolean** | **bool** | | [optional] -**NameArray** | **[]int32** | | [optional] -**NameWrappedArray** | **[]int32** | | [optional] -**PrefixString** | **string** | | [optional] -**PrefixNumber** | **float32** | | [optional] -**PrefixInteger** | **int32** | | [optional] -**PrefixBoolean** | **bool** | | [optional] -**PrefixArray** | **[]int32** | | [optional] -**PrefixWrappedArray** | **[]int32** | | [optional] -**NamespaceString** | **string** | | [optional] -**NamespaceNumber** | **float32** | | [optional] -**NamespaceInteger** | **int32** | | [optional] -**NamespaceBoolean** | **bool** | | [optional] -**NamespaceArray** | **[]int32** | | [optional] -**NamespaceWrappedArray** | **[]int32** | | [optional] -**PrefixNsString** | **string** | | [optional] -**PrefixNsNumber** | **float32** | | [optional] -**PrefixNsInteger** | **int32** | | [optional] -**PrefixNsBoolean** | **bool** | | [optional] -**PrefixNsArray** | **[]int32** | | [optional] -**PrefixNsWrappedArray** | **[]int32** | | [optional] +**AttributeString** | Pointer to **string** | | [optional] +**AttributeNumber** | Pointer to **float32** | | [optional] +**AttributeInteger** | Pointer to **int32** | | [optional] +**AttributeBoolean** | Pointer to **bool** | | [optional] +**WrappedArray** | Pointer to **[]int32** | | [optional] +**NameString** | Pointer to **string** | | [optional] +**NameNumber** | Pointer to **float32** | | [optional] +**NameInteger** | Pointer to **int32** | | [optional] +**NameBoolean** | Pointer to **bool** | | [optional] +**NameArray** | Pointer to **[]int32** | | [optional] +**NameWrappedArray** | Pointer to **[]int32** | | [optional] +**PrefixString** | Pointer to **string** | | [optional] +**PrefixNumber** | Pointer to **float32** | | [optional] +**PrefixInteger** | Pointer to **int32** | | [optional] +**PrefixBoolean** | Pointer to **bool** | | [optional] +**PrefixArray** | Pointer to **[]int32** | | [optional] +**PrefixWrappedArray** | Pointer to **[]int32** | | [optional] +**NamespaceString** | Pointer to **string** | | [optional] +**NamespaceNumber** | Pointer to **float32** | | [optional] +**NamespaceInteger** | Pointer to **int32** | | [optional] +**NamespaceBoolean** | Pointer to **bool** | | [optional] +**NamespaceArray** | Pointer to **[]int32** | | [optional] +**NamespaceWrappedArray** | Pointer to **[]int32** | | [optional] +**PrefixNsString** | Pointer to **string** | | [optional] +**PrefixNsNumber** | Pointer to **float32** | | [optional] +**PrefixNsInteger** | Pointer to **int32** | | [optional] +**PrefixNsBoolean** | Pointer to **bool** | | [optional] +**PrefixNsArray** | Pointer to **[]int32** | | [optional] +**PrefixNsWrappedArray** | Pointer to **[]int32** | | [optional] + +## Methods + +### GetAttributeString + +`func (o *XmlItem) GetAttributeString() string` + +GetAttributeString returns the AttributeString field if non-nil, zero value otherwise. + +### GetAttributeStringOk + +`func (o *XmlItem) GetAttributeStringOk() (string, bool)` + +GetAttributeStringOk returns a tuple with the AttributeString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAttributeString + +`func (o *XmlItem) HasAttributeString() bool` + +HasAttributeString returns a boolean if a field has been set. + +### SetAttributeString + +`func (o *XmlItem) SetAttributeString(v string)` + +SetAttributeString gets a reference to the given string and assigns it to the AttributeString field. + +### GetAttributeNumber + +`func (o *XmlItem) GetAttributeNumber() float32` + +GetAttributeNumber returns the AttributeNumber field if non-nil, zero value otherwise. + +### GetAttributeNumberOk + +`func (o *XmlItem) GetAttributeNumberOk() (float32, bool)` + +GetAttributeNumberOk returns a tuple with the AttributeNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAttributeNumber + +`func (o *XmlItem) HasAttributeNumber() bool` + +HasAttributeNumber returns a boolean if a field has been set. + +### SetAttributeNumber + +`func (o *XmlItem) SetAttributeNumber(v float32)` + +SetAttributeNumber gets a reference to the given float32 and assigns it to the AttributeNumber field. + +### GetAttributeInteger + +`func (o *XmlItem) GetAttributeInteger() int32` + +GetAttributeInteger returns the AttributeInteger field if non-nil, zero value otherwise. + +### GetAttributeIntegerOk + +`func (o *XmlItem) GetAttributeIntegerOk() (int32, bool)` + +GetAttributeIntegerOk returns a tuple with the AttributeInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAttributeInteger + +`func (o *XmlItem) HasAttributeInteger() bool` + +HasAttributeInteger returns a boolean if a field has been set. + +### SetAttributeInteger + +`func (o *XmlItem) SetAttributeInteger(v int32)` + +SetAttributeInteger gets a reference to the given int32 and assigns it to the AttributeInteger field. + +### GetAttributeBoolean + +`func (o *XmlItem) GetAttributeBoolean() bool` + +GetAttributeBoolean returns the AttributeBoolean field if non-nil, zero value otherwise. + +### GetAttributeBooleanOk + +`func (o *XmlItem) GetAttributeBooleanOk() (bool, bool)` + +GetAttributeBooleanOk returns a tuple with the AttributeBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasAttributeBoolean + +`func (o *XmlItem) HasAttributeBoolean() bool` + +HasAttributeBoolean returns a boolean if a field has been set. + +### SetAttributeBoolean + +`func (o *XmlItem) SetAttributeBoolean(v bool)` + +SetAttributeBoolean gets a reference to the given bool and assigns it to the AttributeBoolean field. + +### GetWrappedArray + +`func (o *XmlItem) GetWrappedArray() []int32` + +GetWrappedArray returns the WrappedArray field if non-nil, zero value otherwise. + +### GetWrappedArrayOk + +`func (o *XmlItem) GetWrappedArrayOk() ([]int32, bool)` + +GetWrappedArrayOk returns a tuple with the WrappedArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasWrappedArray + +`func (o *XmlItem) HasWrappedArray() bool` + +HasWrappedArray returns a boolean if a field has been set. + +### SetWrappedArray + +`func (o *XmlItem) SetWrappedArray(v []int32)` + +SetWrappedArray gets a reference to the given []int32 and assigns it to the WrappedArray field. + +### GetNameString + +`func (o *XmlItem) GetNameString() string` + +GetNameString returns the NameString field if non-nil, zero value otherwise. + +### GetNameStringOk + +`func (o *XmlItem) GetNameStringOk() (string, bool)` + +GetNameStringOk returns a tuple with the NameString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameString + +`func (o *XmlItem) HasNameString() bool` + +HasNameString returns a boolean if a field has been set. + +### SetNameString + +`func (o *XmlItem) SetNameString(v string)` + +SetNameString gets a reference to the given string and assigns it to the NameString field. + +### GetNameNumber + +`func (o *XmlItem) GetNameNumber() float32` + +GetNameNumber returns the NameNumber field if non-nil, zero value otherwise. + +### GetNameNumberOk + +`func (o *XmlItem) GetNameNumberOk() (float32, bool)` + +GetNameNumberOk returns a tuple with the NameNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameNumber + +`func (o *XmlItem) HasNameNumber() bool` + +HasNameNumber returns a boolean if a field has been set. + +### SetNameNumber + +`func (o *XmlItem) SetNameNumber(v float32)` + +SetNameNumber gets a reference to the given float32 and assigns it to the NameNumber field. + +### GetNameInteger + +`func (o *XmlItem) GetNameInteger() int32` + +GetNameInteger returns the NameInteger field if non-nil, zero value otherwise. + +### GetNameIntegerOk + +`func (o *XmlItem) GetNameIntegerOk() (int32, bool)` + +GetNameIntegerOk returns a tuple with the NameInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameInteger + +`func (o *XmlItem) HasNameInteger() bool` + +HasNameInteger returns a boolean if a field has been set. + +### SetNameInteger + +`func (o *XmlItem) SetNameInteger(v int32)` + +SetNameInteger gets a reference to the given int32 and assigns it to the NameInteger field. + +### GetNameBoolean + +`func (o *XmlItem) GetNameBoolean() bool` + +GetNameBoolean returns the NameBoolean field if non-nil, zero value otherwise. + +### GetNameBooleanOk + +`func (o *XmlItem) GetNameBooleanOk() (bool, bool)` + +GetNameBooleanOk returns a tuple with the NameBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameBoolean + +`func (o *XmlItem) HasNameBoolean() bool` + +HasNameBoolean returns a boolean if a field has been set. + +### SetNameBoolean + +`func (o *XmlItem) SetNameBoolean(v bool)` + +SetNameBoolean gets a reference to the given bool and assigns it to the NameBoolean field. + +### GetNameArray + +`func (o *XmlItem) GetNameArray() []int32` + +GetNameArray returns the NameArray field if non-nil, zero value otherwise. + +### GetNameArrayOk + +`func (o *XmlItem) GetNameArrayOk() ([]int32, bool)` + +GetNameArrayOk returns a tuple with the NameArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameArray + +`func (o *XmlItem) HasNameArray() bool` + +HasNameArray returns a boolean if a field has been set. + +### SetNameArray + +`func (o *XmlItem) SetNameArray(v []int32)` + +SetNameArray gets a reference to the given []int32 and assigns it to the NameArray field. + +### GetNameWrappedArray + +`func (o *XmlItem) GetNameWrappedArray() []int32` + +GetNameWrappedArray returns the NameWrappedArray field if non-nil, zero value otherwise. + +### GetNameWrappedArrayOk + +`func (o *XmlItem) GetNameWrappedArrayOk() ([]int32, bool)` + +GetNameWrappedArrayOk returns a tuple with the NameWrappedArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNameWrappedArray + +`func (o *XmlItem) HasNameWrappedArray() bool` + +HasNameWrappedArray returns a boolean if a field has been set. + +### SetNameWrappedArray + +`func (o *XmlItem) SetNameWrappedArray(v []int32)` + +SetNameWrappedArray gets a reference to the given []int32 and assigns it to the NameWrappedArray field. + +### GetPrefixString + +`func (o *XmlItem) GetPrefixString() string` + +GetPrefixString returns the PrefixString field if non-nil, zero value otherwise. + +### GetPrefixStringOk + +`func (o *XmlItem) GetPrefixStringOk() (string, bool)` + +GetPrefixStringOk returns a tuple with the PrefixString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixString + +`func (o *XmlItem) HasPrefixString() bool` + +HasPrefixString returns a boolean if a field has been set. + +### SetPrefixString + +`func (o *XmlItem) SetPrefixString(v string)` + +SetPrefixString gets a reference to the given string and assigns it to the PrefixString field. + +### GetPrefixNumber + +`func (o *XmlItem) GetPrefixNumber() float32` + +GetPrefixNumber returns the PrefixNumber field if non-nil, zero value otherwise. + +### GetPrefixNumberOk + +`func (o *XmlItem) GetPrefixNumberOk() (float32, bool)` + +GetPrefixNumberOk returns a tuple with the PrefixNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNumber + +`func (o *XmlItem) HasPrefixNumber() bool` + +HasPrefixNumber returns a boolean if a field has been set. + +### SetPrefixNumber + +`func (o *XmlItem) SetPrefixNumber(v float32)` + +SetPrefixNumber gets a reference to the given float32 and assigns it to the PrefixNumber field. + +### GetPrefixInteger + +`func (o *XmlItem) GetPrefixInteger() int32` + +GetPrefixInteger returns the PrefixInteger field if non-nil, zero value otherwise. + +### GetPrefixIntegerOk + +`func (o *XmlItem) GetPrefixIntegerOk() (int32, bool)` + +GetPrefixIntegerOk returns a tuple with the PrefixInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixInteger + +`func (o *XmlItem) HasPrefixInteger() bool` + +HasPrefixInteger returns a boolean if a field has been set. + +### SetPrefixInteger + +`func (o *XmlItem) SetPrefixInteger(v int32)` + +SetPrefixInteger gets a reference to the given int32 and assigns it to the PrefixInteger field. + +### GetPrefixBoolean + +`func (o *XmlItem) GetPrefixBoolean() bool` + +GetPrefixBoolean returns the PrefixBoolean field if non-nil, zero value otherwise. + +### GetPrefixBooleanOk + +`func (o *XmlItem) GetPrefixBooleanOk() (bool, bool)` + +GetPrefixBooleanOk returns a tuple with the PrefixBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixBoolean + +`func (o *XmlItem) HasPrefixBoolean() bool` + +HasPrefixBoolean returns a boolean if a field has been set. + +### SetPrefixBoolean + +`func (o *XmlItem) SetPrefixBoolean(v bool)` + +SetPrefixBoolean gets a reference to the given bool and assigns it to the PrefixBoolean field. + +### GetPrefixArray + +`func (o *XmlItem) GetPrefixArray() []int32` + +GetPrefixArray returns the PrefixArray field if non-nil, zero value otherwise. + +### GetPrefixArrayOk + +`func (o *XmlItem) GetPrefixArrayOk() ([]int32, bool)` + +GetPrefixArrayOk returns a tuple with the PrefixArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixArray + +`func (o *XmlItem) HasPrefixArray() bool` + +HasPrefixArray returns a boolean if a field has been set. + +### SetPrefixArray + +`func (o *XmlItem) SetPrefixArray(v []int32)` + +SetPrefixArray gets a reference to the given []int32 and assigns it to the PrefixArray field. + +### GetPrefixWrappedArray + +`func (o *XmlItem) GetPrefixWrappedArray() []int32` + +GetPrefixWrappedArray returns the PrefixWrappedArray field if non-nil, zero value otherwise. + +### GetPrefixWrappedArrayOk + +`func (o *XmlItem) GetPrefixWrappedArrayOk() ([]int32, bool)` + +GetPrefixWrappedArrayOk returns a tuple with the PrefixWrappedArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixWrappedArray + +`func (o *XmlItem) HasPrefixWrappedArray() bool` + +HasPrefixWrappedArray returns a boolean if a field has been set. + +### SetPrefixWrappedArray + +`func (o *XmlItem) SetPrefixWrappedArray(v []int32)` + +SetPrefixWrappedArray gets a reference to the given []int32 and assigns it to the PrefixWrappedArray field. + +### GetNamespaceString + +`func (o *XmlItem) GetNamespaceString() string` + +GetNamespaceString returns the NamespaceString field if non-nil, zero value otherwise. + +### GetNamespaceStringOk + +`func (o *XmlItem) GetNamespaceStringOk() (string, bool)` + +GetNamespaceStringOk returns a tuple with the NamespaceString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceString + +`func (o *XmlItem) HasNamespaceString() bool` + +HasNamespaceString returns a boolean if a field has been set. + +### SetNamespaceString + +`func (o *XmlItem) SetNamespaceString(v string)` + +SetNamespaceString gets a reference to the given string and assigns it to the NamespaceString field. + +### GetNamespaceNumber + +`func (o *XmlItem) GetNamespaceNumber() float32` + +GetNamespaceNumber returns the NamespaceNumber field if non-nil, zero value otherwise. + +### GetNamespaceNumberOk + +`func (o *XmlItem) GetNamespaceNumberOk() (float32, bool)` + +GetNamespaceNumberOk returns a tuple with the NamespaceNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceNumber + +`func (o *XmlItem) HasNamespaceNumber() bool` + +HasNamespaceNumber returns a boolean if a field has been set. + +### SetNamespaceNumber + +`func (o *XmlItem) SetNamespaceNumber(v float32)` + +SetNamespaceNumber gets a reference to the given float32 and assigns it to the NamespaceNumber field. + +### GetNamespaceInteger + +`func (o *XmlItem) GetNamespaceInteger() int32` + +GetNamespaceInteger returns the NamespaceInteger field if non-nil, zero value otherwise. + +### GetNamespaceIntegerOk + +`func (o *XmlItem) GetNamespaceIntegerOk() (int32, bool)` + +GetNamespaceIntegerOk returns a tuple with the NamespaceInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceInteger + +`func (o *XmlItem) HasNamespaceInteger() bool` + +HasNamespaceInteger returns a boolean if a field has been set. + +### SetNamespaceInteger + +`func (o *XmlItem) SetNamespaceInteger(v int32)` + +SetNamespaceInteger gets a reference to the given int32 and assigns it to the NamespaceInteger field. + +### GetNamespaceBoolean + +`func (o *XmlItem) GetNamespaceBoolean() bool` + +GetNamespaceBoolean returns the NamespaceBoolean field if non-nil, zero value otherwise. + +### GetNamespaceBooleanOk + +`func (o *XmlItem) GetNamespaceBooleanOk() (bool, bool)` + +GetNamespaceBooleanOk returns a tuple with the NamespaceBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceBoolean + +`func (o *XmlItem) HasNamespaceBoolean() bool` + +HasNamespaceBoolean returns a boolean if a field has been set. + +### SetNamespaceBoolean + +`func (o *XmlItem) SetNamespaceBoolean(v bool)` + +SetNamespaceBoolean gets a reference to the given bool and assigns it to the NamespaceBoolean field. + +### GetNamespaceArray + +`func (o *XmlItem) GetNamespaceArray() []int32` + +GetNamespaceArray returns the NamespaceArray field if non-nil, zero value otherwise. + +### GetNamespaceArrayOk + +`func (o *XmlItem) GetNamespaceArrayOk() ([]int32, bool)` + +GetNamespaceArrayOk returns a tuple with the NamespaceArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceArray + +`func (o *XmlItem) HasNamespaceArray() bool` + +HasNamespaceArray returns a boolean if a field has been set. + +### SetNamespaceArray + +`func (o *XmlItem) SetNamespaceArray(v []int32)` + +SetNamespaceArray gets a reference to the given []int32 and assigns it to the NamespaceArray field. + +### GetNamespaceWrappedArray + +`func (o *XmlItem) GetNamespaceWrappedArray() []int32` + +GetNamespaceWrappedArray returns the NamespaceWrappedArray field if non-nil, zero value otherwise. + +### GetNamespaceWrappedArrayOk + +`func (o *XmlItem) GetNamespaceWrappedArrayOk() ([]int32, bool)` + +GetNamespaceWrappedArrayOk returns a tuple with the NamespaceWrappedArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasNamespaceWrappedArray + +`func (o *XmlItem) HasNamespaceWrappedArray() bool` + +HasNamespaceWrappedArray returns a boolean if a field has been set. + +### SetNamespaceWrappedArray + +`func (o *XmlItem) SetNamespaceWrappedArray(v []int32)` + +SetNamespaceWrappedArray gets a reference to the given []int32 and assigns it to the NamespaceWrappedArray field. + +### GetPrefixNsString + +`func (o *XmlItem) GetPrefixNsString() string` + +GetPrefixNsString returns the PrefixNsString field if non-nil, zero value otherwise. + +### GetPrefixNsStringOk + +`func (o *XmlItem) GetPrefixNsStringOk() (string, bool)` + +GetPrefixNsStringOk returns a tuple with the PrefixNsString field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsString + +`func (o *XmlItem) HasPrefixNsString() bool` + +HasPrefixNsString returns a boolean if a field has been set. + +### SetPrefixNsString + +`func (o *XmlItem) SetPrefixNsString(v string)` + +SetPrefixNsString gets a reference to the given string and assigns it to the PrefixNsString field. + +### GetPrefixNsNumber + +`func (o *XmlItem) GetPrefixNsNumber() float32` + +GetPrefixNsNumber returns the PrefixNsNumber field if non-nil, zero value otherwise. + +### GetPrefixNsNumberOk + +`func (o *XmlItem) GetPrefixNsNumberOk() (float32, bool)` + +GetPrefixNsNumberOk returns a tuple with the PrefixNsNumber field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsNumber + +`func (o *XmlItem) HasPrefixNsNumber() bool` + +HasPrefixNsNumber returns a boolean if a field has been set. + +### SetPrefixNsNumber + +`func (o *XmlItem) SetPrefixNsNumber(v float32)` + +SetPrefixNsNumber gets a reference to the given float32 and assigns it to the PrefixNsNumber field. + +### GetPrefixNsInteger + +`func (o *XmlItem) GetPrefixNsInteger() int32` + +GetPrefixNsInteger returns the PrefixNsInteger field if non-nil, zero value otherwise. + +### GetPrefixNsIntegerOk + +`func (o *XmlItem) GetPrefixNsIntegerOk() (int32, bool)` + +GetPrefixNsIntegerOk returns a tuple with the PrefixNsInteger field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsInteger + +`func (o *XmlItem) HasPrefixNsInteger() bool` + +HasPrefixNsInteger returns a boolean if a field has been set. + +### SetPrefixNsInteger + +`func (o *XmlItem) SetPrefixNsInteger(v int32)` + +SetPrefixNsInteger gets a reference to the given int32 and assigns it to the PrefixNsInteger field. + +### GetPrefixNsBoolean + +`func (o *XmlItem) GetPrefixNsBoolean() bool` + +GetPrefixNsBoolean returns the PrefixNsBoolean field if non-nil, zero value otherwise. + +### GetPrefixNsBooleanOk + +`func (o *XmlItem) GetPrefixNsBooleanOk() (bool, bool)` + +GetPrefixNsBooleanOk returns a tuple with the PrefixNsBoolean field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsBoolean + +`func (o *XmlItem) HasPrefixNsBoolean() bool` + +HasPrefixNsBoolean returns a boolean if a field has been set. + +### SetPrefixNsBoolean + +`func (o *XmlItem) SetPrefixNsBoolean(v bool)` + +SetPrefixNsBoolean gets a reference to the given bool and assigns it to the PrefixNsBoolean field. + +### GetPrefixNsArray + +`func (o *XmlItem) GetPrefixNsArray() []int32` + +GetPrefixNsArray returns the PrefixNsArray field if non-nil, zero value otherwise. + +### GetPrefixNsArrayOk + +`func (o *XmlItem) GetPrefixNsArrayOk() ([]int32, bool)` + +GetPrefixNsArrayOk returns a tuple with the PrefixNsArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsArray + +`func (o *XmlItem) HasPrefixNsArray() bool` + +HasPrefixNsArray returns a boolean if a field has been set. + +### SetPrefixNsArray + +`func (o *XmlItem) SetPrefixNsArray(v []int32)` + +SetPrefixNsArray gets a reference to the given []int32 and assigns it to the PrefixNsArray field. + +### GetPrefixNsWrappedArray + +`func (o *XmlItem) GetPrefixNsWrappedArray() []int32` + +GetPrefixNsWrappedArray returns the PrefixNsWrappedArray field if non-nil, zero value otherwise. + +### GetPrefixNsWrappedArrayOk + +`func (o *XmlItem) GetPrefixNsWrappedArrayOk() ([]int32, bool)` + +GetPrefixNsWrappedArrayOk returns a tuple with the PrefixNsWrappedArray field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### HasPrefixNsWrappedArray + +`func (o *XmlItem) HasPrefixNsWrappedArray() bool` + +HasPrefixNsWrappedArray returns a boolean if a field has been set. + +### SetPrefixNsWrappedArray + +`func (o *XmlItem) SetPrefixNsWrappedArray(v []int32)` + +SetPrefixNsWrappedArray gets a reference to the given []int32 and assigns it to the PrefixNsWrappedArray field. + [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/go-experimental/go-petstore/model_200_response.go b/samples/client/petstore/go-experimental/go-petstore/model_200_response.go index f918cabaaa..97ced8c6d1 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_200_response.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_200_response.go @@ -8,9 +8,94 @@ */ package petstore +import ( + "encoding/json" +) // Model for testing model name starting with number type Model200Response struct { - Name int32 `json:"name,omitempty"` - Class string `json:"class,omitempty"` + Name *int32 `json:"name,omitempty"` + + Class *string `json:"class,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *Model200Response) GetName() int32 { + if o == nil || o.Name == nil { + var ret int32 + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Model200Response) GetNameOk() (int32, bool) { + if o == nil || o.Name == nil { + var ret int32 + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Model200Response) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given int32 and assigns it to the Name field. +func (o *Model200Response) SetName(v int32) { + o.Name = &v +} + +// GetClass returns the Class field if non-nil, zero value otherwise. +func (o *Model200Response) GetClass() string { + if o == nil || o.Class == nil { + var ret string + return ret + } + return *o.Class +} + +// GetClassOk returns a tuple with the Class field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Model200Response) GetClassOk() (string, bool) { + if o == nil || o.Class == nil { + var ret string + return ret, false + } + return *o.Class, true +} + +// HasClass returns a boolean if a field has been set. +func (o *Model200Response) HasClass() bool { + if o != nil && o.Class != nil { + return true + } + + return false +} + +// SetClass gets a reference to the given string and assigns it to the Class field. +func (o *Model200Response) SetClass(v string) { + o.Class = &v +} + + +func (o Model200Response) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + if o.Class != nil { + toSerialize["class"] = o.Class + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_any_type.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_any_type.go index ca06584a72..baa81b92e5 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_any_type.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_any_type.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesAnyType struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesAnyType) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesAnyType) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesAnyType) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesAnyType) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesAnyType) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_array.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_array.go index 2e71585506..0ccbf37442 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_array.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_array.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesArray struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesArray) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesArray) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesArray) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesArray) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesArray) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_boolean.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_boolean.go index 09f1ac3b32..efa95a8767 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_boolean.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_boolean.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesBoolean struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesBoolean) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesBoolean) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesBoolean) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesBoolean) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesBoolean) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_class.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_class.go index 2e1845e194..534148d11d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_class.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_class.go @@ -8,17 +8,435 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesClass struct { - MapString map[string]string `json:"map_string,omitempty"` - MapNumber map[string]float32 `json:"map_number,omitempty"` - MapInteger map[string]int32 `json:"map_integer,omitempty"` - MapBoolean map[string]bool `json:"map_boolean,omitempty"` - MapArrayInteger map[string][]int32 `json:"map_array_integer,omitempty"` - MapArrayAnytype map[string][]map[string]interface{} `json:"map_array_anytype,omitempty"` - MapMapString map[string]map[string]string `json:"map_map_string,omitempty"` - MapMapAnytype map[string]map[string]map[string]interface{} `json:"map_map_anytype,omitempty"` - Anytype1 map[string]interface{} `json:"anytype_1,omitempty"` - Anytype2 map[string]interface{} `json:"anytype_2,omitempty"` - Anytype3 map[string]interface{} `json:"anytype_3,omitempty"` + MapString *map[string]string `json:"map_string,omitempty"` + + MapNumber *map[string]float32 `json:"map_number,omitempty"` + + MapInteger *map[string]int32 `json:"map_integer,omitempty"` + + MapBoolean *map[string]bool `json:"map_boolean,omitempty"` + + MapArrayInteger *map[string][]int32 `json:"map_array_integer,omitempty"` + + MapArrayAnytype *map[string][]map[string]interface{} `json:"map_array_anytype,omitempty"` + + MapMapString *map[string]map[string]string `json:"map_map_string,omitempty"` + + MapMapAnytype *map[string]map[string]map[string]interface{} `json:"map_map_anytype,omitempty"` + + Anytype1 *map[string]interface{} `json:"anytype_1,omitempty"` + + Anytype2 *map[string]interface{} `json:"anytype_2,omitempty"` + + Anytype3 *map[string]interface{} `json:"anytype_3,omitempty"` + } + +// GetMapString returns the MapString field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapString() map[string]string { + if o == nil || o.MapString == nil { + var ret map[string]string + return ret + } + return *o.MapString +} + +// GetMapStringOk returns a tuple with the MapString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapStringOk() (map[string]string, bool) { + if o == nil || o.MapString == nil { + var ret map[string]string + return ret, false + } + return *o.MapString, true +} + +// HasMapString returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapString() bool { + if o != nil && o.MapString != nil { + return true + } + + return false +} + +// SetMapString gets a reference to the given map[string]string and assigns it to the MapString field. +func (o *AdditionalPropertiesClass) SetMapString(v map[string]string) { + o.MapString = &v +} + +// GetMapNumber returns the MapNumber field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapNumber() map[string]float32 { + if o == nil || o.MapNumber == nil { + var ret map[string]float32 + return ret + } + return *o.MapNumber +} + +// GetMapNumberOk returns a tuple with the MapNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapNumberOk() (map[string]float32, bool) { + if o == nil || o.MapNumber == nil { + var ret map[string]float32 + return ret, false + } + return *o.MapNumber, true +} + +// HasMapNumber returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapNumber() bool { + if o != nil && o.MapNumber != nil { + return true + } + + return false +} + +// SetMapNumber gets a reference to the given map[string]float32 and assigns it to the MapNumber field. +func (o *AdditionalPropertiesClass) SetMapNumber(v map[string]float32) { + o.MapNumber = &v +} + +// GetMapInteger returns the MapInteger field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapInteger() map[string]int32 { + if o == nil || o.MapInteger == nil { + var ret map[string]int32 + return ret + } + return *o.MapInteger +} + +// GetMapIntegerOk returns a tuple with the MapInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapIntegerOk() (map[string]int32, bool) { + if o == nil || o.MapInteger == nil { + var ret map[string]int32 + return ret, false + } + return *o.MapInteger, true +} + +// HasMapInteger returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapInteger() bool { + if o != nil && o.MapInteger != nil { + return true + } + + return false +} + +// SetMapInteger gets a reference to the given map[string]int32 and assigns it to the MapInteger field. +func (o *AdditionalPropertiesClass) SetMapInteger(v map[string]int32) { + o.MapInteger = &v +} + +// GetMapBoolean returns the MapBoolean field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapBoolean() map[string]bool { + if o == nil || o.MapBoolean == nil { + var ret map[string]bool + return ret + } + return *o.MapBoolean +} + +// GetMapBooleanOk returns a tuple with the MapBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapBooleanOk() (map[string]bool, bool) { + if o == nil || o.MapBoolean == nil { + var ret map[string]bool + return ret, false + } + return *o.MapBoolean, true +} + +// HasMapBoolean returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapBoolean() bool { + if o != nil && o.MapBoolean != nil { + return true + } + + return false +} + +// SetMapBoolean gets a reference to the given map[string]bool and assigns it to the MapBoolean field. +func (o *AdditionalPropertiesClass) SetMapBoolean(v map[string]bool) { + o.MapBoolean = &v +} + +// GetMapArrayInteger returns the MapArrayInteger field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapArrayInteger() map[string][]int32 { + if o == nil || o.MapArrayInteger == nil { + var ret map[string][]int32 + return ret + } + return *o.MapArrayInteger +} + +// GetMapArrayIntegerOk returns a tuple with the MapArrayInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapArrayIntegerOk() (map[string][]int32, bool) { + if o == nil || o.MapArrayInteger == nil { + var ret map[string][]int32 + return ret, false + } + return *o.MapArrayInteger, true +} + +// HasMapArrayInteger returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapArrayInteger() bool { + if o != nil && o.MapArrayInteger != nil { + return true + } + + return false +} + +// SetMapArrayInteger gets a reference to the given map[string][]int32 and assigns it to the MapArrayInteger field. +func (o *AdditionalPropertiesClass) SetMapArrayInteger(v map[string][]int32) { + o.MapArrayInteger = &v +} + +// GetMapArrayAnytype returns the MapArrayAnytype field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapArrayAnytype() map[string][]map[string]interface{} { + if o == nil || o.MapArrayAnytype == nil { + var ret map[string][]map[string]interface{} + return ret + } + return *o.MapArrayAnytype +} + +// GetMapArrayAnytypeOk returns a tuple with the MapArrayAnytype field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapArrayAnytypeOk() (map[string][]map[string]interface{}, bool) { + if o == nil || o.MapArrayAnytype == nil { + var ret map[string][]map[string]interface{} + return ret, false + } + return *o.MapArrayAnytype, true +} + +// HasMapArrayAnytype returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapArrayAnytype() bool { + if o != nil && o.MapArrayAnytype != nil { + return true + } + + return false +} + +// SetMapArrayAnytype gets a reference to the given map[string][]map[string]interface{} and assigns it to the MapArrayAnytype field. +func (o *AdditionalPropertiesClass) SetMapArrayAnytype(v map[string][]map[string]interface{}) { + o.MapArrayAnytype = &v +} + +// GetMapMapString returns the MapMapString field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapMapString() map[string]map[string]string { + if o == nil || o.MapMapString == nil { + var ret map[string]map[string]string + return ret + } + return *o.MapMapString +} + +// GetMapMapStringOk returns a tuple with the MapMapString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapMapStringOk() (map[string]map[string]string, bool) { + if o == nil || o.MapMapString == nil { + var ret map[string]map[string]string + return ret, false + } + return *o.MapMapString, true +} + +// HasMapMapString returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapMapString() bool { + if o != nil && o.MapMapString != nil { + return true + } + + return false +} + +// SetMapMapString gets a reference to the given map[string]map[string]string and assigns it to the MapMapString field. +func (o *AdditionalPropertiesClass) SetMapMapString(v map[string]map[string]string) { + o.MapMapString = &v +} + +// GetMapMapAnytype returns the MapMapAnytype field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetMapMapAnytype() map[string]map[string]map[string]interface{} { + if o == nil || o.MapMapAnytype == nil { + var ret map[string]map[string]map[string]interface{} + return ret + } + return *o.MapMapAnytype +} + +// GetMapMapAnytypeOk returns a tuple with the MapMapAnytype field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetMapMapAnytypeOk() (map[string]map[string]map[string]interface{}, bool) { + if o == nil || o.MapMapAnytype == nil { + var ret map[string]map[string]map[string]interface{} + return ret, false + } + return *o.MapMapAnytype, true +} + +// HasMapMapAnytype returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasMapMapAnytype() bool { + if o != nil && o.MapMapAnytype != nil { + return true + } + + return false +} + +// SetMapMapAnytype gets a reference to the given map[string]map[string]map[string]interface{} and assigns it to the MapMapAnytype field. +func (o *AdditionalPropertiesClass) SetMapMapAnytype(v map[string]map[string]map[string]interface{}) { + o.MapMapAnytype = &v +} + +// GetAnytype1 returns the Anytype1 field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetAnytype1() map[string]interface{} { + if o == nil || o.Anytype1 == nil { + var ret map[string]interface{} + return ret + } + return *o.Anytype1 +} + +// GetAnytype1Ok returns a tuple with the Anytype1 field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetAnytype1Ok() (map[string]interface{}, bool) { + if o == nil || o.Anytype1 == nil { + var ret map[string]interface{} + return ret, false + } + return *o.Anytype1, true +} + +// HasAnytype1 returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasAnytype1() bool { + if o != nil && o.Anytype1 != nil { + return true + } + + return false +} + +// SetAnytype1 gets a reference to the given map[string]interface{} and assigns it to the Anytype1 field. +func (o *AdditionalPropertiesClass) SetAnytype1(v map[string]interface{}) { + o.Anytype1 = &v +} + +// GetAnytype2 returns the Anytype2 field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetAnytype2() map[string]interface{} { + if o == nil || o.Anytype2 == nil { + var ret map[string]interface{} + return ret + } + return *o.Anytype2 +} + +// GetAnytype2Ok returns a tuple with the Anytype2 field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetAnytype2Ok() (map[string]interface{}, bool) { + if o == nil || o.Anytype2 == nil { + var ret map[string]interface{} + return ret, false + } + return *o.Anytype2, true +} + +// HasAnytype2 returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasAnytype2() bool { + if o != nil && o.Anytype2 != nil { + return true + } + + return false +} + +// SetAnytype2 gets a reference to the given map[string]interface{} and assigns it to the Anytype2 field. +func (o *AdditionalPropertiesClass) SetAnytype2(v map[string]interface{}) { + o.Anytype2 = &v +} + +// GetAnytype3 returns the Anytype3 field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesClass) GetAnytype3() map[string]interface{} { + if o == nil || o.Anytype3 == nil { + var ret map[string]interface{} + return ret + } + return *o.Anytype3 +} + +// GetAnytype3Ok returns a tuple with the Anytype3 field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesClass) GetAnytype3Ok() (map[string]interface{}, bool) { + if o == nil || o.Anytype3 == nil { + var ret map[string]interface{} + return ret, false + } + return *o.Anytype3, true +} + +// HasAnytype3 returns a boolean if a field has been set. +func (o *AdditionalPropertiesClass) HasAnytype3() bool { + if o != nil && o.Anytype3 != nil { + return true + } + + return false +} + +// SetAnytype3 gets a reference to the given map[string]interface{} and assigns it to the Anytype3 field. +func (o *AdditionalPropertiesClass) SetAnytype3(v map[string]interface{}) { + o.Anytype3 = &v +} + + +func (o AdditionalPropertiesClass) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.MapString != nil { + toSerialize["map_string"] = o.MapString + } + if o.MapNumber != nil { + toSerialize["map_number"] = o.MapNumber + } + if o.MapInteger != nil { + toSerialize["map_integer"] = o.MapInteger + } + if o.MapBoolean != nil { + toSerialize["map_boolean"] = o.MapBoolean + } + if o.MapArrayInteger != nil { + toSerialize["map_array_integer"] = o.MapArrayInteger + } + if o.MapArrayAnytype != nil { + toSerialize["map_array_anytype"] = o.MapArrayAnytype + } + if o.MapMapString != nil { + toSerialize["map_map_string"] = o.MapMapString + } + if o.MapMapAnytype != nil { + toSerialize["map_map_anytype"] = o.MapMapAnytype + } + if o.Anytype1 != nil { + toSerialize["anytype_1"] = o.Anytype1 + } + if o.Anytype2 != nil { + toSerialize["anytype_2"] = o.Anytype2 + } + if o.Anytype3 != nil { + toSerialize["anytype_3"] = o.Anytype3 + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_integer.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_integer.go index 2f69fe4b01..05dea42d51 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_integer.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_integer.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesInteger struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesInteger) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesInteger) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesInteger) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesInteger) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesInteger) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_number.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_number.go index 900b2ec32c..484c9d79ad 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_number.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_number.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesNumber struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesNumber) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesNumber) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesNumber) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesNumber) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesNumber) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_object.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_object.go index 99fa6d02fd..0482ad8ef1 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_object.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_object.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesObject struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesObject) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesObject) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesObject) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesObject) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesObject) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_string.go b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_string.go index 82fe0e4ed3..561cd08191 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_string.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_additional_properties_string.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type AdditionalPropertiesString struct { - Name string `json:"name,omitempty"` + Name *string `json:"name,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *AdditionalPropertiesString) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *AdditionalPropertiesString) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AdditionalPropertiesString) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AdditionalPropertiesString) SetName(v string) { + o.Name = &v +} + + +func (o AdditionalPropertiesString) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_animal.go b/samples/client/petstore/go-experimental/go-petstore/model_animal.go index 39d0d2d1ec..897cac1f45 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_animal.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_animal.go @@ -8,8 +8,97 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type Animal struct { - ClassName string `json:"className"` - Color string `json:"color,omitempty"` + ClassName *string `json:"className,omitempty"` + + Color *string `json:"color,omitempty"` + } + +// GetClassName returns the ClassName field if non-nil, zero value otherwise. +func (o *Animal) GetClassName() string { + if o == nil || o.ClassName == nil { + var ret string + return ret + } + return *o.ClassName +} + +// GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Animal) GetClassNameOk() (string, bool) { + if o == nil || o.ClassName == nil { + var ret string + return ret, false + } + return *o.ClassName, true +} + +// HasClassName returns a boolean if a field has been set. +func (o *Animal) HasClassName() bool { + if o != nil && o.ClassName != nil { + return true + } + + return false +} + +// SetClassName gets a reference to the given string and assigns it to the ClassName field. +func (o *Animal) SetClassName(v string) { + o.ClassName = &v +} + +// GetColor returns the Color field if non-nil, zero value otherwise. +func (o *Animal) GetColor() string { + if o == nil || o.Color == nil { + var ret string + return ret + } + return *o.Color +} + +// GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Animal) GetColorOk() (string, bool) { + if o == nil || o.Color == nil { + var ret string + return ret, false + } + return *o.Color, true +} + +// HasColor returns a boolean if a field has been set. +func (o *Animal) HasColor() bool { + if o != nil && o.Color != nil { + return true + } + + return false +} + +// SetColor gets a reference to the given string and assigns it to the Color field. +func (o *Animal) SetColor(v string) { + o.Color = &v +} + + +func (o Animal) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClassName == nil { + return nil, errors.New("ClassName is required and not nullable, but was not set on Animal") + } + if o.ClassName != nil { + toSerialize["className"] = o.ClassName + } + if o.Color != nil { + toSerialize["color"] = o.Color + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_api_response.go b/samples/client/petstore/go-experimental/go-petstore/model_api_response.go index 12732fa32c..009e991072 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_api_response.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_api_response.go @@ -8,9 +8,131 @@ */ package petstore +import ( + "encoding/json" +) type ApiResponse struct { - Code int32 `json:"code,omitempty"` - Type string `json:"type,omitempty"` - Message string `json:"message,omitempty"` + Code *int32 `json:"code,omitempty"` + + Type *string `json:"type,omitempty"` + + Message *string `json:"message,omitempty"` + } + +// GetCode returns the Code field if non-nil, zero value otherwise. +func (o *ApiResponse) GetCode() int32 { + if o == nil || o.Code == nil { + var ret int32 + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ApiResponse) GetCodeOk() (int32, bool) { + if o == nil || o.Code == nil { + var ret int32 + return ret, false + } + return *o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *ApiResponse) HasCode() bool { + if o != nil && o.Code != nil { + return true + } + + return false +} + +// SetCode gets a reference to the given int32 and assigns it to the Code field. +func (o *ApiResponse) SetCode(v int32) { + o.Code = &v +} + +// GetType returns the Type field if non-nil, zero value otherwise. +func (o *ApiResponse) GetType() string { + if o == nil || o.Type == nil { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ApiResponse) GetTypeOk() (string, bool) { + if o == nil || o.Type == nil { + var ret string + return ret, false + } + return *o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *ApiResponse) HasType() bool { + if o != nil && o.Type != nil { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *ApiResponse) SetType(v string) { + o.Type = &v +} + +// GetMessage returns the Message field if non-nil, zero value otherwise. +func (o *ApiResponse) GetMessage() string { + if o == nil || o.Message == nil { + var ret string + return ret + } + return *o.Message +} + +// GetMessageOk returns a tuple with the Message field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ApiResponse) GetMessageOk() (string, bool) { + if o == nil || o.Message == nil { + var ret string + return ret, false + } + return *o.Message, true +} + +// HasMessage returns a boolean if a field has been set. +func (o *ApiResponse) HasMessage() bool { + if o != nil && o.Message != nil { + return true + } + + return false +} + +// SetMessage gets a reference to the given string and assigns it to the Message field. +func (o *ApiResponse) SetMessage(v string) { + o.Message = &v +} + + +func (o ApiResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Code != nil { + toSerialize["code"] = o.Code + } + if o.Type != nil { + toSerialize["type"] = o.Type + } + if o.Message != nil { + toSerialize["message"] = o.Message + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_array_of_array_of_number_only.go b/samples/client/petstore/go-experimental/go-petstore/model_array_of_array_of_number_only.go index 8bf700c7eb..aadebc92a4 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_array_of_array_of_number_only.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_array_of_array_of_number_only.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type ArrayOfArrayOfNumberOnly struct { - ArrayArrayNumber [][]float32 `json:"ArrayArrayNumber,omitempty"` + ArrayArrayNumber *[][]float32 `json:"ArrayArrayNumber,omitempty"` + } + +// GetArrayArrayNumber returns the ArrayArrayNumber field if non-nil, zero value otherwise. +func (o *ArrayOfArrayOfNumberOnly) GetArrayArrayNumber() [][]float32 { + if o == nil || o.ArrayArrayNumber == nil { + var ret [][]float32 + return ret + } + return *o.ArrayArrayNumber +} + +// GetArrayArrayNumberOk returns a tuple with the ArrayArrayNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ArrayOfArrayOfNumberOnly) GetArrayArrayNumberOk() ([][]float32, bool) { + if o == nil || o.ArrayArrayNumber == nil { + var ret [][]float32 + return ret, false + } + return *o.ArrayArrayNumber, true +} + +// HasArrayArrayNumber returns a boolean if a field has been set. +func (o *ArrayOfArrayOfNumberOnly) HasArrayArrayNumber() bool { + if o != nil && o.ArrayArrayNumber != nil { + return true + } + + return false +} + +// SetArrayArrayNumber gets a reference to the given [][]float32 and assigns it to the ArrayArrayNumber field. +func (o *ArrayOfArrayOfNumberOnly) SetArrayArrayNumber(v [][]float32) { + o.ArrayArrayNumber = &v +} + + +func (o ArrayOfArrayOfNumberOnly) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ArrayArrayNumber != nil { + toSerialize["ArrayArrayNumber"] = o.ArrayArrayNumber + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_array_of_number_only.go b/samples/client/petstore/go-experimental/go-petstore/model_array_of_number_only.go index ccb473355c..418a07d7d6 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_array_of_number_only.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_array_of_number_only.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type ArrayOfNumberOnly struct { - ArrayNumber []float32 `json:"ArrayNumber,omitempty"` + ArrayNumber *[]float32 `json:"ArrayNumber,omitempty"` + } + +// GetArrayNumber returns the ArrayNumber field if non-nil, zero value otherwise. +func (o *ArrayOfNumberOnly) GetArrayNumber() []float32 { + if o == nil || o.ArrayNumber == nil { + var ret []float32 + return ret + } + return *o.ArrayNumber +} + +// GetArrayNumberOk returns a tuple with the ArrayNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ArrayOfNumberOnly) GetArrayNumberOk() ([]float32, bool) { + if o == nil || o.ArrayNumber == nil { + var ret []float32 + return ret, false + } + return *o.ArrayNumber, true +} + +// HasArrayNumber returns a boolean if a field has been set. +func (o *ArrayOfNumberOnly) HasArrayNumber() bool { + if o != nil && o.ArrayNumber != nil { + return true + } + + return false +} + +// SetArrayNumber gets a reference to the given []float32 and assigns it to the ArrayNumber field. +func (o *ArrayOfNumberOnly) SetArrayNumber(v []float32) { + o.ArrayNumber = &v +} + + +func (o ArrayOfNumberOnly) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ArrayNumber != nil { + toSerialize["ArrayNumber"] = o.ArrayNumber + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_array_test_.go b/samples/client/petstore/go-experimental/go-petstore/model_array_test_.go index f881980093..8fa143ded8 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_array_test_.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_array_test_.go @@ -8,9 +8,131 @@ */ package petstore +import ( + "encoding/json" +) type ArrayTest struct { - ArrayOfString []string `json:"array_of_string,omitempty"` - ArrayArrayOfInteger [][]int64 `json:"array_array_of_integer,omitempty"` - ArrayArrayOfModel [][]ReadOnlyFirst `json:"array_array_of_model,omitempty"` + ArrayOfString *[]string `json:"array_of_string,omitempty"` + + ArrayArrayOfInteger *[][]int64 `json:"array_array_of_integer,omitempty"` + + ArrayArrayOfModel *[][]ReadOnlyFirst `json:"array_array_of_model,omitempty"` + } + +// GetArrayOfString returns the ArrayOfString field if non-nil, zero value otherwise. +func (o *ArrayTest) GetArrayOfString() []string { + if o == nil || o.ArrayOfString == nil { + var ret []string + return ret + } + return *o.ArrayOfString +} + +// GetArrayOfStringOk returns a tuple with the ArrayOfString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ArrayTest) GetArrayOfStringOk() ([]string, bool) { + if o == nil || o.ArrayOfString == nil { + var ret []string + return ret, false + } + return *o.ArrayOfString, true +} + +// HasArrayOfString returns a boolean if a field has been set. +func (o *ArrayTest) HasArrayOfString() bool { + if o != nil && o.ArrayOfString != nil { + return true + } + + return false +} + +// SetArrayOfString gets a reference to the given []string and assigns it to the ArrayOfString field. +func (o *ArrayTest) SetArrayOfString(v []string) { + o.ArrayOfString = &v +} + +// GetArrayArrayOfInteger returns the ArrayArrayOfInteger field if non-nil, zero value otherwise. +func (o *ArrayTest) GetArrayArrayOfInteger() [][]int64 { + if o == nil || o.ArrayArrayOfInteger == nil { + var ret [][]int64 + return ret + } + return *o.ArrayArrayOfInteger +} + +// GetArrayArrayOfIntegerOk returns a tuple with the ArrayArrayOfInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ArrayTest) GetArrayArrayOfIntegerOk() ([][]int64, bool) { + if o == nil || o.ArrayArrayOfInteger == nil { + var ret [][]int64 + return ret, false + } + return *o.ArrayArrayOfInteger, true +} + +// HasArrayArrayOfInteger returns a boolean if a field has been set. +func (o *ArrayTest) HasArrayArrayOfInteger() bool { + if o != nil && o.ArrayArrayOfInteger != nil { + return true + } + + return false +} + +// SetArrayArrayOfInteger gets a reference to the given [][]int64 and assigns it to the ArrayArrayOfInteger field. +func (o *ArrayTest) SetArrayArrayOfInteger(v [][]int64) { + o.ArrayArrayOfInteger = &v +} + +// GetArrayArrayOfModel returns the ArrayArrayOfModel field if non-nil, zero value otherwise. +func (o *ArrayTest) GetArrayArrayOfModel() [][]ReadOnlyFirst { + if o == nil || o.ArrayArrayOfModel == nil { + var ret [][]ReadOnlyFirst + return ret + } + return *o.ArrayArrayOfModel +} + +// GetArrayArrayOfModelOk returns a tuple with the ArrayArrayOfModel field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ArrayTest) GetArrayArrayOfModelOk() ([][]ReadOnlyFirst, bool) { + if o == nil || o.ArrayArrayOfModel == nil { + var ret [][]ReadOnlyFirst + return ret, false + } + return *o.ArrayArrayOfModel, true +} + +// HasArrayArrayOfModel returns a boolean if a field has been set. +func (o *ArrayTest) HasArrayArrayOfModel() bool { + if o != nil && o.ArrayArrayOfModel != nil { + return true + } + + return false +} + +// SetArrayArrayOfModel gets a reference to the given [][]ReadOnlyFirst and assigns it to the ArrayArrayOfModel field. +func (o *ArrayTest) SetArrayArrayOfModel(v [][]ReadOnlyFirst) { + o.ArrayArrayOfModel = &v +} + + +func (o ArrayTest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ArrayOfString != nil { + toSerialize["array_of_string"] = o.ArrayOfString + } + if o.ArrayArrayOfInteger != nil { + toSerialize["array_array_of_integer"] = o.ArrayArrayOfInteger + } + if o.ArrayArrayOfModel != nil { + toSerialize["array_array_of_model"] = o.ArrayArrayOfModel + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_capitalization.go b/samples/client/petstore/go-experimental/go-petstore/model_capitalization.go index 8284ba9c76..107dd7932e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_capitalization.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_capitalization.go @@ -8,13 +8,246 @@ */ package petstore +import ( + "encoding/json" +) type Capitalization struct { - SmallCamel string `json:"smallCamel,omitempty"` - CapitalCamel string `json:"CapitalCamel,omitempty"` - SmallSnake string `json:"small_Snake,omitempty"` - CapitalSnake string `json:"Capital_Snake,omitempty"` - SCAETHFlowPoints string `json:"SCA_ETH_Flow_Points,omitempty"` + SmallCamel *string `json:"smallCamel,omitempty"` + + CapitalCamel *string `json:"CapitalCamel,omitempty"` + + SmallSnake *string `json:"small_Snake,omitempty"` + + CapitalSnake *string `json:"Capital_Snake,omitempty"` + + SCAETHFlowPoints *string `json:"SCA_ETH_Flow_Points,omitempty"` + // Name of the pet - ATT_NAME string `json:"ATT_NAME,omitempty"` + ATT_NAME *string `json:"ATT_NAME,omitempty"` + } + +// GetSmallCamel returns the SmallCamel field if non-nil, zero value otherwise. +func (o *Capitalization) GetSmallCamel() string { + if o == nil || o.SmallCamel == nil { + var ret string + return ret + } + return *o.SmallCamel +} + +// GetSmallCamelOk returns a tuple with the SmallCamel field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetSmallCamelOk() (string, bool) { + if o == nil || o.SmallCamel == nil { + var ret string + return ret, false + } + return *o.SmallCamel, true +} + +// HasSmallCamel returns a boolean if a field has been set. +func (o *Capitalization) HasSmallCamel() bool { + if o != nil && o.SmallCamel != nil { + return true + } + + return false +} + +// SetSmallCamel gets a reference to the given string and assigns it to the SmallCamel field. +func (o *Capitalization) SetSmallCamel(v string) { + o.SmallCamel = &v +} + +// GetCapitalCamel returns the CapitalCamel field if non-nil, zero value otherwise. +func (o *Capitalization) GetCapitalCamel() string { + if o == nil || o.CapitalCamel == nil { + var ret string + return ret + } + return *o.CapitalCamel +} + +// GetCapitalCamelOk returns a tuple with the CapitalCamel field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetCapitalCamelOk() (string, bool) { + if o == nil || o.CapitalCamel == nil { + var ret string + return ret, false + } + return *o.CapitalCamel, true +} + +// HasCapitalCamel returns a boolean if a field has been set. +func (o *Capitalization) HasCapitalCamel() bool { + if o != nil && o.CapitalCamel != nil { + return true + } + + return false +} + +// SetCapitalCamel gets a reference to the given string and assigns it to the CapitalCamel field. +func (o *Capitalization) SetCapitalCamel(v string) { + o.CapitalCamel = &v +} + +// GetSmallSnake returns the SmallSnake field if non-nil, zero value otherwise. +func (o *Capitalization) GetSmallSnake() string { + if o == nil || o.SmallSnake == nil { + var ret string + return ret + } + return *o.SmallSnake +} + +// GetSmallSnakeOk returns a tuple with the SmallSnake field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetSmallSnakeOk() (string, bool) { + if o == nil || o.SmallSnake == nil { + var ret string + return ret, false + } + return *o.SmallSnake, true +} + +// HasSmallSnake returns a boolean if a field has been set. +func (o *Capitalization) HasSmallSnake() bool { + if o != nil && o.SmallSnake != nil { + return true + } + + return false +} + +// SetSmallSnake gets a reference to the given string and assigns it to the SmallSnake field. +func (o *Capitalization) SetSmallSnake(v string) { + o.SmallSnake = &v +} + +// GetCapitalSnake returns the CapitalSnake field if non-nil, zero value otherwise. +func (o *Capitalization) GetCapitalSnake() string { + if o == nil || o.CapitalSnake == nil { + var ret string + return ret + } + return *o.CapitalSnake +} + +// GetCapitalSnakeOk returns a tuple with the CapitalSnake field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetCapitalSnakeOk() (string, bool) { + if o == nil || o.CapitalSnake == nil { + var ret string + return ret, false + } + return *o.CapitalSnake, true +} + +// HasCapitalSnake returns a boolean if a field has been set. +func (o *Capitalization) HasCapitalSnake() bool { + if o != nil && o.CapitalSnake != nil { + return true + } + + return false +} + +// SetCapitalSnake gets a reference to the given string and assigns it to the CapitalSnake field. +func (o *Capitalization) SetCapitalSnake(v string) { + o.CapitalSnake = &v +} + +// GetSCAETHFlowPoints returns the SCAETHFlowPoints field if non-nil, zero value otherwise. +func (o *Capitalization) GetSCAETHFlowPoints() string { + if o == nil || o.SCAETHFlowPoints == nil { + var ret string + return ret + } + return *o.SCAETHFlowPoints +} + +// GetSCAETHFlowPointsOk returns a tuple with the SCAETHFlowPoints field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetSCAETHFlowPointsOk() (string, bool) { + if o == nil || o.SCAETHFlowPoints == nil { + var ret string + return ret, false + } + return *o.SCAETHFlowPoints, true +} + +// HasSCAETHFlowPoints returns a boolean if a field has been set. +func (o *Capitalization) HasSCAETHFlowPoints() bool { + if o != nil && o.SCAETHFlowPoints != nil { + return true + } + + return false +} + +// SetSCAETHFlowPoints gets a reference to the given string and assigns it to the SCAETHFlowPoints field. +func (o *Capitalization) SetSCAETHFlowPoints(v string) { + o.SCAETHFlowPoints = &v +} + +// GetATT_NAME returns the ATT_NAME field if non-nil, zero value otherwise. +func (o *Capitalization) GetATT_NAME() string { + if o == nil || o.ATT_NAME == nil { + var ret string + return ret + } + return *o.ATT_NAME +} + +// GetATT_NAMEOk returns a tuple with the ATT_NAME field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Capitalization) GetATT_NAMEOk() (string, bool) { + if o == nil || o.ATT_NAME == nil { + var ret string + return ret, false + } + return *o.ATT_NAME, true +} + +// HasATT_NAME returns a boolean if a field has been set. +func (o *Capitalization) HasATT_NAME() bool { + if o != nil && o.ATT_NAME != nil { + return true + } + + return false +} + +// SetATT_NAME gets a reference to the given string and assigns it to the ATT_NAME field. +func (o *Capitalization) SetATT_NAME(v string) { + o.ATT_NAME = &v +} + + +func (o Capitalization) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SmallCamel != nil { + toSerialize["smallCamel"] = o.SmallCamel + } + if o.CapitalCamel != nil { + toSerialize["CapitalCamel"] = o.CapitalCamel + } + if o.SmallSnake != nil { + toSerialize["small_Snake"] = o.SmallSnake + } + if o.CapitalSnake != nil { + toSerialize["Capital_Snake"] = o.CapitalSnake + } + if o.SCAETHFlowPoints != nil { + toSerialize["SCA_ETH_Flow_Points"] = o.SCAETHFlowPoints + } + if o.ATT_NAME != nil { + toSerialize["ATT_NAME"] = o.ATT_NAME + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_cat.go b/samples/client/petstore/go-experimental/go-petstore/model_cat.go index 58b3deeb93..8efbf58fd1 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_cat.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_cat.go @@ -8,9 +8,135 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type Cat struct { - ClassName string `json:"className"` - Color string `json:"color,omitempty"` - Declawed bool `json:"declawed,omitempty"` + ClassName *string `json:"className,omitempty"` + + Color *string `json:"color,omitempty"` + + Declawed *bool `json:"declawed,omitempty"` + } + +// GetClassName returns the ClassName field if non-nil, zero value otherwise. +func (o *Cat) GetClassName() string { + if o == nil || o.ClassName == nil { + var ret string + return ret + } + return *o.ClassName +} + +// GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Cat) GetClassNameOk() (string, bool) { + if o == nil || o.ClassName == nil { + var ret string + return ret, false + } + return *o.ClassName, true +} + +// HasClassName returns a boolean if a field has been set. +func (o *Cat) HasClassName() bool { + if o != nil && o.ClassName != nil { + return true + } + + return false +} + +// SetClassName gets a reference to the given string and assigns it to the ClassName field. +func (o *Cat) SetClassName(v string) { + o.ClassName = &v +} + +// GetColor returns the Color field if non-nil, zero value otherwise. +func (o *Cat) GetColor() string { + if o == nil || o.Color == nil { + var ret string + return ret + } + return *o.Color +} + +// GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Cat) GetColorOk() (string, bool) { + if o == nil || o.Color == nil { + var ret string + return ret, false + } + return *o.Color, true +} + +// HasColor returns a boolean if a field has been set. +func (o *Cat) HasColor() bool { + if o != nil && o.Color != nil { + return true + } + + return false +} + +// SetColor gets a reference to the given string and assigns it to the Color field. +func (o *Cat) SetColor(v string) { + o.Color = &v +} + +// GetDeclawed returns the Declawed field if non-nil, zero value otherwise. +func (o *Cat) GetDeclawed() bool { + if o == nil || o.Declawed == nil { + var ret bool + return ret + } + return *o.Declawed +} + +// GetDeclawedOk returns a tuple with the Declawed field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Cat) GetDeclawedOk() (bool, bool) { + if o == nil || o.Declawed == nil { + var ret bool + return ret, false + } + return *o.Declawed, true +} + +// HasDeclawed returns a boolean if a field has been set. +func (o *Cat) HasDeclawed() bool { + if o != nil && o.Declawed != nil { + return true + } + + return false +} + +// SetDeclawed gets a reference to the given bool and assigns it to the Declawed field. +func (o *Cat) SetDeclawed(v bool) { + o.Declawed = &v +} + + +func (o Cat) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClassName == nil { + return nil, errors.New("ClassName is required and not nullable, but was not set on Cat") + } + if o.ClassName != nil { + toSerialize["className"] = o.ClassName + } + if o.Color != nil { + toSerialize["color"] = o.Color + } + if o.Declawed != nil { + toSerialize["declawed"] = o.Declawed + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_cat_all_of.go b/samples/client/petstore/go-experimental/go-petstore/model_cat_all_of.go index 3c1d802bd4..aaf2c8badb 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_cat_all_of.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_cat_all_of.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type CatAllOf struct { - Declawed bool `json:"declawed,omitempty"` + Declawed *bool `json:"declawed,omitempty"` + } + +// GetDeclawed returns the Declawed field if non-nil, zero value otherwise. +func (o *CatAllOf) GetDeclawed() bool { + if o == nil || o.Declawed == nil { + var ret bool + return ret + } + return *o.Declawed +} + +// GetDeclawedOk returns a tuple with the Declawed field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *CatAllOf) GetDeclawedOk() (bool, bool) { + if o == nil || o.Declawed == nil { + var ret bool + return ret, false + } + return *o.Declawed, true +} + +// HasDeclawed returns a boolean if a field has been set. +func (o *CatAllOf) HasDeclawed() bool { + if o != nil && o.Declawed != nil { + return true + } + + return false +} + +// SetDeclawed gets a reference to the given bool and assigns it to the Declawed field. +func (o *CatAllOf) SetDeclawed(v bool) { + o.Declawed = &v +} + + +func (o CatAllOf) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Declawed != nil { + toSerialize["declawed"] = o.Declawed + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_category.go b/samples/client/petstore/go-experimental/go-petstore/model_category.go index 2f971417ac..c55d4bd6e9 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_category.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_category.go @@ -8,8 +8,97 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type Category struct { - Id int64 `json:"id,omitempty"` - Name string `json:"name"` + Id *int64 `json:"id,omitempty"` + + Name *string `json:"name,omitempty"` + } + +// GetId returns the Id field if non-nil, zero value otherwise. +func (o *Category) GetId() int64 { + if o == nil || o.Id == nil { + var ret int64 + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetIdOk() (int64, bool) { + if o == nil || o.Id == nil { + var ret int64 + return ret, false + } + return *o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Category) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given int64 and assigns it to the Id field. +func (o *Category) SetId(v int64) { + o.Id = &v +} + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *Category) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Category) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *Category) SetName(v string) { + o.Name = &v +} + + +func (o Category) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Id != nil { + toSerialize["id"] = o.Id + } + if o.Name == nil { + return nil, errors.New("Name is required and not nullable, but was not set on Category") + } + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_class_model.go b/samples/client/petstore/go-experimental/go-petstore/model_class_model.go index 09c7e89196..0dcaa26431 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_class_model.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_class_model.go @@ -8,8 +8,56 @@ */ package petstore +import ( + "encoding/json" +) // Model for testing model with \"_class\" property type ClassModel struct { - Class string `json:"_class,omitempty"` + Class *string `json:"_class,omitempty"` + } + +// GetClass returns the Class field if non-nil, zero value otherwise. +func (o *ClassModel) GetClass() string { + if o == nil || o.Class == nil { + var ret string + return ret + } + return *o.Class +} + +// GetClassOk returns a tuple with the Class field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ClassModel) GetClassOk() (string, bool) { + if o == nil || o.Class == nil { + var ret string + return ret, false + } + return *o.Class, true +} + +// HasClass returns a boolean if a field has been set. +func (o *ClassModel) HasClass() bool { + if o != nil && o.Class != nil { + return true + } + + return false +} + +// SetClass gets a reference to the given string and assigns it to the Class field. +func (o *ClassModel) SetClass(v string) { + o.Class = &v +} + + +func (o ClassModel) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Class != nil { + toSerialize["_class"] = o.Class + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_client.go b/samples/client/petstore/go-experimental/go-petstore/model_client.go index 3aa61112c4..72ebd54300 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_client.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_client.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type Client struct { - Client string `json:"client,omitempty"` + Client *string `json:"client,omitempty"` + } + +// GetClient returns the Client field if non-nil, zero value otherwise. +func (o *Client) GetClient() string { + if o == nil || o.Client == nil { + var ret string + return ret + } + return *o.Client +} + +// GetClientOk returns a tuple with the Client field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Client) GetClientOk() (string, bool) { + if o == nil || o.Client == nil { + var ret string + return ret, false + } + return *o.Client, true +} + +// HasClient returns a boolean if a field has been set. +func (o *Client) HasClient() bool { + if o != nil && o.Client != nil { + return true + } + + return false +} + +// SetClient gets a reference to the given string and assigns it to the Client field. +func (o *Client) SetClient(v string) { + o.Client = &v +} + + +func (o Client) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Client != nil { + toSerialize["client"] = o.Client + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_dog.go b/samples/client/petstore/go-experimental/go-petstore/model_dog.go index 3f791ca194..dd9c4e1d67 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_dog.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_dog.go @@ -8,9 +8,135 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type Dog struct { - ClassName string `json:"className"` - Color string `json:"color,omitempty"` - Breed string `json:"breed,omitempty"` + ClassName *string `json:"className,omitempty"` + + Color *string `json:"color,omitempty"` + + Breed *string `json:"breed,omitempty"` + } + +// GetClassName returns the ClassName field if non-nil, zero value otherwise. +func (o *Dog) GetClassName() string { + if o == nil || o.ClassName == nil { + var ret string + return ret + } + return *o.ClassName +} + +// GetClassNameOk returns a tuple with the ClassName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Dog) GetClassNameOk() (string, bool) { + if o == nil || o.ClassName == nil { + var ret string + return ret, false + } + return *o.ClassName, true +} + +// HasClassName returns a boolean if a field has been set. +func (o *Dog) HasClassName() bool { + if o != nil && o.ClassName != nil { + return true + } + + return false +} + +// SetClassName gets a reference to the given string and assigns it to the ClassName field. +func (o *Dog) SetClassName(v string) { + o.ClassName = &v +} + +// GetColor returns the Color field if non-nil, zero value otherwise. +func (o *Dog) GetColor() string { + if o == nil || o.Color == nil { + var ret string + return ret + } + return *o.Color +} + +// GetColorOk returns a tuple with the Color field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Dog) GetColorOk() (string, bool) { + if o == nil || o.Color == nil { + var ret string + return ret, false + } + return *o.Color, true +} + +// HasColor returns a boolean if a field has been set. +func (o *Dog) HasColor() bool { + if o != nil && o.Color != nil { + return true + } + + return false +} + +// SetColor gets a reference to the given string and assigns it to the Color field. +func (o *Dog) SetColor(v string) { + o.Color = &v +} + +// GetBreed returns the Breed field if non-nil, zero value otherwise. +func (o *Dog) GetBreed() string { + if o == nil || o.Breed == nil { + var ret string + return ret + } + return *o.Breed +} + +// GetBreedOk returns a tuple with the Breed field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Dog) GetBreedOk() (string, bool) { + if o == nil || o.Breed == nil { + var ret string + return ret, false + } + return *o.Breed, true +} + +// HasBreed returns a boolean if a field has been set. +func (o *Dog) HasBreed() bool { + if o != nil && o.Breed != nil { + return true + } + + return false +} + +// SetBreed gets a reference to the given string and assigns it to the Breed field. +func (o *Dog) SetBreed(v string) { + o.Breed = &v +} + + +func (o Dog) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClassName == nil { + return nil, errors.New("ClassName is required and not nullable, but was not set on Dog") + } + if o.ClassName != nil { + toSerialize["className"] = o.ClassName + } + if o.Color != nil { + toSerialize["color"] = o.Color + } + if o.Breed != nil { + toSerialize["breed"] = o.Breed + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_dog_all_of.go b/samples/client/petstore/go-experimental/go-petstore/model_dog_all_of.go index a0db0aba4b..9dd6d964f0 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_dog_all_of.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_dog_all_of.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type DogAllOf struct { - Breed string `json:"breed,omitempty"` + Breed *string `json:"breed,omitempty"` + } + +// GetBreed returns the Breed field if non-nil, zero value otherwise. +func (o *DogAllOf) GetBreed() string { + if o == nil || o.Breed == nil { + var ret string + return ret + } + return *o.Breed +} + +// GetBreedOk returns a tuple with the Breed field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *DogAllOf) GetBreedOk() (string, bool) { + if o == nil || o.Breed == nil { + var ret string + return ret, false + } + return *o.Breed, true +} + +// HasBreed returns a boolean if a field has been set. +func (o *DogAllOf) HasBreed() bool { + if o != nil && o.Breed != nil { + return true + } + + return false +} + +// SetBreed gets a reference to the given string and assigns it to the Breed field. +func (o *DogAllOf) SetBreed(v string) { + o.Breed = &v +} + + +func (o DogAllOf) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Breed != nil { + toSerialize["breed"] = o.Breed + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_enum_arrays.go b/samples/client/petstore/go-experimental/go-petstore/model_enum_arrays.go index ab4dce92eb..b52471416a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_enum_arrays.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_enum_arrays.go @@ -8,8 +8,93 @@ */ package petstore +import ( + "encoding/json" +) type EnumArrays struct { - JustSymbol string `json:"just_symbol,omitempty"` - ArrayEnum []string `json:"array_enum,omitempty"` + JustSymbol *string `json:"just_symbol,omitempty"` + + ArrayEnum *[]string `json:"array_enum,omitempty"` + } + +// GetJustSymbol returns the JustSymbol field if non-nil, zero value otherwise. +func (o *EnumArrays) GetJustSymbol() string { + if o == nil || o.JustSymbol == nil { + var ret string + return ret + } + return *o.JustSymbol +} + +// GetJustSymbolOk returns a tuple with the JustSymbol field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumArrays) GetJustSymbolOk() (string, bool) { + if o == nil || o.JustSymbol == nil { + var ret string + return ret, false + } + return *o.JustSymbol, true +} + +// HasJustSymbol returns a boolean if a field has been set. +func (o *EnumArrays) HasJustSymbol() bool { + if o != nil && o.JustSymbol != nil { + return true + } + + return false +} + +// SetJustSymbol gets a reference to the given string and assigns it to the JustSymbol field. +func (o *EnumArrays) SetJustSymbol(v string) { + o.JustSymbol = &v +} + +// GetArrayEnum returns the ArrayEnum field if non-nil, zero value otherwise. +func (o *EnumArrays) GetArrayEnum() []string { + if o == nil || o.ArrayEnum == nil { + var ret []string + return ret + } + return *o.ArrayEnum +} + +// GetArrayEnumOk returns a tuple with the ArrayEnum field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumArrays) GetArrayEnumOk() ([]string, bool) { + if o == nil || o.ArrayEnum == nil { + var ret []string + return ret, false + } + return *o.ArrayEnum, true +} + +// HasArrayEnum returns a boolean if a field has been set. +func (o *EnumArrays) HasArrayEnum() bool { + if o != nil && o.ArrayEnum != nil { + return true + } + + return false +} + +// SetArrayEnum gets a reference to the given []string and assigns it to the ArrayEnum field. +func (o *EnumArrays) SetArrayEnum(v []string) { + o.ArrayEnum = &v +} + + +func (o EnumArrays) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.JustSymbol != nil { + toSerialize["just_symbol"] = o.JustSymbol + } + if o.ArrayEnum != nil { + toSerialize["array_enum"] = o.ArrayEnum + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_enum_class.go b/samples/client/petstore/go-experimental/go-petstore/model_enum_class.go index 534ce43288..b52d109542 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_enum_class.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_enum_class.go @@ -15,4 +15,5 @@ const ( ABC EnumClass = "_abc" EFG EnumClass = "-efg" XYZ EnumClass = "(xyz)" -) \ No newline at end of file +) + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_enum_test_.go b/samples/client/petstore/go-experimental/go-petstore/model_enum_test_.go index f85f31501a..1e9f8a449e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_enum_test_.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_enum_test_.go @@ -8,11 +8,211 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type EnumTest struct { - EnumString string `json:"enum_string,omitempty"` - EnumStringRequired string `json:"enum_string_required"` - EnumInteger int32 `json:"enum_integer,omitempty"` - EnumNumber float64 `json:"enum_number,omitempty"` - OuterEnum OuterEnum `json:"outerEnum,omitempty"` + EnumString *string `json:"enum_string,omitempty"` + + EnumStringRequired *string `json:"enum_string_required,omitempty"` + + EnumInteger *int32 `json:"enum_integer,omitempty"` + + EnumNumber *float64 `json:"enum_number,omitempty"` + + OuterEnum *OuterEnum `json:"outerEnum,omitempty"` + } + +// GetEnumString returns the EnumString field if non-nil, zero value otherwise. +func (o *EnumTest) GetEnumString() string { + if o == nil || o.EnumString == nil { + var ret string + return ret + } + return *o.EnumString +} + +// GetEnumStringOk returns a tuple with the EnumString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumTest) GetEnumStringOk() (string, bool) { + if o == nil || o.EnumString == nil { + var ret string + return ret, false + } + return *o.EnumString, true +} + +// HasEnumString returns a boolean if a field has been set. +func (o *EnumTest) HasEnumString() bool { + if o != nil && o.EnumString != nil { + return true + } + + return false +} + +// SetEnumString gets a reference to the given string and assigns it to the EnumString field. +func (o *EnumTest) SetEnumString(v string) { + o.EnumString = &v +} + +// GetEnumStringRequired returns the EnumStringRequired field if non-nil, zero value otherwise. +func (o *EnumTest) GetEnumStringRequired() string { + if o == nil || o.EnumStringRequired == nil { + var ret string + return ret + } + return *o.EnumStringRequired +} + +// GetEnumStringRequiredOk returns a tuple with the EnumStringRequired field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumTest) GetEnumStringRequiredOk() (string, bool) { + if o == nil || o.EnumStringRequired == nil { + var ret string + return ret, false + } + return *o.EnumStringRequired, true +} + +// HasEnumStringRequired returns a boolean if a field has been set. +func (o *EnumTest) HasEnumStringRequired() bool { + if o != nil && o.EnumStringRequired != nil { + return true + } + + return false +} + +// SetEnumStringRequired gets a reference to the given string and assigns it to the EnumStringRequired field. +func (o *EnumTest) SetEnumStringRequired(v string) { + o.EnumStringRequired = &v +} + +// GetEnumInteger returns the EnumInteger field if non-nil, zero value otherwise. +func (o *EnumTest) GetEnumInteger() int32 { + if o == nil || o.EnumInteger == nil { + var ret int32 + return ret + } + return *o.EnumInteger +} + +// GetEnumIntegerOk returns a tuple with the EnumInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumTest) GetEnumIntegerOk() (int32, bool) { + if o == nil || o.EnumInteger == nil { + var ret int32 + return ret, false + } + return *o.EnumInteger, true +} + +// HasEnumInteger returns a boolean if a field has been set. +func (o *EnumTest) HasEnumInteger() bool { + if o != nil && o.EnumInteger != nil { + return true + } + + return false +} + +// SetEnumInteger gets a reference to the given int32 and assigns it to the EnumInteger field. +func (o *EnumTest) SetEnumInteger(v int32) { + o.EnumInteger = &v +} + +// GetEnumNumber returns the EnumNumber field if non-nil, zero value otherwise. +func (o *EnumTest) GetEnumNumber() float64 { + if o == nil || o.EnumNumber == nil { + var ret float64 + return ret + } + return *o.EnumNumber +} + +// GetEnumNumberOk returns a tuple with the EnumNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumTest) GetEnumNumberOk() (float64, bool) { + if o == nil || o.EnumNumber == nil { + var ret float64 + return ret, false + } + return *o.EnumNumber, true +} + +// HasEnumNumber returns a boolean if a field has been set. +func (o *EnumTest) HasEnumNumber() bool { + if o != nil && o.EnumNumber != nil { + return true + } + + return false +} + +// SetEnumNumber gets a reference to the given float64 and assigns it to the EnumNumber field. +func (o *EnumTest) SetEnumNumber(v float64) { + o.EnumNumber = &v +} + +// GetOuterEnum returns the OuterEnum field if non-nil, zero value otherwise. +func (o *EnumTest) GetOuterEnum() OuterEnum { + if o == nil || o.OuterEnum == nil { + var ret OuterEnum + return ret + } + return *o.OuterEnum +} + +// GetOuterEnumOk returns a tuple with the OuterEnum field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *EnumTest) GetOuterEnumOk() (OuterEnum, bool) { + if o == nil || o.OuterEnum == nil { + var ret OuterEnum + return ret, false + } + return *o.OuterEnum, true +} + +// HasOuterEnum returns a boolean if a field has been set. +func (o *EnumTest) HasOuterEnum() bool { + if o != nil && o.OuterEnum != nil { + return true + } + + return false +} + +// SetOuterEnum gets a reference to the given OuterEnum and assigns it to the OuterEnum field. +func (o *EnumTest) SetOuterEnum(v OuterEnum) { + o.OuterEnum = &v +} + + +func (o EnumTest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.EnumString != nil { + toSerialize["enum_string"] = o.EnumString + } + if o.EnumStringRequired == nil { + return nil, errors.New("EnumStringRequired is required and not nullable, but was not set on EnumTest") + } + if o.EnumStringRequired != nil { + toSerialize["enum_string_required"] = o.EnumStringRequired + } + if o.EnumInteger != nil { + toSerialize["enum_integer"] = o.EnumInteger + } + if o.EnumNumber != nil { + toSerialize["enum_number"] = o.EnumNumber + } + if o.OuterEnum != nil { + toSerialize["outerEnum"] = o.OuterEnum + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_file.go b/samples/client/petstore/go-experimental/go-petstore/model_file.go index 2782ccc9a2..4968739ef4 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_file.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_file.go @@ -8,9 +8,57 @@ */ package petstore +import ( + "encoding/json" +) // Must be named `File` for test. type File struct { // Test capitalization - SourceURI string `json:"sourceURI,omitempty"` + SourceURI *string `json:"sourceURI,omitempty"` + } + +// GetSourceURI returns the SourceURI field if non-nil, zero value otherwise. +func (o *File) GetSourceURI() string { + if o == nil || o.SourceURI == nil { + var ret string + return ret + } + return *o.SourceURI +} + +// GetSourceURIOk returns a tuple with the SourceURI field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *File) GetSourceURIOk() (string, bool) { + if o == nil || o.SourceURI == nil { + var ret string + return ret, false + } + return *o.SourceURI, true +} + +// HasSourceURI returns a boolean if a field has been set. +func (o *File) HasSourceURI() bool { + if o != nil && o.SourceURI != nil { + return true + } + + return false +} + +// SetSourceURI gets a reference to the given string and assigns it to the SourceURI field. +func (o *File) SetSourceURI(v string) { + o.SourceURI = &v +} + + +func (o File) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SourceURI != nil { + toSerialize["sourceURI"] = o.SourceURI + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_file_schema_test_class.go b/samples/client/petstore/go-experimental/go-petstore/model_file_schema_test_class.go index 487f766c64..16cd67f29d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_file_schema_test_class.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_file_schema_test_class.go @@ -8,8 +8,93 @@ */ package petstore +import ( + "encoding/json" +) type FileSchemaTestClass struct { - File File `json:"file,omitempty"` - Files []File `json:"files,omitempty"` + File *File `json:"file,omitempty"` + + Files *[]File `json:"files,omitempty"` + } + +// GetFile returns the File field if non-nil, zero value otherwise. +func (o *FileSchemaTestClass) GetFile() File { + if o == nil || o.File == nil { + var ret File + return ret + } + return *o.File +} + +// GetFileOk returns a tuple with the File field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FileSchemaTestClass) GetFileOk() (File, bool) { + if o == nil || o.File == nil { + var ret File + return ret, false + } + return *o.File, true +} + +// HasFile returns a boolean if a field has been set. +func (o *FileSchemaTestClass) HasFile() bool { + if o != nil && o.File != nil { + return true + } + + return false +} + +// SetFile gets a reference to the given File and assigns it to the File field. +func (o *FileSchemaTestClass) SetFile(v File) { + o.File = &v +} + +// GetFiles returns the Files field if non-nil, zero value otherwise. +func (o *FileSchemaTestClass) GetFiles() []File { + if o == nil || o.Files == nil { + var ret []File + return ret + } + return *o.Files +} + +// GetFilesOk returns a tuple with the Files field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FileSchemaTestClass) GetFilesOk() ([]File, bool) { + if o == nil || o.Files == nil { + var ret []File + return ret, false + } + return *o.Files, true +} + +// HasFiles returns a boolean if a field has been set. +func (o *FileSchemaTestClass) HasFiles() bool { + if o != nil && o.Files != nil { + return true + } + + return false +} + +// SetFiles gets a reference to the given []File and assigns it to the Files field. +func (o *FileSchemaTestClass) SetFiles(v []File) { + o.Files = &v +} + + +func (o FileSchemaTestClass) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.File != nil { + toSerialize["file"] = o.File + } + if o.Files != nil { + toSerialize["files"] = o.Files + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_format_test_.go b/samples/client/petstore/go-experimental/go-petstore/model_format_test_.go index d723bdfee3..5532e92477 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_format_test_.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_format_test_.go @@ -11,20 +11,523 @@ package petstore import ( "os" "time" + "encoding/json" + "errors" ) type FormatTest struct { - Integer int32 `json:"integer,omitempty"` - Int32 int32 `json:"int32,omitempty"` - Int64 int64 `json:"int64,omitempty"` - Number float32 `json:"number"` - Float float32 `json:"float,omitempty"` - Double float64 `json:"double,omitempty"` - String string `json:"string,omitempty"` - Byte string `json:"byte"` - Binary *os.File `json:"binary,omitempty"` - Date string `json:"date"` - DateTime time.Time `json:"dateTime,omitempty"` - Uuid string `json:"uuid,omitempty"` - Password string `json:"password"` + Integer *int32 `json:"integer,omitempty"` + + Int32 *int32 `json:"int32,omitempty"` + + Int64 *int64 `json:"int64,omitempty"` + + Number *float32 `json:"number,omitempty"` + + Float *float32 `json:"float,omitempty"` + + Double *float64 `json:"double,omitempty"` + + String *string `json:"string,omitempty"` + + Byte *string `json:"byte,omitempty"` + + Binary **os.File `json:"binary,omitempty"` + + Date *string `json:"date,omitempty"` + + DateTime *time.Time `json:"dateTime,omitempty"` + + Uuid *string `json:"uuid,omitempty"` + + Password *string `json:"password,omitempty"` + } + +// GetInteger returns the Integer field if non-nil, zero value otherwise. +func (o *FormatTest) GetInteger() int32 { + if o == nil || o.Integer == nil { + var ret int32 + return ret + } + return *o.Integer +} + +// GetIntegerOk returns a tuple with the Integer field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetIntegerOk() (int32, bool) { + if o == nil || o.Integer == nil { + var ret int32 + return ret, false + } + return *o.Integer, true +} + +// HasInteger returns a boolean if a field has been set. +func (o *FormatTest) HasInteger() bool { + if o != nil && o.Integer != nil { + return true + } + + return false +} + +// SetInteger gets a reference to the given int32 and assigns it to the Integer field. +func (o *FormatTest) SetInteger(v int32) { + o.Integer = &v +} + +// GetInt32 returns the Int32 field if non-nil, zero value otherwise. +func (o *FormatTest) GetInt32() int32 { + if o == nil || o.Int32 == nil { + var ret int32 + return ret + } + return *o.Int32 +} + +// GetInt32Ok returns a tuple with the Int32 field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetInt32Ok() (int32, bool) { + if o == nil || o.Int32 == nil { + var ret int32 + return ret, false + } + return *o.Int32, true +} + +// HasInt32 returns a boolean if a field has been set. +func (o *FormatTest) HasInt32() bool { + if o != nil && o.Int32 != nil { + return true + } + + return false +} + +// SetInt32 gets a reference to the given int32 and assigns it to the Int32 field. +func (o *FormatTest) SetInt32(v int32) { + o.Int32 = &v +} + +// GetInt64 returns the Int64 field if non-nil, zero value otherwise. +func (o *FormatTest) GetInt64() int64 { + if o == nil || o.Int64 == nil { + var ret int64 + return ret + } + return *o.Int64 +} + +// GetInt64Ok returns a tuple with the Int64 field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetInt64Ok() (int64, bool) { + if o == nil || o.Int64 == nil { + var ret int64 + return ret, false + } + return *o.Int64, true +} + +// HasInt64 returns a boolean if a field has been set. +func (o *FormatTest) HasInt64() bool { + if o != nil && o.Int64 != nil { + return true + } + + return false +} + +// SetInt64 gets a reference to the given int64 and assigns it to the Int64 field. +func (o *FormatTest) SetInt64(v int64) { + o.Int64 = &v +} + +// GetNumber returns the Number field if non-nil, zero value otherwise. +func (o *FormatTest) GetNumber() float32 { + if o == nil || o.Number == nil { + var ret float32 + return ret + } + return *o.Number +} + +// GetNumberOk returns a tuple with the Number field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetNumberOk() (float32, bool) { + if o == nil || o.Number == nil { + var ret float32 + return ret, false + } + return *o.Number, true +} + +// HasNumber returns a boolean if a field has been set. +func (o *FormatTest) HasNumber() bool { + if o != nil && o.Number != nil { + return true + } + + return false +} + +// SetNumber gets a reference to the given float32 and assigns it to the Number field. +func (o *FormatTest) SetNumber(v float32) { + o.Number = &v +} + +// GetFloat returns the Float field if non-nil, zero value otherwise. +func (o *FormatTest) GetFloat() float32 { + if o == nil || o.Float == nil { + var ret float32 + return ret + } + return *o.Float +} + +// GetFloatOk returns a tuple with the Float field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetFloatOk() (float32, bool) { + if o == nil || o.Float == nil { + var ret float32 + return ret, false + } + return *o.Float, true +} + +// HasFloat returns a boolean if a field has been set. +func (o *FormatTest) HasFloat() bool { + if o != nil && o.Float != nil { + return true + } + + return false +} + +// SetFloat gets a reference to the given float32 and assigns it to the Float field. +func (o *FormatTest) SetFloat(v float32) { + o.Float = &v +} + +// GetDouble returns the Double field if non-nil, zero value otherwise. +func (o *FormatTest) GetDouble() float64 { + if o == nil || o.Double == nil { + var ret float64 + return ret + } + return *o.Double +} + +// GetDoubleOk returns a tuple with the Double field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetDoubleOk() (float64, bool) { + if o == nil || o.Double == nil { + var ret float64 + return ret, false + } + return *o.Double, true +} + +// HasDouble returns a boolean if a field has been set. +func (o *FormatTest) HasDouble() bool { + if o != nil && o.Double != nil { + return true + } + + return false +} + +// SetDouble gets a reference to the given float64 and assigns it to the Double field. +func (o *FormatTest) SetDouble(v float64) { + o.Double = &v +} + +// GetString returns the String field if non-nil, zero value otherwise. +func (o *FormatTest) GetString() string { + if o == nil || o.String == nil { + var ret string + return ret + } + return *o.String +} + +// GetStringOk returns a tuple with the String field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetStringOk() (string, bool) { + if o == nil || o.String == nil { + var ret string + return ret, false + } + return *o.String, true +} + +// HasString returns a boolean if a field has been set. +func (o *FormatTest) HasString() bool { + if o != nil && o.String != nil { + return true + } + + return false +} + +// SetString gets a reference to the given string and assigns it to the String field. +func (o *FormatTest) SetString(v string) { + o.String = &v +} + +// GetByte returns the Byte field if non-nil, zero value otherwise. +func (o *FormatTest) GetByte() string { + if o == nil || o.Byte == nil { + var ret string + return ret + } + return *o.Byte +} + +// GetByteOk returns a tuple with the Byte field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetByteOk() (string, bool) { + if o == nil || o.Byte == nil { + var ret string + return ret, false + } + return *o.Byte, true +} + +// HasByte returns a boolean if a field has been set. +func (o *FormatTest) HasByte() bool { + if o != nil && o.Byte != nil { + return true + } + + return false +} + +// SetByte gets a reference to the given string and assigns it to the Byte field. +func (o *FormatTest) SetByte(v string) { + o.Byte = &v +} + +// GetBinary returns the Binary field if non-nil, zero value otherwise. +func (o *FormatTest) GetBinary() *os.File { + if o == nil || o.Binary == nil { + var ret *os.File + return ret + } + return *o.Binary +} + +// GetBinaryOk returns a tuple with the Binary field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetBinaryOk() (*os.File, bool) { + if o == nil || o.Binary == nil { + var ret *os.File + return ret, false + } + return *o.Binary, true +} + +// HasBinary returns a boolean if a field has been set. +func (o *FormatTest) HasBinary() bool { + if o != nil && o.Binary != nil { + return true + } + + return false +} + +// SetBinary gets a reference to the given *os.File and assigns it to the Binary field. +func (o *FormatTest) SetBinary(v *os.File) { + o.Binary = &v +} + +// GetDate returns the Date field if non-nil, zero value otherwise. +func (o *FormatTest) GetDate() string { + if o == nil || o.Date == nil { + var ret string + return ret + } + return *o.Date +} + +// GetDateOk returns a tuple with the Date field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetDateOk() (string, bool) { + if o == nil || o.Date == nil { + var ret string + return ret, false + } + return *o.Date, true +} + +// HasDate returns a boolean if a field has been set. +func (o *FormatTest) HasDate() bool { + if o != nil && o.Date != nil { + return true + } + + return false +} + +// SetDate gets a reference to the given string and assigns it to the Date field. +func (o *FormatTest) SetDate(v string) { + o.Date = &v +} + +// GetDateTime returns the DateTime field if non-nil, zero value otherwise. +func (o *FormatTest) GetDateTime() time.Time { + if o == nil || o.DateTime == nil { + var ret time.Time + return ret + } + return *o.DateTime +} + +// GetDateTimeOk returns a tuple with the DateTime field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetDateTimeOk() (time.Time, bool) { + if o == nil || o.DateTime == nil { + var ret time.Time + return ret, false + } + return *o.DateTime, true +} + +// HasDateTime returns a boolean if a field has been set. +func (o *FormatTest) HasDateTime() bool { + if o != nil && o.DateTime != nil { + return true + } + + return false +} + +// SetDateTime gets a reference to the given time.Time and assigns it to the DateTime field. +func (o *FormatTest) SetDateTime(v time.Time) { + o.DateTime = &v +} + +// GetUuid returns the Uuid field if non-nil, zero value otherwise. +func (o *FormatTest) GetUuid() string { + if o == nil || o.Uuid == nil { + var ret string + return ret + } + return *o.Uuid +} + +// GetUuidOk returns a tuple with the Uuid field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetUuidOk() (string, bool) { + if o == nil || o.Uuid == nil { + var ret string + return ret, false + } + return *o.Uuid, true +} + +// HasUuid returns a boolean if a field has been set. +func (o *FormatTest) HasUuid() bool { + if o != nil && o.Uuid != nil { + return true + } + + return false +} + +// SetUuid gets a reference to the given string and assigns it to the Uuid field. +func (o *FormatTest) SetUuid(v string) { + o.Uuid = &v +} + +// GetPassword returns the Password field if non-nil, zero value otherwise. +func (o *FormatTest) GetPassword() string { + if o == nil || o.Password == nil { + var ret string + return ret + } + return *o.Password +} + +// GetPasswordOk returns a tuple with the Password field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *FormatTest) GetPasswordOk() (string, bool) { + if o == nil || o.Password == nil { + var ret string + return ret, false + } + return *o.Password, true +} + +// HasPassword returns a boolean if a field has been set. +func (o *FormatTest) HasPassword() bool { + if o != nil && o.Password != nil { + return true + } + + return false +} + +// SetPassword gets a reference to the given string and assigns it to the Password field. +func (o *FormatTest) SetPassword(v string) { + o.Password = &v +} + + +func (o FormatTest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Integer != nil { + toSerialize["integer"] = o.Integer + } + if o.Int32 != nil { + toSerialize["int32"] = o.Int32 + } + if o.Int64 != nil { + toSerialize["int64"] = o.Int64 + } + if o.Number == nil { + return nil, errors.New("Number is required and not nullable, but was not set on FormatTest") + } + if o.Number != nil { + toSerialize["number"] = o.Number + } + if o.Float != nil { + toSerialize["float"] = o.Float + } + if o.Double != nil { + toSerialize["double"] = o.Double + } + if o.String != nil { + toSerialize["string"] = o.String + } + if o.Byte == nil { + return nil, errors.New("Byte is required and not nullable, but was not set on FormatTest") + } + if o.Byte != nil { + toSerialize["byte"] = o.Byte + } + if o.Binary != nil { + toSerialize["binary"] = o.Binary + } + if o.Date == nil { + return nil, errors.New("Date is required and not nullable, but was not set on FormatTest") + } + if o.Date != nil { + toSerialize["date"] = o.Date + } + if o.DateTime != nil { + toSerialize["dateTime"] = o.DateTime + } + if o.Uuid != nil { + toSerialize["uuid"] = o.Uuid + } + if o.Password == nil { + return nil, errors.New("Password is required and not nullable, but was not set on FormatTest") + } + if o.Password != nil { + toSerialize["password"] = o.Password + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_has_only_read_only.go b/samples/client/petstore/go-experimental/go-petstore/model_has_only_read_only.go index 1cf0e4f530..1b03286159 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_has_only_read_only.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_has_only_read_only.go @@ -8,8 +8,93 @@ */ package petstore +import ( + "encoding/json" +) type HasOnlyReadOnly struct { - Bar string `json:"bar,omitempty"` - Foo string `json:"foo,omitempty"` + Bar *string `json:"bar,omitempty"` + + Foo *string `json:"foo,omitempty"` + } + +// GetBar returns the Bar field if non-nil, zero value otherwise. +func (o *HasOnlyReadOnly) GetBar() string { + if o == nil || o.Bar == nil { + var ret string + return ret + } + return *o.Bar +} + +// GetBarOk returns a tuple with the Bar field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *HasOnlyReadOnly) GetBarOk() (string, bool) { + if o == nil || o.Bar == nil { + var ret string + return ret, false + } + return *o.Bar, true +} + +// HasBar returns a boolean if a field has been set. +func (o *HasOnlyReadOnly) HasBar() bool { + if o != nil && o.Bar != nil { + return true + } + + return false +} + +// SetBar gets a reference to the given string and assigns it to the Bar field. +func (o *HasOnlyReadOnly) SetBar(v string) { + o.Bar = &v +} + +// GetFoo returns the Foo field if non-nil, zero value otherwise. +func (o *HasOnlyReadOnly) GetFoo() string { + if o == nil || o.Foo == nil { + var ret string + return ret + } + return *o.Foo +} + +// GetFooOk returns a tuple with the Foo field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *HasOnlyReadOnly) GetFooOk() (string, bool) { + if o == nil || o.Foo == nil { + var ret string + return ret, false + } + return *o.Foo, true +} + +// HasFoo returns a boolean if a field has been set. +func (o *HasOnlyReadOnly) HasFoo() bool { + if o != nil && o.Foo != nil { + return true + } + + return false +} + +// SetFoo gets a reference to the given string and assigns it to the Foo field. +func (o *HasOnlyReadOnly) SetFoo(v string) { + o.Foo = &v +} + + +func (o HasOnlyReadOnly) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bar != nil { + toSerialize["bar"] = o.Bar + } + if o.Foo != nil { + toSerialize["foo"] = o.Foo + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_list.go b/samples/client/petstore/go-experimental/go-petstore/model_list.go index 12f3bd3f66..5c9d4df5c9 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_list.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_list.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type List struct { - Var123List string `json:"123-list,omitempty"` + Var123List *string `json:"123-list,omitempty"` + } + +// GetVar123List returns the Var123List field if non-nil, zero value otherwise. +func (o *List) GetVar123List() string { + if o == nil || o.Var123List == nil { + var ret string + return ret + } + return *o.Var123List +} + +// GetVar123ListOk returns a tuple with the Var123List field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *List) GetVar123ListOk() (string, bool) { + if o == nil || o.Var123List == nil { + var ret string + return ret, false + } + return *o.Var123List, true +} + +// HasVar123List returns a boolean if a field has been set. +func (o *List) HasVar123List() bool { + if o != nil && o.Var123List != nil { + return true + } + + return false +} + +// SetVar123List gets a reference to the given string and assigns it to the Var123List field. +func (o *List) SetVar123List(v string) { + o.Var123List = &v +} + + +func (o List) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Var123List != nil { + toSerialize["123-list"] = o.Var123List + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_map_test_.go b/samples/client/petstore/go-experimental/go-petstore/model_map_test_.go index 830e760fe3..3ae7b22b88 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_map_test_.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_map_test_.go @@ -8,10 +8,169 @@ */ package petstore +import ( + "encoding/json" +) type MapTest struct { - MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty"` - MapOfEnumString map[string]string `json:"map_of_enum_string,omitempty"` - DirectMap map[string]bool `json:"direct_map,omitempty"` - IndirectMap map[string]bool `json:"indirect_map,omitempty"` + MapMapOfString *map[string]map[string]string `json:"map_map_of_string,omitempty"` + + MapOfEnumString *map[string]string `json:"map_of_enum_string,omitempty"` + + DirectMap *map[string]bool `json:"direct_map,omitempty"` + + IndirectMap *map[string]bool `json:"indirect_map,omitempty"` + } + +// GetMapMapOfString returns the MapMapOfString field if non-nil, zero value otherwise. +func (o *MapTest) GetMapMapOfString() map[string]map[string]string { + if o == nil || o.MapMapOfString == nil { + var ret map[string]map[string]string + return ret + } + return *o.MapMapOfString +} + +// GetMapMapOfStringOk returns a tuple with the MapMapOfString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MapTest) GetMapMapOfStringOk() (map[string]map[string]string, bool) { + if o == nil || o.MapMapOfString == nil { + var ret map[string]map[string]string + return ret, false + } + return *o.MapMapOfString, true +} + +// HasMapMapOfString returns a boolean if a field has been set. +func (o *MapTest) HasMapMapOfString() bool { + if o != nil && o.MapMapOfString != nil { + return true + } + + return false +} + +// SetMapMapOfString gets a reference to the given map[string]map[string]string and assigns it to the MapMapOfString field. +func (o *MapTest) SetMapMapOfString(v map[string]map[string]string) { + o.MapMapOfString = &v +} + +// GetMapOfEnumString returns the MapOfEnumString field if non-nil, zero value otherwise. +func (o *MapTest) GetMapOfEnumString() map[string]string { + if o == nil || o.MapOfEnumString == nil { + var ret map[string]string + return ret + } + return *o.MapOfEnumString +} + +// GetMapOfEnumStringOk returns a tuple with the MapOfEnumString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MapTest) GetMapOfEnumStringOk() (map[string]string, bool) { + if o == nil || o.MapOfEnumString == nil { + var ret map[string]string + return ret, false + } + return *o.MapOfEnumString, true +} + +// HasMapOfEnumString returns a boolean if a field has been set. +func (o *MapTest) HasMapOfEnumString() bool { + if o != nil && o.MapOfEnumString != nil { + return true + } + + return false +} + +// SetMapOfEnumString gets a reference to the given map[string]string and assigns it to the MapOfEnumString field. +func (o *MapTest) SetMapOfEnumString(v map[string]string) { + o.MapOfEnumString = &v +} + +// GetDirectMap returns the DirectMap field if non-nil, zero value otherwise. +func (o *MapTest) GetDirectMap() map[string]bool { + if o == nil || o.DirectMap == nil { + var ret map[string]bool + return ret + } + return *o.DirectMap +} + +// GetDirectMapOk returns a tuple with the DirectMap field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MapTest) GetDirectMapOk() (map[string]bool, bool) { + if o == nil || o.DirectMap == nil { + var ret map[string]bool + return ret, false + } + return *o.DirectMap, true +} + +// HasDirectMap returns a boolean if a field has been set. +func (o *MapTest) HasDirectMap() bool { + if o != nil && o.DirectMap != nil { + return true + } + + return false +} + +// SetDirectMap gets a reference to the given map[string]bool and assigns it to the DirectMap field. +func (o *MapTest) SetDirectMap(v map[string]bool) { + o.DirectMap = &v +} + +// GetIndirectMap returns the IndirectMap field if non-nil, zero value otherwise. +func (o *MapTest) GetIndirectMap() map[string]bool { + if o == nil || o.IndirectMap == nil { + var ret map[string]bool + return ret + } + return *o.IndirectMap +} + +// GetIndirectMapOk returns a tuple with the IndirectMap field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MapTest) GetIndirectMapOk() (map[string]bool, bool) { + if o == nil || o.IndirectMap == nil { + var ret map[string]bool + return ret, false + } + return *o.IndirectMap, true +} + +// HasIndirectMap returns a boolean if a field has been set. +func (o *MapTest) HasIndirectMap() bool { + if o != nil && o.IndirectMap != nil { + return true + } + + return false +} + +// SetIndirectMap gets a reference to the given map[string]bool and assigns it to the IndirectMap field. +func (o *MapTest) SetIndirectMap(v map[string]bool) { + o.IndirectMap = &v +} + + +func (o MapTest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.MapMapOfString != nil { + toSerialize["map_map_of_string"] = o.MapMapOfString + } + if o.MapOfEnumString != nil { + toSerialize["map_of_enum_string"] = o.MapOfEnumString + } + if o.DirectMap != nil { + toSerialize["direct_map"] = o.DirectMap + } + if o.IndirectMap != nil { + toSerialize["indirect_map"] = o.IndirectMap + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_mixed_properties_and_additional_properties_class.go b/samples/client/petstore/go-experimental/go-petstore/model_mixed_properties_and_additional_properties_class.go index 0ad92e96f8..5dd3d1d020 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_mixed_properties_and_additional_properties_class.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_mixed_properties_and_additional_properties_class.go @@ -10,10 +10,130 @@ package petstore import ( "time" + "encoding/json" ) type MixedPropertiesAndAdditionalPropertiesClass struct { - Uuid string `json:"uuid,omitempty"` - DateTime time.Time `json:"dateTime,omitempty"` - Map map[string]Animal `json:"map,omitempty"` + Uuid *string `json:"uuid,omitempty"` + + DateTime *time.Time `json:"dateTime,omitempty"` + + Map *map[string]Animal `json:"map,omitempty"` + } + +// GetUuid returns the Uuid field if non-nil, zero value otherwise. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetUuid() string { + if o == nil || o.Uuid == nil { + var ret string + return ret + } + return *o.Uuid +} + +// GetUuidOk returns a tuple with the Uuid field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetUuidOk() (string, bool) { + if o == nil || o.Uuid == nil { + var ret string + return ret, false + } + return *o.Uuid, true +} + +// HasUuid returns a boolean if a field has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) HasUuid() bool { + if o != nil && o.Uuid != nil { + return true + } + + return false +} + +// SetUuid gets a reference to the given string and assigns it to the Uuid field. +func (o *MixedPropertiesAndAdditionalPropertiesClass) SetUuid(v string) { + o.Uuid = &v +} + +// GetDateTime returns the DateTime field if non-nil, zero value otherwise. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetDateTime() time.Time { + if o == nil || o.DateTime == nil { + var ret time.Time + return ret + } + return *o.DateTime +} + +// GetDateTimeOk returns a tuple with the DateTime field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetDateTimeOk() (time.Time, bool) { + if o == nil || o.DateTime == nil { + var ret time.Time + return ret, false + } + return *o.DateTime, true +} + +// HasDateTime returns a boolean if a field has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) HasDateTime() bool { + if o != nil && o.DateTime != nil { + return true + } + + return false +} + +// SetDateTime gets a reference to the given time.Time and assigns it to the DateTime field. +func (o *MixedPropertiesAndAdditionalPropertiesClass) SetDateTime(v time.Time) { + o.DateTime = &v +} + +// GetMap returns the Map field if non-nil, zero value otherwise. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetMap() map[string]Animal { + if o == nil || o.Map == nil { + var ret map[string]Animal + return ret + } + return *o.Map +} + +// GetMapOk returns a tuple with the Map field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) GetMapOk() (map[string]Animal, bool) { + if o == nil || o.Map == nil { + var ret map[string]Animal + return ret, false + } + return *o.Map, true +} + +// HasMap returns a boolean if a field has been set. +func (o *MixedPropertiesAndAdditionalPropertiesClass) HasMap() bool { + if o != nil && o.Map != nil { + return true + } + + return false +} + +// SetMap gets a reference to the given map[string]Animal and assigns it to the Map field. +func (o *MixedPropertiesAndAdditionalPropertiesClass) SetMap(v map[string]Animal) { + o.Map = &v +} + + +func (o MixedPropertiesAndAdditionalPropertiesClass) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Uuid != nil { + toSerialize["uuid"] = o.Uuid + } + if o.DateTime != nil { + toSerialize["dateTime"] = o.DateTime + } + if o.Map != nil { + toSerialize["map"] = o.Map + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_name.go b/samples/client/petstore/go-experimental/go-petstore/model_name.go index dde1b92eb6..1a0addae44 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_name.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_name.go @@ -8,11 +8,174 @@ */ package petstore +import ( + "encoding/json" + "errors" +) // Model for testing model name same as property name type Name struct { - Name int32 `json:"name"` - SnakeCase int32 `json:"snake_case,omitempty"` - Property string `json:"property,omitempty"` - Var123Number int32 `json:"123Number,omitempty"` + Name *int32 `json:"name,omitempty"` + + SnakeCase *int32 `json:"snake_case,omitempty"` + + Property *string `json:"property,omitempty"` + + Var123Number *int32 `json:"123Number,omitempty"` + } + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *Name) GetName() int32 { + if o == nil || o.Name == nil { + var ret int32 + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Name) GetNameOk() (int32, bool) { + if o == nil || o.Name == nil { + var ret int32 + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Name) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given int32 and assigns it to the Name field. +func (o *Name) SetName(v int32) { + o.Name = &v +} + +// GetSnakeCase returns the SnakeCase field if non-nil, zero value otherwise. +func (o *Name) GetSnakeCase() int32 { + if o == nil || o.SnakeCase == nil { + var ret int32 + return ret + } + return *o.SnakeCase +} + +// GetSnakeCaseOk returns a tuple with the SnakeCase field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Name) GetSnakeCaseOk() (int32, bool) { + if o == nil || o.SnakeCase == nil { + var ret int32 + return ret, false + } + return *o.SnakeCase, true +} + +// HasSnakeCase returns a boolean if a field has been set. +func (o *Name) HasSnakeCase() bool { + if o != nil && o.SnakeCase != nil { + return true + } + + return false +} + +// SetSnakeCase gets a reference to the given int32 and assigns it to the SnakeCase field. +func (o *Name) SetSnakeCase(v int32) { + o.SnakeCase = &v +} + +// GetProperty returns the Property field if non-nil, zero value otherwise. +func (o *Name) GetProperty() string { + if o == nil || o.Property == nil { + var ret string + return ret + } + return *o.Property +} + +// GetPropertyOk returns a tuple with the Property field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Name) GetPropertyOk() (string, bool) { + if o == nil || o.Property == nil { + var ret string + return ret, false + } + return *o.Property, true +} + +// HasProperty returns a boolean if a field has been set. +func (o *Name) HasProperty() bool { + if o != nil && o.Property != nil { + return true + } + + return false +} + +// SetProperty gets a reference to the given string and assigns it to the Property field. +func (o *Name) SetProperty(v string) { + o.Property = &v +} + +// GetVar123Number returns the Var123Number field if non-nil, zero value otherwise. +func (o *Name) GetVar123Number() int32 { + if o == nil || o.Var123Number == nil { + var ret int32 + return ret + } + return *o.Var123Number +} + +// GetVar123NumberOk returns a tuple with the Var123Number field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Name) GetVar123NumberOk() (int32, bool) { + if o == nil || o.Var123Number == nil { + var ret int32 + return ret, false + } + return *o.Var123Number, true +} + +// HasVar123Number returns a boolean if a field has been set. +func (o *Name) HasVar123Number() bool { + if o != nil && o.Var123Number != nil { + return true + } + + return false +} + +// SetVar123Number gets a reference to the given int32 and assigns it to the Var123Number field. +func (o *Name) SetVar123Number(v int32) { + o.Var123Number = &v +} + + +func (o Name) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Name == nil { + return nil, errors.New("Name is required and not nullable, but was not set on Name") + } + if o.Name != nil { + toSerialize["name"] = o.Name + } + if o.SnakeCase != nil { + toSerialize["snake_case"] = o.SnakeCase + } + if o.Property != nil { + toSerialize["property"] = o.Property + } + if o.Var123Number != nil { + toSerialize["123Number"] = o.Var123Number + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_number_only.go b/samples/client/petstore/go-experimental/go-petstore/model_number_only.go index 7a2fd5fd8f..47d69c607e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_number_only.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_number_only.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type NumberOnly struct { - JustNumber float32 `json:"JustNumber,omitempty"` + JustNumber *float32 `json:"JustNumber,omitempty"` + } + +// GetJustNumber returns the JustNumber field if non-nil, zero value otherwise. +func (o *NumberOnly) GetJustNumber() float32 { + if o == nil || o.JustNumber == nil { + var ret float32 + return ret + } + return *o.JustNumber +} + +// GetJustNumberOk returns a tuple with the JustNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *NumberOnly) GetJustNumberOk() (float32, bool) { + if o == nil || o.JustNumber == nil { + var ret float32 + return ret, false + } + return *o.JustNumber, true +} + +// HasJustNumber returns a boolean if a field has been set. +func (o *NumberOnly) HasJustNumber() bool { + if o != nil && o.JustNumber != nil { + return true + } + + return false +} + +// SetJustNumber gets a reference to the given float32 and assigns it to the JustNumber field. +func (o *NumberOnly) SetJustNumber(v float32) { + o.JustNumber = &v +} + + +func (o NumberOnly) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.JustNumber != nil { + toSerialize["JustNumber"] = o.JustNumber + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_order.go b/samples/client/petstore/go-experimental/go-petstore/model_order.go index c81d67ae0f..75d9299386 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_order.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_order.go @@ -10,14 +10,245 @@ package petstore import ( "time" + "encoding/json" ) type Order struct { - Id int64 `json:"id,omitempty"` - PetId int64 `json:"petId,omitempty"` - Quantity int32 `json:"quantity,omitempty"` - ShipDate time.Time `json:"shipDate,omitempty"` + Id *int64 `json:"id,omitempty"` + + PetId *int64 `json:"petId,omitempty"` + + Quantity *int32 `json:"quantity,omitempty"` + + ShipDate *time.Time `json:"shipDate,omitempty"` + // Order Status - Status string `json:"status,omitempty"` - Complete bool `json:"complete,omitempty"` + Status *string `json:"status,omitempty"` + + Complete *bool `json:"complete,omitempty"` + } + +// GetId returns the Id field if non-nil, zero value otherwise. +func (o *Order) GetId() int64 { + if o == nil || o.Id == nil { + var ret int64 + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetIdOk() (int64, bool) { + if o == nil || o.Id == nil { + var ret int64 + return ret, false + } + return *o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Order) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given int64 and assigns it to the Id field. +func (o *Order) SetId(v int64) { + o.Id = &v +} + +// GetPetId returns the PetId field if non-nil, zero value otherwise. +func (o *Order) GetPetId() int64 { + if o == nil || o.PetId == nil { + var ret int64 + return ret + } + return *o.PetId +} + +// GetPetIdOk returns a tuple with the PetId field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetPetIdOk() (int64, bool) { + if o == nil || o.PetId == nil { + var ret int64 + return ret, false + } + return *o.PetId, true +} + +// HasPetId returns a boolean if a field has been set. +func (o *Order) HasPetId() bool { + if o != nil && o.PetId != nil { + return true + } + + return false +} + +// SetPetId gets a reference to the given int64 and assigns it to the PetId field. +func (o *Order) SetPetId(v int64) { + o.PetId = &v +} + +// GetQuantity returns the Quantity field if non-nil, zero value otherwise. +func (o *Order) GetQuantity() int32 { + if o == nil || o.Quantity == nil { + var ret int32 + return ret + } + return *o.Quantity +} + +// GetQuantityOk returns a tuple with the Quantity field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetQuantityOk() (int32, bool) { + if o == nil || o.Quantity == nil { + var ret int32 + return ret, false + } + return *o.Quantity, true +} + +// HasQuantity returns a boolean if a field has been set. +func (o *Order) HasQuantity() bool { + if o != nil && o.Quantity != nil { + return true + } + + return false +} + +// SetQuantity gets a reference to the given int32 and assigns it to the Quantity field. +func (o *Order) SetQuantity(v int32) { + o.Quantity = &v +} + +// GetShipDate returns the ShipDate field if non-nil, zero value otherwise. +func (o *Order) GetShipDate() time.Time { + if o == nil || o.ShipDate == nil { + var ret time.Time + return ret + } + return *o.ShipDate +} + +// GetShipDateOk returns a tuple with the ShipDate field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetShipDateOk() (time.Time, bool) { + if o == nil || o.ShipDate == nil { + var ret time.Time + return ret, false + } + return *o.ShipDate, true +} + +// HasShipDate returns a boolean if a field has been set. +func (o *Order) HasShipDate() bool { + if o != nil && o.ShipDate != nil { + return true + } + + return false +} + +// SetShipDate gets a reference to the given time.Time and assigns it to the ShipDate field. +func (o *Order) SetShipDate(v time.Time) { + o.ShipDate = &v +} + +// GetStatus returns the Status field if non-nil, zero value otherwise. +func (o *Order) GetStatus() string { + if o == nil || o.Status == nil { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetStatusOk() (string, bool) { + if o == nil || o.Status == nil { + var ret string + return ret, false + } + return *o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *Order) HasStatus() bool { + if o != nil && o.Status != nil { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *Order) SetStatus(v string) { + o.Status = &v +} + +// GetComplete returns the Complete field if non-nil, zero value otherwise. +func (o *Order) GetComplete() bool { + if o == nil || o.Complete == nil { + var ret bool + return ret + } + return *o.Complete +} + +// GetCompleteOk returns a tuple with the Complete field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Order) GetCompleteOk() (bool, bool) { + if o == nil || o.Complete == nil { + var ret bool + return ret, false + } + return *o.Complete, true +} + +// HasComplete returns a boolean if a field has been set. +func (o *Order) HasComplete() bool { + if o != nil && o.Complete != nil { + return true + } + + return false +} + +// SetComplete gets a reference to the given bool and assigns it to the Complete field. +func (o *Order) SetComplete(v bool) { + o.Complete = &v +} + + +func (o Order) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Id != nil { + toSerialize["id"] = o.Id + } + if o.PetId != nil { + toSerialize["petId"] = o.PetId + } + if o.Quantity != nil { + toSerialize["quantity"] = o.Quantity + } + if o.ShipDate != nil { + toSerialize["shipDate"] = o.ShipDate + } + if o.Status != nil { + toSerialize["status"] = o.Status + } + if o.Complete != nil { + toSerialize["complete"] = o.Complete + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_outer_composite.go b/samples/client/petstore/go-experimental/go-petstore/model_outer_composite.go index 0ebb526267..83723a9b8e 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_outer_composite.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_outer_composite.go @@ -8,9 +8,131 @@ */ package petstore +import ( + "encoding/json" +) type OuterComposite struct { - MyNumber float32 `json:"my_number,omitempty"` - MyString string `json:"my_string,omitempty"` - MyBoolean bool `json:"my_boolean,omitempty"` + MyNumber *float32 `json:"my_number,omitempty"` + + MyString *string `json:"my_string,omitempty"` + + MyBoolean *bool `json:"my_boolean,omitempty"` + } + +// GetMyNumber returns the MyNumber field if non-nil, zero value otherwise. +func (o *OuterComposite) GetMyNumber() float32 { + if o == nil || o.MyNumber == nil { + var ret float32 + return ret + } + return *o.MyNumber +} + +// GetMyNumberOk returns a tuple with the MyNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *OuterComposite) GetMyNumberOk() (float32, bool) { + if o == nil || o.MyNumber == nil { + var ret float32 + return ret, false + } + return *o.MyNumber, true +} + +// HasMyNumber returns a boolean if a field has been set. +func (o *OuterComposite) HasMyNumber() bool { + if o != nil && o.MyNumber != nil { + return true + } + + return false +} + +// SetMyNumber gets a reference to the given float32 and assigns it to the MyNumber field. +func (o *OuterComposite) SetMyNumber(v float32) { + o.MyNumber = &v +} + +// GetMyString returns the MyString field if non-nil, zero value otherwise. +func (o *OuterComposite) GetMyString() string { + if o == nil || o.MyString == nil { + var ret string + return ret + } + return *o.MyString +} + +// GetMyStringOk returns a tuple with the MyString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *OuterComposite) GetMyStringOk() (string, bool) { + if o == nil || o.MyString == nil { + var ret string + return ret, false + } + return *o.MyString, true +} + +// HasMyString returns a boolean if a field has been set. +func (o *OuterComposite) HasMyString() bool { + if o != nil && o.MyString != nil { + return true + } + + return false +} + +// SetMyString gets a reference to the given string and assigns it to the MyString field. +func (o *OuterComposite) SetMyString(v string) { + o.MyString = &v +} + +// GetMyBoolean returns the MyBoolean field if non-nil, zero value otherwise. +func (o *OuterComposite) GetMyBoolean() bool { + if o == nil || o.MyBoolean == nil { + var ret bool + return ret + } + return *o.MyBoolean +} + +// GetMyBooleanOk returns a tuple with the MyBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *OuterComposite) GetMyBooleanOk() (bool, bool) { + if o == nil || o.MyBoolean == nil { + var ret bool + return ret, false + } + return *o.MyBoolean, true +} + +// HasMyBoolean returns a boolean if a field has been set. +func (o *OuterComposite) HasMyBoolean() bool { + if o != nil && o.MyBoolean != nil { + return true + } + + return false +} + +// SetMyBoolean gets a reference to the given bool and assigns it to the MyBoolean field. +func (o *OuterComposite) SetMyBoolean(v bool) { + o.MyBoolean = &v +} + + +func (o OuterComposite) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.MyNumber != nil { + toSerialize["my_number"] = o.MyNumber + } + if o.MyString != nil { + toSerialize["my_string"] = o.MyString + } + if o.MyBoolean != nil { + toSerialize["my_boolean"] = o.MyBoolean + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_outer_enum.go b/samples/client/petstore/go-experimental/go-petstore/model_outer_enum.go index 903d31e826..131a07c71a 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_outer_enum.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_outer_enum.go @@ -15,4 +15,5 @@ const ( PLACED OuterEnum = "placed" APPROVED OuterEnum = "approved" DELIVERED OuterEnum = "delivered" -) \ No newline at end of file +) + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_pet.go b/samples/client/petstore/go-experimental/go-petstore/model_pet.go index 4930dbb92e..1216b0e799 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_pet.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_pet.go @@ -8,13 +8,253 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type Pet struct { - Id int64 `json:"id,omitempty"` - Category Category `json:"category,omitempty"` - Name string `json:"name"` - PhotoUrls []string `json:"photoUrls"` - Tags []Tag `json:"tags,omitempty"` + Id *int64 `json:"id,omitempty"` + + Category *Category `json:"category,omitempty"` + + Name *string `json:"name,omitempty"` + + PhotoUrls *[]string `json:"photoUrls,omitempty"` + + Tags *[]Tag `json:"tags,omitempty"` + // pet status in the store - Status string `json:"status,omitempty"` + Status *string `json:"status,omitempty"` + } + +// GetId returns the Id field if non-nil, zero value otherwise. +func (o *Pet) GetId() int64 { + if o == nil || o.Id == nil { + var ret int64 + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetIdOk() (int64, bool) { + if o == nil || o.Id == nil { + var ret int64 + return ret, false + } + return *o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Pet) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given int64 and assigns it to the Id field. +func (o *Pet) SetId(v int64) { + o.Id = &v +} + +// GetCategory returns the Category field if non-nil, zero value otherwise. +func (o *Pet) GetCategory() Category { + if o == nil || o.Category == nil { + var ret Category + return ret + } + return *o.Category +} + +// GetCategoryOk returns a tuple with the Category field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetCategoryOk() (Category, bool) { + if o == nil || o.Category == nil { + var ret Category + return ret, false + } + return *o.Category, true +} + +// HasCategory returns a boolean if a field has been set. +func (o *Pet) HasCategory() bool { + if o != nil && o.Category != nil { + return true + } + + return false +} + +// SetCategory gets a reference to the given Category and assigns it to the Category field. +func (o *Pet) SetCategory(v Category) { + o.Category = &v +} + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *Pet) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Pet) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *Pet) SetName(v string) { + o.Name = &v +} + +// GetPhotoUrls returns the PhotoUrls field if non-nil, zero value otherwise. +func (o *Pet) GetPhotoUrls() []string { + if o == nil || o.PhotoUrls == nil { + var ret []string + return ret + } + return *o.PhotoUrls +} + +// GetPhotoUrlsOk returns a tuple with the PhotoUrls field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetPhotoUrlsOk() ([]string, bool) { + if o == nil || o.PhotoUrls == nil { + var ret []string + return ret, false + } + return *o.PhotoUrls, true +} + +// HasPhotoUrls returns a boolean if a field has been set. +func (o *Pet) HasPhotoUrls() bool { + if o != nil && o.PhotoUrls != nil { + return true + } + + return false +} + +// SetPhotoUrls gets a reference to the given []string and assigns it to the PhotoUrls field. +func (o *Pet) SetPhotoUrls(v []string) { + o.PhotoUrls = &v +} + +// GetTags returns the Tags field if non-nil, zero value otherwise. +func (o *Pet) GetTags() []Tag { + if o == nil || o.Tags == nil { + var ret []Tag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetTagsOk() ([]Tag, bool) { + if o == nil || o.Tags == nil { + var ret []Tag + return ret, false + } + return *o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Pet) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []Tag and assigns it to the Tags field. +func (o *Pet) SetTags(v []Tag) { + o.Tags = &v +} + +// GetStatus returns the Status field if non-nil, zero value otherwise. +func (o *Pet) GetStatus() string { + if o == nil || o.Status == nil { + var ret string + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Pet) GetStatusOk() (string, bool) { + if o == nil || o.Status == nil { + var ret string + return ret, false + } + return *o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *Pet) HasStatus() bool { + if o != nil && o.Status != nil { + return true + } + + return false +} + +// SetStatus gets a reference to the given string and assigns it to the Status field. +func (o *Pet) SetStatus(v string) { + o.Status = &v +} + + +func (o Pet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Id != nil { + toSerialize["id"] = o.Id + } + if o.Category != nil { + toSerialize["category"] = o.Category + } + if o.Name == nil { + return nil, errors.New("Name is required and not nullable, but was not set on Pet") + } + if o.Name != nil { + toSerialize["name"] = o.Name + } + if o.PhotoUrls == nil { + return nil, errors.New("PhotoUrls is required and not nullable, but was not set on Pet") + } + if o.PhotoUrls != nil { + toSerialize["photoUrls"] = o.PhotoUrls + } + if o.Tags != nil { + toSerialize["tags"] = o.Tags + } + if o.Status != nil { + toSerialize["status"] = o.Status + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_read_only_first.go b/samples/client/petstore/go-experimental/go-petstore/model_read_only_first.go index 6b22163900..5c92010e8d 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_read_only_first.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_read_only_first.go @@ -8,8 +8,93 @@ */ package petstore +import ( + "encoding/json" +) type ReadOnlyFirst struct { - Bar string `json:"bar,omitempty"` - Baz string `json:"baz,omitempty"` + Bar *string `json:"bar,omitempty"` + + Baz *string `json:"baz,omitempty"` + } + +// GetBar returns the Bar field if non-nil, zero value otherwise. +func (o *ReadOnlyFirst) GetBar() string { + if o == nil || o.Bar == nil { + var ret string + return ret + } + return *o.Bar +} + +// GetBarOk returns a tuple with the Bar field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ReadOnlyFirst) GetBarOk() (string, bool) { + if o == nil || o.Bar == nil { + var ret string + return ret, false + } + return *o.Bar, true +} + +// HasBar returns a boolean if a field has been set. +func (o *ReadOnlyFirst) HasBar() bool { + if o != nil && o.Bar != nil { + return true + } + + return false +} + +// SetBar gets a reference to the given string and assigns it to the Bar field. +func (o *ReadOnlyFirst) SetBar(v string) { + o.Bar = &v +} + +// GetBaz returns the Baz field if non-nil, zero value otherwise. +func (o *ReadOnlyFirst) GetBaz() string { + if o == nil || o.Baz == nil { + var ret string + return ret + } + return *o.Baz +} + +// GetBazOk returns a tuple with the Baz field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *ReadOnlyFirst) GetBazOk() (string, bool) { + if o == nil || o.Baz == nil { + var ret string + return ret, false + } + return *o.Baz, true +} + +// HasBaz returns a boolean if a field has been set. +func (o *ReadOnlyFirst) HasBaz() bool { + if o != nil && o.Baz != nil { + return true + } + + return false +} + +// SetBaz gets a reference to the given string and assigns it to the Baz field. +func (o *ReadOnlyFirst) SetBaz(v string) { + o.Baz = &v +} + + +func (o ReadOnlyFirst) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bar != nil { + toSerialize["bar"] = o.Bar + } + if o.Baz != nil { + toSerialize["baz"] = o.Baz + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_return.go b/samples/client/petstore/go-experimental/go-petstore/model_return.go index 7851dd851d..e53cc31b5f 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_return.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_return.go @@ -8,8 +8,56 @@ */ package petstore +import ( + "encoding/json" +) // Model for testing reserved words type Return struct { - Return int32 `json:"return,omitempty"` + Return *int32 `json:"return,omitempty"` + } + +// GetReturn returns the Return field if non-nil, zero value otherwise. +func (o *Return) GetReturn() int32 { + if o == nil || o.Return == nil { + var ret int32 + return ret + } + return *o.Return +} + +// GetReturnOk returns a tuple with the Return field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Return) GetReturnOk() (int32, bool) { + if o == nil || o.Return == nil { + var ret int32 + return ret, false + } + return *o.Return, true +} + +// HasReturn returns a boolean if a field has been set. +func (o *Return) HasReturn() bool { + if o != nil && o.Return != nil { + return true + } + + return false +} + +// SetReturn gets a reference to the given int32 and assigns it to the Return field. +func (o *Return) SetReturn(v int32) { + o.Return = &v +} + + +func (o Return) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Return != nil { + toSerialize["return"] = o.Return + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_special_model_name.go b/samples/client/petstore/go-experimental/go-petstore/model_special_model_name.go index f906e91987..7e940165d9 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_special_model_name.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_special_model_name.go @@ -8,7 +8,55 @@ */ package petstore +import ( + "encoding/json" +) type SpecialModelName struct { - SpecialPropertyName int64 `json:"$special[property.name],omitempty"` + SpecialPropertyName *int64 `json:"$special[property.name],omitempty"` + } + +// GetSpecialPropertyName returns the SpecialPropertyName field if non-nil, zero value otherwise. +func (o *SpecialModelName) GetSpecialPropertyName() int64 { + if o == nil || o.SpecialPropertyName == nil { + var ret int64 + return ret + } + return *o.SpecialPropertyName +} + +// GetSpecialPropertyNameOk returns a tuple with the SpecialPropertyName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *SpecialModelName) GetSpecialPropertyNameOk() (int64, bool) { + if o == nil || o.SpecialPropertyName == nil { + var ret int64 + return ret, false + } + return *o.SpecialPropertyName, true +} + +// HasSpecialPropertyName returns a boolean if a field has been set. +func (o *SpecialModelName) HasSpecialPropertyName() bool { + if o != nil && o.SpecialPropertyName != nil { + return true + } + + return false +} + +// SetSpecialPropertyName gets a reference to the given int64 and assigns it to the SpecialPropertyName field. +func (o *SpecialModelName) SetSpecialPropertyName(v int64) { + o.SpecialPropertyName = &v +} + + +func (o SpecialModelName) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SpecialPropertyName != nil { + toSerialize["$special[property.name]"] = o.SpecialPropertyName + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_tag.go b/samples/client/petstore/go-experimental/go-petstore/model_tag.go index 37a2b63d44..dc4053da9b 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_tag.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_tag.go @@ -8,8 +8,93 @@ */ package petstore +import ( + "encoding/json" +) type Tag struct { - Id int64 `json:"id,omitempty"` - Name string `json:"name,omitempty"` + Id *int64 `json:"id,omitempty"` + + Name *string `json:"name,omitempty"` + } + +// GetId returns the Id field if non-nil, zero value otherwise. +func (o *Tag) GetId() int64 { + if o == nil || o.Id == nil { + var ret int64 + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetIdOk() (int64, bool) { + if o == nil || o.Id == nil { + var ret int64 + return ret, false + } + return *o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Tag) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given int64 and assigns it to the Id field. +func (o *Tag) SetId(v int64) { + o.Id = &v +} + +// GetName returns the Name field if non-nil, zero value otherwise. +func (o *Tag) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetNameOk() (string, bool) { + if o == nil || o.Name == nil { + var ret string + return ret, false + } + return *o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Tag) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *Tag) SetName(v string) { + o.Name = &v +} + + +func (o Tag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Id != nil { + toSerialize["id"] = o.Id + } + if o.Name != nil { + toSerialize["name"] = o.Name + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_type_holder_default.go b/samples/client/petstore/go-experimental/go-petstore/model_type_holder_default.go index 68e1218ec9..f1fcc93dd8 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_type_holder_default.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_type_holder_default.go @@ -8,11 +8,223 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type TypeHolderDefault struct { - StringItem string `json:"string_item"` - NumberItem float32 `json:"number_item"` - IntegerItem int32 `json:"integer_item"` - BoolItem bool `json:"bool_item"` - ArrayItem []int32 `json:"array_item"` + StringItem *string `json:"string_item,omitempty"` + + NumberItem *float32 `json:"number_item,omitempty"` + + IntegerItem *int32 `json:"integer_item,omitempty"` + + BoolItem *bool `json:"bool_item,omitempty"` + + ArrayItem *[]int32 `json:"array_item,omitempty"` + } + +// GetStringItem returns the StringItem field if non-nil, zero value otherwise. +func (o *TypeHolderDefault) GetStringItem() string { + if o == nil || o.StringItem == nil { + var ret string + return ret + } + return *o.StringItem +} + +// GetStringItemOk returns a tuple with the StringItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderDefault) GetStringItemOk() (string, bool) { + if o == nil || o.StringItem == nil { + var ret string + return ret, false + } + return *o.StringItem, true +} + +// HasStringItem returns a boolean if a field has been set. +func (o *TypeHolderDefault) HasStringItem() bool { + if o != nil && o.StringItem != nil { + return true + } + + return false +} + +// SetStringItem gets a reference to the given string and assigns it to the StringItem field. +func (o *TypeHolderDefault) SetStringItem(v string) { + o.StringItem = &v +} + +// GetNumberItem returns the NumberItem field if non-nil, zero value otherwise. +func (o *TypeHolderDefault) GetNumberItem() float32 { + if o == nil || o.NumberItem == nil { + var ret float32 + return ret + } + return *o.NumberItem +} + +// GetNumberItemOk returns a tuple with the NumberItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderDefault) GetNumberItemOk() (float32, bool) { + if o == nil || o.NumberItem == nil { + var ret float32 + return ret, false + } + return *o.NumberItem, true +} + +// HasNumberItem returns a boolean if a field has been set. +func (o *TypeHolderDefault) HasNumberItem() bool { + if o != nil && o.NumberItem != nil { + return true + } + + return false +} + +// SetNumberItem gets a reference to the given float32 and assigns it to the NumberItem field. +func (o *TypeHolderDefault) SetNumberItem(v float32) { + o.NumberItem = &v +} + +// GetIntegerItem returns the IntegerItem field if non-nil, zero value otherwise. +func (o *TypeHolderDefault) GetIntegerItem() int32 { + if o == nil || o.IntegerItem == nil { + var ret int32 + return ret + } + return *o.IntegerItem +} + +// GetIntegerItemOk returns a tuple with the IntegerItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderDefault) GetIntegerItemOk() (int32, bool) { + if o == nil || o.IntegerItem == nil { + var ret int32 + return ret, false + } + return *o.IntegerItem, true +} + +// HasIntegerItem returns a boolean if a field has been set. +func (o *TypeHolderDefault) HasIntegerItem() bool { + if o != nil && o.IntegerItem != nil { + return true + } + + return false +} + +// SetIntegerItem gets a reference to the given int32 and assigns it to the IntegerItem field. +func (o *TypeHolderDefault) SetIntegerItem(v int32) { + o.IntegerItem = &v +} + +// GetBoolItem returns the BoolItem field if non-nil, zero value otherwise. +func (o *TypeHolderDefault) GetBoolItem() bool { + if o == nil || o.BoolItem == nil { + var ret bool + return ret + } + return *o.BoolItem +} + +// GetBoolItemOk returns a tuple with the BoolItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderDefault) GetBoolItemOk() (bool, bool) { + if o == nil || o.BoolItem == nil { + var ret bool + return ret, false + } + return *o.BoolItem, true +} + +// HasBoolItem returns a boolean if a field has been set. +func (o *TypeHolderDefault) HasBoolItem() bool { + if o != nil && o.BoolItem != nil { + return true + } + + return false +} + +// SetBoolItem gets a reference to the given bool and assigns it to the BoolItem field. +func (o *TypeHolderDefault) SetBoolItem(v bool) { + o.BoolItem = &v +} + +// GetArrayItem returns the ArrayItem field if non-nil, zero value otherwise. +func (o *TypeHolderDefault) GetArrayItem() []int32 { + if o == nil || o.ArrayItem == nil { + var ret []int32 + return ret + } + return *o.ArrayItem +} + +// GetArrayItemOk returns a tuple with the ArrayItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderDefault) GetArrayItemOk() ([]int32, bool) { + if o == nil || o.ArrayItem == nil { + var ret []int32 + return ret, false + } + return *o.ArrayItem, true +} + +// HasArrayItem returns a boolean if a field has been set. +func (o *TypeHolderDefault) HasArrayItem() bool { + if o != nil && o.ArrayItem != nil { + return true + } + + return false +} + +// SetArrayItem gets a reference to the given []int32 and assigns it to the ArrayItem field. +func (o *TypeHolderDefault) SetArrayItem(v []int32) { + o.ArrayItem = &v +} + + +func (o TypeHolderDefault) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.StringItem == nil { + return nil, errors.New("StringItem is required and not nullable, but was not set on TypeHolderDefault") + } + if o.StringItem != nil { + toSerialize["string_item"] = o.StringItem + } + if o.NumberItem == nil { + return nil, errors.New("NumberItem is required and not nullable, but was not set on TypeHolderDefault") + } + if o.NumberItem != nil { + toSerialize["number_item"] = o.NumberItem + } + if o.IntegerItem == nil { + return nil, errors.New("IntegerItem is required and not nullable, but was not set on TypeHolderDefault") + } + if o.IntegerItem != nil { + toSerialize["integer_item"] = o.IntegerItem + } + if o.BoolItem == nil { + return nil, errors.New("BoolItem is required and not nullable, but was not set on TypeHolderDefault") + } + if o.BoolItem != nil { + toSerialize["bool_item"] = o.BoolItem + } + if o.ArrayItem == nil { + return nil, errors.New("ArrayItem is required and not nullable, but was not set on TypeHolderDefault") + } + if o.ArrayItem != nil { + toSerialize["array_item"] = o.ArrayItem + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_type_holder_example.go b/samples/client/petstore/go-experimental/go-petstore/model_type_holder_example.go index e129bb6a76..0fe346c7cd 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_type_holder_example.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_type_holder_example.go @@ -8,11 +8,223 @@ */ package petstore +import ( + "encoding/json" + "errors" +) type TypeHolderExample struct { - StringItem string `json:"string_item"` - NumberItem float32 `json:"number_item"` - IntegerItem int32 `json:"integer_item"` - BoolItem bool `json:"bool_item"` - ArrayItem []int32 `json:"array_item"` + StringItem *string `json:"string_item,omitempty"` + + NumberItem *float32 `json:"number_item,omitempty"` + + IntegerItem *int32 `json:"integer_item,omitempty"` + + BoolItem *bool `json:"bool_item,omitempty"` + + ArrayItem *[]int32 `json:"array_item,omitempty"` + } + +// GetStringItem returns the StringItem field if non-nil, zero value otherwise. +func (o *TypeHolderExample) GetStringItem() string { + if o == nil || o.StringItem == nil { + var ret string + return ret + } + return *o.StringItem +} + +// GetStringItemOk returns a tuple with the StringItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderExample) GetStringItemOk() (string, bool) { + if o == nil || o.StringItem == nil { + var ret string + return ret, false + } + return *o.StringItem, true +} + +// HasStringItem returns a boolean if a field has been set. +func (o *TypeHolderExample) HasStringItem() bool { + if o != nil && o.StringItem != nil { + return true + } + + return false +} + +// SetStringItem gets a reference to the given string and assigns it to the StringItem field. +func (o *TypeHolderExample) SetStringItem(v string) { + o.StringItem = &v +} + +// GetNumberItem returns the NumberItem field if non-nil, zero value otherwise. +func (o *TypeHolderExample) GetNumberItem() float32 { + if o == nil || o.NumberItem == nil { + var ret float32 + return ret + } + return *o.NumberItem +} + +// GetNumberItemOk returns a tuple with the NumberItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderExample) GetNumberItemOk() (float32, bool) { + if o == nil || o.NumberItem == nil { + var ret float32 + return ret, false + } + return *o.NumberItem, true +} + +// HasNumberItem returns a boolean if a field has been set. +func (o *TypeHolderExample) HasNumberItem() bool { + if o != nil && o.NumberItem != nil { + return true + } + + return false +} + +// SetNumberItem gets a reference to the given float32 and assigns it to the NumberItem field. +func (o *TypeHolderExample) SetNumberItem(v float32) { + o.NumberItem = &v +} + +// GetIntegerItem returns the IntegerItem field if non-nil, zero value otherwise. +func (o *TypeHolderExample) GetIntegerItem() int32 { + if o == nil || o.IntegerItem == nil { + var ret int32 + return ret + } + return *o.IntegerItem +} + +// GetIntegerItemOk returns a tuple with the IntegerItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderExample) GetIntegerItemOk() (int32, bool) { + if o == nil || o.IntegerItem == nil { + var ret int32 + return ret, false + } + return *o.IntegerItem, true +} + +// HasIntegerItem returns a boolean if a field has been set. +func (o *TypeHolderExample) HasIntegerItem() bool { + if o != nil && o.IntegerItem != nil { + return true + } + + return false +} + +// SetIntegerItem gets a reference to the given int32 and assigns it to the IntegerItem field. +func (o *TypeHolderExample) SetIntegerItem(v int32) { + o.IntegerItem = &v +} + +// GetBoolItem returns the BoolItem field if non-nil, zero value otherwise. +func (o *TypeHolderExample) GetBoolItem() bool { + if o == nil || o.BoolItem == nil { + var ret bool + return ret + } + return *o.BoolItem +} + +// GetBoolItemOk returns a tuple with the BoolItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderExample) GetBoolItemOk() (bool, bool) { + if o == nil || o.BoolItem == nil { + var ret bool + return ret, false + } + return *o.BoolItem, true +} + +// HasBoolItem returns a boolean if a field has been set. +func (o *TypeHolderExample) HasBoolItem() bool { + if o != nil && o.BoolItem != nil { + return true + } + + return false +} + +// SetBoolItem gets a reference to the given bool and assigns it to the BoolItem field. +func (o *TypeHolderExample) SetBoolItem(v bool) { + o.BoolItem = &v +} + +// GetArrayItem returns the ArrayItem field if non-nil, zero value otherwise. +func (o *TypeHolderExample) GetArrayItem() []int32 { + if o == nil || o.ArrayItem == nil { + var ret []int32 + return ret + } + return *o.ArrayItem +} + +// GetArrayItemOk returns a tuple with the ArrayItem field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *TypeHolderExample) GetArrayItemOk() ([]int32, bool) { + if o == nil || o.ArrayItem == nil { + var ret []int32 + return ret, false + } + return *o.ArrayItem, true +} + +// HasArrayItem returns a boolean if a field has been set. +func (o *TypeHolderExample) HasArrayItem() bool { + if o != nil && o.ArrayItem != nil { + return true + } + + return false +} + +// SetArrayItem gets a reference to the given []int32 and assigns it to the ArrayItem field. +func (o *TypeHolderExample) SetArrayItem(v []int32) { + o.ArrayItem = &v +} + + +func (o TypeHolderExample) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.StringItem == nil { + return nil, errors.New("StringItem is required and not nullable, but was not set on TypeHolderExample") + } + if o.StringItem != nil { + toSerialize["string_item"] = o.StringItem + } + if o.NumberItem == nil { + return nil, errors.New("NumberItem is required and not nullable, but was not set on TypeHolderExample") + } + if o.NumberItem != nil { + toSerialize["number_item"] = o.NumberItem + } + if o.IntegerItem == nil { + return nil, errors.New("IntegerItem is required and not nullable, but was not set on TypeHolderExample") + } + if o.IntegerItem != nil { + toSerialize["integer_item"] = o.IntegerItem + } + if o.BoolItem == nil { + return nil, errors.New("BoolItem is required and not nullable, but was not set on TypeHolderExample") + } + if o.BoolItem != nil { + toSerialize["bool_item"] = o.BoolItem + } + if o.ArrayItem == nil { + return nil, errors.New("ArrayItem is required and not nullable, but was not set on TypeHolderExample") + } + if o.ArrayItem != nil { + toSerialize["array_item"] = o.ArrayItem + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_user.go b/samples/client/petstore/go-experimental/go-petstore/model_user.go index caff75ebc2..925f82d582 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_user.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_user.go @@ -8,15 +8,322 @@ */ package petstore +import ( + "encoding/json" +) type User struct { - Id int64 `json:"id,omitempty"` - Username string `json:"username,omitempty"` - FirstName string `json:"firstName,omitempty"` - LastName string `json:"lastName,omitempty"` - Email string `json:"email,omitempty"` - Password string `json:"password,omitempty"` - Phone string `json:"phone,omitempty"` + Id *int64 `json:"id,omitempty"` + + Username *string `json:"username,omitempty"` + + FirstName *string `json:"firstName,omitempty"` + + LastName *string `json:"lastName,omitempty"` + + Email *string `json:"email,omitempty"` + + Password *string `json:"password,omitempty"` + + Phone *string `json:"phone,omitempty"` + // User Status - UserStatus int32 `json:"userStatus,omitempty"` + UserStatus *int32 `json:"userStatus,omitempty"` + } + +// GetId returns the Id field if non-nil, zero value otherwise. +func (o *User) GetId() int64 { + if o == nil || o.Id == nil { + var ret int64 + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetIdOk() (int64, bool) { + if o == nil || o.Id == nil { + var ret int64 + return ret, false + } + return *o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *User) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given int64 and assigns it to the Id field. +func (o *User) SetId(v int64) { + o.Id = &v +} + +// GetUsername returns the Username field if non-nil, zero value otherwise. +func (o *User) GetUsername() string { + if o == nil || o.Username == nil { + var ret string + return ret + } + return *o.Username +} + +// GetUsernameOk returns a tuple with the Username field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetUsernameOk() (string, bool) { + if o == nil || o.Username == nil { + var ret string + return ret, false + } + return *o.Username, true +} + +// HasUsername returns a boolean if a field has been set. +func (o *User) HasUsername() bool { + if o != nil && o.Username != nil { + return true + } + + return false +} + +// SetUsername gets a reference to the given string and assigns it to the Username field. +func (o *User) SetUsername(v string) { + o.Username = &v +} + +// GetFirstName returns the FirstName field if non-nil, zero value otherwise. +func (o *User) GetFirstName() string { + if o == nil || o.FirstName == nil { + var ret string + return ret + } + return *o.FirstName +} + +// GetFirstNameOk returns a tuple with the FirstName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetFirstNameOk() (string, bool) { + if o == nil || o.FirstName == nil { + var ret string + return ret, false + } + return *o.FirstName, true +} + +// HasFirstName returns a boolean if a field has been set. +func (o *User) HasFirstName() bool { + if o != nil && o.FirstName != nil { + return true + } + + return false +} + +// SetFirstName gets a reference to the given string and assigns it to the FirstName field. +func (o *User) SetFirstName(v string) { + o.FirstName = &v +} + +// GetLastName returns the LastName field if non-nil, zero value otherwise. +func (o *User) GetLastName() string { + if o == nil || o.LastName == nil { + var ret string + return ret + } + return *o.LastName +} + +// GetLastNameOk returns a tuple with the LastName field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetLastNameOk() (string, bool) { + if o == nil || o.LastName == nil { + var ret string + return ret, false + } + return *o.LastName, true +} + +// HasLastName returns a boolean if a field has been set. +func (o *User) HasLastName() bool { + if o != nil && o.LastName != nil { + return true + } + + return false +} + +// SetLastName gets a reference to the given string and assigns it to the LastName field. +func (o *User) SetLastName(v string) { + o.LastName = &v +} + +// GetEmail returns the Email field if non-nil, zero value otherwise. +func (o *User) GetEmail() string { + if o == nil || o.Email == nil { + var ret string + return ret + } + return *o.Email +} + +// GetEmailOk returns a tuple with the Email field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetEmailOk() (string, bool) { + if o == nil || o.Email == nil { + var ret string + return ret, false + } + return *o.Email, true +} + +// HasEmail returns a boolean if a field has been set. +func (o *User) HasEmail() bool { + if o != nil && o.Email != nil { + return true + } + + return false +} + +// SetEmail gets a reference to the given string and assigns it to the Email field. +func (o *User) SetEmail(v string) { + o.Email = &v +} + +// GetPassword returns the Password field if non-nil, zero value otherwise. +func (o *User) GetPassword() string { + if o == nil || o.Password == nil { + var ret string + return ret + } + return *o.Password +} + +// GetPasswordOk returns a tuple with the Password field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetPasswordOk() (string, bool) { + if o == nil || o.Password == nil { + var ret string + return ret, false + } + return *o.Password, true +} + +// HasPassword returns a boolean if a field has been set. +func (o *User) HasPassword() bool { + if o != nil && o.Password != nil { + return true + } + + return false +} + +// SetPassword gets a reference to the given string and assigns it to the Password field. +func (o *User) SetPassword(v string) { + o.Password = &v +} + +// GetPhone returns the Phone field if non-nil, zero value otherwise. +func (o *User) GetPhone() string { + if o == nil || o.Phone == nil { + var ret string + return ret + } + return *o.Phone +} + +// GetPhoneOk returns a tuple with the Phone field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetPhoneOk() (string, bool) { + if o == nil || o.Phone == nil { + var ret string + return ret, false + } + return *o.Phone, true +} + +// HasPhone returns a boolean if a field has been set. +func (o *User) HasPhone() bool { + if o != nil && o.Phone != nil { + return true + } + + return false +} + +// SetPhone gets a reference to the given string and assigns it to the Phone field. +func (o *User) SetPhone(v string) { + o.Phone = &v +} + +// GetUserStatus returns the UserStatus field if non-nil, zero value otherwise. +func (o *User) GetUserStatus() int32 { + if o == nil || o.UserStatus == nil { + var ret int32 + return ret + } + return *o.UserStatus +} + +// GetUserStatusOk returns a tuple with the UserStatus field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *User) GetUserStatusOk() (int32, bool) { + if o == nil || o.UserStatus == nil { + var ret int32 + return ret, false + } + return *o.UserStatus, true +} + +// HasUserStatus returns a boolean if a field has been set. +func (o *User) HasUserStatus() bool { + if o != nil && o.UserStatus != nil { + return true + } + + return false +} + +// SetUserStatus gets a reference to the given int32 and assigns it to the UserStatus field. +func (o *User) SetUserStatus(v int32) { + o.UserStatus = &v +} + + +func (o User) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Id != nil { + toSerialize["id"] = o.Id + } + if o.Username != nil { + toSerialize["username"] = o.Username + } + if o.FirstName != nil { + toSerialize["firstName"] = o.FirstName + } + if o.LastName != nil { + toSerialize["lastName"] = o.LastName + } + if o.Email != nil { + toSerialize["email"] = o.Email + } + if o.Password != nil { + toSerialize["password"] = o.Password + } + if o.Phone != nil { + toSerialize["phone"] = o.Phone + } + if o.UserStatus != nil { + toSerialize["userStatus"] = o.UserStatus + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/model_xml_item.go b/samples/client/petstore/go-experimental/go-petstore/model_xml_item.go index a623bda5c7..2f0f8f89c4 100644 --- a/samples/client/petstore/go-experimental/go-petstore/model_xml_item.go +++ b/samples/client/petstore/go-experimental/go-petstore/model_xml_item.go @@ -8,35 +8,1119 @@ */ package petstore +import ( + "encoding/json" +) type XmlItem struct { - AttributeString string `json:"attribute_string,omitempty"` - AttributeNumber float32 `json:"attribute_number,omitempty"` - AttributeInteger int32 `json:"attribute_integer,omitempty"` - AttributeBoolean bool `json:"attribute_boolean,omitempty"` - WrappedArray []int32 `json:"wrapped_array,omitempty"` - NameString string `json:"name_string,omitempty"` - NameNumber float32 `json:"name_number,omitempty"` - NameInteger int32 `json:"name_integer,omitempty"` - NameBoolean bool `json:"name_boolean,omitempty"` - NameArray []int32 `json:"name_array,omitempty"` - NameWrappedArray []int32 `json:"name_wrapped_array,omitempty"` - PrefixString string `json:"prefix_string,omitempty"` - PrefixNumber float32 `json:"prefix_number,omitempty"` - PrefixInteger int32 `json:"prefix_integer,omitempty"` - PrefixBoolean bool `json:"prefix_boolean,omitempty"` - PrefixArray []int32 `json:"prefix_array,omitempty"` - PrefixWrappedArray []int32 `json:"prefix_wrapped_array,omitempty"` - NamespaceString string `json:"namespace_string,omitempty"` - NamespaceNumber float32 `json:"namespace_number,omitempty"` - NamespaceInteger int32 `json:"namespace_integer,omitempty"` - NamespaceBoolean bool `json:"namespace_boolean,omitempty"` - NamespaceArray []int32 `json:"namespace_array,omitempty"` - NamespaceWrappedArray []int32 `json:"namespace_wrapped_array,omitempty"` - PrefixNsString string `json:"prefix_ns_string,omitempty"` - PrefixNsNumber float32 `json:"prefix_ns_number,omitempty"` - PrefixNsInteger int32 `json:"prefix_ns_integer,omitempty"` - PrefixNsBoolean bool `json:"prefix_ns_boolean,omitempty"` - PrefixNsArray []int32 `json:"prefix_ns_array,omitempty"` - PrefixNsWrappedArray []int32 `json:"prefix_ns_wrapped_array,omitempty"` + AttributeString *string `json:"attribute_string,omitempty"` + + AttributeNumber *float32 `json:"attribute_number,omitempty"` + + AttributeInteger *int32 `json:"attribute_integer,omitempty"` + + AttributeBoolean *bool `json:"attribute_boolean,omitempty"` + + WrappedArray *[]int32 `json:"wrapped_array,omitempty"` + + NameString *string `json:"name_string,omitempty"` + + NameNumber *float32 `json:"name_number,omitempty"` + + NameInteger *int32 `json:"name_integer,omitempty"` + + NameBoolean *bool `json:"name_boolean,omitempty"` + + NameArray *[]int32 `json:"name_array,omitempty"` + + NameWrappedArray *[]int32 `json:"name_wrapped_array,omitempty"` + + PrefixString *string `json:"prefix_string,omitempty"` + + PrefixNumber *float32 `json:"prefix_number,omitempty"` + + PrefixInteger *int32 `json:"prefix_integer,omitempty"` + + PrefixBoolean *bool `json:"prefix_boolean,omitempty"` + + PrefixArray *[]int32 `json:"prefix_array,omitempty"` + + PrefixWrappedArray *[]int32 `json:"prefix_wrapped_array,omitempty"` + + NamespaceString *string `json:"namespace_string,omitempty"` + + NamespaceNumber *float32 `json:"namespace_number,omitempty"` + + NamespaceInteger *int32 `json:"namespace_integer,omitempty"` + + NamespaceBoolean *bool `json:"namespace_boolean,omitempty"` + + NamespaceArray *[]int32 `json:"namespace_array,omitempty"` + + NamespaceWrappedArray *[]int32 `json:"namespace_wrapped_array,omitempty"` + + PrefixNsString *string `json:"prefix_ns_string,omitempty"` + + PrefixNsNumber *float32 `json:"prefix_ns_number,omitempty"` + + PrefixNsInteger *int32 `json:"prefix_ns_integer,omitempty"` + + PrefixNsBoolean *bool `json:"prefix_ns_boolean,omitempty"` + + PrefixNsArray *[]int32 `json:"prefix_ns_array,omitempty"` + + PrefixNsWrappedArray *[]int32 `json:"prefix_ns_wrapped_array,omitempty"` + } + +// GetAttributeString returns the AttributeString field if non-nil, zero value otherwise. +func (o *XmlItem) GetAttributeString() string { + if o == nil || o.AttributeString == nil { + var ret string + return ret + } + return *o.AttributeString +} + +// GetAttributeStringOk returns a tuple with the AttributeString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetAttributeStringOk() (string, bool) { + if o == nil || o.AttributeString == nil { + var ret string + return ret, false + } + return *o.AttributeString, true +} + +// HasAttributeString returns a boolean if a field has been set. +func (o *XmlItem) HasAttributeString() bool { + if o != nil && o.AttributeString != nil { + return true + } + + return false +} + +// SetAttributeString gets a reference to the given string and assigns it to the AttributeString field. +func (o *XmlItem) SetAttributeString(v string) { + o.AttributeString = &v +} + +// GetAttributeNumber returns the AttributeNumber field if non-nil, zero value otherwise. +func (o *XmlItem) GetAttributeNumber() float32 { + if o == nil || o.AttributeNumber == nil { + var ret float32 + return ret + } + return *o.AttributeNumber +} + +// GetAttributeNumberOk returns a tuple with the AttributeNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetAttributeNumberOk() (float32, bool) { + if o == nil || o.AttributeNumber == nil { + var ret float32 + return ret, false + } + return *o.AttributeNumber, true +} + +// HasAttributeNumber returns a boolean if a field has been set. +func (o *XmlItem) HasAttributeNumber() bool { + if o != nil && o.AttributeNumber != nil { + return true + } + + return false +} + +// SetAttributeNumber gets a reference to the given float32 and assigns it to the AttributeNumber field. +func (o *XmlItem) SetAttributeNumber(v float32) { + o.AttributeNumber = &v +} + +// GetAttributeInteger returns the AttributeInteger field if non-nil, zero value otherwise. +func (o *XmlItem) GetAttributeInteger() int32 { + if o == nil || o.AttributeInteger == nil { + var ret int32 + return ret + } + return *o.AttributeInteger +} + +// GetAttributeIntegerOk returns a tuple with the AttributeInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetAttributeIntegerOk() (int32, bool) { + if o == nil || o.AttributeInteger == nil { + var ret int32 + return ret, false + } + return *o.AttributeInteger, true +} + +// HasAttributeInteger returns a boolean if a field has been set. +func (o *XmlItem) HasAttributeInteger() bool { + if o != nil && o.AttributeInteger != nil { + return true + } + + return false +} + +// SetAttributeInteger gets a reference to the given int32 and assigns it to the AttributeInteger field. +func (o *XmlItem) SetAttributeInteger(v int32) { + o.AttributeInteger = &v +} + +// GetAttributeBoolean returns the AttributeBoolean field if non-nil, zero value otherwise. +func (o *XmlItem) GetAttributeBoolean() bool { + if o == nil || o.AttributeBoolean == nil { + var ret bool + return ret + } + return *o.AttributeBoolean +} + +// GetAttributeBooleanOk returns a tuple with the AttributeBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetAttributeBooleanOk() (bool, bool) { + if o == nil || o.AttributeBoolean == nil { + var ret bool + return ret, false + } + return *o.AttributeBoolean, true +} + +// HasAttributeBoolean returns a boolean if a field has been set. +func (o *XmlItem) HasAttributeBoolean() bool { + if o != nil && o.AttributeBoolean != nil { + return true + } + + return false +} + +// SetAttributeBoolean gets a reference to the given bool and assigns it to the AttributeBoolean field. +func (o *XmlItem) SetAttributeBoolean(v bool) { + o.AttributeBoolean = &v +} + +// GetWrappedArray returns the WrappedArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetWrappedArray() []int32 { + if o == nil || o.WrappedArray == nil { + var ret []int32 + return ret + } + return *o.WrappedArray +} + +// GetWrappedArrayOk returns a tuple with the WrappedArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetWrappedArrayOk() ([]int32, bool) { + if o == nil || o.WrappedArray == nil { + var ret []int32 + return ret, false + } + return *o.WrappedArray, true +} + +// HasWrappedArray returns a boolean if a field has been set. +func (o *XmlItem) HasWrappedArray() bool { + if o != nil && o.WrappedArray != nil { + return true + } + + return false +} + +// SetWrappedArray gets a reference to the given []int32 and assigns it to the WrappedArray field. +func (o *XmlItem) SetWrappedArray(v []int32) { + o.WrappedArray = &v +} + +// GetNameString returns the NameString field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameString() string { + if o == nil || o.NameString == nil { + var ret string + return ret + } + return *o.NameString +} + +// GetNameStringOk returns a tuple with the NameString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameStringOk() (string, bool) { + if o == nil || o.NameString == nil { + var ret string + return ret, false + } + return *o.NameString, true +} + +// HasNameString returns a boolean if a field has been set. +func (o *XmlItem) HasNameString() bool { + if o != nil && o.NameString != nil { + return true + } + + return false +} + +// SetNameString gets a reference to the given string and assigns it to the NameString field. +func (o *XmlItem) SetNameString(v string) { + o.NameString = &v +} + +// GetNameNumber returns the NameNumber field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameNumber() float32 { + if o == nil || o.NameNumber == nil { + var ret float32 + return ret + } + return *o.NameNumber +} + +// GetNameNumberOk returns a tuple with the NameNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameNumberOk() (float32, bool) { + if o == nil || o.NameNumber == nil { + var ret float32 + return ret, false + } + return *o.NameNumber, true +} + +// HasNameNumber returns a boolean if a field has been set. +func (o *XmlItem) HasNameNumber() bool { + if o != nil && o.NameNumber != nil { + return true + } + + return false +} + +// SetNameNumber gets a reference to the given float32 and assigns it to the NameNumber field. +func (o *XmlItem) SetNameNumber(v float32) { + o.NameNumber = &v +} + +// GetNameInteger returns the NameInteger field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameInteger() int32 { + if o == nil || o.NameInteger == nil { + var ret int32 + return ret + } + return *o.NameInteger +} + +// GetNameIntegerOk returns a tuple with the NameInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameIntegerOk() (int32, bool) { + if o == nil || o.NameInteger == nil { + var ret int32 + return ret, false + } + return *o.NameInteger, true +} + +// HasNameInteger returns a boolean if a field has been set. +func (o *XmlItem) HasNameInteger() bool { + if o != nil && o.NameInteger != nil { + return true + } + + return false +} + +// SetNameInteger gets a reference to the given int32 and assigns it to the NameInteger field. +func (o *XmlItem) SetNameInteger(v int32) { + o.NameInteger = &v +} + +// GetNameBoolean returns the NameBoolean field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameBoolean() bool { + if o == nil || o.NameBoolean == nil { + var ret bool + return ret + } + return *o.NameBoolean +} + +// GetNameBooleanOk returns a tuple with the NameBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameBooleanOk() (bool, bool) { + if o == nil || o.NameBoolean == nil { + var ret bool + return ret, false + } + return *o.NameBoolean, true +} + +// HasNameBoolean returns a boolean if a field has been set. +func (o *XmlItem) HasNameBoolean() bool { + if o != nil && o.NameBoolean != nil { + return true + } + + return false +} + +// SetNameBoolean gets a reference to the given bool and assigns it to the NameBoolean field. +func (o *XmlItem) SetNameBoolean(v bool) { + o.NameBoolean = &v +} + +// GetNameArray returns the NameArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameArray() []int32 { + if o == nil || o.NameArray == nil { + var ret []int32 + return ret + } + return *o.NameArray +} + +// GetNameArrayOk returns a tuple with the NameArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameArrayOk() ([]int32, bool) { + if o == nil || o.NameArray == nil { + var ret []int32 + return ret, false + } + return *o.NameArray, true +} + +// HasNameArray returns a boolean if a field has been set. +func (o *XmlItem) HasNameArray() bool { + if o != nil && o.NameArray != nil { + return true + } + + return false +} + +// SetNameArray gets a reference to the given []int32 and assigns it to the NameArray field. +func (o *XmlItem) SetNameArray(v []int32) { + o.NameArray = &v +} + +// GetNameWrappedArray returns the NameWrappedArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetNameWrappedArray() []int32 { + if o == nil || o.NameWrappedArray == nil { + var ret []int32 + return ret + } + return *o.NameWrappedArray +} + +// GetNameWrappedArrayOk returns a tuple with the NameWrappedArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNameWrappedArrayOk() ([]int32, bool) { + if o == nil || o.NameWrappedArray == nil { + var ret []int32 + return ret, false + } + return *o.NameWrappedArray, true +} + +// HasNameWrappedArray returns a boolean if a field has been set. +func (o *XmlItem) HasNameWrappedArray() bool { + if o != nil && o.NameWrappedArray != nil { + return true + } + + return false +} + +// SetNameWrappedArray gets a reference to the given []int32 and assigns it to the NameWrappedArray field. +func (o *XmlItem) SetNameWrappedArray(v []int32) { + o.NameWrappedArray = &v +} + +// GetPrefixString returns the PrefixString field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixString() string { + if o == nil || o.PrefixString == nil { + var ret string + return ret + } + return *o.PrefixString +} + +// GetPrefixStringOk returns a tuple with the PrefixString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixStringOk() (string, bool) { + if o == nil || o.PrefixString == nil { + var ret string + return ret, false + } + return *o.PrefixString, true +} + +// HasPrefixString returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixString() bool { + if o != nil && o.PrefixString != nil { + return true + } + + return false +} + +// SetPrefixString gets a reference to the given string and assigns it to the PrefixString field. +func (o *XmlItem) SetPrefixString(v string) { + o.PrefixString = &v +} + +// GetPrefixNumber returns the PrefixNumber field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNumber() float32 { + if o == nil || o.PrefixNumber == nil { + var ret float32 + return ret + } + return *o.PrefixNumber +} + +// GetPrefixNumberOk returns a tuple with the PrefixNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNumberOk() (float32, bool) { + if o == nil || o.PrefixNumber == nil { + var ret float32 + return ret, false + } + return *o.PrefixNumber, true +} + +// HasPrefixNumber returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNumber() bool { + if o != nil && o.PrefixNumber != nil { + return true + } + + return false +} + +// SetPrefixNumber gets a reference to the given float32 and assigns it to the PrefixNumber field. +func (o *XmlItem) SetPrefixNumber(v float32) { + o.PrefixNumber = &v +} + +// GetPrefixInteger returns the PrefixInteger field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixInteger() int32 { + if o == nil || o.PrefixInteger == nil { + var ret int32 + return ret + } + return *o.PrefixInteger +} + +// GetPrefixIntegerOk returns a tuple with the PrefixInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixIntegerOk() (int32, bool) { + if o == nil || o.PrefixInteger == nil { + var ret int32 + return ret, false + } + return *o.PrefixInteger, true +} + +// HasPrefixInteger returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixInteger() bool { + if o != nil && o.PrefixInteger != nil { + return true + } + + return false +} + +// SetPrefixInteger gets a reference to the given int32 and assigns it to the PrefixInteger field. +func (o *XmlItem) SetPrefixInteger(v int32) { + o.PrefixInteger = &v +} + +// GetPrefixBoolean returns the PrefixBoolean field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixBoolean() bool { + if o == nil || o.PrefixBoolean == nil { + var ret bool + return ret + } + return *o.PrefixBoolean +} + +// GetPrefixBooleanOk returns a tuple with the PrefixBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixBooleanOk() (bool, bool) { + if o == nil || o.PrefixBoolean == nil { + var ret bool + return ret, false + } + return *o.PrefixBoolean, true +} + +// HasPrefixBoolean returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixBoolean() bool { + if o != nil && o.PrefixBoolean != nil { + return true + } + + return false +} + +// SetPrefixBoolean gets a reference to the given bool and assigns it to the PrefixBoolean field. +func (o *XmlItem) SetPrefixBoolean(v bool) { + o.PrefixBoolean = &v +} + +// GetPrefixArray returns the PrefixArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixArray() []int32 { + if o == nil || o.PrefixArray == nil { + var ret []int32 + return ret + } + return *o.PrefixArray +} + +// GetPrefixArrayOk returns a tuple with the PrefixArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixArrayOk() ([]int32, bool) { + if o == nil || o.PrefixArray == nil { + var ret []int32 + return ret, false + } + return *o.PrefixArray, true +} + +// HasPrefixArray returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixArray() bool { + if o != nil && o.PrefixArray != nil { + return true + } + + return false +} + +// SetPrefixArray gets a reference to the given []int32 and assigns it to the PrefixArray field. +func (o *XmlItem) SetPrefixArray(v []int32) { + o.PrefixArray = &v +} + +// GetPrefixWrappedArray returns the PrefixWrappedArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixWrappedArray() []int32 { + if o == nil || o.PrefixWrappedArray == nil { + var ret []int32 + return ret + } + return *o.PrefixWrappedArray +} + +// GetPrefixWrappedArrayOk returns a tuple with the PrefixWrappedArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixWrappedArrayOk() ([]int32, bool) { + if o == nil || o.PrefixWrappedArray == nil { + var ret []int32 + return ret, false + } + return *o.PrefixWrappedArray, true +} + +// HasPrefixWrappedArray returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixWrappedArray() bool { + if o != nil && o.PrefixWrappedArray != nil { + return true + } + + return false +} + +// SetPrefixWrappedArray gets a reference to the given []int32 and assigns it to the PrefixWrappedArray field. +func (o *XmlItem) SetPrefixWrappedArray(v []int32) { + o.PrefixWrappedArray = &v +} + +// GetNamespaceString returns the NamespaceString field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceString() string { + if o == nil || o.NamespaceString == nil { + var ret string + return ret + } + return *o.NamespaceString +} + +// GetNamespaceStringOk returns a tuple with the NamespaceString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceStringOk() (string, bool) { + if o == nil || o.NamespaceString == nil { + var ret string + return ret, false + } + return *o.NamespaceString, true +} + +// HasNamespaceString returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceString() bool { + if o != nil && o.NamespaceString != nil { + return true + } + + return false +} + +// SetNamespaceString gets a reference to the given string and assigns it to the NamespaceString field. +func (o *XmlItem) SetNamespaceString(v string) { + o.NamespaceString = &v +} + +// GetNamespaceNumber returns the NamespaceNumber field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceNumber() float32 { + if o == nil || o.NamespaceNumber == nil { + var ret float32 + return ret + } + return *o.NamespaceNumber +} + +// GetNamespaceNumberOk returns a tuple with the NamespaceNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceNumberOk() (float32, bool) { + if o == nil || o.NamespaceNumber == nil { + var ret float32 + return ret, false + } + return *o.NamespaceNumber, true +} + +// HasNamespaceNumber returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceNumber() bool { + if o != nil && o.NamespaceNumber != nil { + return true + } + + return false +} + +// SetNamespaceNumber gets a reference to the given float32 and assigns it to the NamespaceNumber field. +func (o *XmlItem) SetNamespaceNumber(v float32) { + o.NamespaceNumber = &v +} + +// GetNamespaceInteger returns the NamespaceInteger field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceInteger() int32 { + if o == nil || o.NamespaceInteger == nil { + var ret int32 + return ret + } + return *o.NamespaceInteger +} + +// GetNamespaceIntegerOk returns a tuple with the NamespaceInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceIntegerOk() (int32, bool) { + if o == nil || o.NamespaceInteger == nil { + var ret int32 + return ret, false + } + return *o.NamespaceInteger, true +} + +// HasNamespaceInteger returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceInteger() bool { + if o != nil && o.NamespaceInteger != nil { + return true + } + + return false +} + +// SetNamespaceInteger gets a reference to the given int32 and assigns it to the NamespaceInteger field. +func (o *XmlItem) SetNamespaceInteger(v int32) { + o.NamespaceInteger = &v +} + +// GetNamespaceBoolean returns the NamespaceBoolean field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceBoolean() bool { + if o == nil || o.NamespaceBoolean == nil { + var ret bool + return ret + } + return *o.NamespaceBoolean +} + +// GetNamespaceBooleanOk returns a tuple with the NamespaceBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceBooleanOk() (bool, bool) { + if o == nil || o.NamespaceBoolean == nil { + var ret bool + return ret, false + } + return *o.NamespaceBoolean, true +} + +// HasNamespaceBoolean returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceBoolean() bool { + if o != nil && o.NamespaceBoolean != nil { + return true + } + + return false +} + +// SetNamespaceBoolean gets a reference to the given bool and assigns it to the NamespaceBoolean field. +func (o *XmlItem) SetNamespaceBoolean(v bool) { + o.NamespaceBoolean = &v +} + +// GetNamespaceArray returns the NamespaceArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceArray() []int32 { + if o == nil || o.NamespaceArray == nil { + var ret []int32 + return ret + } + return *o.NamespaceArray +} + +// GetNamespaceArrayOk returns a tuple with the NamespaceArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceArrayOk() ([]int32, bool) { + if o == nil || o.NamespaceArray == nil { + var ret []int32 + return ret, false + } + return *o.NamespaceArray, true +} + +// HasNamespaceArray returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceArray() bool { + if o != nil && o.NamespaceArray != nil { + return true + } + + return false +} + +// SetNamespaceArray gets a reference to the given []int32 and assigns it to the NamespaceArray field. +func (o *XmlItem) SetNamespaceArray(v []int32) { + o.NamespaceArray = &v +} + +// GetNamespaceWrappedArray returns the NamespaceWrappedArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetNamespaceWrappedArray() []int32 { + if o == nil || o.NamespaceWrappedArray == nil { + var ret []int32 + return ret + } + return *o.NamespaceWrappedArray +} + +// GetNamespaceWrappedArrayOk returns a tuple with the NamespaceWrappedArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetNamespaceWrappedArrayOk() ([]int32, bool) { + if o == nil || o.NamespaceWrappedArray == nil { + var ret []int32 + return ret, false + } + return *o.NamespaceWrappedArray, true +} + +// HasNamespaceWrappedArray returns a boolean if a field has been set. +func (o *XmlItem) HasNamespaceWrappedArray() bool { + if o != nil && o.NamespaceWrappedArray != nil { + return true + } + + return false +} + +// SetNamespaceWrappedArray gets a reference to the given []int32 and assigns it to the NamespaceWrappedArray field. +func (o *XmlItem) SetNamespaceWrappedArray(v []int32) { + o.NamespaceWrappedArray = &v +} + +// GetPrefixNsString returns the PrefixNsString field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsString() string { + if o == nil || o.PrefixNsString == nil { + var ret string + return ret + } + return *o.PrefixNsString +} + +// GetPrefixNsStringOk returns a tuple with the PrefixNsString field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsStringOk() (string, bool) { + if o == nil || o.PrefixNsString == nil { + var ret string + return ret, false + } + return *o.PrefixNsString, true +} + +// HasPrefixNsString returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsString() bool { + if o != nil && o.PrefixNsString != nil { + return true + } + + return false +} + +// SetPrefixNsString gets a reference to the given string and assigns it to the PrefixNsString field. +func (o *XmlItem) SetPrefixNsString(v string) { + o.PrefixNsString = &v +} + +// GetPrefixNsNumber returns the PrefixNsNumber field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsNumber() float32 { + if o == nil || o.PrefixNsNumber == nil { + var ret float32 + return ret + } + return *o.PrefixNsNumber +} + +// GetPrefixNsNumberOk returns a tuple with the PrefixNsNumber field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsNumberOk() (float32, bool) { + if o == nil || o.PrefixNsNumber == nil { + var ret float32 + return ret, false + } + return *o.PrefixNsNumber, true +} + +// HasPrefixNsNumber returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsNumber() bool { + if o != nil && o.PrefixNsNumber != nil { + return true + } + + return false +} + +// SetPrefixNsNumber gets a reference to the given float32 and assigns it to the PrefixNsNumber field. +func (o *XmlItem) SetPrefixNsNumber(v float32) { + o.PrefixNsNumber = &v +} + +// GetPrefixNsInteger returns the PrefixNsInteger field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsInteger() int32 { + if o == nil || o.PrefixNsInteger == nil { + var ret int32 + return ret + } + return *o.PrefixNsInteger +} + +// GetPrefixNsIntegerOk returns a tuple with the PrefixNsInteger field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsIntegerOk() (int32, bool) { + if o == nil || o.PrefixNsInteger == nil { + var ret int32 + return ret, false + } + return *o.PrefixNsInteger, true +} + +// HasPrefixNsInteger returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsInteger() bool { + if o != nil && o.PrefixNsInteger != nil { + return true + } + + return false +} + +// SetPrefixNsInteger gets a reference to the given int32 and assigns it to the PrefixNsInteger field. +func (o *XmlItem) SetPrefixNsInteger(v int32) { + o.PrefixNsInteger = &v +} + +// GetPrefixNsBoolean returns the PrefixNsBoolean field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsBoolean() bool { + if o == nil || o.PrefixNsBoolean == nil { + var ret bool + return ret + } + return *o.PrefixNsBoolean +} + +// GetPrefixNsBooleanOk returns a tuple with the PrefixNsBoolean field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsBooleanOk() (bool, bool) { + if o == nil || o.PrefixNsBoolean == nil { + var ret bool + return ret, false + } + return *o.PrefixNsBoolean, true +} + +// HasPrefixNsBoolean returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsBoolean() bool { + if o != nil && o.PrefixNsBoolean != nil { + return true + } + + return false +} + +// SetPrefixNsBoolean gets a reference to the given bool and assigns it to the PrefixNsBoolean field. +func (o *XmlItem) SetPrefixNsBoolean(v bool) { + o.PrefixNsBoolean = &v +} + +// GetPrefixNsArray returns the PrefixNsArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsArray() []int32 { + if o == nil || o.PrefixNsArray == nil { + var ret []int32 + return ret + } + return *o.PrefixNsArray +} + +// GetPrefixNsArrayOk returns a tuple with the PrefixNsArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsArrayOk() ([]int32, bool) { + if o == nil || o.PrefixNsArray == nil { + var ret []int32 + return ret, false + } + return *o.PrefixNsArray, true +} + +// HasPrefixNsArray returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsArray() bool { + if o != nil && o.PrefixNsArray != nil { + return true + } + + return false +} + +// SetPrefixNsArray gets a reference to the given []int32 and assigns it to the PrefixNsArray field. +func (o *XmlItem) SetPrefixNsArray(v []int32) { + o.PrefixNsArray = &v +} + +// GetPrefixNsWrappedArray returns the PrefixNsWrappedArray field if non-nil, zero value otherwise. +func (o *XmlItem) GetPrefixNsWrappedArray() []int32 { + if o == nil || o.PrefixNsWrappedArray == nil { + var ret []int32 + return ret + } + return *o.PrefixNsWrappedArray +} + +// GetPrefixNsWrappedArrayOk returns a tuple with the PrefixNsWrappedArray field if it's non-nil, zero value otherwise +// and a boolean to check if the value has been set. +func (o *XmlItem) GetPrefixNsWrappedArrayOk() ([]int32, bool) { + if o == nil || o.PrefixNsWrappedArray == nil { + var ret []int32 + return ret, false + } + return *o.PrefixNsWrappedArray, true +} + +// HasPrefixNsWrappedArray returns a boolean if a field has been set. +func (o *XmlItem) HasPrefixNsWrappedArray() bool { + if o != nil && o.PrefixNsWrappedArray != nil { + return true + } + + return false +} + +// SetPrefixNsWrappedArray gets a reference to the given []int32 and assigns it to the PrefixNsWrappedArray field. +func (o *XmlItem) SetPrefixNsWrappedArray(v []int32) { + o.PrefixNsWrappedArray = &v +} + + +func (o XmlItem) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AttributeString != nil { + toSerialize["attribute_string"] = o.AttributeString + } + if o.AttributeNumber != nil { + toSerialize["attribute_number"] = o.AttributeNumber + } + if o.AttributeInteger != nil { + toSerialize["attribute_integer"] = o.AttributeInteger + } + if o.AttributeBoolean != nil { + toSerialize["attribute_boolean"] = o.AttributeBoolean + } + if o.WrappedArray != nil { + toSerialize["wrapped_array"] = o.WrappedArray + } + if o.NameString != nil { + toSerialize["name_string"] = o.NameString + } + if o.NameNumber != nil { + toSerialize["name_number"] = o.NameNumber + } + if o.NameInteger != nil { + toSerialize["name_integer"] = o.NameInteger + } + if o.NameBoolean != nil { + toSerialize["name_boolean"] = o.NameBoolean + } + if o.NameArray != nil { + toSerialize["name_array"] = o.NameArray + } + if o.NameWrappedArray != nil { + toSerialize["name_wrapped_array"] = o.NameWrappedArray + } + if o.PrefixString != nil { + toSerialize["prefix_string"] = o.PrefixString + } + if o.PrefixNumber != nil { + toSerialize["prefix_number"] = o.PrefixNumber + } + if o.PrefixInteger != nil { + toSerialize["prefix_integer"] = o.PrefixInteger + } + if o.PrefixBoolean != nil { + toSerialize["prefix_boolean"] = o.PrefixBoolean + } + if o.PrefixArray != nil { + toSerialize["prefix_array"] = o.PrefixArray + } + if o.PrefixWrappedArray != nil { + toSerialize["prefix_wrapped_array"] = o.PrefixWrappedArray + } + if o.NamespaceString != nil { + toSerialize["namespace_string"] = o.NamespaceString + } + if o.NamespaceNumber != nil { + toSerialize["namespace_number"] = o.NamespaceNumber + } + if o.NamespaceInteger != nil { + toSerialize["namespace_integer"] = o.NamespaceInteger + } + if o.NamespaceBoolean != nil { + toSerialize["namespace_boolean"] = o.NamespaceBoolean + } + if o.NamespaceArray != nil { + toSerialize["namespace_array"] = o.NamespaceArray + } + if o.NamespaceWrappedArray != nil { + toSerialize["namespace_wrapped_array"] = o.NamespaceWrappedArray + } + if o.PrefixNsString != nil { + toSerialize["prefix_ns_string"] = o.PrefixNsString + } + if o.PrefixNsNumber != nil { + toSerialize["prefix_ns_number"] = o.PrefixNsNumber + } + if o.PrefixNsInteger != nil { + toSerialize["prefix_ns_integer"] = o.PrefixNsInteger + } + if o.PrefixNsBoolean != nil { + toSerialize["prefix_ns_boolean"] = o.PrefixNsBoolean + } + if o.PrefixNsArray != nil { + toSerialize["prefix_ns_array"] = o.PrefixNsArray + } + if o.PrefixNsWrappedArray != nil { + toSerialize["prefix_ns_wrapped_array"] = o.PrefixNsWrappedArray + } + return json.Marshal(toSerialize) +} + + diff --git a/samples/client/petstore/go-experimental/go-petstore/utils.go b/samples/client/petstore/go-experimental/go-petstore/utils.go new file mode 100644 index 0000000000..8d2130be3f --- /dev/null +++ b/samples/client/petstore/go-experimental/go-petstore/utils.go @@ -0,0 +1,39 @@ +/* + * OpenAPI Petstore + * + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ + * + * API version: 1.0.0 + * Generated by: OpenAPI Generator (https://openapi-generator.tech) + */ + +package petstore + +import "time" + +// PtrBool is a helper routine that returns a pointer to given integer value. +func PtrBool(v bool) *bool { return &v } + +// PtrInt is a helper routine that returns a pointer to given integer value. +func PtrInt(v int) *int { return &v } + +// PtrInt32 is a helper routine that returns a pointer to given integer value. +func PtrInt32(v int32) *int32 { return &v } + +// PtrInt64 is a helper routine that returns a pointer to given integer value. +func PtrInt64(v int64) *int64 { return &v } + +// PtrFloat is a helper routine that returns a pointer to given float value. +func PtrFloat(v float32) *float32 { return &v } + +// PtrFloat32 is a helper routine that returns a pointer to given float value. +func PtrFloat32(v float32) *float32 { return &v } + +// PtrFloat64 is a helper routine that returns a pointer to given float value. +func PtrFloat64(v float64) *float64 { return &v } + +// PtrString is a helper routine that returns a pointer to given string value. +func PtrString(v string) *string { return &v } + +// PtrTime is helper routine that returns a pointer to given Time value. +func PtrTime(v time.Time) *time.Time { return &v } \ No newline at end of file diff --git a/samples/client/petstore/go-experimental/pet_api_test.go b/samples/client/petstore/go-experimental/pet_api_test.go index 969fab1f66..c1e8006bb0 100644 --- a/samples/client/petstore/go-experimental/pet_api_test.go +++ b/samples/client/petstore/go-experimental/pet_api_test.go @@ -28,8 +28,9 @@ func TestMain(m *testing.M) { } func TestAddPet(t *testing.T) { - newPet := (sw.Pet{Id: 12830, Name: "gopher", - PhotoUrls: []string{"http://1.com", "http://2.com"}, Status: "pending", Tags: []sw.Tag{sw.Tag{Id: 1, Name: "tag2"}}}) + newPet := (sw.Pet{Id: sw.PtrInt64(12830), Name: sw.PtrString("gopher"), + PhotoUrls: &[]string{"http://1.com", "http://2.com"}, Status: sw.PtrString("pending"), + Tags: &[]sw.Tag{sw.Tag{Id: sw.PtrInt64(1), Name: sw.PtrString("tag2")}}}) r, err := client.PetApi.AddPet(context.Background(), newPet) @@ -86,8 +87,8 @@ func TestUpdatePetWithForm(t *testing.T) { t.Log(r) } - // get the pet with id 12830 from server to verify the update - isPetCorrect(t, 12830, "golang", "available") + // get the pet with id 12830 from server to verify the update + isPetCorrect(t, 12830, "golang", "available") } func TestFindPetsByTag(t *testing.T) { @@ -103,8 +104,8 @@ func TestFindPetsByTag(t *testing.T) { assert := assert.New(t) for i := 0; i < len(resp); i++ { - if resp[i].Id == 12830 { - assert.Equal(resp[i].Status, "available", "Pet status should be `pending`") + if *resp[i].Id == 12830 { + assert.Equal(*resp[i].Status, "available", "Pet status should be `pending`") found = true } } @@ -131,7 +132,7 @@ func TestFindPetsByStatus(t *testing.T) { } else { assert := assert.New(t) for i := 0; i < len(resp); i++ { - assert.Equal(resp[i].Status, "available", "Pet status should be `available`") + assert.Equal(*resp[i].Status, "available", "Pet status should be `available`") } } @@ -284,9 +285,9 @@ func isPetCorrect(t *testing.T, id int64, name string, status string) { if err != nil { t.Fatalf("Error while getting pet by id: %v", err) } else { - assert.Equal(resp.Id, int64(id), "Pet id should be equal") - assert.Equal(resp.Name, name, fmt.Sprintf("Pet name should be %s", name)) - assert.Equal(resp.Status, status, fmt.Sprintf("Pet status should be %s", status)) + assert.Equal(*resp.Id, int64(id), "Pet id should be equal") + assert.Equal(*resp.Name, name, fmt.Sprintf("Pet name should be %s", name)) + assert.Equal(*resp.Status, status, fmt.Sprintf("Pet status should be %s", status)) //t.Log(resp) } @@ -294,4 +295,3 @@ func isPetCorrect(t *testing.T, id int64, name string, status string) { t.Log(r) } } - diff --git a/samples/client/petstore/go-experimental/store_api_test.go b/samples/client/petstore/go-experimental/store_api_test.go index 3088adf7b4..81f4fd7e33 100644 --- a/samples/client/petstore/go-experimental/store_api_test.go +++ b/samples/client/petstore/go-experimental/store_api_test.go @@ -11,12 +11,12 @@ import ( func TestPlaceOrder(t *testing.T) { newOrder := sw.Order{ - Id: 0, - PetId: 0, - Quantity: 0, - ShipDate: time.Now().UTC(), - Status: "placed", - Complete: false} + Id: sw.PtrInt64(0), + PetId: sw.PtrInt64(0), + Quantity: sw.PtrInt32(0), + ShipDate: sw.PtrTime(time.Now().UTC()), + Status: sw.PtrString("placed"), + Complete: sw.PtrBool(false)} _, r, err := client.StoreApi.PlaceOrder(context.Background(), newOrder) diff --git a/samples/client/petstore/go-experimental/user_api_test.go b/samples/client/petstore/go-experimental/user_api_test.go index 012c608fab..07b82ebb97 100644 --- a/samples/client/petstore/go-experimental/user_api_test.go +++ b/samples/client/petstore/go-experimental/user_api_test.go @@ -11,14 +11,14 @@ import ( func TestCreateUser(t *testing.T) { newUser := sw.User{ - Id: 1000, - FirstName: "gopher", - LastName: "lang", - Username: "gopher", - Password: "lang", - Email: "lang@test.com", - Phone: "5101112222", - UserStatus: 1} + Id: sw.PtrInt64(1000), + FirstName: sw.PtrString("gopher"), + LastName: sw.PtrString("lang"), + Username: sw.PtrString("gopher"), + Password: sw.PtrString("lang"), + Email: sw.PtrString("lang@test.com"), + Phone: sw.PtrString("5101112222"), + UserStatus: sw.PtrInt32(1)} apiResponse, err := client.UserApi.CreateUser(context.Background(), newUser) @@ -34,24 +34,24 @@ func TestCreateUser(t *testing.T) { func TestCreateUsersWithArrayInput(t *testing.T) { newUsers := []sw.User{ sw.User{ - Id: int64(1001), - FirstName: "gopher1", - LastName: "lang1", - Username: "gopher1", - Password: "lang1", - Email: "lang1@test.com", - Phone: "5101112222", - UserStatus: int32(1), + Id: sw.PtrInt64(1001), + FirstName: sw.PtrString("gopher1"), + LastName: sw.PtrString("lang1"), + Username: sw.PtrString("gopher1"), + Password: sw.PtrString("lang1"), + Email: sw.PtrString("lang1@test.com"), + Phone: sw.PtrString("5101112222"), + UserStatus: sw.PtrInt32(1), }, sw.User{ - Id: int64(1002), - FirstName: "gopher2", - LastName: "lang2", - Username: "gopher2", - Password: "lang2", - Email: "lang2@test.com", - Phone: "5101112222", - UserStatus: int32(1), + Id: sw.PtrInt64(1002), + FirstName: sw.PtrString("gopher2"), + LastName: sw.PtrString("lang2"), + Username: sw.PtrString("gopher2"), + Password: sw.PtrString("lang2"), + Email: sw.PtrString("lang2@test.com"), + Phone: sw.PtrString("5101112222"), + UserStatus: sw.PtrInt32(1), }, } @@ -84,9 +84,9 @@ func TestGetUserByName(t *testing.T) { if err != nil { t.Fatalf("Error while getting user by id: %v", err) } else { - assert.Equal(resp.Id, int64(1000), "User id should be equal") - assert.Equal(resp.Username, "gopher", "User name should be gopher") - assert.Equal(resp.LastName, "lang", "Last name should be lang") + assert.Equal(*resp.Id, int64(1000), "User id should be equal") + assert.Equal(*resp.Username, "gopher", "User name should be gopher") + assert.Equal(*resp.LastName, "lang", "Last name should be lang") //t.Log(resp) } if apiResponse.StatusCode != 200 { @@ -113,14 +113,14 @@ func TestUpdateUser(t *testing.T) { assert := assert.New(t) newUser := sw.User{ - Id: 1000, - FirstName: "gopher20", - LastName: "lang20", - Username: "gopher", - Password: "lang", - Email: "lang@test.com", - Phone: "5101112222", - UserStatus: 1} + Id: sw.PtrInt64(1000), + FirstName: sw.PtrString("gopher20"), + LastName: sw.PtrString("lang20"), + Username: sw.PtrString("gopher"), + Password: sw.PtrString("lang"), + Email: sw.PtrString("lang@test.com"), + Phone: sw.PtrString("5101112222"), + UserStatus: sw.PtrInt32(1)} apiResponse, err := client.UserApi.UpdateUser(context.Background(), "gopher", newUser) if err != nil { @@ -135,9 +135,9 @@ func TestUpdateUser(t *testing.T) { if err != nil { t.Fatalf("Error while getting user by id: %v", err) } else { - assert.Equal(resp.Id, int64(1000), "User id should be equal") - assert.Equal(resp.FirstName, "gopher20", "User name should be gopher") - assert.Equal(resp.Password, "lang", "User name should be the same") + assert.Equal(*resp.Id, int64(1000), "User id should be equal") + assert.Equal(*resp.FirstName, "gopher20", "User name should be gopher") + assert.Equal(*resp.Password, "lang", "User name should be the same") } } From 26b8d1f4c2e6f09a17979a7f7ea18704d4606fbf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Courtine?= Date: Thu, 18 Jul 2019 11:08:48 +0200 Subject: [PATCH 27/62] Better Rust client imports (#3332) * Better Rust client imports. * No more "unused_imports" in models for serde_json::Value. * No more compilation problem for apis requiring serde_json::Value. * "crate::" prefix for models and apis imports, for compatibility with Rust 2018 edition. * Rust samples regeneration using new code. --- .../codegen/languages/RustClientCodegen.java | 8 +++---- .../main/resources/rust/hyper/api.mustache | 4 ++-- .../main/resources/rust/hyper/client.mustache | 6 ++--- .../src/main/resources/rust/model.mustache | 3 --- .../main/resources/rust/reqwest/api.mustache | 4 ++-- .../resources/rust/reqwest/client.mustache | 6 ++--- .../rust-reqwest/.openapi-generator/VERSION | 2 +- .../client/petstore/rust-reqwest/docs/Pet.md | 4 ++-- .../petstore/rust-reqwest/docs/PetApi.md | 16 ++++++------- .../petstore/rust-reqwest/docs/StoreApi.md | 8 +++---- .../petstore/rust-reqwest/docs/UserApi.md | 8 +++---- .../petstore/rust-reqwest/src/apis/client.rs | 18 +++++++------- .../petstore/rust-reqwest/src/apis/pet_api.rs | 24 +++++++++---------- .../rust-reqwest/src/apis/store_api.rs | 8 +++---- .../rust-reqwest/src/apis/user_api.rs | 20 ++++++++-------- .../rust-reqwest/src/models/api_response.rs | 3 --- .../rust-reqwest/src/models/category.rs | 3 --- .../petstore/rust-reqwest/src/models/order.rs | 3 --- .../petstore/rust-reqwest/src/models/pet.rs | 7 ++---- .../petstore/rust-reqwest/src/models/tag.rs | 3 --- .../petstore/rust-reqwest/src/models/user.rs | 3 --- .../petstore/rust/.openapi-generator/VERSION | 2 +- samples/client/petstore/rust/docs/Pet.md | 4 ++-- samples/client/petstore/rust/docs/PetApi.md | 16 ++++++------- samples/client/petstore/rust/docs/StoreApi.md | 8 +++---- samples/client/petstore/rust/docs/UserApi.md | 8 +++---- .../client/petstore/rust/src/apis/client.rs | 18 +++++++------- .../client/petstore/rust/src/apis/pet_api.rs | 24 +++++++++---------- .../petstore/rust/src/apis/store_api.rs | 8 +++---- .../client/petstore/rust/src/apis/user_api.rs | 20 ++++++++-------- .../petstore/rust/src/models/api_response.rs | 3 --- .../petstore/rust/src/models/category.rs | 3 --- .../client/petstore/rust/src/models/order.rs | 3 --- .../client/petstore/rust/src/models/pet.rs | 7 ++---- .../client/petstore/rust/src/models/tag.rs | 3 --- .../client/petstore/rust/src/models/user.rs | 3 --- 36 files changed, 126 insertions(+), 165 deletions(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RustClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RustClientCodegen.java index 6bd358bd23..ad2c260cac 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RustClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/RustClientCodegen.java @@ -124,9 +124,9 @@ public class RustClientCodegen extends DefaultCodegen implements CodegenConfig { // I tried to map as "std::io::File", but Reqwest multipart file requires a "AsRef" param. // Getting a file from a Path is simple, but the opposite is difficult. So I map as "std::path::Path". typeMapping.put("file", "std::path::PathBuf"); - typeMapping.put("binary", "::models::File"); + typeMapping.put("binary", "crate::models::File"); typeMapping.put("ByteArray", "String"); - typeMapping.put("object", "Value"); + typeMapping.put("object", "serde_json::Value"); // no need for rust //importMapping = new HashMap(); @@ -352,8 +352,8 @@ public class RustClientCodegen extends DefaultCodegen implements CodegenConfig { } // return fully-qualified model name - // ::models::{{classnameFile}}::{{classname}} - return "::models::" + toModelName(schemaType); + // crate::models::{{classnameFile}}::{{classname}} + return "crate::models::" + toModelName(schemaType); } @Override diff --git a/modules/openapi-generator/src/main/resources/rust/hyper/api.mustache b/modules/openapi-generator/src/main/resources/rust/hyper/api.mustache index 426fee7fe8..872148bddd 100644 --- a/modules/openapi-generator/src/main/resources/rust/hyper/api.mustache +++ b/modules/openapi-generator/src/main/resources/rust/hyper/api.mustache @@ -24,7 +24,7 @@ impl {{{classname}}}Client { pub trait {{{classname}}} { {{#operations}} {{#operation}} - fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Box>>; + fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}crate::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Box>>; {{/operation}} {{/operations}} } @@ -33,7 +33,7 @@ pub trait {{{classname}}} { impl{{{classname}}} for {{{classname}}}Client { {{#operations}} {{#operation}} - fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Box>> { + fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}crate::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Box>> { __internal_request::Request::new(hyper::Method::{{{httpMethod}}}, "{{{path}}}".to_string()) {{#hasAuthMethods}} {{#authMethods}} diff --git a/modules/openapi-generator/src/main/resources/rust/hyper/client.mustache b/modules/openapi-generator/src/main/resources/rust/hyper/client.mustache index f93577e7cb..a0648b758b 100644 --- a/modules/openapi-generator/src/main/resources/rust/hyper/client.mustache +++ b/modules/openapi-generator/src/main/resources/rust/hyper/client.mustache @@ -10,7 +10,7 @@ pub struct APIClient { {{#operations}} {{#operation}} {{#-last}} - {{{classFilename}}}: Box<::apis::{{{classname}}}>, + {{{classFilename}}}: Box, {{/-last}} {{/operation}} {{/operations}} @@ -29,7 +29,7 @@ impl APIClient { {{#operations}} {{#operation}} {{#-last}} - {{{classFilename}}}: Box::new(::apis::{{{classname}}}Client::new(rc.clone())), + {{{classFilename}}}: Box::new(crate::apis::{{{classname}}}Client::new(rc.clone())), {{/-last}} {{/operation}} {{/operations}} @@ -43,7 +43,7 @@ impl APIClient { {{#operations}} {{#operation}} {{#-last}} - pub fn {{{classFilename}}}(&self) -> &::apis::{{{classname}}}{ + pub fn {{{classFilename}}}(&self) -> &crate::apis::{{{classname}}}{ self.{{{classFilename}}}.as_ref() } diff --git a/modules/openapi-generator/src/main/resources/rust/model.mustache b/modules/openapi-generator/src/main/resources/rust/model.mustache index 4c6b8dff10..37a3ff77bc 100644 --- a/modules/openapi-generator/src/main/resources/rust/model.mustache +++ b/modules/openapi-generator/src/main/resources/rust/model.mustache @@ -5,9 +5,6 @@ /// {{{classname}}} : {{{description}}} {{/description}} -#[allow(unused_imports)] -use serde_json::Value; - {{!-- for enum schemas --}} {{#isEnum}} /// {{{description}}} diff --git a/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache b/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache index e6706f7afe..038284ec6c 100644 --- a/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache +++ b/modules/openapi-generator/src/main/resources/rust/reqwest/api.mustache @@ -21,7 +21,7 @@ impl {{{classname}}}Client { pub trait {{{classname}}} { {{#operations}} {{#operation}} - fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Result<{{^returnType}}(){{/returnType}}{{#returnType}}{{{returnType}}}{{/returnType}}, Error>; + fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}crate::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Result<{{^returnType}}(){{/returnType}}{{#returnType}}{{{returnType}}}{{/returnType}}, Error>; {{/operation}} {{/operations}} } @@ -29,7 +29,7 @@ pub trait {{{classname}}} { impl {{{classname}}} for {{{classname}}}Client { {{#operations}} {{#operation}} - fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Result<{{^returnType}}(){{/returnType}}{{#returnType}}{{{returnType}}}{{/returnType}}, Error> { + fn {{{operationId}}}(&self, {{#allParams}}{{{paramName}}}: {{#isString}}&str{{/isString}}{{#isUuid}}&str{{/isUuid}}{{^isString}}{{^isUuid}}{{^isPrimitiveType}}{{^isContainer}}crate::models::{{/isContainer}}{{/isPrimitiveType}}{{{dataType}}}{{/isUuid}}{{/isString}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) -> Result<{{^returnType}}(){{/returnType}}{{#returnType}}{{{returnType}}}{{/returnType}}, Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; diff --git a/modules/openapi-generator/src/main/resources/rust/reqwest/client.mustache b/modules/openapi-generator/src/main/resources/rust/reqwest/client.mustache index 33f2b2fd61..5fdede09c4 100644 --- a/modules/openapi-generator/src/main/resources/rust/reqwest/client.mustache +++ b/modules/openapi-generator/src/main/resources/rust/reqwest/client.mustache @@ -9,7 +9,7 @@ pub struct APIClient { {{#operations}} {{#operation}} {{#-last}} - {{{classFilename}}}: Box<::apis::{{{classname}}}>, + {{{classFilename}}}: Box, {{/-last}} {{/operation}} {{/operations}} @@ -28,7 +28,7 @@ impl APIClient { {{#operations}} {{#operation}} {{#-last}} - {{{classFilename}}}: Box::new(::apis::{{{classname}}}Client::new(rc.clone())), + {{{classFilename}}}: Box::new(crate::apis::{{{classname}}}Client::new(rc.clone())), {{/-last}} {{/operation}} {{/operations}} @@ -42,7 +42,7 @@ impl APIClient { {{#operations}} {{#operation}} {{#-last}} - pub fn {{{classFilename}}}(&self) -> &::apis::{{{classname}}}{ + pub fn {{{classFilename}}}(&self) -> &crate::apis::{{{classname}}}{ self.{{{classFilename}}}.as_ref() } diff --git a/samples/client/petstore/rust-reqwest/.openapi-generator/VERSION b/samples/client/petstore/rust-reqwest/.openapi-generator/VERSION index d96260ba33..83a328a922 100644 --- a/samples/client/petstore/rust-reqwest/.openapi-generator/VERSION +++ b/samples/client/petstore/rust-reqwest/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.2-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/rust-reqwest/docs/Pet.md b/samples/client/petstore/rust-reqwest/docs/Pet.md index 53a462e68b..2c8ea36dd9 100644 --- a/samples/client/petstore/rust-reqwest/docs/Pet.md +++ b/samples/client/petstore/rust-reqwest/docs/Pet.md @@ -5,10 +5,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **id** | **i64** | | [optional] -**category** | [***::models::Category**](Category.md) | | [optional] +**category** | [***crate::models::Category**](Category.md) | | [optional] **name** | **String** | | **photo_urls** | **Vec** | | -**tags** | [**Vec<::models::Tag>**](Tag.md) | | [optional] +**tags** | [**Vec**](Tag.md) | | [optional] **status** | **String** | pet status in the store | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/rust-reqwest/docs/PetApi.md b/samples/client/petstore/rust-reqwest/docs/PetApi.md index a74635038e..336116bee5 100644 --- a/samples/client/petstore/rust-reqwest/docs/PetApi.md +++ b/samples/client/petstore/rust-reqwest/docs/PetApi.md @@ -85,7 +85,7 @@ Name | Type | Description | Notes ## find_pets_by_status -> Vec<::models::Pet> find_pets_by_status(ctx, status) +> Vec find_pets_by_status(ctx, status) Finds Pets by status Multiple status values can be provided with comma separated strings @@ -100,7 +100,7 @@ Name | Type | Description | Notes ### Return type -[**Vec<::models::Pet>**](Pet.md) +[**Vec**](Pet.md) ### Authorization @@ -116,7 +116,7 @@ Name | Type | Description | Notes ## find_pets_by_tags -> Vec<::models::Pet> find_pets_by_tags(ctx, tags) +> Vec find_pets_by_tags(ctx, tags) Finds Pets by tags Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. @@ -131,7 +131,7 @@ Name | Type | Description | Notes ### Return type -[**Vec<::models::Pet>**](Pet.md) +[**Vec**](Pet.md) ### Authorization @@ -147,7 +147,7 @@ Name | Type | Description | Notes ## get_pet_by_id -> ::models::Pet get_pet_by_id(ctx, pet_id) +> crate::models::Pet get_pet_by_id(ctx, pet_id) Find pet by ID Returns a single pet @@ -162,7 +162,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Pet**](Pet.md) +[**crate::models::Pet**](Pet.md) ### Authorization @@ -247,7 +247,7 @@ Name | Type | Description | Notes ## upload_file -> ::models::ApiResponse upload_file(ctx, pet_id, optional) +> crate::models::ApiResponse upload_file(ctx, pet_id, optional) uploads an image ### Required Parameters @@ -271,7 +271,7 @@ Name | Type | Description | Notes ### Return type -[**::models::ApiResponse**](ApiResponse.md) +[**crate::models::ApiResponse**](ApiResponse.md) ### Authorization diff --git a/samples/client/petstore/rust-reqwest/docs/StoreApi.md b/samples/client/petstore/rust-reqwest/docs/StoreApi.md index e57378b9f8..28ae8c60af 100644 --- a/samples/client/petstore/rust-reqwest/docs/StoreApi.md +++ b/samples/client/petstore/rust-reqwest/docs/StoreApi.md @@ -70,7 +70,7 @@ This endpoint does not need any parameter. ## get_order_by_id -> ::models::Order get_order_by_id(order_id) +> crate::models::Order get_order_by_id(order_id) Find purchase order by ID For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions @@ -84,7 +84,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Order**](Order.md) +[**crate::models::Order**](Order.md) ### Authorization @@ -100,7 +100,7 @@ No authorization required ## place_order -> ::models::Order place_order(body) +> crate::models::Order place_order(body) Place an order for a pet ### Required Parameters @@ -112,7 +112,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Order**](Order.md) +[**crate::models::Order**](Order.md) ### Authorization diff --git a/samples/client/petstore/rust-reqwest/docs/UserApi.md b/samples/client/petstore/rust-reqwest/docs/UserApi.md index d469a52df8..ce5490e806 100644 --- a/samples/client/petstore/rust-reqwest/docs/UserApi.md +++ b/samples/client/petstore/rust-reqwest/docs/UserApi.md @@ -55,7 +55,7 @@ Creates list of users with given input array Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Vec<::models::User>**](User.md)| List of user object | + **body** | [**Vec**](User.md)| List of user object | ### Return type @@ -83,7 +83,7 @@ Creates list of users with given input array Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Vec<::models::User>**](User.md)| List of user object | + **body** | [**Vec**](User.md)| List of user object | ### Return type @@ -133,7 +133,7 @@ No authorization required ## get_user_by_name -> ::models::User get_user_by_name(username) +> crate::models::User get_user_by_name(username) Get user by user name ### Required Parameters @@ -145,7 +145,7 @@ Name | Type | Description | Notes ### Return type -[**::models::User**](User.md) +[**crate::models::User**](User.md) ### Authorization diff --git a/samples/client/petstore/rust-reqwest/src/apis/client.rs b/samples/client/petstore/rust-reqwest/src/apis/client.rs index ea6b0eb635..14088cbe30 100644 --- a/samples/client/petstore/rust-reqwest/src/apis/client.rs +++ b/samples/client/petstore/rust-reqwest/src/apis/client.rs @@ -4,9 +4,9 @@ use super::configuration::Configuration; pub struct APIClient { configuration: Rc, - pet_api: Box<::apis::PetApi>, - store_api: Box<::apis::StoreApi>, - user_api: Box<::apis::UserApi>, + pet_api: Box, + store_api: Box, + user_api: Box, } impl APIClient { @@ -15,21 +15,21 @@ impl APIClient { APIClient { configuration: rc.clone(), - pet_api: Box::new(::apis::PetApiClient::new(rc.clone())), - store_api: Box::new(::apis::StoreApiClient::new(rc.clone())), - user_api: Box::new(::apis::UserApiClient::new(rc.clone())), + pet_api: Box::new(crate::apis::PetApiClient::new(rc.clone())), + store_api: Box::new(crate::apis::StoreApiClient::new(rc.clone())), + user_api: Box::new(crate::apis::UserApiClient::new(rc.clone())), } } - pub fn pet_api(&self) -> &::apis::PetApi{ + pub fn pet_api(&self) -> &crate::apis::PetApi{ self.pet_api.as_ref() } - pub fn store_api(&self) -> &::apis::StoreApi{ + pub fn store_api(&self) -> &crate::apis::StoreApi{ self.store_api.as_ref() } - pub fn user_api(&self) -> &::apis::UserApi{ + pub fn user_api(&self) -> &crate::apis::UserApi{ self.user_api.as_ref() } diff --git a/samples/client/petstore/rust-reqwest/src/apis/pet_api.rs b/samples/client/petstore/rust-reqwest/src/apis/pet_api.rs index 53d2b82ea7..264fc30e68 100644 --- a/samples/client/petstore/rust-reqwest/src/apis/pet_api.rs +++ b/samples/client/petstore/rust-reqwest/src/apis/pet_api.rs @@ -28,18 +28,18 @@ impl PetApiClient { } pub trait PetApi { - fn add_pet(&self, body: ::models::Pet) -> Result<(), Error>; + fn add_pet(&self, body: crate::models::Pet) -> Result<(), Error>; fn delete_pet(&self, pet_id: i64, api_key: &str) -> Result<(), Error>; - fn find_pets_by_status(&self, status: Vec) -> Result, Error>; - fn find_pets_by_tags(&self, tags: Vec) -> Result, Error>; - fn get_pet_by_id(&self, pet_id: i64) -> Result<::models::Pet, Error>; - fn update_pet(&self, body: ::models::Pet) -> Result<(), Error>; + fn find_pets_by_status(&self, status: Vec) -> Result, Error>; + fn find_pets_by_tags(&self, tags: Vec) -> Result, Error>; + fn get_pet_by_id(&self, pet_id: i64) -> Result; + fn update_pet(&self, body: crate::models::Pet) -> Result<(), Error>; fn update_pet_with_form(&self, pet_id: i64, name: &str, status: &str) -> Result<(), Error>; - fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Result<::models::ApiResponse, Error>; + fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Result; } impl PetApi for PetApiClient { - fn add_pet(&self, body: ::models::Pet) -> Result<(), Error> { + fn add_pet(&self, body: crate::models::Pet) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -83,7 +83,7 @@ impl PetApi for PetApiClient { Ok(()) } - fn find_pets_by_status(&self, status: Vec) -> Result, Error> { + fn find_pets_by_status(&self, status: Vec) -> Result, Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -104,7 +104,7 @@ impl PetApi for PetApiClient { Ok(client.execute(req)?.error_for_status()?.json()?) } - fn find_pets_by_tags(&self, tags: Vec) -> Result, Error> { + fn find_pets_by_tags(&self, tags: Vec) -> Result, Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -125,7 +125,7 @@ impl PetApi for PetApiClient { Ok(client.execute(req)?.error_for_status()?.json()?) } - fn get_pet_by_id(&self, pet_id: i64) -> Result<::models::Pet, Error> { + fn get_pet_by_id(&self, pet_id: i64) -> Result { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -150,7 +150,7 @@ impl PetApi for PetApiClient { Ok(client.execute(req)?.error_for_status()?.json()?) } - fn update_pet(&self, body: ::models::Pet) -> Result<(), Error> { + fn update_pet(&self, body: crate::models::Pet) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -197,7 +197,7 @@ impl PetApi for PetApiClient { Ok(()) } - fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Result<::models::ApiResponse, Error> { + fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Result { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; diff --git a/samples/client/petstore/rust-reqwest/src/apis/store_api.rs b/samples/client/petstore/rust-reqwest/src/apis/store_api.rs index d9d60f0996..dac744b3b2 100644 --- a/samples/client/petstore/rust-reqwest/src/apis/store_api.rs +++ b/samples/client/petstore/rust-reqwest/src/apis/store_api.rs @@ -30,8 +30,8 @@ impl StoreApiClient { pub trait StoreApi { fn delete_order(&self, order_id: &str) -> Result<(), Error>; fn get_inventory(&self, ) -> Result<::std::collections::HashMap, Error>; - fn get_order_by_id(&self, order_id: i64) -> Result<::models::Order, Error>; - fn place_order(&self, body: ::models::Order) -> Result<::models::Order, Error>; + fn get_order_by_id(&self, order_id: i64) -> Result; + fn place_order(&self, body: crate::models::Order) -> Result; } impl StoreApi for StoreApiClient { @@ -78,7 +78,7 @@ impl StoreApi for StoreApiClient { Ok(client.execute(req)?.error_for_status()?.json()?) } - fn get_order_by_id(&self, order_id: i64) -> Result<::models::Order, Error> { + fn get_order_by_id(&self, order_id: i64) -> Result { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -95,7 +95,7 @@ impl StoreApi for StoreApiClient { Ok(client.execute(req)?.error_for_status()?.json()?) } - fn place_order(&self, body: ::models::Order) -> Result<::models::Order, Error> { + fn place_order(&self, body: crate::models::Order) -> Result { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; diff --git a/samples/client/petstore/rust-reqwest/src/apis/user_api.rs b/samples/client/petstore/rust-reqwest/src/apis/user_api.rs index 68d4c9f126..e2321b3daa 100644 --- a/samples/client/petstore/rust-reqwest/src/apis/user_api.rs +++ b/samples/client/petstore/rust-reqwest/src/apis/user_api.rs @@ -28,18 +28,18 @@ impl UserApiClient { } pub trait UserApi { - fn create_user(&self, body: ::models::User) -> Result<(), Error>; - fn create_users_with_array_input(&self, body: Vec<::models::User>) -> Result<(), Error>; - fn create_users_with_list_input(&self, body: Vec<::models::User>) -> Result<(), Error>; + fn create_user(&self, body: crate::models::User) -> Result<(), Error>; + fn create_users_with_array_input(&self, body: Vec) -> Result<(), Error>; + fn create_users_with_list_input(&self, body: Vec) -> Result<(), Error>; fn delete_user(&self, username: &str) -> Result<(), Error>; - fn get_user_by_name(&self, username: &str) -> Result<::models::User, Error>; + fn get_user_by_name(&self, username: &str) -> Result; fn login_user(&self, username: &str, password: &str) -> Result; fn logout_user(&self, ) -> Result<(), Error>; - fn update_user(&self, username: &str, body: ::models::User) -> Result<(), Error>; + fn update_user(&self, username: &str, body: crate::models::User) -> Result<(), Error>; } impl UserApi for UserApiClient { - fn create_user(&self, body: ::models::User) -> Result<(), Error> { + fn create_user(&self, body: crate::models::User) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -58,7 +58,7 @@ impl UserApi for UserApiClient { Ok(()) } - fn create_users_with_array_input(&self, body: Vec<::models::User>) -> Result<(), Error> { + fn create_users_with_array_input(&self, body: Vec) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -77,7 +77,7 @@ impl UserApi for UserApiClient { Ok(()) } - fn create_users_with_list_input(&self, body: Vec<::models::User>) -> Result<(), Error> { + fn create_users_with_list_input(&self, body: Vec) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -114,7 +114,7 @@ impl UserApi for UserApiClient { Ok(()) } - fn get_user_by_name(&self, username: &str) -> Result<::models::User, Error> { + fn get_user_by_name(&self, username: &str) -> Result { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; @@ -168,7 +168,7 @@ impl UserApi for UserApiClient { Ok(()) } - fn update_user(&self, username: &str, body: ::models::User) -> Result<(), Error> { + fn update_user(&self, username: &str, body: crate::models::User) -> Result<(), Error> { let configuration: &configuration::Configuration = self.configuration.borrow(); let client = &configuration.client; diff --git a/samples/client/petstore/rust-reqwest/src/models/api_response.rs b/samples/client/petstore/rust-reqwest/src/models/api_response.rs index 7884fba590..814483602d 100644 --- a/samples/client/petstore/rust-reqwest/src/models/api_response.rs +++ b/samples/client/petstore/rust-reqwest/src/models/api_response.rs @@ -10,9 +10,6 @@ /// ApiResponse : Describes the result of uploading an image resource -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct ApiResponse { diff --git a/samples/client/petstore/rust-reqwest/src/models/category.rs b/samples/client/petstore/rust-reqwest/src/models/category.rs index 804f9f4c70..8cb5797ee1 100644 --- a/samples/client/petstore/rust-reqwest/src/models/category.rs +++ b/samples/client/petstore/rust-reqwest/src/models/category.rs @@ -10,9 +10,6 @@ /// Category : A category for a pet -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Category { diff --git a/samples/client/petstore/rust-reqwest/src/models/order.rs b/samples/client/petstore/rust-reqwest/src/models/order.rs index 118dc31076..24ad342497 100644 --- a/samples/client/petstore/rust-reqwest/src/models/order.rs +++ b/samples/client/petstore/rust-reqwest/src/models/order.rs @@ -10,9 +10,6 @@ /// Order : An order for a pets from the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Order { diff --git a/samples/client/petstore/rust-reqwest/src/models/pet.rs b/samples/client/petstore/rust-reqwest/src/models/pet.rs index 64dae06e45..e3c61239cd 100644 --- a/samples/client/petstore/rust-reqwest/src/models/pet.rs +++ b/samples/client/petstore/rust-reqwest/src/models/pet.rs @@ -10,22 +10,19 @@ /// Pet : A pet for sale in the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Pet { #[serde(rename = "id", skip_serializing_if = "Option::is_none")] pub id: Option, #[serde(rename = "category", skip_serializing_if = "Option::is_none")] - pub category: Option<::models::Category>, + pub category: Option, #[serde(rename = "name")] pub name: String, #[serde(rename = "photoUrls")] pub photo_urls: Vec, #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option>, + pub tags: Option>, /// pet status in the store #[serde(rename = "status", skip_serializing_if = "Option::is_none")] pub status: Option, diff --git a/samples/client/petstore/rust-reqwest/src/models/tag.rs b/samples/client/petstore/rust-reqwest/src/models/tag.rs index 503fb7f61b..c7cbdf2cc0 100644 --- a/samples/client/petstore/rust-reqwest/src/models/tag.rs +++ b/samples/client/petstore/rust-reqwest/src/models/tag.rs @@ -10,9 +10,6 @@ /// Tag : A tag for a pet -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Tag { diff --git a/samples/client/petstore/rust-reqwest/src/models/user.rs b/samples/client/petstore/rust-reqwest/src/models/user.rs index 6bfa6e2167..e54ed70130 100644 --- a/samples/client/petstore/rust-reqwest/src/models/user.rs +++ b/samples/client/petstore/rust-reqwest/src/models/user.rs @@ -10,9 +10,6 @@ /// User : A User who is purchasing from the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct User { diff --git a/samples/client/petstore/rust/.openapi-generator/VERSION b/samples/client/petstore/rust/.openapi-generator/VERSION index d96260ba33..83a328a922 100644 --- a/samples/client/petstore/rust/.openapi-generator/VERSION +++ b/samples/client/petstore/rust/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.2-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/rust/docs/Pet.md b/samples/client/petstore/rust/docs/Pet.md index 53a462e68b..2c8ea36dd9 100644 --- a/samples/client/petstore/rust/docs/Pet.md +++ b/samples/client/petstore/rust/docs/Pet.md @@ -5,10 +5,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **id** | **i64** | | [optional] -**category** | [***::models::Category**](Category.md) | | [optional] +**category** | [***crate::models::Category**](Category.md) | | [optional] **name** | **String** | | **photo_urls** | **Vec** | | -**tags** | [**Vec<::models::Tag>**](Tag.md) | | [optional] +**tags** | [**Vec**](Tag.md) | | [optional] **status** | **String** | pet status in the store | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/samples/client/petstore/rust/docs/PetApi.md b/samples/client/petstore/rust/docs/PetApi.md index e690c80518..4d5e4c7839 100644 --- a/samples/client/petstore/rust/docs/PetApi.md +++ b/samples/client/petstore/rust/docs/PetApi.md @@ -85,7 +85,7 @@ Name | Type | Description | Notes ## find_pets_by_status -> Vec<::models::Pet> find_pets_by_status(ctx, status) +> Vec find_pets_by_status(ctx, status) Finds Pets by status Multiple status values can be provided with comma separated strings @@ -100,7 +100,7 @@ Name | Type | Description | Notes ### Return type -[**Vec<::models::Pet>**](Pet.md) +[**Vec**](Pet.md) ### Authorization @@ -116,7 +116,7 @@ Name | Type | Description | Notes ## find_pets_by_tags -> Vec<::models::Pet> find_pets_by_tags(ctx, tags) +> Vec find_pets_by_tags(ctx, tags) Finds Pets by tags Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. @@ -131,7 +131,7 @@ Name | Type | Description | Notes ### Return type -[**Vec<::models::Pet>**](Pet.md) +[**Vec**](Pet.md) ### Authorization @@ -147,7 +147,7 @@ Name | Type | Description | Notes ## get_pet_by_id -> ::models::Pet get_pet_by_id(ctx, pet_id) +> crate::models::Pet get_pet_by_id(ctx, pet_id) Find pet by ID Returns a single pet @@ -162,7 +162,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Pet**](Pet.md) +[**crate::models::Pet**](Pet.md) ### Authorization @@ -247,7 +247,7 @@ Name | Type | Description | Notes ## upload_file -> ::models::ApiResponse upload_file(ctx, pet_id, optional) +> crate::models::ApiResponse upload_file(ctx, pet_id, optional) uploads an image ### Required Parameters @@ -271,7 +271,7 @@ Name | Type | Description | Notes ### Return type -[**::models::ApiResponse**](ApiResponse.md) +[**crate::models::ApiResponse**](ApiResponse.md) ### Authorization diff --git a/samples/client/petstore/rust/docs/StoreApi.md b/samples/client/petstore/rust/docs/StoreApi.md index 1e4bdc3e14..16a09fae3f 100644 --- a/samples/client/petstore/rust/docs/StoreApi.md +++ b/samples/client/petstore/rust/docs/StoreApi.md @@ -70,7 +70,7 @@ This endpoint does not need any parameter. ## get_order_by_id -> ::models::Order get_order_by_id(order_id) +> crate::models::Order get_order_by_id(order_id) Find purchase order by ID For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions @@ -84,7 +84,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Order**](Order.md) +[**crate::models::Order**](Order.md) ### Authorization @@ -100,7 +100,7 @@ No authorization required ## place_order -> ::models::Order place_order(body) +> crate::models::Order place_order(body) Place an order for a pet ### Required Parameters @@ -112,7 +112,7 @@ Name | Type | Description | Notes ### Return type -[**::models::Order**](Order.md) +[**crate::models::Order**](Order.md) ### Authorization diff --git a/samples/client/petstore/rust/docs/UserApi.md b/samples/client/petstore/rust/docs/UserApi.md index ffa733d64d..9c4af81392 100644 --- a/samples/client/petstore/rust/docs/UserApi.md +++ b/samples/client/petstore/rust/docs/UserApi.md @@ -55,7 +55,7 @@ Creates list of users with given input array Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Vec<::models::User>**](User.md)| List of user object | + **body** | [**Vec**](User.md)| List of user object | ### Return type @@ -83,7 +83,7 @@ Creates list of users with given input array Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**Vec<::models::User>**](User.md)| List of user object | + **body** | [**Vec**](User.md)| List of user object | ### Return type @@ -133,7 +133,7 @@ No authorization required ## get_user_by_name -> ::models::User get_user_by_name(username) +> crate::models::User get_user_by_name(username) Get user by user name ### Required Parameters @@ -145,7 +145,7 @@ Name | Type | Description | Notes ### Return type -[**::models::User**](User.md) +[**crate::models::User**](User.md) ### Authorization diff --git a/samples/client/petstore/rust/src/apis/client.rs b/samples/client/petstore/rust/src/apis/client.rs index ddf5f6ee08..dd0de97eb5 100644 --- a/samples/client/petstore/rust/src/apis/client.rs +++ b/samples/client/petstore/rust/src/apis/client.rs @@ -5,9 +5,9 @@ use super::configuration::Configuration; pub struct APIClient { configuration: Rc>, - pet_api: Box<::apis::PetApi>, - store_api: Box<::apis::StoreApi>, - user_api: Box<::apis::UserApi>, + pet_api: Box, + store_api: Box, + user_api: Box, } impl APIClient { @@ -16,21 +16,21 @@ impl APIClient { APIClient { configuration: rc.clone(), - pet_api: Box::new(::apis::PetApiClient::new(rc.clone())), - store_api: Box::new(::apis::StoreApiClient::new(rc.clone())), - user_api: Box::new(::apis::UserApiClient::new(rc.clone())), + pet_api: Box::new(crate::apis::PetApiClient::new(rc.clone())), + store_api: Box::new(crate::apis::StoreApiClient::new(rc.clone())), + user_api: Box::new(crate::apis::UserApiClient::new(rc.clone())), } } - pub fn pet_api(&self) -> &::apis::PetApi{ + pub fn pet_api(&self) -> &crate::apis::PetApi{ self.pet_api.as_ref() } - pub fn store_api(&self) -> &::apis::StoreApi{ + pub fn store_api(&self) -> &crate::apis::StoreApi{ self.store_api.as_ref() } - pub fn user_api(&self) -> &::apis::UserApi{ + pub fn user_api(&self) -> &crate::apis::UserApi{ self.user_api.as_ref() } diff --git a/samples/client/petstore/rust/src/apis/pet_api.rs b/samples/client/petstore/rust/src/apis/pet_api.rs index 0c98efec5c..e3fe372fc9 100644 --- a/samples/client/petstore/rust/src/apis/pet_api.rs +++ b/samples/client/petstore/rust/src/apis/pet_api.rs @@ -31,19 +31,19 @@ impl PetApiClient { } pub trait PetApi { - fn add_pet(&self, body: ::models::Pet) -> Box>>; + fn add_pet(&self, body: crate::models::Pet) -> Box>>; fn delete_pet(&self, pet_id: i64, api_key: &str) -> Box>>; - fn find_pets_by_status(&self, status: Vec) -> Box, Error = Error>>; - fn find_pets_by_tags(&self, tags: Vec) -> Box, Error = Error>>; - fn get_pet_by_id(&self, pet_id: i64) -> Box>>; - fn update_pet(&self, body: ::models::Pet) -> Box>>; + fn find_pets_by_status(&self, status: Vec) -> Box, Error = Error>>; + fn find_pets_by_tags(&self, tags: Vec) -> Box, Error = Error>>; + fn get_pet_by_id(&self, pet_id: i64) -> Box>>; + fn update_pet(&self, body: crate::models::Pet) -> Box>>; fn update_pet_with_form(&self, pet_id: i64, name: &str, status: &str) -> Box>>; - fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Box>>; + fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Box>>; } implPetApi for PetApiClient { - fn add_pet(&self, body: ::models::Pet) -> Box>> { + fn add_pet(&self, body: crate::models::Pet) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/pet".to_string()) .with_auth(__internal_request::Auth::Oauth) .with_body_param(body) @@ -60,21 +60,21 @@ implPetApi for PetApiClient { .execute(self.configuration.borrow()) } - fn find_pets_by_status(&self, status: Vec) -> Box, Error = Error>> { + fn find_pets_by_status(&self, status: Vec) -> Box, Error = Error>> { __internal_request::Request::new(hyper::Method::Get, "/pet/findByStatus".to_string()) .with_auth(__internal_request::Auth::Oauth) .with_query_param("status".to_string(), status.join(",").to_string()) .execute(self.configuration.borrow()) } - fn find_pets_by_tags(&self, tags: Vec) -> Box, Error = Error>> { + fn find_pets_by_tags(&self, tags: Vec) -> Box, Error = Error>> { __internal_request::Request::new(hyper::Method::Get, "/pet/findByTags".to_string()) .with_auth(__internal_request::Auth::Oauth) .with_query_param("tags".to_string(), tags.join(",").to_string()) .execute(self.configuration.borrow()) } - fn get_pet_by_id(&self, pet_id: i64) -> Box>> { + fn get_pet_by_id(&self, pet_id: i64) -> Box>> { __internal_request::Request::new(hyper::Method::Get, "/pet/{petId}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, @@ -85,7 +85,7 @@ implPetApi for PetApiClient { .execute(self.configuration.borrow()) } - fn update_pet(&self, body: ::models::Pet) -> Box>> { + fn update_pet(&self, body: crate::models::Pet) -> Box>> { __internal_request::Request::new(hyper::Method::Put, "/pet".to_string()) .with_auth(__internal_request::Auth::Oauth) .with_body_param(body) @@ -103,7 +103,7 @@ implPetApi for PetApiClient { .execute(self.configuration.borrow()) } - fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Box>> { + fn upload_file(&self, pet_id: i64, additional_metadata: &str, file: std::path::PathBuf) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/pet/{petId}/uploadImage".to_string()) .with_auth(__internal_request::Auth::Oauth) .with_path_param("petId".to_string(), pet_id.to_string()) diff --git a/samples/client/petstore/rust/src/apis/store_api.rs b/samples/client/petstore/rust/src/apis/store_api.rs index 46f0bf53cf..2c827cce04 100644 --- a/samples/client/petstore/rust/src/apis/store_api.rs +++ b/samples/client/petstore/rust/src/apis/store_api.rs @@ -33,8 +33,8 @@ impl StoreApiClient { pub trait StoreApi { fn delete_order(&self, order_id: &str) -> Box>>; fn get_inventory(&self, ) -> Box, Error = Error>>; - fn get_order_by_id(&self, order_id: i64) -> Box>>; - fn place_order(&self, body: ::models::Order) -> Box>>; + fn get_order_by_id(&self, order_id: i64) -> Box>>; + fn place_order(&self, body: crate::models::Order) -> Box>>; } @@ -56,13 +56,13 @@ implStoreApi for StoreApiClient { .execute(self.configuration.borrow()) } - fn get_order_by_id(&self, order_id: i64) -> Box>> { + fn get_order_by_id(&self, order_id: i64) -> Box>> { __internal_request::Request::new(hyper::Method::Get, "/store/order/{orderId}".to_string()) .with_path_param("orderId".to_string(), order_id.to_string()) .execute(self.configuration.borrow()) } - fn place_order(&self, body: ::models::Order) -> Box>> { + fn place_order(&self, body: crate::models::Order) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/store/order".to_string()) .with_body_param(body) .execute(self.configuration.borrow()) diff --git a/samples/client/petstore/rust/src/apis/user_api.rs b/samples/client/petstore/rust/src/apis/user_api.rs index ba3ad140b4..1ea00f7536 100644 --- a/samples/client/petstore/rust/src/apis/user_api.rs +++ b/samples/client/petstore/rust/src/apis/user_api.rs @@ -31,33 +31,33 @@ impl UserApiClient { } pub trait UserApi { - fn create_user(&self, body: ::models::User) -> Box>>; - fn create_users_with_array_input(&self, body: Vec<::models::User>) -> Box>>; - fn create_users_with_list_input(&self, body: Vec<::models::User>) -> Box>>; + fn create_user(&self, body: crate::models::User) -> Box>>; + fn create_users_with_array_input(&self, body: Vec) -> Box>>; + fn create_users_with_list_input(&self, body: Vec) -> Box>>; fn delete_user(&self, username: &str) -> Box>>; - fn get_user_by_name(&self, username: &str) -> Box>>; + fn get_user_by_name(&self, username: &str) -> Box>>; fn login_user(&self, username: &str, password: &str) -> Box>>; fn logout_user(&self, ) -> Box>>; - fn update_user(&self, username: &str, body: ::models::User) -> Box>>; + fn update_user(&self, username: &str, body: crate::models::User) -> Box>>; } implUserApi for UserApiClient { - fn create_user(&self, body: ::models::User) -> Box>> { + fn create_user(&self, body: crate::models::User) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/user".to_string()) .with_body_param(body) .returns_nothing() .execute(self.configuration.borrow()) } - fn create_users_with_array_input(&self, body: Vec<::models::User>) -> Box>> { + fn create_users_with_array_input(&self, body: Vec) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/user/createWithArray".to_string()) .with_body_param(body) .returns_nothing() .execute(self.configuration.borrow()) } - fn create_users_with_list_input(&self, body: Vec<::models::User>) -> Box>> { + fn create_users_with_list_input(&self, body: Vec) -> Box>> { __internal_request::Request::new(hyper::Method::Post, "/user/createWithList".to_string()) .with_body_param(body) .returns_nothing() @@ -71,7 +71,7 @@ implUserApi for UserApiClient { .execute(self.configuration.borrow()) } - fn get_user_by_name(&self, username: &str) -> Box>> { + fn get_user_by_name(&self, username: &str) -> Box>> { __internal_request::Request::new(hyper::Method::Get, "/user/{username}".to_string()) .with_path_param("username".to_string(), username.to_string()) .execute(self.configuration.borrow()) @@ -90,7 +90,7 @@ implUserApi for UserApiClient { .execute(self.configuration.borrow()) } - fn update_user(&self, username: &str, body: ::models::User) -> Box>> { + fn update_user(&self, username: &str, body: crate::models::User) -> Box>> { __internal_request::Request::new(hyper::Method::Put, "/user/{username}".to_string()) .with_path_param("username".to_string(), username.to_string()) .with_body_param(body) diff --git a/samples/client/petstore/rust/src/models/api_response.rs b/samples/client/petstore/rust/src/models/api_response.rs index 7884fba590..814483602d 100644 --- a/samples/client/petstore/rust/src/models/api_response.rs +++ b/samples/client/petstore/rust/src/models/api_response.rs @@ -10,9 +10,6 @@ /// ApiResponse : Describes the result of uploading an image resource -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct ApiResponse { diff --git a/samples/client/petstore/rust/src/models/category.rs b/samples/client/petstore/rust/src/models/category.rs index 804f9f4c70..8cb5797ee1 100644 --- a/samples/client/petstore/rust/src/models/category.rs +++ b/samples/client/petstore/rust/src/models/category.rs @@ -10,9 +10,6 @@ /// Category : A category for a pet -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Category { diff --git a/samples/client/petstore/rust/src/models/order.rs b/samples/client/petstore/rust/src/models/order.rs index 118dc31076..24ad342497 100644 --- a/samples/client/petstore/rust/src/models/order.rs +++ b/samples/client/petstore/rust/src/models/order.rs @@ -10,9 +10,6 @@ /// Order : An order for a pets from the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Order { diff --git a/samples/client/petstore/rust/src/models/pet.rs b/samples/client/petstore/rust/src/models/pet.rs index 64dae06e45..e3c61239cd 100644 --- a/samples/client/petstore/rust/src/models/pet.rs +++ b/samples/client/petstore/rust/src/models/pet.rs @@ -10,22 +10,19 @@ /// Pet : A pet for sale in the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Pet { #[serde(rename = "id", skip_serializing_if = "Option::is_none")] pub id: Option, #[serde(rename = "category", skip_serializing_if = "Option::is_none")] - pub category: Option<::models::Category>, + pub category: Option, #[serde(rename = "name")] pub name: String, #[serde(rename = "photoUrls")] pub photo_urls: Vec, #[serde(rename = "tags", skip_serializing_if = "Option::is_none")] - pub tags: Option>, + pub tags: Option>, /// pet status in the store #[serde(rename = "status", skip_serializing_if = "Option::is_none")] pub status: Option, diff --git a/samples/client/petstore/rust/src/models/tag.rs b/samples/client/petstore/rust/src/models/tag.rs index 503fb7f61b..c7cbdf2cc0 100644 --- a/samples/client/petstore/rust/src/models/tag.rs +++ b/samples/client/petstore/rust/src/models/tag.rs @@ -10,9 +10,6 @@ /// Tag : A tag for a pet -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct Tag { diff --git a/samples/client/petstore/rust/src/models/user.rs b/samples/client/petstore/rust/src/models/user.rs index 6bfa6e2167..e54ed70130 100644 --- a/samples/client/petstore/rust/src/models/user.rs +++ b/samples/client/petstore/rust/src/models/user.rs @@ -10,9 +10,6 @@ /// User : A User who is purchasing from the pet store -#[allow(unused_imports)] -use serde_json::Value; - #[derive(Debug, Serialize, Deserialize)] pub struct User { From 944e1c34688c29b0003a4dd0d371afb28ae3285c Mon Sep 17 00:00:00 2001 From: Jim Schubert Date: Thu, 18 Jul 2019 09:50:54 -0400 Subject: [PATCH 28/62] [fix] Assign template directory to additional properties (#3385) * [fix] Assign template directory to additional properties --- .../codegen/config/CodegenConfigurator.java | 11 ++ .../config/CodegenConfiguratorTest.java | 122 ++++++++++++++++++ .../builds/multiple-parameters/runtime.ts | 7 +- .../php-symfony/SymfonyBundle-php/.gitignore | 54 ++++++++ 4 files changed, 193 insertions(+), 1 deletion(-) create mode 100644 modules/openapi-generator/src/test/java/org/openapitools/codegen/config/CodegenConfiguratorTest.java create mode 100644 samples/server/petstore/php-symfony/SymfonyBundle-php/.gitignore diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/config/CodegenConfigurator.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/config/CodegenConfigurator.java index 4c251ffc4a..88f2a54898 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/config/CodegenConfigurator.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/config/CodegenConfigurator.java @@ -223,6 +223,7 @@ public class CodegenConfigurator { } public CodegenConfigurator setImportMappings(Map importMappings) { + this.importMappings = importMappings; generatorSettingsBuilder.withImportMappings(importMappings); return this; } @@ -234,6 +235,7 @@ public class CodegenConfigurator { } public CodegenConfigurator setInstantiationTypes(Map instantiationTypes) { + this.instantiationTypes = instantiationTypes; generatorSettingsBuilder.withInstantiationTypes(instantiationTypes); return this; } @@ -295,6 +297,7 @@ public class CodegenConfigurator { } public CodegenConfigurator setReservedWordsMappings(Map reservedWordMappings) { + this.reservedWordMappings = reservedWordMappings; generatorSettingsBuilder.withReservedWordMappings(reservedWordMappings); return this; } @@ -310,6 +313,7 @@ public class CodegenConfigurator { } public CodegenConfigurator setSystemProperties(Map systemProperties) { + this.systemProperties = systemProperties; workflowSettingsBuilder.withSystemProperties(systemProperties); return this; } @@ -326,6 +330,7 @@ public class CodegenConfigurator { } public CodegenConfigurator setTypeMappings(Map typeMappings) { + this.typeMappings = typeMappings; generatorSettingsBuilder.withTypeMappings(typeMappings); return this; } @@ -454,6 +459,12 @@ public class CodegenConfigurator { config.reservedWordsMappings().putAll(generatorSettings.getReservedWordMappings()); config.additionalProperties().putAll(generatorSettings.getAdditionalProperties()); + // any other additional properties? + String templateDir = workflowSettings.getTemplateDir(); + if (templateDir != null) { + config.additionalProperties().put(CodegenConstants.TEMPLATE_DIR, workflowSettings.getTemplateDir()); + } + ClientOptInput input = new ClientOptInput() .config(config); diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/config/CodegenConfiguratorTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/config/CodegenConfiguratorTest.java new file mode 100644 index 0000000000..68271020ca --- /dev/null +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/config/CodegenConfiguratorTest.java @@ -0,0 +1,122 @@ +/* + * Copyright 2019 OpenAPI-Generator Contributors (https://openapi-generator.tech) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.openapitools.codegen.config; + +import org.openapitools.codegen.ClientOptInput; +import org.openapitools.codegen.CodegenConfig; +import org.openapitools.codegen.CodegenConstants; +import org.openapitools.codegen.DefaultGenerator; +import org.testng.annotations.Test; + +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.util.HashMap; +import java.util.Map; + +import static org.testng.Assert.*; + +public class CodegenConfiguratorTest { + private void want(Map additionalProperties, String key, Object expected) { + assertEquals(additionalProperties.getOrDefault(key, null), expected); + } + + @Test + public void shouldSetConfiglProperties() throws IOException { + // This tests that properties we set on CodegenConfigurator make it down into generator properties, + // limiting to those managed in DefaultCodegen. + Map properties = new HashMap() {{ + put("foo", "bar"); + put("baz", "quux"); + put(CodegenConstants.HIDE_GENERATION_TIMESTAMP, true); + put(CodegenConstants.SORT_PARAMS_BY_REQUIRED_FLAG, true); + put(CodegenConstants.PREPEND_FORM_OR_BODY_PARAMETERS, false); + put(CodegenConstants.ENSURE_UNIQUE_PARAMS, true); + put(CodegenConstants.ALLOW_UNICODE_IDENTIFIERS, true); + put(CodegenConstants.REMOVE_OPERATION_ID_PREFIX, false); + put(CodegenConstants.DOCEXTENSION, "D"); + put(CodegenConstants.ENABLE_POST_PROCESS_FILE, false); + put(CodegenConstants.GENERATE_ALIAS_AS_MODEL, true); + }}; + + File output = Files.createTempDirectory("test").toFile(); + File template = Files.createTempDirectory("test").toFile(); + String outDir = Paths.get(output.toURI()).toAbsolutePath().toString(); + String templateDir = Paths.get(template.toURI()).toAbsolutePath().toString(); + + final CodegenConfigurator configurator = new CodegenConfigurator() + .setGeneratorName("java") + .setAdditionalProperties(properties) + .setInputSpec("src/test/resources/3_0/ping.yaml") + .addImportMapping("one", "two") + .addInstantiationType("three", "four") + .addLanguageSpecificPrimitive("five") + .addSystemProperty("six", "seven") + .addTypeMapping("eight", "nine") + .setApiPackage("test-api") + .setArtifactId("test-artifactId") + .setArtifactVersion("test-artifactVersion") + .setAuth("test-auth") + .setGitRepoId("git") + .setGitUserId("user") + .setGroupId("group") + .setHttpUserAgent("agent") + .setModelNamePrefix("model-prefix") + .setModelNameSuffix("model-suffix") + .setModelPackage("model-package") + .setPackageName("package-name") + .setReleaseNote("release-note") + .setTemplateDir(templateDir) + .setOutputDir(outDir); + + final ClientOptInput clientOptInput = configurator.toClientOptInput(); + + CodegenConfig config = clientOptInput.getConfig(); + config.processOpts(); + + Map props = config.additionalProperties(); + + // This verifies that things we expect to make it into the template will, as a result of this CodegenConfigurator. + want(props, CodegenConstants.MODEL_PACKAGE, "model_package"); // * mutated by codegen + want(props, CodegenConstants.API_PACKAGE, "test_api"); // * mutated by codegen + want(props, CodegenConstants.HIDE_GENERATION_TIMESTAMP, true); + want(props, CodegenConstants.SORT_PARAMS_BY_REQUIRED_FLAG, true); + want(props, CodegenConstants.PREPEND_FORM_OR_BODY_PARAMETERS, false); + want(props, CodegenConstants.ENSURE_UNIQUE_PARAMS, true); + want(props, CodegenConstants.ALLOW_UNICODE_IDENTIFIERS, true); + want(props, CodegenConstants.MODEL_NAME_PREFIX, "model-prefix"); + want(props, CodegenConstants.MODEL_NAME_SUFFIX, "model-suffix"); + want(props, CodegenConstants.REMOVE_OPERATION_ID_PREFIX, false); + want(props, CodegenConstants.DOCEXTENSION, "D"); + want(props, CodegenConstants.ENABLE_POST_PROCESS_FILE, false); + want(props, CodegenConstants.GENERATE_ALIAS_AS_MODEL, true); + want(props, CodegenConstants.TEMPLATE_DIR, templateDir); + want(props, CodegenConstants.GIT_REPO_ID, "git"); + want(props, CodegenConstants.GIT_USER_ID, "user"); + want(props, CodegenConstants.GROUP_ID, "group"); + want(props, CodegenConstants.ARTIFACT_ID, "test-artifactId"); + want(props, CodegenConstants.ARTIFACT_VERSION, "test-artifactVersion"); + want(props, CodegenConstants.HTTP_USER_AGENT, "agent"); + want(props, CodegenConstants.RELEASE_NOTE, "release-note"); + want(props, CodegenConstants.PACKAGE_NAME, "package-name"); + + // test custom properties + want(props, "foo", "bar"); + want(props, "baz", "quux"); + } +} \ No newline at end of file diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts index 5b07f81118..c95a101fba 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/runtime.ts @@ -58,7 +58,7 @@ export class BaseAPI { // only add the querystring to the URL if there are query parameters. // this is done to avoid urls ending with a "?" character which buggy webservers // do not handle correctly sometimes. - url += '?' + querystring(context.query); + url += '?' + this.configuration.queryParamsStringify(context.query); } const body = (context.body instanceof FormData || isBlob(context.body)) ? context.body @@ -127,6 +127,7 @@ export interface ConfigurationParameters { basePath?: string; // override base path fetchApi?: FetchAPI; // override for fetch implementation middleware?: Middleware[]; // middleware to apply before/after fetch requests + queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings username?: string; // parameter for basic security password?: string; // parameter for basic security apiKey?: string | ((name: string) => string); // parameter for apiKey security @@ -148,6 +149,10 @@ export class Configuration { return this.configuration.middleware || []; } + get queryParamsStringify(): (params: HTTPQuery) => string { + return this.configuration.queryParamsStringify || querystring; + } + get username(): string | undefined { return this.configuration.username; } diff --git a/samples/server/petstore/php-symfony/SymfonyBundle-php/.gitignore b/samples/server/petstore/php-symfony/SymfonyBundle-php/.gitignore new file mode 100644 index 0000000000..20b7b98976 --- /dev/null +++ b/samples/server/petstore/php-symfony/SymfonyBundle-php/.gitignore @@ -0,0 +1,54 @@ +# ref: https://github.com/github/gitignore/blob/master/Symfony.gitignore + +# Cache and logs (Symfony2) +/app/cache/* +/app/logs/* +!app/cache/.gitkeep +!app/logs/.gitkeep + +# Email spool folder +/app/spool/* + +# Cache, session files and logs (Symfony3) +/var/cache/* +/var/logs/* +/var/sessions/* +!var/cache/.gitkeep +!var/logs/.gitkeep +!var/sessions/.gitkeep + +# Parameters +/app/config/parameters.yml +/app/config/parameters.ini + +# Managed by Composer +/app/bootstrap.php.cache +/var/bootstrap.php.cache +/bin/* +!bin/console +!bin/symfony_requirements +/vendor/ + +# Assets and user uploads +/web/bundles/ +/web/uploads/ + +# PHPUnit +/app/phpunit.xml +/phpunit.xml + +# Build data +/build/ + +# Composer PHAR +/composer.phar + +# Backup entities generated with doctrine:generate:entities command +**/Entity/*~ + +# Embedded web-server pid file +/.web-server-pid + +# From root gitignore +/Tests/cache/ +/Tests/logs/ \ No newline at end of file From 84e2f60d6b3f268afd8547745265c6fbf3a37997 Mon Sep 17 00:00:00 2001 From: Prateek Malhotra Date: Fri, 19 Jul 2019 02:04:27 -0400 Subject: [PATCH 29/62] typescript-fetch: fix basic type errors (#3380) * use proper response for simple object return types * exclude api and/or model support files and imports if none are generated Signed-off-by: Prateek Malhotra --- .../TypeScriptFetchClientCodegen.java | 35 +++++++++++++++++-- .../resources/typescript-fetch/index.mustache | 6 ++++ 2 files changed, 38 insertions(+), 3 deletions(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java index 5521d72e7b..f663409561 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/TypeScriptFetchClientCodegen.java @@ -36,6 +36,9 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege protected String npmRepository = null; private boolean useSingleRequestParameter = true; + protected boolean addedApiIndex = false; + protected boolean addedModelIndex = false; + public TypeScriptFetchClientCodegen() { super(); @@ -83,8 +86,6 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege additionalProperties.put("modelPropertyNaming", getModelPropertyNaming()); supportingFiles.add(new SupportingFile("index.mustache", "", "index.ts")); supportingFiles.add(new SupportingFile("runtime.mustache", "", "runtime.ts")); - supportingFiles.add(new SupportingFile("apis.index.mustache", apiPackage().replace('.', File.separatorChar), "index.ts")); - supportingFiles.add(new SupportingFile("models.index.mustache", modelPackage().replace('.', File.separatorChar), "index.ts")); supportingFiles.add(new SupportingFile("tsconfig.mustache", "", "tsconfig.json")); supportingFiles.add(new SupportingFile("gitignore", "", ".gitignore")); @@ -127,8 +128,9 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege @Override public Map postProcessModels(Map objs) { - // process enum in models List models = (List) postProcessModelsEnum(objs).get("models"); + + // process enum in models for (Object _mo : models) { Map mo = (Map) _mo; CodegenModel cm = (CodegenModel) mo.get("model"); @@ -190,8 +192,21 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege @Override public Map postProcessOperationsWithModels(Map operations, List allModels) { + // Add supporting file only if we plan to generate files in /apis + if (operations.size() > 0 && !addedApiIndex) { + addedApiIndex = true; + supportingFiles.add(new SupportingFile("apis.index.mustache", apiPackage().replace('.', File.separatorChar), "index.ts")); + } + + // Add supporting file only if we plan to generate files in /models + if (allModels.size() > 0 && !addedModelIndex) { + addedModelIndex = true; + supportingFiles.add(new SupportingFile("models.index.mustache", modelPackage().replace('.', File.separatorChar), "index.ts")); + } + this.addOperationModelImportInfomation(operations); this.updateOperationParameterEnumInformation(operations); + this.addOperationObjectResponseInformation(operations); return operations; } @@ -224,6 +239,20 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege operations.put("hasEnums", hasEnum); } + private void addOperationObjectResponseInformation(Map operations) { + // This method will modify the infomation on the operations' return type. + // The api template uses this infomation to know when to return a text + // response for a given simple response operation. + Map _operations = (Map) operations.get("operations"); + List operationList = (List) _operations.get("operation"); + for (CodegenOperation op : operationList) { + if(op.returnType == "object") { + op.isMapContainer = true; + op.returnSimpleType = false; + } + } + } + private void addExtraReservedWords() { this.reservedWords.add("BASE_PATH"); this.reservedWords.add("BaseAPI"); diff --git a/modules/openapi-generator/src/main/resources/typescript-fetch/index.mustache b/modules/openapi-generator/src/main/resources/typescript-fetch/index.mustache index 848ecfa4d1..e548c9df6b 100644 --- a/modules/openapi-generator/src/main/resources/typescript-fetch/index.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-fetch/index.mustache @@ -1,3 +1,9 @@ export * from './runtime'; +{{#apiInfo}} +{{#apis.0}} export * from './apis'; +{{/apis.0}} +{{/apiInfo}} +{{#models.0}} export * from './models'; +{{/models.0}} \ No newline at end of file From e58cc2a28247020c547736c6bae516f89278da6e Mon Sep 17 00:00:00 2001 From: William Cheng Date: Fri, 19 Jul 2019 15:10:01 +0800 Subject: [PATCH 30/62] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 8c56937a88..5893543054 100644 --- a/README.md +++ b/README.md @@ -597,6 +597,8 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - 2019-07-04 - [REST API のためのコード生成入門 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh), [和田拓朗](https://github.com/taxpon) - 2019-07-08 - [OpenAPI Generator にコントリビュートしたら社名が載った話。(CAM) - CAM TECH BLOG](https://tech.cam-inc.co.jp/entry/2019/07/08/140000) by [CAM, Inc.](https://www.cam-inc.co.jp/) - 2019-07-14 - [OpenAPI GeneratorでPythonのクライアントライブラリを作成した](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) +- 2019-07-19 - [Developer Experience (DX) for Open-Source Projects: How to Engage Developers and Build a Growing Developer Community] by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh) at [Open Source Summit Japan 2019](https://events.linuxfoundation.org/events/open-source-summit-japan-2019/) +](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) ## [6 - About Us](#table-of-contents) From 5c7d902c4c7016a6726f7428f9b5b65c1b868cc4 Mon Sep 17 00:00:00 2001 From: wing328 Date: Fri, 19 Jul 2019 15:15:22 +0800 Subject: [PATCH 31/62] fix link to open summit presentation --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 5893543054..192ef232c2 100644 --- a/README.md +++ b/README.md @@ -597,8 +597,7 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in - 2019-07-04 - [REST API のためのコード生成入門 (OpenAPI Generator)](https://gum.co/openapi_generator_ebook_big5) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh), [和田拓朗](https://github.com/taxpon) - 2019-07-08 - [OpenAPI Generator にコントリビュートしたら社名が載った話。(CAM) - CAM TECH BLOG](https://tech.cam-inc.co.jp/entry/2019/07/08/140000) by [CAM, Inc.](https://www.cam-inc.co.jp/) - 2019-07-14 - [OpenAPI GeneratorでPythonのクライアントライブラリを作成した](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) -- 2019-07-19 - [Developer Experience (DX) for Open-Source Projects: How to Engage Developers and Build a Growing Developer Community] by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh) at [Open Source Summit Japan 2019](https://events.linuxfoundation.org/events/open-source-summit-japan-2019/) -](https://qiita.com/yuji38kwmt/items/dfb929316a1335a161c0) by [yuji38kwmt](https://qiita.com/yuji38kwmt) +- 2019-07-19 - [Developer Experience (DX) for Open-Source Projects: How to Engage Developers and Build a Growing Developer Community](https://speakerdeck.com/wing328/developer-experience-dx-for-open-source-projects-english-japanese) by [William Cheng](https://twitter.com/wing328), [中野暁人](https://github.com/ackintosh) at [Open Source Summit Japan 2019](https://events.linuxfoundation.org/events/open-source-summit-japan-2019/) ## [6 - About Us](#table-of-contents) From 21e29d7177d30ffc2b6e99dde229f3b923ac3a92 Mon Sep 17 00:00:00 2001 From: John Wang Date: Fri, 19 Jul 2019 00:44:31 -0700 Subject: [PATCH 32/62] fix README.md missing paren typo (#3391) --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 192ef232c2..fb598b1b9f 100644 --- a/README.md +++ b/README.md @@ -774,7 +774,7 @@ If you want to join the committee, please kindly apply by sending an email to te | Elm | @eriktim (2018/09) | | Erlang | @tsloughter (2017/11) @jfacorro (2018/10) @robertoaloi (2018/10) | | F# | @nmfisher (2019/05) | -| Go | @antihax (2017/11) @bvwells (2017/12) @grokify (2018/07) @kemokemo (2018/09 | +| Go | @antihax (2017/11) @bvwells (2017/12) @grokify (2018/07) @kemokemo (2018/09) | | GraphQL | @renepardon (2018/12) | | Groovy | | | Haskell | | From 1413775e0e17968c8a573cae611db762852a182b Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Sun, 21 Jul 2019 22:23:15 +0200 Subject: [PATCH 33/62] qt5 client: strip whitespace (#3406) --- .../cpp-qt5-client/HttpRequest.cpp.mustache | 4 ++-- .../cpp-qt5-client/HttpRequest.h.mustache | 6 ++--- .../resources/cpp-qt5-client/Project.mustache | 2 +- .../cpp-qt5-client/api-body.mustache | 6 ++--- .../cpp-qt5-client/api-header.mustache | 2 +- .../resources/cpp-qt5-client/enum.mustache | 4 ++-- .../cpp-qt5-client/helpers-body.mustache | 18 +++++++------- .../cpp-qt5-client/helpers-header.mustache | 2 +- .../cpp-qt5-client/model-body.mustache | 4 ++-- .../cpp-qt5-client/model-header.mustache | 2 +- .../resources/cpp-qt5-client/object.mustache | 2 +- .../cpp-qt5/.openapi-generator/VERSION | 2 +- .../petstore/cpp-qt5/client/OAIApiResponse.h | 2 +- .../petstore/cpp-qt5/client/OAICategory.h | 2 +- .../client/petstore/cpp-qt5/client/OAIEnum.h | 4 ++-- .../petstore/cpp-qt5/client/OAIHelpers.cpp | 18 +++++++------- .../petstore/cpp-qt5/client/OAIHelpers.h | 2 +- .../cpp-qt5/client/OAIHttpRequest.cpp | 4 ++-- .../petstore/cpp-qt5/client/OAIHttpRequest.h | 6 ++--- .../petstore/cpp-qt5/client/OAIObject.h | 2 +- .../client/petstore/cpp-qt5/client/OAIOrder.h | 2 +- .../client/petstore/cpp-qt5/client/OAIPet.h | 2 +- .../petstore/cpp-qt5/client/OAIPetApi.cpp | 24 +++++++++---------- .../petstore/cpp-qt5/client/OAIPetApi.h | 2 +- .../petstore/cpp-qt5/client/OAIStoreApi.cpp | 12 +++++----- .../petstore/cpp-qt5/client/OAIStoreApi.h | 2 +- .../client/petstore/cpp-qt5/client/OAITag.h | 2 +- .../client/petstore/cpp-qt5/client/OAIUser.h | 2 +- .../petstore/cpp-qt5/client/OAIUserApi.cpp | 24 +++++++++---------- .../petstore/cpp-qt5/client/OAIUserApi.h | 2 +- .../client/petstore/cpp-qt5/client/client.pri | 2 +- 31 files changed, 85 insertions(+), 85 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.cpp.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.cpp.mustache index f9c036f820..05bad7539e 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.cpp.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.cpp.mustache @@ -45,7 +45,7 @@ void {{prefix}}HttpRequestInput::add_file(QString variable_name, QString local_f : QObject(parent), manager(nullptr) { qsrand(QDateTime::currentDateTime().toTime_t()); - timeout = 0; + timeout = 0; timer = new QTimer(); manager = new QNetworkAccessManager(this); connect(manager, &QNetworkAccessManager::finished, this, &{{prefix}}HttpRequestWorker::on_manager_finished); @@ -57,7 +57,7 @@ void {{prefix}}HttpRequestInput::add_file(QString variable_name, QString local_f timer->stop(); } timer->deleteLater(); - } + } } QMap {{prefix}}HttpRequestWorker::getResponseHeaders() const { diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.h.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.h.mustache index 6ba6b63117..0af88c4070 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.h.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/HttpRequest.h.mustache @@ -76,10 +76,10 @@ signals: private: QNetworkAccessManager *manager; QMap headers; - int timeout; - void on_manager_timeout(QNetworkReply *reply); + int timeout; + void on_manager_timeout(QNetworkReply *reply); private slots: - void on_manager_finished(QNetworkReply *reply); + void on_manager_finished(QNetworkReply *reply); }; {{#cppNamespaceDeclarations}} diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/Project.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/Project.mustache index 11a0eb49bf..9f530b381a 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/Project.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/Project.mustache @@ -19,7 +19,7 @@ HEADERS += \ $${PWD}/{{prefix}}Helpers.h \ $${PWD}/{{prefix}}HttpRequest.h \ $${PWD}/{{prefix}}Object.h - $${PWD}/{{prefix}}Enum.h + $${PWD}/{{prefix}}Enum.h SOURCES += \ # Models diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-body.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-body.mustache index 899a16b059..5777507ec9 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-body.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-body.mustache @@ -49,7 +49,7 @@ void QString fullPath; fullPath.append(this->host).append(this->basePath).append("{{{path}}}"); {{#pathParams}} - QString {{paramName}}PathParam("{"); + QString {{paramName}}PathParam("{"); {{paramName}}PathParam.append("{{baseName}}").append("}"); fullPath.replace({{paramName}}PathParam, QUrl::toPercentEncoding(::{{cppNamespace}}::toStringValue({{paramName}}))); {{/pathParams}} @@ -103,7 +103,7 @@ void } {{/collectionFormat}}{{/queryParams}} {{prefix}}HttpRequestWorker *worker = new {{prefix}}HttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); {{prefix}}HttpRequestInput input(fullPath, "{{httpMethod}}"); {{#formParams}} if ({{paramName}} != nullptr) { @@ -166,7 +166,7 @@ void {{^isListContainer}} {{^isMapContainer}} {{#returnTypeIsPrimitive}} - {{{returnType}}} output; + {{{returnType}}} output; ::{{cppNamespace}}::fromStringValue(QString(worker->response), output); {{/returnTypeIsPrimitive}} {{/isMapContainer}} diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-header.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-header.mustache index ea9218ad52..5f02327975 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-header.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/api-header.mustache @@ -25,7 +25,7 @@ public: void setHost(const QString& host); void setApiTimeOutMs(const int tout); void addHeaders(const QString& key, const QString& value); - + {{#operations}}{{#operation}}void {{nickname}}({{#allParams}}const {{{dataType}}}& {{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}); {{/operation}}{{/operations}} private: diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/enum.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/enum.mustache index 2874ef8c71..bf34a3a150 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/enum.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/enum.mustache @@ -15,7 +15,7 @@ class {{prefix}}Enum { {{prefix}}Enum() { } - + {{prefix}}Enum(QString jsonString) { fromJson(jsonString); } @@ -48,7 +48,7 @@ class {{prefix}}Enum { return true; } private : - QString jstr; + QString jstr; }; {{#cppNamespaceDeclarations}} diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache index 9aa16e1b52..ddf83be291 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache @@ -220,7 +220,7 @@ fromJsonValue(QString &value, const QJsonValue &jval){ } else if(jval.isDouble()){ value = QString::number(jval.toDouble()); } else { - ok = false; + ok = false; } } else { ok = false; @@ -230,7 +230,7 @@ fromJsonValue(QString &value, const QJsonValue &jval){ bool fromJsonValue(QDateTime &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && jval.isString()){ value = QDateTime::fromString(jval.toString(), Qt::ISODate); ok = value.isValid(); @@ -254,7 +254,7 @@ fromJsonValue(QByteArray &value, const QJsonValue &jval){ bool fromJsonValue(QDate &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && jval.isString()){ value = QDate::fromString(jval.toString(), Qt::ISODate); ok = value.isValid(); @@ -266,7 +266,7 @@ fromJsonValue(QDate &value, const QJsonValue &jval){ bool fromJsonValue(qint32 &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && !jval.isObject() && !jval.isArray()){ value = jval.toInt(); } else { @@ -277,7 +277,7 @@ fromJsonValue(qint32 &value, const QJsonValue &jval){ bool fromJsonValue(qint64 &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && !jval.isObject() && !jval.isArray()){ value = jval.toVariant().toLongLong(); } else { @@ -288,7 +288,7 @@ fromJsonValue(qint64 &value, const QJsonValue &jval){ bool fromJsonValue(bool &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isBool()){ value = jval.toBool(); } else { @@ -299,7 +299,7 @@ fromJsonValue(bool &value, const QJsonValue &jval){ bool fromJsonValue(float &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isDouble()){ value = static_cast(jval.toDouble()); } else { @@ -310,7 +310,7 @@ fromJsonValue(float &value, const QJsonValue &jval){ bool fromJsonValue(double &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isDouble()){ value = jval.toDouble(); } else { @@ -321,7 +321,7 @@ fromJsonValue(double &value, const QJsonValue &jval){ bool fromJsonValue({{prefix}}Object &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isObject()){ value.fromJsonObject(jval.toObject()); ok = value.isValid(); diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-header.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-header.mustache index 0948f4f662..6c8436c554 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-header.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-header.mustache @@ -129,7 +129,7 @@ namespace {{this}} { ok = false; } return ok; - } + } template bool fromJsonValue(QMap &val, const QJsonValue &jval) { diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-body.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-body.mustache index 2a75a18c76..1e25f89827 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-body.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-body.mustache @@ -43,7 +43,7 @@ void {{^isEnum}}QByteArray array (jsonString.toStdString().c_str()); QJsonDocument doc = QJsonDocument::fromJson(array); QJsonObject jsonObject = doc.object(); - this->fromJsonObject(jsonObject);{{/isEnum}}{{#isEnum}}{{#allowableValues}}{{#enumVars}} + this->fromJsonObject(jsonObject);{{/isEnum}}{{#isEnum}}{{#allowableValues}}{{#enumVars}} {{#-first}}if{{/-first}}{{^-first}}else if{{/-first}} ( jsonString.compare({{#isString}}"{{value}}"{{/isString}}{{^isString}}QString::number({{value}}){{/isString}}, Qt::CaseInsensitive) == 0) { m_value = e{{classname}}::{{name}}; m_value_isValid = true; @@ -92,7 +92,7 @@ QString {{#enumVars}} case e{{classname}}::{{name}}: val = {{#isString}}"{{value}}"{{/isString}}{{^isString}}QString::number({{value}}){{/isString}}; - break;{{#-last}} + break;{{#-last}} default: break;{{/-last}} {{/enumVars}} diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-header.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-header.mustache index 38b42f401a..556139facf 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-header.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/model-header.mustache @@ -53,7 +53,7 @@ public: {{classname}}::e{{classname}} getValue() const; void setValue(const {{classname}}::e{{classname}}& value);{{/isEnum}} - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/object.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/object.mustache index 100670d1fc..e58b49adb9 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/object.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/object.mustache @@ -15,7 +15,7 @@ class {{prefix}}Object { {{prefix}}Object() { } - + {{prefix}}Object(QString jsonString) { fromJson(jsonString); } diff --git a/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION b/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION index d96260ba33..83a328a922 100644 --- a/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION +++ b/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.2-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/cpp-qt5/client/OAIApiResponse.h b/samples/client/petstore/cpp-qt5/client/OAIApiResponse.h index 2fe8209ac1..aa71d9cdfb 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIApiResponse.h +++ b/samples/client/petstore/cpp-qt5/client/OAIApiResponse.h @@ -53,7 +53,7 @@ public: void setMessage(const QString &message); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAICategory.h b/samples/client/petstore/cpp-qt5/client/OAICategory.h index 129d974857..966f5e295f 100644 --- a/samples/client/petstore/cpp-qt5/client/OAICategory.h +++ b/samples/client/petstore/cpp-qt5/client/OAICategory.h @@ -49,7 +49,7 @@ public: void setName(const QString &name); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAIEnum.h b/samples/client/petstore/cpp-qt5/client/OAIEnum.h index a5e619960f..66625c43b6 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIEnum.h +++ b/samples/client/petstore/cpp-qt5/client/OAIEnum.h @@ -24,7 +24,7 @@ class OAIEnum { OAIEnum() { } - + OAIEnum(QString jsonString) { fromJson(jsonString); } @@ -57,7 +57,7 @@ class OAIEnum { return true; } private : - QString jstr; + QString jstr; }; } diff --git a/samples/client/petstore/cpp-qt5/client/OAIHelpers.cpp b/samples/client/petstore/cpp-qt5/client/OAIHelpers.cpp index bbe372ea85..fa0ba7d9f2 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIHelpers.cpp +++ b/samples/client/petstore/cpp-qt5/client/OAIHelpers.cpp @@ -229,7 +229,7 @@ fromJsonValue(QString &value, const QJsonValue &jval){ } else if(jval.isDouble()){ value = QString::number(jval.toDouble()); } else { - ok = false; + ok = false; } } else { ok = false; @@ -239,7 +239,7 @@ fromJsonValue(QString &value, const QJsonValue &jval){ bool fromJsonValue(QDateTime &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && jval.isString()){ value = QDateTime::fromString(jval.toString(), Qt::ISODate); ok = value.isValid(); @@ -263,7 +263,7 @@ fromJsonValue(QByteArray &value, const QJsonValue &jval){ bool fromJsonValue(QDate &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && jval.isString()){ value = QDate::fromString(jval.toString(), Qt::ISODate); ok = value.isValid(); @@ -275,7 +275,7 @@ fromJsonValue(QDate &value, const QJsonValue &jval){ bool fromJsonValue(qint32 &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && !jval.isObject() && !jval.isArray()){ value = jval.toInt(); } else { @@ -286,7 +286,7 @@ fromJsonValue(qint32 &value, const QJsonValue &jval){ bool fromJsonValue(qint64 &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(!jval.isUndefined() && !jval.isNull() && !jval.isObject() && !jval.isArray()){ value = jval.toVariant().toLongLong(); } else { @@ -297,7 +297,7 @@ fromJsonValue(qint64 &value, const QJsonValue &jval){ bool fromJsonValue(bool &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isBool()){ value = jval.toBool(); } else { @@ -308,7 +308,7 @@ fromJsonValue(bool &value, const QJsonValue &jval){ bool fromJsonValue(float &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isDouble()){ value = static_cast(jval.toDouble()); } else { @@ -319,7 +319,7 @@ fromJsonValue(float &value, const QJsonValue &jval){ bool fromJsonValue(double &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isDouble()){ value = jval.toDouble(); } else { @@ -330,7 +330,7 @@ fromJsonValue(double &value, const QJsonValue &jval){ bool fromJsonValue(OAIObject &value, const QJsonValue &jval){ - bool ok = true; + bool ok = true; if(jval.isObject()){ value.fromJsonObject(jval.toObject()); ok = value.isValid(); diff --git a/samples/client/petstore/cpp-qt5/client/OAIHelpers.h b/samples/client/petstore/cpp-qt5/client/OAIHelpers.h index ce7cec3fc7..0555e5dc24 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIHelpers.h +++ b/samples/client/petstore/cpp-qt5/client/OAIHelpers.h @@ -138,7 +138,7 @@ namespace OpenAPI { ok = false; } return ok; - } + } template bool fromJsonValue(QMap &val, const QJsonValue &jval) { diff --git a/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.cpp b/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.cpp index 8fdd4ea5e9..a2ec8558ce 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.cpp +++ b/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.cpp @@ -54,7 +54,7 @@ OAIHttpRequestWorker::OAIHttpRequestWorker(QObject *parent) : QObject(parent), manager(nullptr) { qsrand(QDateTime::currentDateTime().toTime_t()); - timeout = 0; + timeout = 0; timer = new QTimer(); manager = new QNetworkAccessManager(this); connect(manager, &QNetworkAccessManager::finished, this, &OAIHttpRequestWorker::on_manager_finished); @@ -66,7 +66,7 @@ OAIHttpRequestWorker::~OAIHttpRequestWorker() { timer->stop(); } timer->deleteLater(); - } + } } QMap OAIHttpRequestWorker::getResponseHeaders() const { diff --git a/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.h b/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.h index b7380595c0..ad3c31f694 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.h +++ b/samples/client/petstore/cpp-qt5/client/OAIHttpRequest.h @@ -85,10 +85,10 @@ signals: private: QNetworkAccessManager *manager; QMap headers; - int timeout; - void on_manager_timeout(QNetworkReply *reply); + int timeout; + void on_manager_timeout(QNetworkReply *reply); private slots: - void on_manager_finished(QNetworkReply *reply); + void on_manager_finished(QNetworkReply *reply); }; } diff --git a/samples/client/petstore/cpp-qt5/client/OAIObject.h b/samples/client/petstore/cpp-qt5/client/OAIObject.h index babc1e64fb..83757b5671 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIObject.h +++ b/samples/client/petstore/cpp-qt5/client/OAIObject.h @@ -24,7 +24,7 @@ class OAIObject { OAIObject() { } - + OAIObject(QString jsonString) { fromJson(jsonString); } diff --git a/samples/client/petstore/cpp-qt5/client/OAIOrder.h b/samples/client/petstore/cpp-qt5/client/OAIOrder.h index c9b006d363..79b3fe7413 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIOrder.h +++ b/samples/client/petstore/cpp-qt5/client/OAIOrder.h @@ -66,7 +66,7 @@ public: void setComplete(const bool &complete); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAIPet.h b/samples/client/petstore/cpp-qt5/client/OAIPet.h index 6bec604d21..f4e357e693 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIPet.h +++ b/samples/client/petstore/cpp-qt5/client/OAIPet.h @@ -68,7 +68,7 @@ public: void setStatus(const QString &status); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAIPetApi.cpp b/samples/client/petstore/cpp-qt5/client/OAIPetApi.cpp index 3e83ea0066..1341a73c3b 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIPetApi.cpp +++ b/samples/client/petstore/cpp-qt5/client/OAIPetApi.cpp @@ -57,7 +57,7 @@ OAIPetApi::addPet(const OAIPet& body) { fullPath.append(this->host).append(this->basePath).append("/pet"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); @@ -104,12 +104,12 @@ void OAIPetApi::deletePet(const qint64& pet_id, const QString& api_key) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/pet/{petId}"); - QString pet_idPathParam("{"); + QString pet_idPathParam("{"); pet_idPathParam.append("petId").append("}"); fullPath.replace(pet_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(pet_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "DELETE"); if (api_key != nullptr) { @@ -197,7 +197,7 @@ OAIPetApi::findPetsByStatus(const QList& status) { } OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -292,7 +292,7 @@ OAIPetApi::findPetsByTags(const QList& tags) { } OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -345,12 +345,12 @@ void OAIPetApi::getPetById(const qint64& pet_id) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/pet/{petId}"); - QString pet_idPathParam("{"); + QString pet_idPathParam("{"); pet_idPathParam.append("petId").append("}"); fullPath.replace(pet_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(pet_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -396,7 +396,7 @@ OAIPetApi::updatePet(const OAIPet& body) { fullPath.append(this->host).append(this->basePath).append("/pet"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "PUT"); @@ -443,12 +443,12 @@ void OAIPetApi::updatePetWithForm(const qint64& pet_id, const QString& name, const QString& status) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/pet/{petId}"); - QString pet_idPathParam("{"); + QString pet_idPathParam("{"); pet_idPathParam.append("petId").append("}"); fullPath.replace(pet_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(pet_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); if (name != nullptr) { input.add_var("name", name); @@ -497,12 +497,12 @@ void OAIPetApi::uploadFile(const qint64& pet_id, const QString& additional_metadata, const OAIHttpRequestInputFileElement*& file) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/pet/{petId}/uploadImage"); - QString pet_idPathParam("{"); + QString pet_idPathParam("{"); pet_idPathParam.append("petId").append("}"); fullPath.replace(pet_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(pet_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); if (additional_metadata != nullptr) { input.add_var("additionalMetadata", additional_metadata); diff --git a/samples/client/petstore/cpp-qt5/client/OAIPetApi.h b/samples/client/petstore/cpp-qt5/client/OAIPetApi.h index bd64db93db..449de95853 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIPetApi.h +++ b/samples/client/petstore/cpp-qt5/client/OAIPetApi.h @@ -36,7 +36,7 @@ public: void setHost(const QString& host); void setApiTimeOutMs(const int tout); void addHeaders(const QString& key, const QString& value); - + void addPet(const OAIPet& body); void deletePet(const qint64& pet_id, const QString& api_key); void findPetsByStatus(const QList& status); diff --git a/samples/client/petstore/cpp-qt5/client/OAIStoreApi.cpp b/samples/client/petstore/cpp-qt5/client/OAIStoreApi.cpp index 90ac22d129..7b2e37f635 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIStoreApi.cpp +++ b/samples/client/petstore/cpp-qt5/client/OAIStoreApi.cpp @@ -55,12 +55,12 @@ void OAIStoreApi::deleteOrder(const QString& order_id) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/store/order/{orderId}"); - QString order_idPathParam("{"); + QString order_idPathParam("{"); order_idPathParam.append("orderId").append("}"); fullPath.replace(order_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(order_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "DELETE"); @@ -105,7 +105,7 @@ OAIStoreApi::getInventory() { fullPath.append(this->host).append(this->basePath).append("/store/inventory"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -158,12 +158,12 @@ void OAIStoreApi::getOrderById(const qint64& order_id) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/store/order/{orderId}"); - QString order_idPathParam("{"); + QString order_idPathParam("{"); order_idPathParam.append("orderId").append("}"); fullPath.replace(order_idPathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(order_id))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -209,7 +209,7 @@ OAIStoreApi::placeOrder(const OAIOrder& body) { fullPath.append(this->host).append(this->basePath).append("/store/order"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); diff --git a/samples/client/petstore/cpp-qt5/client/OAIStoreApi.h b/samples/client/petstore/cpp-qt5/client/OAIStoreApi.h index e532321dcd..2f9d41b998 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIStoreApi.h +++ b/samples/client/petstore/cpp-qt5/client/OAIStoreApi.h @@ -35,7 +35,7 @@ public: void setHost(const QString& host); void setApiTimeOutMs(const int tout); void addHeaders(const QString& key, const QString& value); - + void deleteOrder(const QString& order_id); void getInventory(); void getOrderById(const qint64& order_id); diff --git a/samples/client/petstore/cpp-qt5/client/OAITag.h b/samples/client/petstore/cpp-qt5/client/OAITag.h index 497a021f08..1ea18b3867 100644 --- a/samples/client/petstore/cpp-qt5/client/OAITag.h +++ b/samples/client/petstore/cpp-qt5/client/OAITag.h @@ -49,7 +49,7 @@ public: void setName(const QString &name); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAIUser.h b/samples/client/petstore/cpp-qt5/client/OAIUser.h index 556de32258..f7dd6591ec 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIUser.h +++ b/samples/client/petstore/cpp-qt5/client/OAIUser.h @@ -73,7 +73,7 @@ public: void setUserStatus(const qint32 &user_status); - + virtual bool isSet() const override; virtual bool isValid() const override; diff --git a/samples/client/petstore/cpp-qt5/client/OAIUserApi.cpp b/samples/client/petstore/cpp-qt5/client/OAIUserApi.cpp index 36a418994f..57556eab78 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIUserApi.cpp +++ b/samples/client/petstore/cpp-qt5/client/OAIUserApi.cpp @@ -57,7 +57,7 @@ OAIUserApi::createUser(const OAIUser& body) { fullPath.append(this->host).append(this->basePath).append("/user"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); @@ -106,7 +106,7 @@ OAIUserApi::createUsersWithArrayInput(const QList& body) { fullPath.append(this->host).append(this->basePath).append("/user/createWithArray"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); @@ -156,7 +156,7 @@ OAIUserApi::createUsersWithListInput(const QList& body) { fullPath.append(this->host).append(this->basePath).append("/user/createWithList"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "POST"); @@ -204,12 +204,12 @@ void OAIUserApi::deleteUser(const QString& username) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/user/{username}"); - QString usernamePathParam("{"); + QString usernamePathParam("{"); usernamePathParam.append("username").append("}"); fullPath.replace(usernamePathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(username))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "DELETE"); @@ -252,12 +252,12 @@ void OAIUserApi::getUserByName(const QString& username) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/user/{username}"); - QString usernamePathParam("{"); + QString usernamePathParam("{"); usernamePathParam.append("username").append("}"); fullPath.replace(usernamePathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(username))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -319,7 +319,7 @@ OAIUserApi::loginUser(const QString& username, const QString& password) { .append(QUrl::toPercentEncoding(::OpenAPI::toStringValue(password))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -347,7 +347,7 @@ OAIUserApi::loginUserCallback(OAIHttpRequestWorker * worker) { else { msg = "Error: " + worker->error_str; } - QString output; + QString output; ::OpenAPI::fromStringValue(QString(worker->response), output); worker->deleteLater(); @@ -366,7 +366,7 @@ OAIUserApi::logoutUser() { fullPath.append(this->host).append(this->basePath).append("/user/logout"); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "GET"); @@ -409,12 +409,12 @@ void OAIUserApi::updateUser(const QString& username, const OAIUser& body) { QString fullPath; fullPath.append(this->host).append(this->basePath).append("/user/{username}"); - QString usernamePathParam("{"); + QString usernamePathParam("{"); usernamePathParam.append("username").append("}"); fullPath.replace(usernamePathParam, QUrl::toPercentEncoding(::OpenAPI::toStringValue(username))); OAIHttpRequestWorker *worker = new OAIHttpRequestWorker(); - worker->setTimeOut(timeout); + worker->setTimeOut(timeout); OAIHttpRequestInput input(fullPath, "PUT"); diff --git a/samples/client/petstore/cpp-qt5/client/OAIUserApi.h b/samples/client/petstore/cpp-qt5/client/OAIUserApi.h index d95814e071..454210caa6 100644 --- a/samples/client/petstore/cpp-qt5/client/OAIUserApi.h +++ b/samples/client/petstore/cpp-qt5/client/OAIUserApi.h @@ -35,7 +35,7 @@ public: void setHost(const QString& host); void setApiTimeOutMs(const int tout); void addHeaders(const QString& key, const QString& value); - + void createUser(const OAIUser& body); void createUsersWithArrayInput(const QList& body); void createUsersWithListInput(const QList& body); diff --git a/samples/client/petstore/cpp-qt5/client/client.pri b/samples/client/petstore/cpp-qt5/client/client.pri index c2b0a272a1..ca6c9b5524 100644 --- a/samples/client/petstore/cpp-qt5/client/client.pri +++ b/samples/client/petstore/cpp-qt5/client/client.pri @@ -16,7 +16,7 @@ HEADERS += \ $${PWD}/OAIHelpers.h \ $${PWD}/OAIHttpRequest.h \ $${PWD}/OAIObject.h - $${PWD}/OAIEnum.h + $${PWD}/OAIEnum.h SOURCES += \ # Models From 5cba55f8fbd196a9d6754a5136e046b5089e0d47 Mon Sep 17 00:00:00 2001 From: Daiki Matsudate Date: Mon, 22 Jul 2019 17:12:34 +0900 Subject: [PATCH 34/62] [Swift4] Introduce XcodeGen (#3396) * add XcodeGen.mustache * generate code * add dependencies --- bin/swift4-petstore-objcCompatible.sh | 10 + bin/swift4-petstore-promisekit.sh | 10 + bin/swift4-petstore-rxswift.sh | 10 + bin/swift4-petstore-unwrapRequired.sh | 10 + bin/swift4-petstore.sh | 10 + bin/swift4-test.sh | 10 + .../codegen/languages/Swift4Codegen.java | 3 + .../main/resources/swift4/XcodeGen.mustache | 17 + .../swift4/default/.openapi-generator/VERSION | 2 +- .../client/petstore/swift4/default/Info.plist | 22 + .../PetstoreClient.xcodeproj/project.pbxproj | 569 ++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcshareddata/IDEWorkspaceChecks.plist | 8 + .../xcschemes/PetstoreClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 11 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 4 +- .../Classes/OpenAPIs/APIs/FakeAPI.swift | 56 +- .../APIs/FakeClassnameTags123API.swift | 4 +- .../Classes/OpenAPIs/APIs/PetAPI.swift | 48 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 26 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 36 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../Classes/OpenAPIs/Models.swift | 2 +- .../Models/AdditionalPropertiesClass.swift | 12 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/CatAllOf.swift | 18 + .../Classes/OpenAPIs/Models/Category.swift | 4 - .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/DogAllOf.swift | 18 + .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/File.swift | 3 - .../OpenAPIs/Models/FileSchemaTestClass.swift | 4 - .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 14 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 4 - .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 4 - .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../OpenAPIs/Models/StringBooleanMap.swift | 8 +- .../Classes/OpenAPIs/Models/Tag.swift | 4 - .../OpenAPIs/Models/TypeHolderDefault.swift | 6 +- .../OpenAPIs/Models/TypeHolderExample.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 4 - .../client/petstore/swift4/default/README.md | 2 + .../Pods/Alamofire/Source/Alamofire.swift | 27 +- .../Alamofire/Source/MultipartFormData.swift | 6 +- .../Source/NetworkReachabilityManager.swift | 6 +- .../Alamofire/Source/ParameterEncoding.swift | 3 +- .../Pods/Alamofire/Source/Request.swift | 6 +- .../Pods/Alamofire/Source/Response.swift | 12 +- .../Source/ResponseSerialization.swift | 54 +- .../Alamofire/Source/ServerTrustPolicy.swift | 1 - .../Alamofire/Source/SessionDelegate.swift | 36 +- .../Alamofire/Source/SessionManager.swift | 39 +- .../Pods/Alamofire/Source/TaskDelegate.swift | 30 +- .../Pods/Alamofire/Source/Timeline.swift | 3 +- .../Pods/Alamofire/Source/Validation.swift | 6 +- .../SwaggerClient/AppDelegate.swift | 3 - .../SwaggerClient/ViewController.swift | 2 - .../SwaggerClientTests/DateFormatTests.swift | 38 +- .../SwaggerClientTests/PetAPITests.swift | 30 +- .../SwaggerClientTests/StoreAPITests.swift | 26 +- .../SwaggerClientTests/UserAPITests.swift | 22 +- .../petstore/swift4/default/docs/CatAllOf.md | 10 + .../petstore/swift4/default/docs/DogAllOf.md | 10 + .../petstore/swift4/default/docs/UserAPI.md | 4 +- .../petstore/swift4/default/project.yml | 15 + .../objcCompatible/.openapi-generator/VERSION | 2 +- .../petstore/swift4/objcCompatible/Info.plist | 22 + .../PetstoreClient.xcodeproj/project.pbxproj | 601 +++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcschemes/PetstoreClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 11 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 4 +- .../Classes/OpenAPIs/APIs/FakeAPI.swift | 58 +- .../APIs/FakeClassnameTags123API.swift | 4 +- .../Classes/OpenAPIs/APIs/PetAPI.swift | 48 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 26 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 36 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../Classes/OpenAPIs/Models.swift | 2 +- .../Models/AdditionalPropertiesAnyType.swift | 7 +- .../Models/AdditionalPropertiesArray.swift | 7 +- .../Models/AdditionalPropertiesBoolean.swift | 7 +- .../Models/AdditionalPropertiesClass.swift | 24 +- .../Models/AdditionalPropertiesInteger.swift | 7 +- .../Models/AdditionalPropertiesNumber.swift | 7 +- .../Models/AdditionalPropertiesObject.swift | 7 +- .../Models/AdditionalPropertiesString.swift | 7 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/CatAllOf.swift | 18 + .../Classes/OpenAPIs/Models/Category.swift | 6 +- .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/DogAllOf.swift | 18 + .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/File.swift | 3 - .../OpenAPIs/Models/FileSchemaTestClass.swift | 4 - .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 16 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 6 +- .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 6 +- .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../OpenAPIs/Models/StringBooleanMap.swift | 8 +- .../Classes/OpenAPIs/Models/Tag.swift | 6 +- .../OpenAPIs/Models/TypeHolderDefault.swift | 6 +- .../OpenAPIs/Models/TypeHolderExample.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 6 +- .../Classes/OpenAPIs/Models/XmlItem.swift | 6 +- .../petstore/swift4/objcCompatible/README.md | 2 + .../swift4/objcCompatible/docs/CatAllOf.md | 10 + .../swift4/objcCompatible/docs/DogAllOf.md | 10 + .../swift4/objcCompatible/docs/UserAPI.md | 4 +- .../swift4/objcCompatible/project.yml | 15 + .../promisekit/.openapi-generator/VERSION | 2 +- .../petstore/swift4/promisekit/Info.plist | 22 + .../PetstoreClient.xcodeproj/project.pbxproj | 577 +++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcschemes/PetstoreClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 11 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 2 - .../Classes/OpenAPIs/APIs/FakeAPI.swift | 44 +- .../APIs/FakeClassnameTags123API.swift | 2 - .../Classes/OpenAPIs/APIs/PetAPI.swift | 38 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 22 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 24 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../Classes/OpenAPIs/Models.swift | 2 +- .../Models/AdditionalPropertiesClass.swift | 12 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/CatAllOf.swift | 18 + .../Classes/OpenAPIs/Models/Category.swift | 4 - .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/DogAllOf.swift | 18 + .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/File.swift | 3 - .../OpenAPIs/Models/FileSchemaTestClass.swift | 4 - .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 14 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 4 - .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 4 - .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../OpenAPIs/Models/StringBooleanMap.swift | 8 +- .../Classes/OpenAPIs/Models/Tag.swift | 4 - .../OpenAPIs/Models/TypeHolderDefault.swift | 6 +- .../OpenAPIs/Models/TypeHolderExample.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 4 - .../Classes/OpenAPIs/Models/XmlItem.swift | 6 +- .../petstore/swift4/promisekit/README.md | 2 + .../Pods/Alamofire/Source/Alamofire.swift | 27 +- .../Alamofire/Source/MultipartFormData.swift | 6 +- .../Source/NetworkReachabilityManager.swift | 6 +- .../Alamofire/Source/ParameterEncoding.swift | 3 +- .../Pods/Alamofire/Source/Request.swift | 6 +- .../Pods/Alamofire/Source/Response.swift | 12 +- .../Source/ResponseSerialization.swift | 54 +- .../Alamofire/Source/ServerTrustPolicy.swift | 1 - .../Alamofire/Source/SessionDelegate.swift | 36 +- .../Alamofire/Source/SessionManager.swift | 39 +- .../Pods/Alamofire/Source/TaskDelegate.swift | 30 +- .../Pods/Alamofire/Source/Timeline.swift | 3 +- .../Pods/Alamofire/Source/Validation.swift | 6 +- .../Pods/PromiseKit/Sources/AnyPromise.swift | 3 +- .../Pods/PromiseKit/Sources/Error.swift | 5 +- .../Pods/PromiseKit/Sources/Promise.swift | 20 +- .../Pods/PromiseKit/Sources/State.swift | 6 +- .../Pods/PromiseKit/Sources/Zalgo.swift | 1 - .../Pods/PromiseKit/Sources/join.swift | 4 +- .../Pods/PromiseKit/Sources/when.swift | 8 +- .../Pods/PromiseKit/Sources/wrap.swift | 2 +- .../SwaggerClient/AppDelegate.swift | 3 - .../SwaggerClient/ViewController.swift | 2 - .../SwaggerClientTests/PetAPITests.swift | 16 +- .../SwaggerClientTests/StoreAPITests.swift | 12 +- .../SwaggerClientTests/UserAPITests.swift | 6 +- .../swift4/promisekit/docs/CatAllOf.md | 10 + .../swift4/promisekit/docs/DogAllOf.md | 10 + .../swift4/promisekit/docs/UserAPI.md | 4 +- .../petstore/swift4/promisekit/project.yml | 16 + .../swift4/rxswift/.openapi-generator/VERSION | 2 +- .../client/petstore/swift4/rxswift/Info.plist | 22 + .../PetstoreClient.xcodeproj/project.pbxproj | 605 ++++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcschemes/PetstoreClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 11 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 2 - .../Classes/OpenAPIs/APIs/FakeAPI.swift | 34 +- .../APIs/FakeClassnameTags123API.swift | 2 - .../Classes/OpenAPIs/APIs/PetAPI.swift | 30 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 20 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 20 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../Classes/OpenAPIs/Models.swift | 2 +- .../Models/AdditionalPropertiesAnyType.swift | 7 +- .../Models/AdditionalPropertiesArray.swift | 7 +- .../Models/AdditionalPropertiesBoolean.swift | 7 +- .../Models/AdditionalPropertiesClass.swift | 12 +- .../Models/AdditionalPropertiesInteger.swift | 7 +- .../Models/AdditionalPropertiesNumber.swift | 7 +- .../Models/AdditionalPropertiesObject.swift | 7 +- .../Models/AdditionalPropertiesString.swift | 7 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/CatAllOf.swift | 18 + .../Classes/OpenAPIs/Models/Category.swift | 4 - .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/DogAllOf.swift | 18 + .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/File.swift | 3 - .../OpenAPIs/Models/FileSchemaTestClass.swift | 4 - .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 14 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 4 - .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 4 - .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../OpenAPIs/Models/StringBooleanMap.swift | 8 +- .../Classes/OpenAPIs/Models/Tag.swift | 4 - .../OpenAPIs/Models/TypeHolderDefault.swift | 6 +- .../OpenAPIs/Models/TypeHolderExample.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 4 - .../Classes/OpenAPIs/Models/XmlItem.swift | 6 +- .../client/petstore/swift4/rxswift/README.md | 2 + .../Pods/Alamofire/Source/Alamofire.swift | 27 +- .../Alamofire/Source/MultipartFormData.swift | 6 +- .../Source/NetworkReachabilityManager.swift | 6 +- .../Alamofire/Source/ParameterEncoding.swift | 3 +- .../Pods/Alamofire/Source/Request.swift | 6 +- .../Pods/Alamofire/Source/Response.swift | 12 +- .../Source/ResponseSerialization.swift | 54 +- .../Alamofire/Source/ServerTrustPolicy.swift | 1 - .../Alamofire/Source/SessionDelegate.swift | 36 +- .../Alamofire/Source/SessionManager.swift | 39 +- .../Pods/Alamofire/Source/TaskDelegate.swift | 30 +- .../Pods/Alamofire/Source/Timeline.swift | 3 +- .../Pods/Alamofire/Source/Validation.swift | 6 +- .../Classes/OpenAPIs/APIHelper.swift | 12 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 4 +- .../Classes/OpenAPIs/APIs/FakeAPI.swift | 64 +- .../APIs/FakeClassnameTags123API.swift | 4 +- .../Classes/OpenAPIs/APIs/PetAPI.swift | 50 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 32 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 50 +- .../OpenAPIs/AlamofireImplementations.swift | 29 +- .../Classes/OpenAPIs/CodableHelper.swift | 10 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 20 +- .../OpenAPIs/JSONEncodableEncoding.swift | 2 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 8 +- .../Classes/OpenAPIs/Models.swift | 4 +- .../Models/AdditionalPropertiesClass.swift | 12 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/Category.swift | 6 +- .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 12 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 6 +- .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 6 +- .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../Classes/OpenAPIs/Models/Tag.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 6 +- .../Pods/RxSwift/Platform/AtomicInt.swift | 1 - .../RxSwift/Platform/DataStructures/Bag.swift | 24 +- .../DataStructures/InfiniteSequence.swift | 6 +- .../DataStructures/PriorityQueue.swift | 2 +- .../Platform/DataStructures/Queue.swift | 36 +- .../RxSwift/Platform/DeprecationWarner.swift | 9 +- .../RxSwift/Platform/Platform.Darwin.swift | 5 +- .../RxSwift/Platform/Platform.Linux.swift | 3 +- .../Pods/RxSwift/RxSwift/AnyObserver.swift | 10 +- .../Pods/RxSwift/RxSwift/Cancelable.swift | 2 +- .../RxSwift/Concurrency/AsyncLock.swift | 23 +- .../RxSwift/RxSwift/Concurrency/Lock.swift | 2 +- .../RxSwift/Concurrency/LockOwnerType.swift | 2 +- .../Concurrency/SynchronizedDisposeType.swift | 2 +- .../Concurrency/SynchronizedOnType.swift | 2 +- .../SynchronizedUnsubscribeType.swift | 2 +- .../RxSwift/ConnectableObservableType.swift | 2 +- .../Pods/RxSwift/RxSwift/Deprecated.swift | 4 - .../Disposables/AnonymousDisposable.swift | 12 +- .../Disposables/BinaryDisposable.swift | 6 +- .../Disposables/BooleanDisposable.swift | 10 +- .../Disposables/CompositeDisposable.swift | 56 +- .../RxSwift/Disposables/Disposables.swift | 1 - .../RxSwift/Disposables/DisposeBag.swift | 14 +- .../RxSwift/Disposables/DisposeBase.swift | 6 +- .../RxSwift/Disposables/NopDisposable.swift | 10 +- .../Disposables/RefCountDisposable.swift | 21 +- .../Disposables/ScheduledDisposable.swift | 4 +- .../Disposables/SerialDisposable.swift | 20 +- .../SingleAssignmentDisposable.swift | 4 +- .../Pods/RxSwift/RxSwift/Errors.swift | 4 +- .../Pods/RxSwift/RxSwift/Event.swift | 7 +- .../RxSwift/RxSwift/Extensions/Bag+Rx.swift | 3 +- .../RxSwift/RxSwift/GroupedObservable.swift | 2 +- .../RxSwift/ImmediateSchedulerType.swift | 6 +- .../Pods/RxSwift/RxSwift/Observable.swift | 13 +- .../RxSwift/ObservableType+Extensions.swift | 26 +- .../Pods/RxSwift/RxSwift/ObservableType.swift | 4 +- .../RxSwift/RxSwift/Observables/AddRef.swift | 14 +- .../RxSwift/RxSwift/Observables/Amb.swift | 46 +- .../RxSwift/RxSwift/Observables/AsMaybe.swift | 4 +- .../RxSwift/Observables/AsSingle.swift | 7 +- .../RxSwift/RxSwift/Observables/Buffer.swift | 49 +- .../RxSwift/RxSwift/Observables/Catch.swift | 68 +- .../CombineLatest+Collection.swift | 48 +- .../Observables/CombineLatest+arity.swift | 16 - .../RxSwift/Observables/CombineLatest.swift | 39 +- .../RxSwift/RxSwift/Observables/Concat.swift | 23 +- .../RxSwift/RxSwift/Observables/Create.swift | 6 +- .../RxSwift/Observables/Debounce.swift | 14 +- .../RxSwift/RxSwift/Observables/Debug.swift | 24 +- .../RxSwift/Observables/DefaultIfEmpty.swift | 16 +- .../RxSwift/Observables/Deferred.swift | 21 +- .../RxSwift/RxSwift/Observables/Delay.swift | 43 +- .../Observables/DelaySubscription.swift | 18 +- .../RxSwift/Observables/Dematerialize.swift | 8 +- .../Observables/DistinctUntilChanged.swift | 27 +- .../Pods/RxSwift/RxSwift/Observables/Do.swift | 29 +- .../RxSwift/Observables/ElementAt.swift | 28 +- .../RxSwift/RxSwift/Observables/Empty.swift | 4 +- .../RxSwift/Observables/Enumerated.swift | 9 +- .../RxSwift/RxSwift/Observables/Error.swift | 8 +- .../RxSwift/RxSwift/Observables/Filter.swift | 19 +- .../RxSwift/RxSwift/Observables/First.swift | 2 +- .../RxSwift/Observables/Generate.swift | 28 +- .../RxSwift/RxSwift/Observables/GroupBy.swift | 37 +- .../RxSwift/RxSwift/Observables/Just.swift | 14 +- .../RxSwift/RxSwift/Observables/Map.swift | 17 +- .../RxSwift/Observables/Materialize.swift | 6 +- .../RxSwift/RxSwift/Observables/Merge.swift | 105 ++- .../RxSwift/Observables/Multicast.swift | 60 +- .../RxSwift/RxSwift/Observables/Never.swift | 4 +- .../RxSwift/Observables/ObserveOn.swift | 62 +- .../RxSwift/Observables/Optional.swift | 14 +- .../RxSwift/Observables/Producer.swift | 17 +- .../RxSwift/RxSwift/Observables/Range.swift | 19 +- .../RxSwift/RxSwift/Observables/Reduce.swift | 24 +- .../RxSwift/RxSwift/Observables/Repeat.swift | 16 +- .../RxSwift/Observables/RetryWhen.swift | 43 +- .../RxSwift/RxSwift/Observables/Sample.swift | 41 +- .../RxSwift/RxSwift/Observables/Scan.swift | 27 +- .../RxSwift/Observables/Sequence.swift | 9 +- .../Observables/ShareReplayScope.swift | 32 +- .../RxSwift/Observables/SingleAsync.swift | 17 +- .../RxSwift/RxSwift/Observables/Sink.swift | 16 +- .../RxSwift/RxSwift/Observables/Skip.swift | 51 +- .../RxSwift/Observables/SkipUntil.swift | 44 +- .../RxSwift/Observables/SkipWhile.swift | 6 +- .../RxSwift/Observables/StartWith.swift | 4 +- .../RxSwift/Observables/SubscribeOn.swift | 26 +- .../RxSwift/RxSwift/Observables/Switch.swift | 52 +- .../RxSwift/Observables/SwitchIfEmpty.swift | 29 +- .../RxSwift/RxSwift/Observables/Take.swift | 60 +- .../RxSwift/Observables/TakeLast.swift | 20 +- .../RxSwift/Observables/TakeUntil.swift | 50 +- .../RxSwift/Observables/TakeWhile.swift | 17 +- .../RxSwift/Observables/Throttle.swift | 43 +- .../RxSwift/RxSwift/Observables/Timeout.swift | 55 +- .../RxSwift/RxSwift/Observables/Timer.swift | 31 +- .../RxSwift/RxSwift/Observables/ToArray.swift | 15 +- .../RxSwift/RxSwift/Observables/Using.swift | 27 +- .../RxSwift/RxSwift/Observables/Window.swift | 69 +- .../RxSwift/Observables/WithLatestFrom.swift | 39 +- .../RxSwift/Observables/Zip+Collection.swift | 58 +- .../RxSwift/Observables/Zip+arity.swift | 16 - .../RxSwift/RxSwift/Observables/Zip.swift | 57 +- .../Pods/RxSwift/RxSwift/ObserverType.swift | 6 +- .../RxSwift/Observers/AnonymousObserver.swift | 14 +- .../RxSwift/Observers/TailRecursiveSink.swift | 22 +- .../Pods/RxSwift/RxSwift/Rx.swift | 10 +- .../Pods/RxSwift/RxSwift/RxMutableBox.swift | 4 +- .../Pods/RxSwift/RxSwift/SchedulerType.swift | 12 +- .../ConcurrentDispatchQueueScheduler.swift | 12 +- .../Schedulers/ConcurrentMainScheduler.swift | 4 +- .../Schedulers/CurrentThreadScheduler.swift | 15 +- .../Schedulers/HistoricalScheduler.swift | 2 +- .../HistoricalSchedulerTimeConverter.swift | 2 +- .../Internal/DispatchQueueConfiguration.swift | 5 +- .../Schedulers/Internal/ScheduledItem.swift | 11 +- .../Internal/ScheduledItemType.swift | 4 +- .../RxSwift/Schedulers/MainScheduler.swift | 2 +- .../Schedulers/OperationQueueScheduler.swift | 7 +- .../Schedulers/RecursiveScheduler.swift | 57 +- .../SchedulerServices+Emulation.swift | 2 +- .../SerialDispatchQueueScheduler.swift | 14 +- .../Schedulers/VirtualTimeScheduler.swift | 25 +- .../RxSwift/Subjects/AsyncSubject.swift | 18 +- .../RxSwift/Subjects/BehaviorSubject.swift | 39 +- .../RxSwift/Subjects/PublishSubject.swift | 34 +- .../RxSwift/Subjects/ReplaySubject.swift | 76 +-- .../RxSwift/Subjects/SubjectType.swift | 6 +- .../RxSwift/Traits/Completable+AndThen.swift | 15 +- .../RxSwift/RxSwift/Traits/Completable.swift | 38 +- .../Pods/RxSwift/RxSwift/Traits/Maybe.swift | 32 +- .../Traits/PrimitiveSequence+Zip+arity.swift | 23 - .../RxSwift/Traits/PrimitiveSequence.swift | 13 +- .../Pods/RxSwift/RxSwift/Traits/Single.swift | 50 +- .../SwaggerClient/AppDelegate.swift | 2 - .../SwaggerClient/ViewController.swift | 1 - .../SwaggerClientTests/APIHelperTests.swift | 6 +- .../SwaggerClientTests/PetAPITests.swift | 4 +- .../SwaggerClientTests/StoreAPITests.swift | 4 +- .../SwaggerClientTests/UserAPITests.swift | 2 +- .../petstore/swift4/rxswift/docs/CatAllOf.md | 10 + .../petstore/swift4/rxswift/docs/DogAllOf.md | 10 + .../petstore/swift4/rxswift/docs/UserAPI.md | 4 +- .../petstore/swift4/rxswift/project.yml | 16 + .../unwrapRequired/.openapi-generator/VERSION | 2 +- .../petstore/swift4/unwrapRequired/Info.plist | 22 + .../PetstoreClient.xcodeproj/project.pbxproj | 601 +++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcschemes/PetstoreClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 11 +- .../Classes/OpenAPIs/APIs.swift | 14 +- .../OpenAPIs/APIs/AnotherFakeAPI.swift | 4 +- .../Classes/OpenAPIs/APIs/FakeAPI.swift | 56 +- .../APIs/FakeClassnameTags123API.swift | 4 +- .../Classes/OpenAPIs/APIs/PetAPI.swift | 48 +- .../Classes/OpenAPIs/APIs/StoreAPI.swift | 26 +- .../Classes/OpenAPIs/APIs/UserAPI.swift | 36 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../Classes/OpenAPIs/Models.swift | 2 +- .../Models/AdditionalPropertiesAnyType.swift | 7 +- .../Models/AdditionalPropertiesArray.swift | 7 +- .../Models/AdditionalPropertiesBoolean.swift | 7 +- .../Models/AdditionalPropertiesClass.swift | 12 +- .../Models/AdditionalPropertiesInteger.swift | 7 +- .../Models/AdditionalPropertiesNumber.swift | 7 +- .../Models/AdditionalPropertiesObject.swift | 7 +- .../Models/AdditionalPropertiesString.swift | 7 +- .../Classes/OpenAPIs/Models/Animal.swift | 4 - .../Classes/OpenAPIs/Models/AnimalFarm.swift | 1 - .../Classes/OpenAPIs/Models/ApiResponse.swift | 4 - .../Models/ArrayOfArrayOfNumberOnly.swift | 6 +- .../OpenAPIs/Models/ArrayOfNumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/ArrayTest.swift | 6 +- .../OpenAPIs/Models/Capitalization.swift | 6 +- .../Classes/OpenAPIs/Models/Cat.swift | 4 - .../Classes/OpenAPIs/Models/CatAllOf.swift | 18 + .../Classes/OpenAPIs/Models/Category.swift | 4 - .../Classes/OpenAPIs/Models/ClassModel.swift | 3 - .../Classes/OpenAPIs/Models/Client.swift | 4 - .../Classes/OpenAPIs/Models/Dog.swift | 4 - .../Classes/OpenAPIs/Models/DogAllOf.swift | 18 + .../Classes/OpenAPIs/Models/EnumArrays.swift | 6 +- .../Classes/OpenAPIs/Models/EnumClass.swift | 1 - .../Classes/OpenAPIs/Models/EnumTest.swift | 6 +- .../Classes/OpenAPIs/Models/File.swift | 3 - .../OpenAPIs/Models/FileSchemaTestClass.swift | 4 - .../Classes/OpenAPIs/Models/FormatTest.swift | 4 - .../OpenAPIs/Models/HasOnlyReadOnly.swift | 4 - .../Classes/OpenAPIs/Models/List.swift | 6 +- .../Classes/OpenAPIs/Models/MapTest.swift | 14 +- ...opertiesAndAdditionalPropertiesClass.swift | 8 +- .../OpenAPIs/Models/Model200Response.swift | 5 +- .../Classes/OpenAPIs/Models/Name.swift | 5 +- .../Classes/OpenAPIs/Models/NumberOnly.swift | 6 +- .../Classes/OpenAPIs/Models/Order.swift | 4 - .../OpenAPIs/Models/OuterComposite.swift | 6 +- .../Classes/OpenAPIs/Models/OuterEnum.swift | 1 - .../Classes/OpenAPIs/Models/Pet.swift | 4 - .../OpenAPIs/Models/ReadOnlyFirst.swift | 4 - .../Classes/OpenAPIs/Models/Return.swift | 5 +- .../OpenAPIs/Models/SpecialModelName.swift | 6 +- .../OpenAPIs/Models/StringBooleanMap.swift | 8 +- .../Classes/OpenAPIs/Models/Tag.swift | 4 - .../OpenAPIs/Models/TypeHolderDefault.swift | 6 +- .../OpenAPIs/Models/TypeHolderExample.swift | 6 +- .../Classes/OpenAPIs/Models/User.swift | 4 - .../Classes/OpenAPIs/Models/XmlItem.swift | 6 +- .../petstore/swift4/unwrapRequired/README.md | 2 + .../swift4/unwrapRequired/docs/CatAllOf.md | 10 + .../swift4/unwrapRequired/docs/DogAllOf.md | 10 + .../swift4/unwrapRequired/docs/UserAPI.md | 4 +- .../swift4/unwrapRequired/project.yml | 15 + .../swift4/default/.openapi-generator/VERSION | 2 +- samples/client/test/swift4/default/Info.plist | 22 + samples/client/test/swift4/default/README.md | 58 ++ .../TestClient.xcodeproj/project.pbxproj | 593 +++++++++++++++++ .../contents.xcworkspacedata | 7 + .../xcschemes/TestClient.xcscheme | 96 +++ .../Classes/OpenAPIs/APIHelper.swift | 17 +- .../TestClient/Classes/OpenAPIs/APIs.swift | 14 +- .../Classes/OpenAPIs/APIs/Swift4TestAPI.swift | 8 +- .../OpenAPIs/AlamofireImplementations.swift | 25 +- .../Classes/OpenAPIs/CodableHelper.swift | 4 +- .../Classes/OpenAPIs/Configuration.swift | 6 +- .../Classes/OpenAPIs/Extensions.swift | 18 +- .../Classes/OpenAPIs/JSONEncodingHelper.swift | 4 +- .../TestClient/Classes/OpenAPIs/Models.swift | 2 +- .../OpenAPIs/Models/AllPrimitives.swift | 3 - .../Classes/OpenAPIs/Models/BaseCard.swift | 3 - .../Classes/OpenAPIs/Models/ErrorInfo.swift | 3 - .../OpenAPIs/Models/GetAllModelsResult.swift | 3 - .../OpenAPIs/Models/ModelDoubleArray.swift | 1 - .../OpenAPIs/Models/ModelErrorInfoArray.swift | 1 - .../OpenAPIs/Models/ModelStringArray.swift | 1 - ...ModelWithIntAdditionalPropertiesOnly.swift | 7 +- ...ithPropertiesAndAdditionalProperties.swift | 6 +- ...elWithStringAdditionalPropertiesOnly.swift | 7 +- .../Classes/OpenAPIs/Models/PersonCard.swift | 3 - .../OpenAPIs/Models/PersonCardAllOf.swift | 20 + .../Classes/OpenAPIs/Models/PlaceCard.swift | 3 - .../OpenAPIs/Models/PlaceCardAllOf.swift | 20 + .../Classes/OpenAPIs/Models/SampleBase.swift | 3 - .../OpenAPIs/Models/SampleSubClass.swift | 10 +- .../OpenAPIs/Models/SampleSubClassAllOf.swift | 20 + .../Classes/OpenAPIs/Models/StringEnum.swift | 1 - .../OpenAPIs/Models/VariableNameTest.swift | 5 +- .../Classes/Swaggers/APIHelper.swift | 12 +- .../TestClient/Classes/Swaggers/APIs.swift | 14 +- .../Classes/Swaggers/APIs/Swift4TestAPI.swift | 9 +- .../Swaggers/AlamofireImplementations.swift | 29 +- .../Classes/Swaggers/CodableHelper.swift | 10 +- .../Classes/Swaggers/Configuration.swift | 6 +- .../Classes/Swaggers/Extensions.swift | 20 +- .../Swaggers/JSONEncodableEncoding.swift | 2 +- .../Classes/Swaggers/JSONEncodingHelper.swift | 8 +- .../TestClient/Classes/Swaggers/Models.swift | 4 +- .../Swaggers/Models/AllPrimitives.swift | 3 - .../Classes/Swaggers/Models/BaseCard.swift | 3 - .../Classes/Swaggers/Models/ErrorInfo.swift | 3 - .../Swaggers/Models/GetAllModelsResult.swift | 3 - .../Swaggers/Models/ModelDoubleArray.swift | 1 - .../Swaggers/Models/ModelErrorInfoArray.swift | 1 - .../Swaggers/Models/ModelStringArray.swift | 1 - ...ModelWithIntAdditionalPropertiesOnly.swift | 7 +- ...ithPropertiesAndAdditionalProperties.swift | 6 +- ...elWithStringAdditionalPropertiesOnly.swift | 7 +- .../Classes/Swaggers/Models/PersonCard.swift | 3 - .../Classes/Swaggers/Models/PlaceCard.swift | 3 - .../Classes/Swaggers/Models/SampleBase.swift | 3 - .../Swaggers/Models/SampleSubClass.swift | 3 - .../Classes/Swaggers/Models/StringEnum.swift | 1 - .../Swaggers/Models/VariableNameTest.swift | 5 +- .../Pods/Alamofire/Source/Alamofire.swift | 27 +- .../Alamofire/Source/MultipartFormData.swift | 6 +- .../Source/NetworkReachabilityManager.swift | 6 +- .../Alamofire/Source/ParameterEncoding.swift | 3 +- .../Pods/Alamofire/Source/Request.swift | 6 +- .../Pods/Alamofire/Source/Response.swift | 12 +- .../Source/ResponseSerialization.swift | 54 +- .../Alamofire/Source/ServerTrustPolicy.swift | 1 - .../Alamofire/Source/SessionDelegate.swift | 36 +- .../Alamofire/Source/SessionManager.swift | 39 +- .../Pods/Alamofire/Source/TaskDelegate.swift | 30 +- .../Pods/Alamofire/Source/Timeline.swift | 3 +- .../Pods/Alamofire/Source/Validation.swift | 6 +- .../TestClientApp/AppDelegate.swift | 3 - .../TestClientApp/ViewController.swift | 2 - .../TestClientAppTests.swift | 2 - .../test/swift4/default/docs/AllPrimitives.md | 34 + .../test/swift4/default/docs/BaseCard.md | 10 + .../test/swift4/default/docs/ErrorInfo.md | 12 + .../swift4/default/docs/GetAllModelsResult.md | 12 + ...elWithPropertiesAndAdditionalProperties.md | 17 + .../test/swift4/default/docs/PersonCard.md | 11 + .../swift4/default/docs/PersonCardAllOf.md | 11 + .../test/swift4/default/docs/PlaceCard.md | 11 + .../swift4/default/docs/PlaceCardAllOf.md | 11 + .../test/swift4/default/docs/SampleBase.md | 11 + .../swift4/default/docs/SampleSubClass.md | 13 + .../default/docs/SampleSubClassAllOf.md | 11 + .../test/swift4/default/docs/StringEnum.md | 9 + .../test/swift4/default/docs/Swift4TestAPI.md | 59 ++ .../swift4/default/docs/VariableNameTest.md | 12 + .../client/test/swift4/default/project.yml | 15 + 695 files changed, 7886 insertions(+), 4490 deletions(-) create mode 100644 modules/openapi-generator/src/main/resources/swift4/XcodeGen.mustache create mode 100644 samples/client/petstore/swift4/default/Info.plist create mode 100644 samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.pbxproj create mode 100644 samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist create mode 100644 samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme create mode 100644 samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift create mode 100644 samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift create mode 100644 samples/client/petstore/swift4/default/docs/CatAllOf.md create mode 100644 samples/client/petstore/swift4/default/docs/DogAllOf.md create mode 100644 samples/client/petstore/swift4/default/project.yml create mode 100644 samples/client/petstore/swift4/objcCompatible/Info.plist create mode 100644 samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.pbxproj create mode 100644 samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme create mode 100644 samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift create mode 100644 samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift create mode 100644 samples/client/petstore/swift4/objcCompatible/docs/CatAllOf.md create mode 100644 samples/client/petstore/swift4/objcCompatible/docs/DogAllOf.md create mode 100644 samples/client/petstore/swift4/objcCompatible/project.yml create mode 100644 samples/client/petstore/swift4/promisekit/Info.plist create mode 100644 samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.pbxproj create mode 100644 samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme create mode 100644 samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift create mode 100644 samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift create mode 100644 samples/client/petstore/swift4/promisekit/docs/CatAllOf.md create mode 100644 samples/client/petstore/swift4/promisekit/docs/DogAllOf.md create mode 100644 samples/client/petstore/swift4/promisekit/project.yml create mode 100644 samples/client/petstore/swift4/rxswift/Info.plist create mode 100644 samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.pbxproj create mode 100644 samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme create mode 100644 samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift create mode 100644 samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift create mode 100644 samples/client/petstore/swift4/rxswift/docs/CatAllOf.md create mode 100644 samples/client/petstore/swift4/rxswift/docs/DogAllOf.md create mode 100644 samples/client/petstore/swift4/rxswift/project.yml create mode 100644 samples/client/petstore/swift4/unwrapRequired/Info.plist create mode 100644 samples/client/petstore/swift4/unwrapRequired/PetstoreClient.xcodeproj/project.pbxproj create mode 100644 samples/client/petstore/swift4/unwrapRequired/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/petstore/swift4/unwrapRequired/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme create mode 100644 samples/client/petstore/swift4/unwrapRequired/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift create mode 100644 samples/client/petstore/swift4/unwrapRequired/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift create mode 100644 samples/client/petstore/swift4/unwrapRequired/docs/CatAllOf.md create mode 100644 samples/client/petstore/swift4/unwrapRequired/docs/DogAllOf.md create mode 100644 samples/client/petstore/swift4/unwrapRequired/project.yml create mode 100644 samples/client/test/swift4/default/Info.plist create mode 100644 samples/client/test/swift4/default/README.md create mode 100644 samples/client/test/swift4/default/TestClient.xcodeproj/project.pbxproj create mode 100644 samples/client/test/swift4/default/TestClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 samples/client/test/swift4/default/TestClient.xcodeproj/xcshareddata/xcschemes/TestClient.xcscheme create mode 100644 samples/client/test/swift4/default/TestClient/Classes/OpenAPIs/Models/PersonCardAllOf.swift create mode 100644 samples/client/test/swift4/default/TestClient/Classes/OpenAPIs/Models/PlaceCardAllOf.swift create mode 100644 samples/client/test/swift4/default/TestClient/Classes/OpenAPIs/Models/SampleSubClassAllOf.swift create mode 100644 samples/client/test/swift4/default/docs/AllPrimitives.md create mode 100644 samples/client/test/swift4/default/docs/BaseCard.md create mode 100644 samples/client/test/swift4/default/docs/ErrorInfo.md create mode 100644 samples/client/test/swift4/default/docs/GetAllModelsResult.md create mode 100644 samples/client/test/swift4/default/docs/ModelWithPropertiesAndAdditionalProperties.md create mode 100644 samples/client/test/swift4/default/docs/PersonCard.md create mode 100644 samples/client/test/swift4/default/docs/PersonCardAllOf.md create mode 100644 samples/client/test/swift4/default/docs/PlaceCard.md create mode 100644 samples/client/test/swift4/default/docs/PlaceCardAllOf.md create mode 100644 samples/client/test/swift4/default/docs/SampleBase.md create mode 100644 samples/client/test/swift4/default/docs/SampleSubClass.md create mode 100644 samples/client/test/swift4/default/docs/SampleSubClassAllOf.md create mode 100644 samples/client/test/swift4/default/docs/StringEnum.md create mode 100644 samples/client/test/swift4/default/docs/Swift4TestAPI.md create mode 100644 samples/client/test/swift4/default/docs/VariableNameTest.md create mode 100644 samples/client/test/swift4/default/project.yml diff --git a/bin/swift4-petstore-objcCompatible.sh b/bin/swift4-petstore-objcCompatible.sh index 1cec3c94b8..655d718fce 100755 --- a/bin/swift4-petstore-objcCompatible.sh +++ b/bin/swift4-petstore-objcCompatible.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -g swift4 -c ./bin/swift4-petstore-objcCompatible.json -o samples/client/petstore/swift4/objcCompatible $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/objcCompatible + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/objcCompatible + swiftlint autocorrect +fi \ No newline at end of file diff --git a/bin/swift4-petstore-promisekit.sh b/bin/swift4-petstore-promisekit.sh index 69c3836406..6fc3975d9d 100755 --- a/bin/swift4-petstore-promisekit.sh +++ b/bin/swift4-petstore-promisekit.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/swift/petstore-with-fake-endpoints-models-for-testing.yaml -g swift4 -c ./bin/swift4-petstore-promisekit.json -o samples/client/petstore/swift4/promisekit --generate-alias-as-model $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/promisekit + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/promisekit + swiftlint autocorrect +fi \ No newline at end of file diff --git a/bin/swift4-petstore-rxswift.sh b/bin/swift4-petstore-rxswift.sh index 3a50fbf823..80d2cee49a 100755 --- a/bin/swift4-petstore-rxswift.sh +++ b/bin/swift4-petstore-rxswift.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/swift/petstore-with-fake-endpoints-models-for-testing.yaml -g swift4 -c ./bin/swift4-petstore-rxswift.json -o samples/client/petstore/swift4/rxswift --generate-alias-as-model $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/rxswift + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/rxswift + swiftlint autocorrect +fi \ No newline at end of file diff --git a/bin/swift4-petstore-unwrapRequired.sh b/bin/swift4-petstore-unwrapRequired.sh index 7332dcd2ea..500ee6fbd1 100755 --- a/bin/swift4-petstore-unwrapRequired.sh +++ b/bin/swift4-petstore-unwrapRequired.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/swift/petstore-with-fake-endpoints-models-for-testing.yaml -g swift4 -c ./bin/swift4-petstore-unwrapRequired.json -o samples/client/petstore/swift4/unwrapRequired --generate-alias-as-model $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/unwrapRequired + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/unwrapRequired + swiftlint autocorrect +fi \ No newline at end of file diff --git a/bin/swift4-petstore.sh b/bin/swift4-petstore.sh index a99d4d69b1..9057c1ee23 100755 --- a/bin/swift4-petstore.sh +++ b/bin/swift4-petstore.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/swift/petstore-with-fake-endpoints-models-for-testing.yaml -g swift4 -c ./bin/swift4-petstore.json -o samples/client/petstore/swift4/default --generate-alias-as-model $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/default + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/petstore/swift4/default + swiftlint autocorrect +fi diff --git a/bin/swift4-test.sh b/bin/swift4-test.sh index f43bd6e278..7bced643c4 100755 --- a/bin/swift4-test.sh +++ b/bin/swift4-test.sh @@ -30,3 +30,13 @@ export JAVA_OPTS="${JAVA_OPTS} -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/openapi-generator/src/main/resources/swift4 -i modules/openapi-generator/src/test/resources/2_0/swift4Test.json -g swift4 -c ./bin/swift4-test.json -o samples/client/test/swift4/default $@" java $JAVA_OPTS -jar $executable $ags + +if type "xcodegen" > /dev/null 2>&1; then + cd samples/client/test/swift4/default + xcodegen generate +fi + +if type "swiftlint" > /dev/null 2>&1; then + cd samples/client/test/swift4/default + swiftlint autocorrect +fi diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/Swift4Codegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/Swift4Codegen.java index b78891af4f..1422504281 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/Swift4Codegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/Swift4Codegen.java @@ -421,6 +421,9 @@ public class Swift4Codegen extends DefaultCodegen implements CodegenConfig { supportingFiles.add(new SupportingFile("README.mustache", "", "README.md")); + supportingFiles.add(new SupportingFile("XcodeGen.mustache", + "", + "project.yml")); } diff --git a/modules/openapi-generator/src/main/resources/swift4/XcodeGen.mustache b/modules/openapi-generator/src/main/resources/swift4/XcodeGen.mustache new file mode 100644 index 0000000000..9e447e49a6 --- /dev/null +++ b/modules/openapi-generator/src/main/resources/swift4/XcodeGen.mustache @@ -0,0 +1,17 @@ +name: {{projectName}} +targets: + {{projectName}}: + type: framework + platform: iOS + deploymentTarget: "10.0" + sources: [{{projectName}}] + info: + path: ./Info.plist + version: {{#podVersion}}{{podVersion}}{{/podVersion}}{{^podVersion}}{{#apiInfo}}{{version}}{{/apiInfo}}{{^apiInfo}}}0.0.1{{/apiInfo}}{{/podVersion}} + settings: + APPLICATION_EXTENSION_API_ONLY: true + scheme: {} + dependencies: + - carthage: Alamofire{{#useRxSwift}} + - carthage: RxSwift{{/useRxSwift}}{{#usePromiseKit}} + - carthage: PromiseKit{{/usePromiseKit}} diff --git a/samples/client/petstore/swift4/default/.openapi-generator/VERSION b/samples/client/petstore/swift4/default/.openapi-generator/VERSION index afa6365606..83a328a922 100644 --- a/samples/client/petstore/swift4/default/.openapi-generator/VERSION +++ b/samples/client/petstore/swift4/default/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.0-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/swift4/default/Info.plist b/samples/client/petstore/swift4/default/Info.plist new file mode 100644 index 0000000000..323e5ecfc4 --- /dev/null +++ b/samples/client/petstore/swift4/default/Info.plist @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.pbxproj b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.pbxproj new file mode 100644 index 0000000000..6d0f6ef15b --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.pbxproj @@ -0,0 +1,569 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */; }; + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */; }; + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */; }; + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */ = {isa = PBXBuildFile; fileRef = C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */; }; + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */; }; + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */; }; + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */; }; + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */; }; + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */ = {isa = PBXBuildFile; fileRef = 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */; }; + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */; }; + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */; }; + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */; }; + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */; }; + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */; }; + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */ = {isa = PBXBuildFile; fileRef = 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */; }; + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */; }; + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */; }; + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */; }; + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */; }; + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */; }; + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */; }; + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */; }; + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */; }; + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */; }; + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */ = {isa = PBXBuildFile; fileRef = 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */; }; + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */; }; + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */; }; + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */; }; + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */; }; + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */ = {isa = PBXBuildFile; fileRef = A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */; }; + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */ = {isa = PBXBuildFile; fileRef = F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */; }; + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */; }; + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */ = {isa = PBXBuildFile; fileRef = A913A57E72D723632E9A718FF4525C81 /* Client.swift */; }; + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */; }; + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */; }; + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */ = {isa = PBXBuildFile; fileRef = 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */; }; + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */ = {isa = PBXBuildFile; fileRef = B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */; }; + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */; }; + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */; }; + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */; }; + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */; }; + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7A6070F581E611FF44AFD40A4315C49A /* List.swift */; }; + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */; }; + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */; }; + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */; }; + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */ = {isa = PBXBuildFile; fileRef = C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */; }; + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */; }; + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */; }; + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */; }; + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */; }; + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */ = {isa = PBXBuildFile; fileRef = 386FD590658E90509C121118F057604D /* SpecialModelName.swift */; }; + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */ = {isa = PBXBuildFile; fileRef = B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */; }; + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8699F7966F748ED026A6FB4CF550442B /* Models.swift */; }; + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */ = {isa = PBXBuildFile; fileRef = C81447828475F76C5CF4F08AA65292F7 /* Return.swift */; }; + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */ = {isa = PBXBuildFile; fileRef = 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */; }; + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CodableHelper.swift; sourceTree = ""; }; + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumArrays.swift; sourceTree = ""; }; + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PetstoreClient.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderExample.swift; sourceTree = ""; }; + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Cat.swift; sourceTree = ""; }; + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Order.swift; sourceTree = ""; }; + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Configuration.swift; sourceTree = ""; }; + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FormatTest.swift; sourceTree = ""; }; + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodingHelper.swift; sourceTree = ""; }; + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIs.swift; sourceTree = ""; }; + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SpecialModelName.swift; sourceTree = ""; }; + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = File.swift; sourceTree = ""; }; + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesClass.swift; sourceTree = ""; }; + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CatAllOf.swift; sourceTree = ""; }; + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ClassModel.swift; sourceTree = ""; }; + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringBooleanMap.swift; sourceTree = ""; }; + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumClass.swift; sourceTree = ""; }; + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileSchemaTestClass.swift; sourceTree = ""; }; + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HasOnlyReadOnly.swift; sourceTree = ""; }; + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Name.swift; sourceTree = ""; }; + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeAPI.swift; sourceTree = ""; }; + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Category.swift; sourceTree = ""; }; + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReadOnlyFirst.swift; sourceTree = ""; }; + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MapTest.swift; sourceTree = ""; }; + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = List.swift; sourceTree = ""; }; + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfArrayOfNumberOnly.swift; sourceTree = ""; }; + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UserAPI.swift; sourceTree = ""; }; + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Model200Response.swift; sourceTree = ""; }; + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AlamofireImplementations.swift; sourceTree = ""; }; + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Models.swift; sourceTree = ""; }; + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIHelper.swift; sourceTree = ""; }; + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnimalFarm.swift; sourceTree = ""; }; + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Animal.swift; sourceTree = ""; }; + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodableEncoding.swift; sourceTree = ""; }; + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PetAPI.swift; sourceTree = ""; }; + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MixedPropertiesAndAdditionalPropertiesClass.swift; sourceTree = ""; }; + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnotherFakeAPI.swift; sourceTree = ""; }; + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DogAllOf.swift; sourceTree = ""; }; + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Alamofire.framework; sourceTree = ""; }; + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreAPI.swift; sourceTree = ""; }; + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Capitalization.swift; sourceTree = ""; }; + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApiResponse.swift; sourceTree = ""; }; + A913A57E72D723632E9A718FF4525C81 /* Client.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Client.swift; sourceTree = ""; }; + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Tag.swift; sourceTree = ""; }; + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeClassnameTags123API.swift; sourceTree = ""; }; + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfNumberOnly.swift; sourceTree = ""; }; + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Extensions.swift; sourceTree = ""; }; + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NumberOnly.swift; sourceTree = ""; }; + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterEnum.swift; sourceTree = ""; }; + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Dog.swift; sourceTree = ""; }; + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Return.swift; sourceTree = ""; }; + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = User.swift; sourceTree = ""; }; + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderDefault.swift; sourceTree = ""; }; + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pet.swift; sourceTree = ""; }; + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayTest.swift; sourceTree = ""; }; + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterComposite.swift; sourceTree = ""; }; + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumTest.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */ = { + isa = PBXGroup; + children = ( + 7861EE241895128F64DD787367B3022D /* Carthage */, + ); + name = Frameworks; + sourceTree = ""; + }; + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */ = { + isa = PBXGroup; + children = ( + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */, + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */, + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */, + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */, + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */, + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */, + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */, + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */, + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */, + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */, + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */, + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */, + A913A57E72D723632E9A718FF4525C81 /* Client.swift */, + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */, + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */, + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */, + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */, + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */, + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */, + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */, + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */, + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */, + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */, + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */, + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */, + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */, + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */, + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */, + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */, + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */, + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */, + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */, + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */, + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */, + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */, + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */, + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */, + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */, + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */, + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */, + ); + path = Models; + sourceTree = ""; + }; + 5FBA6AE5F64CD737F88B4565AC3CCD3B = { + isa = PBXGroup; + children = ( + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */, + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */, + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */, + ); + sourceTree = ""; + }; + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */ = { + isa = PBXGroup; + children = ( + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */, + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */, + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */, + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */, + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */, + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */, + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */, + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */, + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */, + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */, + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */, + ); + path = OpenAPIs; + sourceTree = ""; + }; + 7861EE241895128F64DD787367B3022D /* Carthage */ = { + isa = PBXGroup; + children = ( + A012205B41CB71A62B86EECDEAFB0990 /* iOS */, + ); + name = Carthage; + path = Carthage/Build; + sourceTree = ""; + }; + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */ = { + isa = PBXGroup; + children = ( + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */, + ); + name = Products; + sourceTree = ""; + }; + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */ = { + isa = PBXGroup; + children = ( + EF4C81BDD734856ED5023B777D35098B /* Classes */, + ); + path = PetstoreClient; + sourceTree = ""; + }; + A012205B41CB71A62B86EECDEAFB0990 /* iOS */ = { + isa = PBXGroup; + children = ( + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */, + ); + path = iOS; + sourceTree = ""; + }; + EF4C81BDD734856ED5023B777D35098B /* Classes */ = { + isa = PBXGroup; + children = ( + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */, + ); + path = Classes; + sourceTree = ""; + }; + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */ = { + isa = PBXGroup; + children = ( + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */, + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */, + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */, + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */, + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */, + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */, + ); + path = APIs; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */ = { + isa = PBXNativeTarget; + buildConfigurationList = B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */; + buildPhases = ( + E539708354CE60FE486F81EDE56D13C8 /* Sources */, + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = PetstoreClient; + productName = PetstoreClient; + productReference = 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + E7D276EE2369D8C455513C2E05F9AED0 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1000; + }; + buildConfigurationList = ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 5FBA6AE5F64CD737F88B4565AC3CCD3B; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + E539708354CE60FE486F81EDE56D13C8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */, + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */, + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */, + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */, + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */, + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */, + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */, + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */, + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */, + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */, + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */, + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */, + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */, + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */, + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */, + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */, + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */, + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */, + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */, + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */, + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */, + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */, + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */, + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */, + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */, + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */, + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */, + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */, + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */, + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */, + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */, + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */, + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */, + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */, + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */, + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */, + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */, + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */, + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */, + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */, + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */, + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */, + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */, + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */, + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */, + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */, + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */, + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */, + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */, + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */, + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */, + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */, + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */, + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */, + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "$(inherited)", + "DEBUG=1", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 4.2; + }; + name = Debug; + }; + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 4.2; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */, + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = ""; + }; + ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */, + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = E7D276EE2369D8C455513C2E05F9AED0 /* Project object */; +} diff --git a/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000000..919434a625 --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000000..18d981003d --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme new file mode 100644 index 0000000000..7802e37945 --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIHelper.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIHelper.swift index d94614b34f..75dea24395 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIHelper.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIHelper.swift @@ -7,7 +7,7 @@ import Foundation public struct APIHelper { - public static func rejectNil(_ source: [String:Any?]) -> [String:Any]? { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { let destination = source.reduce(into: [String: Any]()) { (result, item) in if let value = item.value { result[item.key] = value @@ -20,17 +20,17 @@ public struct APIHelper { return destination } - public static func rejectNilHeaders(_ source: [String:Any?]) -> [String:String] { + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { return source.reduce(into: [String: String]()) { (result, item) in if let collection = item.value as? Array { - result[item.key] = collection.filter({ $0 != nil }).map{ "\($0!)" }.joined(separator: ",") + result[item.key] = collection.filter({ $0 != nil }).map { "\($0!)" }.joined(separator: ",") } else if let value: Any = item.value { result[item.key] = "\(value)" } } } - public static func convertBoolToString(_ source: [String: Any]?) -> [String:Any]? { + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { guard let source = source else { return nil } @@ -52,7 +52,7 @@ public struct APIHelper { return source } - public static func mapValuesToQueryItems(_ source: [String:Any?]) -> [URLQueryItem]? { + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { let destination = source.filter({ $0.value != nil}).reduce(into: [URLQueryItem]()) { (result, item) in if let collection = item.value as? Array { let value = collection.filter({ $0 != nil }).map({"\($0!)"}).joined(separator: ",") @@ -68,4 +68,3 @@ public struct APIHelper { return destination } } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs.swift index 2890bffa27..9e4312f685 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs.swift @@ -9,22 +9,22 @@ import Foundation open class PetstoreClientAPI { public static var basePath = "http://petstore.swagger.io:80/v2" public static var credential: URLCredential? - public static var customHeaders: [String:String] = [:] + public static var customHeaders: [String: String] = [:] public static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory() } open class RequestBuilder { var credential: URLCredential? - var headers: [String:String] - public let parameters: [String:Any]? + var headers: [String: String] + public let parameters: [String: Any]? public let isBody: Bool public let method: String public let URLString: String /// Optional block to obtain a reference to the request's progress instance when available. - public var onProgressReady: ((Progress) -> ())? + public var onProgressReady: ((Progress) -> Void)? - required public init(method: String, URLString: String, parameters: [String:Any]?, isBody: Bool, headers: [String:String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { self.method = method self.URLString = URLString self.parameters = parameters @@ -34,7 +34,7 @@ open class RequestBuilder { addHeaders(PetstoreClientAPI.customHeaders) } - open func addHeaders(_ aHeaders:[String:String]) { + open func addHeaders(_ aHeaders: [String: String]) { for (header, value) in aHeaders { headers[header] = value } @@ -57,5 +57,5 @@ open class RequestBuilder { public protocol RequestBuilderFactory { func getNonDecodableBuilder() -> RequestBuilder.Type - func getBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift index ffecb66c48..30b346de0e 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class AnotherFakeAPI { /** To test special tags @@ -17,7 +15,7 @@ open class AnotherFakeAPI { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func call123testSpecialTags(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func call123testSpecialTags(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { call123testSpecialTagsWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift index 302767c2b0..1073935592 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift @@ -8,15 +8,13 @@ import Foundation import Alamofire - - open class FakeAPI { /** - parameter body: (body) Input boolean as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?,_ error: Error?) -> Void)) { + open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?, _ error: Error?) -> Void)) { fakeOuterBooleanSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -45,7 +43,7 @@ open class FakeAPI { - parameter body: (body) Input composite as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterCompositeSerialize(body: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?,_ error: Error?) -> Void)) { + open class func fakeOuterCompositeSerialize(body: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?, _ error: Error?) -> Void)) { fakeOuterCompositeSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -74,7 +72,7 @@ open class FakeAPI { - parameter body: (body) Input number as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?,_ error: Error?) -> Void)) { + open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?, _ error: Error?) -> Void)) { fakeOuterNumberSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -103,7 +101,7 @@ open class FakeAPI { - parameter body: (body) Input string as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { fakeOuterStringSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -132,7 +130,7 @@ open class FakeAPI { - parameter body: (body) - parameter completion: completion handler to receive the data and the error objects */ - open class func testBodyWithFileSchema(body: FileSchemaTestClass, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testBodyWithFileSchema(body: FileSchemaTestClass, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testBodyWithFileSchemaWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -166,7 +164,7 @@ open class FakeAPI { - parameter body: (body) - parameter completion: completion handler to receive the data and the error objects */ - open class func testBodyWithQueryParams(query: String, body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testBodyWithQueryParams(query: String, body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testBodyWithQueryParamsWithRequestBuilder(query: query, body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -203,7 +201,7 @@ open class FakeAPI { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClientModel(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClientModel(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClientModelWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -247,7 +245,7 @@ open class FakeAPI { - parameter callback: (form) None (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testEndpointParametersWithRequestBuilder(number: number, double: double, patternWithoutDelimiter: patternWithoutDelimiter, byte: byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -283,7 +281,7 @@ open class FakeAPI { open class func testEndpointParametersWithRequestBuilder(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "integer": integer?.encodeToJSON(), "int32": int32?.encodeToJSON(), "int64": int64?.encodeToJSON(), @@ -302,7 +300,7 @@ open class FakeAPI { let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -390,7 +388,7 @@ open class FakeAPI { - parameter enumFormString: (form) Form parameter enum test (string) (optional, default to .-efg) - parameter completion: completion handler to receive the data and the error objects */ - open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testEnumParametersWithRequestBuilder(enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -417,19 +415,19 @@ open class FakeAPI { open class func testEnumParametersWithRequestBuilder(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "enum_form_string_array": enumFormStringArray, "enum_form_string": enumFormString?.rawValue ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "enum_query_string_array": enumQueryStringArray, - "enum_query_string": enumQueryString?.rawValue, - "enum_query_integer": enumQueryInteger?.rawValue, + "enum_query_string_array": enumQueryStringArray, + "enum_query_string": enumQueryString?.rawValue, + "enum_query_integer": enumQueryInteger?.rawValue, "enum_query_double": enumQueryDouble?.rawValue ]) let nillableHeaders: [String: Any?] = [ @@ -454,7 +452,7 @@ open class FakeAPI { - parameter int64Group: (query) Integer in group parameters (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func testGroupParameters(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testGroupParameters(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testGroupParametersWithRequestBuilder(requiredStringGroup: requiredStringGroup, requiredBooleanGroup: requiredBooleanGroup, requiredInt64Group: requiredInt64Group, stringGroup: stringGroup, booleanGroup: booleanGroup, int64Group: int64Group).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -479,13 +477,13 @@ open class FakeAPI { open class func testGroupParametersWithRequestBuilder(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "required_string_group": requiredStringGroup.encodeToJSON(), - "required_int64_group": requiredInt64Group.encodeToJSON(), - "string_group": stringGroup?.encodeToJSON(), + "required_string_group": requiredStringGroup.encodeToJSON(), + "required_int64_group": requiredInt64Group.encodeToJSON(), + "string_group": stringGroup?.encodeToJSON(), "int64_group": int64Group?.encodeToJSON() ]) let nillableHeaders: [String: Any?] = [ @@ -505,7 +503,7 @@ open class FakeAPI { - parameter param: (body) request body - parameter completion: completion handler to receive the data and the error objects */ - open class func testInlineAdditionalProperties(param: [String:String], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testInlineAdditionalProperties(param: [String: String], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testInlineAdditionalPropertiesWithRequestBuilder(param: param).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -521,7 +519,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: RequestBuilder */ - open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String:String]) -> RequestBuilder { + open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String: String]) -> RequestBuilder { let path = "/fake/inline-additionalProperties" let URLString = PetstoreClientAPI.basePath + path let parameters = JSONEncodingHelper.encodingParameters(forEncodableObject: param) @@ -540,7 +538,7 @@ open class FakeAPI { - parameter param2: (form) field2 - parameter completion: completion handler to receive the data and the error objects */ - open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testJsonFormDataWithRequestBuilder(param: param, param2: param2).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -560,14 +558,14 @@ open class FakeAPI { open class func testJsonFormDataWithRequestBuilder(param: String, param2: String) -> RequestBuilder { let path = "/fake/jsonFormData" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "param": param, "param2": param2 ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift index ddfeae23ed..6bfa09016f 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class FakeClassnameTags123API { /** To test class name in snake case @@ -17,7 +15,7 @@ open class FakeClassnameTags123API { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClassname(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClassname(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClassnameWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift index 0a5dfeb39b..896f151180 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class PetAPI { /** Add a new pet to the store @@ -17,7 +15,7 @@ open class PetAPI { - parameter body: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func addPet(body: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func addPet(body: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { addPetWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -55,7 +53,7 @@ open class PetAPI { - parameter apiKey: (header) (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deletePetWithRequestBuilder(petId: petId, apiKey: apiKey).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -81,8 +79,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let nillableHeaders: [String: Any?] = [ "api_key": apiKey @@ -109,7 +107,7 @@ open class PetAPI { - parameter status: (query) Status values that need to be considered for filter - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByStatusWithRequestBuilder(status: status).execute { (response, error) -> Void in completion(response?.body, error) } @@ -128,8 +126,8 @@ open class PetAPI { open class func findPetsByStatusWithRequestBuilder(status: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByStatus" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "status": status @@ -146,7 +144,7 @@ open class PetAPI { - parameter tags: (query) Tags to filter by - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByTagsWithRequestBuilder(tags: tags).execute { (response, error) -> Void in completion(response?.body, error) } @@ -165,8 +163,8 @@ open class PetAPI { open class func findPetsByTagsWithRequestBuilder(tags: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByTags" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "tags": tags @@ -183,7 +181,7 @@ open class PetAPI { - parameter petId: (path) ID of pet to return - parameter completion: completion handler to receive the data and the error objects */ - open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?,_ error: Error?) -> Void)) { + open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?, _ error: Error?) -> Void)) { getPetByIdWithRequestBuilder(petId: petId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -205,8 +203,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -220,7 +218,7 @@ open class PetAPI { - parameter body: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePet(body: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updatePet(body: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updatePetWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -259,7 +257,7 @@ open class PetAPI { - parameter status: (form) Updated status of the pet (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updatePetWithFormWithRequestBuilder(petId: petId, name: name, status: status).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -286,14 +284,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "name": name, "status": status ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -309,7 +307,7 @@ open class PetAPI { - parameter file: (form) file to upload (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?,_ error: Error?) -> Void)) { + open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?, _ error: Error?) -> Void)) { uploadFileWithRequestBuilder(petId: petId, additionalMetadata: additionalMetadata, file: file).execute { (response, error) -> Void in completion(response?.body, error) } @@ -332,14 +330,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "file": file ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -355,7 +353,7 @@ open class PetAPI { - parameter additionalMetadata: (form) Additional data to pass to server (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func uploadFileWithRequiredFile(petId: Int64, requiredFile: URL, additionalMetadata: String? = nil, completion: @escaping ((_ data: ApiResponse?,_ error: Error?) -> Void)) { + open class func uploadFileWithRequiredFile(petId: Int64, requiredFile: URL, additionalMetadata: String? = nil, completion: @escaping ((_ data: ApiResponse?, _ error: Error?) -> Void)) { uploadFileWithRequiredFileWithRequestBuilder(petId: petId, requiredFile: requiredFile, additionalMetadata: additionalMetadata).execute { (response, error) -> Void in completion(response?.body, error) } @@ -378,14 +376,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "requiredFile": requiredFile ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift index a2bced598f..71949b335d 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class StoreAPI { /** Delete purchase order by ID @@ -17,7 +15,7 @@ open class StoreAPI { - parameter orderId: (path) ID of the order that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deleteOrderWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -40,8 +38,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -54,7 +52,7 @@ open class StoreAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func getInventory(completion: @escaping ((_ data: [String:Int]?,_ error: Error?) -> Void)) { + open class func getInventory(completion: @escaping ((_ data: [String: Int]?, _ error: Error?) -> Void)) { getInventoryWithRequestBuilder().execute { (response, error) -> Void in completion(response?.body, error) } @@ -69,14 +67,14 @@ open class StoreAPI { - name: api_key - returns: RequestBuilder<[String:Int]> */ - open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String:Int]> { + open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String: Int]> { let path = "/store/inventory" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) - let requestBuilder: RequestBuilder<[String:Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() + let requestBuilder: RequestBuilder<[String: Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() return requestBuilder.init(method: "GET", URLString: (url?.string ?? URLString), parameters: parameters, isBody: false) } @@ -87,7 +85,7 @@ open class StoreAPI { - parameter orderId: (path) ID of pet that needs to be fetched - parameter completion: completion handler to receive the data and the error objects */ - open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { getOrderByIdWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -106,8 +104,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -121,7 +119,7 @@ open class StoreAPI { - parameter body: (body) order placed for purchasing the pet - parameter completion: completion handler to receive the data and the error objects */ - open class func placeOrder(body: Order, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func placeOrder(body: Order, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { placeOrderWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift index d8cafaf2c9..efeb64468a 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class UserAPI { /** Create user @@ -17,7 +15,7 @@ open class UserAPI { - parameter body: (body) Created user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUser(body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUser(body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUserWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -52,7 +50,7 @@ open class UserAPI { - parameter body: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithArrayInput(body: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUsersWithArrayInput(body: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUsersWithArrayInputWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -86,7 +84,7 @@ open class UserAPI { - parameter body: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithListInput(body: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUsersWithListInput(body: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUsersWithListInputWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -120,7 +118,7 @@ open class UserAPI { - parameter username: (path) The name that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteUser(username: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deleteUser(username: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deleteUserWithRequestBuilder(username: username).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -143,8 +141,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -158,7 +156,7 @@ open class UserAPI { - parameter username: (path) The name that needs to be fetched. Use user1 for testing. - parameter completion: completion handler to receive the data and the error objects */ - open class func getUserByName(username: String, completion: @escaping ((_ data: User?,_ error: Error?) -> Void)) { + open class func getUserByName(username: String, completion: @escaping ((_ data: User?, _ error: Error?) -> Void)) { getUserByNameWithRequestBuilder(username: username).execute { (response, error) -> Void in completion(response?.body, error) } @@ -176,8 +174,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -192,7 +190,7 @@ open class UserAPI { - parameter password: (query) The password for login in clear text - parameter completion: completion handler to receive the data and the error objects */ - open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { loginUserWithRequestBuilder(username: username, password: password).execute { (response, error) -> Void in completion(response?.body, error) } @@ -209,11 +207,11 @@ open class UserAPI { open class func loginUserWithRequestBuilder(username: String, password: String) -> RequestBuilder { let path = "/user/login" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "username": username, + "username": username, "password": password ]) @@ -227,7 +225,7 @@ open class UserAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func logoutUser(completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func logoutUser(completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { logoutUserWithRequestBuilder().execute { (response, error) -> Void in if error == nil { completion((), error) @@ -245,8 +243,8 @@ open class UserAPI { open class func logoutUserWithRequestBuilder() -> RequestBuilder { let path = "/user/logout" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -261,7 +259,7 @@ open class UserAPI { - parameter body: (body) Updated user object - parameter completion: completion handler to receive the data and the error objects */ - open class func updateUser(username: String, body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updateUser(username: String, body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updateUserWithRequestBuilder(username: username, body: body).execute { (response, error) -> Void in if error == nil { completion((), error) diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift index dac40e9a31..04ad02a5ce 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift @@ -12,7 +12,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { return AlamofireRequestBuilder.self } - func getBuilder() -> RequestBuilder.Type { + func getBuilder() -> RequestBuilder.Type { return AlamofireDecodableRequestBuilder.self } } @@ -50,7 +50,7 @@ private struct SynchronizedDictionary { private var managerStore = SynchronizedDictionary() open class AlamofireRequestBuilder: RequestBuilder { - required public init(method: String, URLString: String, parameters: [String : Any]?, isBody: Bool, headers: [String : String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { super.init(method: method, URLString: URLString, parameters: parameters, isBody: isBody, headers: headers) } @@ -88,17 +88,17 @@ open class AlamofireRequestBuilder: RequestBuilder { May be overridden by a subclass if you want to control the request configuration (e.g. to override the cache policy). */ - open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String:String]) -> DataRequest { + open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) -> DataRequest { return manager.request(URLString, method: method, parameters: parameters, encoding: encoding, headers: headers) } override open func execute(_ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { - let managerId:String = UUID().uuidString + let managerId: String = UUID().uuidString // Create a new manager for each request to customize its request header let manager = createSessionManager() managerStore[managerId] = manager - let encoding:ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() + let encoding: ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() let xMethod = Alamofire.HTTPMethod(rawValue: method) let fileKeys = parameters == nil ? [] : parameters!.filter { $1 is NSURL } @@ -111,8 +111,7 @@ open class AlamofireRequestBuilder: RequestBuilder { case let fileURL as URL: if let mimeType = self.contentTypeForFormPart(fileURL: fileURL) { mpForm.append(fileURL, withName: k, fileName: fileURL.lastPathComponent, mimeType: mimeType) - } - else { + } else { mpForm.append(fileURL, withName: k) } case let string as String: @@ -276,7 +275,7 @@ open class AlamofireRequestBuilder: RequestBuilder { return httpHeaders } - fileprivate func getFileName(fromContentDisposition contentDisposition : String?) -> String? { + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { guard let contentDisposition = contentDisposition else { return nil @@ -284,7 +283,7 @@ open class AlamofireRequestBuilder: RequestBuilder { let items = contentDisposition.components(separatedBy: ";") - var filename : String? = nil + var filename: String? = nil for contentItem in items { @@ -304,7 +303,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getPath(from url : URL) throws -> String { + fileprivate func getPath(from url: URL) throws -> String { guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { throw DownloadException.requestMissingPath @@ -318,7 +317,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getURL(from urlRequest : URLRequest) throws -> URL { + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { guard let url = urlRequest.url else { throw DownloadException.requestMissingURL @@ -329,7 +328,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } -fileprivate enum DownloadException : Error { +private enum DownloadException: Error { case responseDataMissing case responseFailed case requestMissing @@ -344,7 +343,7 @@ public enum AlamofireDecodableRequestBuilderError: Error { case generalError(Error) } -open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { +open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { override fileprivate func processRequest(request: DataRequest, _ managerId: String, _ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { if let credential = self.credential { diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift index 584de8c3d5..111d5a3a8c 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift @@ -13,7 +13,7 @@ open class CodableHelper { public static var dateformatter: DateFormatter? - open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T : Decodable { + open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T: Decodable { var returnedDecodable: T? = nil var returnedError: Error? = nil @@ -39,7 +39,7 @@ open class CodableHelper { return (returnedDecodable, returnedError) } - open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T : Encodable { + open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T: Encodable { var returnedData: Data? var returnedError: Error? = nil diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Configuration.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Configuration.swift index 516590da5d..e1ecb39726 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Configuration.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Configuration.swift @@ -7,9 +7,9 @@ import Foundation open class Configuration { - + // This value is used to configure the date formatter that is used to serialize dates into JSON format. // You must set it prior to encoding any dates, and it will only be read once. public static var dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" - -} \ No newline at end of file + +} diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Extensions.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Extensions.swift index 8bf1829ba8..24c128daad 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Extensions.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Extensions.swift @@ -112,24 +112,24 @@ extension String: CodingKey { extension KeyedEncodingContainerProtocol { - public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { var arrayContainer = nestedUnkeyedContainer(forKey: key) try arrayContainer.encode(contentsOf: values) } - public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { if let values = values { try encodeArray(values, forKey: key) } } - public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T : Encodable { + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { for (key, value) in pairs { try encode(value, forKey: key) } } - public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T : Encodable { + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { if let pairs = pairs { try encodeMap(pairs) } @@ -139,7 +139,7 @@ extension KeyedEncodingContainerProtocol { extension KeyedDecodingContainerProtocol { - public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T : Decodable { + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { var tmpArray = [T]() var nestedContainer = try nestedUnkeyedContainer(forKey: key) @@ -151,7 +151,7 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T : Decodable { + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { var tmpArray: [T]? = nil if contains(key) { @@ -161,8 +161,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T : Decodable { - var map: [Self.Key : T] = [:] + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] for key in allKeys { if !excludedKeys.contains(key) { @@ -175,5 +175,3 @@ extension KeyedDecodingContainerProtocol { } } - - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift index 7044951584..3e68bb5d4a 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -10,7 +10,7 @@ import Alamofire open class JSONEncodingHelper { - open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { + open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { var params: Parameters? = nil // Encode the Encodable object @@ -39,5 +39,5 @@ open class JSONEncodingHelper { return params } - + } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models.swift index 4085638903..e87ce399c7 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models.swift @@ -10,7 +10,7 @@ protocol JSONEncodable { func encodeToJSON() -> Any } -public enum ErrorResponse : Error { +public enum ErrorResponse: Error { case error(Int, Data?, Error) } diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift index 4db39adae8..83a06951cc 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift @@ -7,23 +7,19 @@ import Foundation - - public struct AdditionalPropertiesClass: Codable { - public var mapString: [String:String]? - public var mapMapString: [String:[String:String]]? + public var mapString: [String: String]? + public var mapMapString: [String: [String: String]]? - public init(mapString: [String:String]?, mapMapString: [String:[String:String]]?) { + public init(mapString: [String: String]?, mapMapString: [String: [String: String]]?) { self.mapString = mapString self.mapMapString = mapMapString } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapString = "map_string" case mapMapString = "map_map_string" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift index 7221a1be09..5ed9f31e2a 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Animal: Codable { public var className: String @@ -19,6 +17,4 @@ public struct Animal: Codable { self.color = color } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift index e7bea63f8e..e09b0e9efd 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift @@ -7,5 +7,4 @@ import Foundation - public typealias AnimalFarm = [Animal] diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift index a22e9aaebb..ec270da890 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ApiResponse: Codable { public var code: Int? @@ -21,6 +19,4 @@ public struct ApiResponse: Codable { self.message = message } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift index 4e5a5ca144..3843287630 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfArrayOfNumberOnly: Codable { public var arrayArrayNumber: [[Double]]? @@ -17,10 +15,8 @@ public struct ArrayOfArrayOfNumberOnly: Codable { self.arrayArrayNumber = arrayArrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayArrayNumber = "ArrayArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift index 7d059d3683..f8b198e81f 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfNumberOnly: Codable { public var arrayNumber: [Double]? @@ -17,10 +15,8 @@ public struct ArrayOfNumberOnly: Codable { self.arrayNumber = arrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayNumber = "ArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift index 9c56fed50c..67f7f7e515 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayTest: Codable { public var arrayOfString: [String]? @@ -21,12 +19,10 @@ public struct ArrayTest: Codable { self.arrayArrayOfModel = arrayArrayOfModel } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayOfString = "array_of_string" case arrayArrayOfInteger = "array_array_of_integer" case arrayArrayOfModel = "array_array_of_model" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift index 98cda23dac..d576b50b1c 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Capitalization: Codable { public var smallCamel: String? @@ -28,7 +26,7 @@ public struct Capitalization: Codable { self.ATT_NAME = ATT_NAME } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case smallCamel case capitalCamel = "CapitalCamel" case smallSnake = "small_Snake" @@ -37,6 +35,4 @@ public struct Capitalization: Codable { case ATT_NAME } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift index a116d964ea..7ab887f311 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Cat: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Cat: Codable { self.declawed = declawed } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift new file mode 100644 index 0000000000..a51ad0dffa --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift @@ -0,0 +1,18 @@ +// +// CatAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct CatAllOf: Codable { + + public var declawed: Bool? + + public init(declawed: Bool?) { + self.declawed = declawed + } + +} diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Category.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Category.swift index e8c489be46..eb8f7e5e19 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Category.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Category.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Category: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Category: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift index f673ed127c..28cb30ce7b 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model with \"_class\" property */ public struct ClassModel: Codable { @@ -18,6 +17,4 @@ public struct ClassModel: Codable { self._class = _class } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Client.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Client.swift index 51390b6c4e..00245ca372 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Client.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Client.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Client: Codable { public var client: String? @@ -17,6 +15,4 @@ public struct Client: Codable { self.client = client } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift index 239ce74dcc..492c122800 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Dog: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Dog: Codable { self.breed = breed } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift new file mode 100644 index 0000000000..7786f8acc5 --- /dev/null +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift @@ -0,0 +1,18 @@ +// +// DogAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct DogAllOf: Codable { + + public var breed: String? + + public init(breed: String?) { + self.breed = breed + } + +} diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift index 8713961520..5034ff0b8c 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumArrays: Codable { public enum JustSymbol: String, Codable { @@ -27,11 +25,9 @@ public struct EnumArrays: Codable { self.arrayEnum = arrayEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justSymbol = "just_symbol" case arrayEnum = "array_enum" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift index 7280a621fe..3c1dfcac57 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift @@ -7,7 +7,6 @@ import Foundation - public enum EnumClass: String, Codable { case abc = "_abc" case efg = "-efg" diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift index 0f546c76a2..6db9b34d18 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumTest: Codable { public enum EnumString: String, Codable { @@ -43,7 +41,7 @@ public struct EnumTest: Codable { self.outerEnum = outerEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case enumString = "enum_string" case enumStringRequired = "enum_string_required" case enumInteger = "enum_integer" @@ -51,6 +49,4 @@ public struct EnumTest: Codable { case outerEnum } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/File.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/File.swift index c8bd1f1958..ea3520f053 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/File.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/File.swift @@ -7,7 +7,6 @@ import Foundation - /** Must be named `File` for test. */ public struct File: Codable { @@ -19,6 +18,4 @@ public struct File: Codable { self.sourceURI = sourceURI } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift index 64d0250680..532f145793 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FileSchemaTestClass: Codable { public var file: File? @@ -19,6 +17,4 @@ public struct FileSchemaTestClass: Codable { self.files = files } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift index faa091b065..20bd6d103b 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FormatTest: Codable { public var integer: Int? @@ -41,6 +39,4 @@ public struct FormatTest: Codable { self.password = password } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift index 554aee1081..906ddb06fb 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct HasOnlyReadOnly: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct HasOnlyReadOnly: Codable { self.foo = foo } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/List.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/List.swift index 8997340ff4..08d5995387 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/List.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/List.swift @@ -7,8 +7,6 @@ import Foundation - - public struct List: Codable { public var _123list: String? @@ -17,10 +15,8 @@ public struct List: Codable { self._123list = _123list } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _123list = "123-list" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift index 2d3a45d35a..3a10a7dfca 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift @@ -7,33 +7,29 @@ import Foundation - - public struct MapTest: Codable { public enum MapOfEnumString: String, Codable { case upper = "UPPER" case lower = "lower" } - public var mapMapOfString: [String:[String:String]]? - public var mapOfEnumString: [String:String]? - public var directMap: [String:Bool]? + public var mapMapOfString: [String: [String: String]]? + public var mapOfEnumString: [String: String]? + public var directMap: [String: Bool]? public var indirectMap: StringBooleanMap? - public init(mapMapOfString: [String:[String:String]]?, mapOfEnumString: [String:String]?, directMap: [String:Bool]?, indirectMap: StringBooleanMap?) { + public init(mapMapOfString: [String: [String: String]]?, mapOfEnumString: [String: String]?, directMap: [String: Bool]?, indirectMap: StringBooleanMap?) { self.mapMapOfString = mapMapOfString self.mapOfEnumString = mapOfEnumString self.directMap = directMap self.indirectMap = indirectMap } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapMapOfString = "map_map_of_string" case mapOfEnumString = "map_of_enum_string" case directMap = "direct_map" case indirectMap = "indirect_map" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift index 7116108fd7..c3deb2f289 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift @@ -7,20 +7,16 @@ import Foundation - - public struct MixedPropertiesAndAdditionalPropertiesClass: Codable { public var uuid: UUID? public var dateTime: Date? - public var map: [String:Animal]? + public var map: [String: Animal]? - public init(uuid: UUID?, dateTime: Date?, map: [String:Animal]?) { + public init(uuid: UUID?, dateTime: Date?, map: [String: Animal]?) { self.uuid = uuid self.dateTime = dateTime self.map = map } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift index fc1d0606b7..7ed6aad907 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name starting with number */ public struct Model200Response: Codable { @@ -20,11 +19,9 @@ public struct Model200Response: Codable { self._class = _class } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case _class = "class" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Name.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Name.swift index cc165d767d..ce9ffe4fb3 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Name.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Name.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name same as property name */ public struct Name: Codable { @@ -24,13 +23,11 @@ public struct Name: Codable { self._123number = _123number } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case snakeCase = "snake_case" case property case _123number = "123Number" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift index e6fb206093..abd2269e8e 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct NumberOnly: Codable { public var justNumber: Double? @@ -17,10 +15,8 @@ public struct NumberOnly: Codable { self.justNumber = justNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justNumber = "JustNumber" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Order.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Order.swift index 83c3b85e66..a6e1b1d2e5 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Order.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Order.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Order: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Order: Codable { self.complete = complete } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift index edc4523d9f..49aec001c5 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift @@ -7,8 +7,6 @@ import Foundation - - public struct OuterComposite: Codable { public var myNumber: Double? @@ -21,12 +19,10 @@ public struct OuterComposite: Codable { self.myBoolean = myBoolean } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case myNumber = "my_number" case myString = "my_string" case myBoolean = "my_boolean" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift index bd1643d279..9f80fc95ec 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift @@ -7,7 +7,6 @@ import Foundation - public enum OuterEnum: String, Codable { case placed = "placed" case approved = "approved" diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift index 5e39abae6c..af60a550bb 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Pet: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Pet: Codable { self.status = status } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift index 48b655a5b0..0acd21fd10 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ReadOnlyFirst: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct ReadOnlyFirst: Codable { self.baz = baz } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Return.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Return.swift index de4b218999..076082af84 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Return.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Return.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing reserved words */ public struct Return: Codable { @@ -18,10 +17,8 @@ public struct Return: Codable { self._return = _return } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _return = "return" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift index 213d896ba9..e79fc45c0e 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift @@ -7,8 +7,6 @@ import Foundation - - public struct SpecialModelName: Codable { public var specialPropertyName: Int64? @@ -17,10 +15,8 @@ public struct SpecialModelName: Codable { self.specialPropertyName = specialPropertyName } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case specialPropertyName = "$special[property.name]" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift index ae15e87d94..3f1237fee4 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift @@ -7,12 +7,9 @@ import Foundation - - public struct StringBooleanMap: Codable { - - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -45,7 +42,4 @@ public struct StringBooleanMap: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift index 32ee33a1a1..4dd8a9a9f5 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Tag: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Tag: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift index be1afdf026..bf0006e1a2 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderDefault: Codable { public var stringItem: String = "what" @@ -25,7 +23,7 @@ public struct TypeHolderDefault: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderDefault: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift index f46c8952e1..602a2a6d18 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderExample: Codable { public var stringItem: String @@ -25,7 +23,7 @@ public struct TypeHolderExample: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderExample: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/User.swift b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/User.swift index a61b584420..79f271ed73 100644 --- a/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/User.swift +++ b/samples/client/petstore/swift4/default/PetstoreClient/Classes/OpenAPIs/Models/User.swift @@ -7,8 +7,6 @@ import Foundation - - public struct User: Codable { public var id: Int64? @@ -32,6 +30,4 @@ public struct User: Codable { self.userStatus = userStatus } - } - diff --git a/samples/client/petstore/swift4/default/README.md b/samples/client/petstore/swift4/default/README.md index 1e7f0a59ea..0711eb8705 100644 --- a/samples/client/petstore/swift4/default/README.md +++ b/samples/client/petstore/swift4/default/README.md @@ -73,10 +73,12 @@ Class | Method | HTTP request | Description - [ArrayTest](docs/ArrayTest.md) - [Capitalization](docs/Capitalization.md) - [Cat](docs/Cat.md) + - [CatAllOf](docs/CatAllOf.md) - [Category](docs/Category.md) - [ClassModel](docs/ClassModel.md) - [Client](docs/Client.md) - [Dog](docs/Dog.md) + - [DogAllOf](docs/DogAllOf.md) - [EnumArrays](docs/EnumArrays.md) - [EnumClass](docs/EnumClass.md) - [EnumTest](docs/EnumTest.md) diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift index 2fcc05ca06..a411b77491 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift @@ -135,8 +135,7 @@ public func request( parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest -{ + -> DataRequest { return SessionManager.default.request( url, method: method, @@ -183,8 +182,7 @@ public func download( encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download( url, method: method, @@ -209,8 +207,7 @@ public func download( public func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(urlRequest, to: destination) } @@ -239,8 +236,7 @@ public func download( public func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(resumingWith: resumeData, to: destination) } @@ -263,8 +259,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(fileURL, to: url, method: method, headers: headers) } @@ -297,8 +292,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(data, to: url, method: method, headers: headers) } @@ -331,8 +325,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(stream, to: url, method: method, headers: headers) } @@ -379,8 +372,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, @@ -416,8 +408,7 @@ public func upload( multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift index 057e68b977..85a0685748 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift @@ -275,8 +275,7 @@ open class MultipartFormData { } bodyContentLength = fileSize.uint64Value - } - catch { + } catch { setBodyPartError(withReason: .bodyPartFileSizeQueryFailedWithError(forURL: fileURL, error: error)) return } @@ -312,8 +311,7 @@ open class MultipartFormData { withLength length: UInt64, name: String, fileName: String, - mimeType: String) - { + mimeType: String) { let headers = contentHeaders(withName: name, fileName: fileName, mimeType: mimeType) append(stream, withLength: length, headers: headers) } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift index 3ff2e7fc27..60bda83d2f 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift @@ -146,8 +146,7 @@ open class NetworkReachabilityManager { context.info = Unmanaged.passUnretained(self).toOpaque() let callbackEnabled = SCNetworkReachabilitySetCallback( - reachability, - { (_, flags, info) in + reachability, { (_, flags, info) in let reachability = Unmanaged.fromOpaque(info!).takeUnretainedValue() reachability.notifyListener(flags) }, @@ -216,8 +215,7 @@ extension NetworkReachabilityManager.NetworkReachabilityStatus: Equatable {} public func ==( lhs: NetworkReachabilityManager.NetworkReachabilityStatus, rhs: NetworkReachabilityManager.NetworkReachabilityStatus) - -> Bool -{ + -> Bool { switch (lhs, rhs) { case (.unknown, .unknown): return true diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift index 4a54f2dd00..344a048cad 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift @@ -435,8 +435,7 @@ public struct PropertyListEncoding: ParameterEncoding { /// - returns: The new `PropertyListEncoding` instance. public init( format: PropertyListSerialization.PropertyListFormat = .xml, - options: PropertyListSerialization.WriteOptions = 0) - { + options: PropertyListSerialization.WriteOptions = 0) { self.format = format self.options = options } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Request.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Request.swift index ea43411377..18b83a0e73 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Request.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Request.swift @@ -161,8 +161,7 @@ open class Request { user: String, password: String, persistence: URLCredential.Persistence = .forSession) - -> Self - { + -> Self { let credential = URLCredential(user: user, password: password, persistence: persistence) return authenticate(usingCredential: credential) } @@ -538,8 +537,7 @@ open class DownloadRequest: Request { open class func suggestedDownloadDestination( for directory: FileManager.SearchPathDirectory = .documentDirectory, in domain: FileManager.SearchPathDomainMask = .userDomainMask) - -> DownloadFileDestination - { + -> DownloadFileDestination { return { temporaryURL, response in let directoryURLs = FileManager.default.urls(for: directory, in: domain) diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Response.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Response.swift index 74b1ef54d0..23571383ba 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Response.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Response.swift @@ -58,8 +58,7 @@ public struct DefaultDataResponse { data: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.data = data @@ -109,8 +108,7 @@ public struct DataResponse { response: HTTPURLResponse?, data: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.data = data @@ -296,8 +294,7 @@ public struct DefaultDownloadResponse { resumeData: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.temporaryURL = temporaryURL @@ -359,8 +356,7 @@ public struct DownloadResponse { destinationURL: URL?, resumeData: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.temporaryURL = temporaryURL diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift index 3333726d5c..fd049edac1 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift @@ -144,8 +144,7 @@ extension DataRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -182,8 +181,7 @@ extension DownloadRequest { public func response( queue: DispatchQueue? = nil, completionHandler: @escaping (DefaultDownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { (queue ?? DispatchQueue.main).async { var downloadResponse = DefaultDownloadResponse( @@ -218,8 +216,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -289,8 +286,7 @@ extension DataRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.dataResponseSerializer(), @@ -329,8 +325,7 @@ extension DownloadRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.dataResponseSerializer(), @@ -356,8 +351,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success("") } @@ -411,8 +405,7 @@ extension DataRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.stringResponseSerializer(encoding: encoding), @@ -459,8 +452,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.stringResponseSerializer(encoding: encoding), @@ -486,8 +478,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -514,8 +505,7 @@ extension DataRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponseJSON(options: options, response: response, data: data, error: error) } @@ -532,8 +522,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.jsonResponseSerializer(options: options), @@ -551,8 +540,7 @@ extension DownloadRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -580,8 +568,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.jsonResponseSerializer(options: options), @@ -607,8 +594,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -635,8 +621,7 @@ extension DataRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponsePropertyList(options: options, response: response, data: data, error: error) } @@ -653,8 +638,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.propertyListResponseSerializer(options: options), @@ -672,8 +656,7 @@ extension DownloadRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -701,8 +684,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.propertyListResponseSerializer(options: options), diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift index 7f44c8d2c6..d50e941fab 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift @@ -249,7 +249,6 @@ public enum ServerTrustPolicy { let unspecified = SecTrustResultType.unspecified let proceed = SecTrustResultType.proceed - isValid = result == unspecified || result == proceed } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift index 03bcb7ced6..17d0d9f150 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift @@ -255,8 +255,7 @@ extension SessionDelegate: URLSessionDelegate { open func urlSession( _ session: URLSession, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard sessionDidReceiveChallengeWithCompletion == nil else { sessionDidReceiveChallengeWithCompletion?(session, challenge, completionHandler) return @@ -315,8 +314,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { guard taskWillPerformHTTPRedirectionWithCompletion == nil else { taskWillPerformHTTPRedirectionWithCompletion?(session, task, response, request, completionHandler) return @@ -342,8 +340,7 @@ extension SessionDelegate: URLSessionTaskDelegate { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard taskDidReceiveChallengeWithCompletion == nil else { taskDidReceiveChallengeWithCompletion?(session, task, challenge, completionHandler) return @@ -372,8 +369,7 @@ extension SessionDelegate: URLSessionTaskDelegate { open func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { guard taskNeedNewBodyStreamWithCompletion == nil else { taskNeedNewBodyStreamWithCompletion?(session, task, completionHandler) return @@ -398,8 +394,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if let taskDidSendBodyData = taskDidSendBodyData { taskDidSendBodyData(session, task, bytesSent, totalBytesSent, totalBytesExpectedToSend) } else if let delegate = self[task]?.delegate as? UploadTaskDelegate { @@ -512,8 +507,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { guard dataTaskDidReceiveResponseWithCompletion == nil else { dataTaskDidReceiveResponseWithCompletion?(session, dataTask, response, completionHandler) return @@ -536,8 +530,7 @@ extension SessionDelegate: URLSessionDataDelegate { open func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { if let dataTaskDidBecomeDownloadTask = dataTaskDidBecomeDownloadTask { dataTaskDidBecomeDownloadTask(session, dataTask, downloadTask) } else { @@ -573,8 +566,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { guard dataTaskWillCacheResponseWithCompletion == nil else { dataTaskWillCacheResponseWithCompletion?(session, dataTask, proposedResponse, completionHandler) return @@ -608,8 +600,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { open func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { if let downloadTaskDidFinishDownloadingToURL = downloadTaskDidFinishDownloadingToURL { downloadTaskDidFinishDownloadingToURL(session, downloadTask, location) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -632,8 +623,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if let downloadTaskDidWriteData = downloadTaskDidWriteData { downloadTaskDidWriteData(session, downloadTask, bytesWritten, totalBytesWritten, totalBytesExpectedToWrite) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -661,8 +651,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -716,8 +705,7 @@ extension SessionDelegate: URLSessionStreamDelegate { _ session: URLSession, streamTask: URLSessionStreamTask, didBecome inputStream: InputStream, - outputStream: OutputStream) - { + outputStream: OutputStream) { streamTaskDidBecomeInputAndOutputStreams?(session, streamTask, inputStream, outputStream) } } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift index 8779efdaa6..8c10706677 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift @@ -166,8 +166,7 @@ open class SessionManager { public init( configuration: URLSessionConfiguration = URLSessionConfiguration.default, delegate: SessionDelegate = SessionDelegate(), - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { self.delegate = delegate self.session = URLSession(configuration: configuration, delegate: delegate, delegateQueue: nil) @@ -185,8 +184,7 @@ open class SessionManager { public init?( session: URLSession, delegate: SessionDelegate, - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { guard delegate === session.delegate else { return nil } self.delegate = delegate @@ -229,8 +227,7 @@ open class SessionManager { parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest - { + -> DataRequest { var originalRequest: URLRequest? do { @@ -320,8 +317,7 @@ open class SessionManager { encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) let encodedURLRequest = try encoding.encode(urlRequest, with: parameters) @@ -347,8 +343,7 @@ open class SessionManager { open func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try urlRequest.asURLRequest() return download(.request(urlRequest), to: destination) @@ -384,8 +379,7 @@ open class SessionManager { open func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { return download(.resumeData(resumeData), to: destination) } @@ -394,8 +388,7 @@ open class SessionManager { private func download( _ downloadable: DownloadRequest.Downloadable, to destination: DownloadRequest.DownloadFileDestination?) - -> DownloadRequest - { + -> DownloadRequest { do { let task = try downloadable.task(session: session, adapter: adapter, queue: queue) let download = DownloadRequest(session: session, requestTask: .download(downloadable, task)) @@ -416,8 +409,7 @@ open class SessionManager { _ downloadable: DownloadRequest.Downloadable?, to destination: DownloadRequest.DownloadFileDestination?, failedWith error: Error) - -> DownloadRequest - { + -> DownloadRequest { var downloadTask: Request.RequestTask = .download(nil, nil) if let downloadable = downloadable { @@ -458,8 +450,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(fileURL, with: urlRequest) @@ -504,8 +495,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(data, with: urlRequest) @@ -550,8 +540,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(stream, with: urlRequest) @@ -611,8 +600,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) @@ -654,8 +642,7 @@ open class SessionManager { multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { DispatchQueue.global(qos: .utility).async { let formData = MultipartFormData() multipartFormData(formData) diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift index 8e19888fc8..12fcbe92d3 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift @@ -94,8 +94,7 @@ open class TaskDelegate: NSObject { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { var redirectRequest: URLRequest? = request if let taskWillPerformHTTPRedirection = taskWillPerformHTTPRedirection { @@ -110,8 +109,7 @@ open class TaskDelegate: NSObject { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { var disposition: URLSession.AuthChallengeDisposition = .performDefaultHandling var credential: URLCredential? @@ -150,8 +148,7 @@ open class TaskDelegate: NSObject { func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { var bodyStream: InputStream? if let taskNeedNewBodyStream = taskNeedNewBodyStream { @@ -237,8 +234,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { var disposition: URLSession.ResponseDisposition = .allow expectedContentLength = response.expectedContentLength @@ -253,8 +249,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { dataTaskDidBecomeDownloadTask?(session, dataTask, downloadTask) } @@ -287,8 +282,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { var cachedResponse: CachedURLResponse? = proposedResponse if let dataTaskWillCacheResponse = dataTaskWillCacheResponse { @@ -343,8 +337,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { temporaryURL = location guard @@ -379,8 +372,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let downloadTaskDidWriteData = downloadTaskDidWriteData { @@ -405,8 +397,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else { @@ -448,8 +439,7 @@ class UploadTaskDelegate: DataTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let taskDidSendBodyData = taskDidSendBodyData { diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift index 181c9883cb..b318b1ff48 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift @@ -64,8 +64,7 @@ public struct Timeline { requestStartTime: CFAbsoluteTime = 0.0, initialResponseTime: CFAbsoluteTime = 0.0, requestCompletedTime: CFAbsoluteTime = 0.0, - serializationCompletedTime: CFAbsoluteTime = 0.0) - { + serializationCompletedTime: CFAbsoluteTime = 0.0) { self.requestStartTime = requestStartTime self.initialResponseTime = initialResponseTime self.requestCompletedTime = requestCompletedTime diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift index ec2c5c35a0..deaee34ad8 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift @@ -94,8 +94,7 @@ extension Request { statusCode acceptableStatusCodes: S, response: HTTPURLResponse) -> ValidationResult - where S.Iterator.Element == Int - { + where S.Iterator.Element == Int { if acceptableStatusCodes.contains(response.statusCode) { return .success } else { @@ -111,8 +110,7 @@ extension Request { response: HTTPURLResponse, data: Data?) -> ValidationResult - where S.Iterator.Element == String - { + where S.Iterator.Element == String { guard let data = data, data.count > 0 else { return .success } guard diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/AppDelegate.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/AppDelegate.swift index bb73371c38..b1896774c7 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/AppDelegate.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/AppDelegate.swift @@ -13,7 +13,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? - func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true @@ -41,6 +40,4 @@ class AppDelegate: UIResponder, UIApplicationDelegate { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } - } - diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/ViewController.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/ViewController.swift index cd7e9a1676..8dad16b10f 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/ViewController.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClient/ViewController.swift @@ -20,6 +20,4 @@ class ViewController: UIViewController { // Dispose of any resources that can be recreated. } - } - diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/DateFormatTests.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/DateFormatTests.swift index 978417c358..b83a008b79 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/DateFormatTests.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/DateFormatTests.swift @@ -12,21 +12,21 @@ import XCTest @testable import SwaggerClient class DateFormatTests: XCTestCase { - + struct DateTest: Codable { let date: Date } - + override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. } - + override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() } - + func testEncodeToJSONAlwaysResultsInUTCEncodedDate() { var dateComponents = DateComponents() dateComponents.calendar = Calendar(identifier: .gregorian) @@ -37,40 +37,40 @@ class DateFormatTests: XCTestCase { dateComponents.minute = 35 dateComponents.second = 43 dateComponents.nanosecond = 500 - + // Testing a date with a timezone of +00:00 (UTC) dateComponents.timeZone = TimeZone(secondsFromGMT: 0) XCTAssert(dateComponents.isValidDate) - + guard let utcDate = dateComponents.date else { XCTFail("Couldn't get a valid date") return } - + var encodedDate = utcDate.encodeToJSON() as! String XCTAssert(encodedDate.hasSuffix("Z")) - + // test with a positive timzone offset from UTC dateComponents.timeZone = TimeZone(secondsFromGMT: 60 * 60) // +01:00 XCTAssert(dateComponents.isValidDate) - + guard let nonUTCDate1 = dateComponents.date else { XCTFail("Couldn't get a valid date") return } - + encodedDate = nonUTCDate1.encodeToJSON() as! String XCTAssert(encodedDate.hasSuffix("Z")) - + // test with a negative timzone offset from UTC dateComponents.timeZone = TimeZone(secondsFromGMT: -(60 * 60)) // -01:00 XCTAssert(dateComponents.isValidDate) - + guard let nonUTCDate2 = dateComponents.date else { XCTFail("Couldn't get a valid date") return } - + encodedDate = nonUTCDate2.encodeToJSON() as! String XCTAssert(encodedDate.hasSuffix("Z")) } @@ -79,7 +79,7 @@ class DateFormatTests: XCTestCase { let jsonData = "{\"date\":\"1970-01-01T00:00:00.000Z\"}".data(using: .utf8)! let decodeResult = CodableHelper.decode(DateTest.self, from: jsonData) XCTAssert(decodeResult.decodableObj != nil && decodeResult.error == nil) - + var dateComponents = DateComponents() dateComponents.calendar = Calendar(identifier: .gregorian) dateComponents.year = 1970 @@ -88,16 +88,16 @@ class DateFormatTests: XCTestCase { dateComponents.hour = 00 dateComponents.minute = 00 dateComponents.second = 00 - + // Testing a date with a timezone of +00:00 (UTC) dateComponents.timeZone = TimeZone(secondsFromGMT: 0) XCTAssert(dateComponents.isValidDate) - + guard let date = dateComponents.date else { XCTFail("Couldn't get a valid date") return } - + let dateTest = DateTest(date: date) let encodeResult = CodableHelper.encode(dateTest) XCTAssert(encodeResult.data != nil && encodeResult.error == nil) @@ -105,9 +105,9 @@ class DateFormatTests: XCTestCase { XCTFail("Unable to convert encoded data to string.") return } - + let exampleJSONString = "{\"date\":\"1970-01-01T00:00:00.000Z\"}" XCTAssert(jsonString == exampleJSONString, "Encoded JSON String: \(jsonString) should match: \(exampleJSONString)") } - + } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift index b2f9fecb40..6be5bc6d29 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift @@ -11,61 +11,61 @@ import XCTest @testable import SwaggerClient class PetAPITests: XCTestCase { - + let testTimeout = 10.0 override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. } - + override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() } - + func test1CreatePet() { let expectation = self.expectation(description: "testCreatePet") let category = PetstoreClient.Category(id: 1234, name: "eyeColor") let tags = [Tag(id: 1234, name: "New York"), Tag(id: 124321, name: "Jose")] let newPet = Pet(id: 1000, category: category, name: "Fluffy", photoUrls: ["https://petstore.com/sample/photo1.jpg", "https://petstore.com/sample/photo2.jpg"], tags: tags, status: .available) - PetAPI.addPet(body: newPet) { (response, error) in + PetAPI.addPet(body: newPet) { (_, error) in guard error == nil else { XCTFail("error creating pet") return } - + expectation.fulfill() } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test2GetPet() { let expectation = self.expectation(description: "testGetPet") - + PetAPI.getPetById(petId: 1000) { (pet, error) in guard error == nil else { XCTFail("error retrieving pet") return } - + if let pet = pet { XCTAssert(pet.id == 1000, "invalid id") XCTAssert(pet.name == "Fluffy", "invalid name") - + expectation.fulfill() } } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test3DeletePet() { let expectation = self.expectation(description: "testDeletePet") - - PetAPI.deletePet(petId: 1000) { (response, error) in + + PetAPI.deletePet(petId: 1000) { (_, error) in guard error == nil else { XCTFail("error deleting pet") return @@ -73,7 +73,7 @@ class PetAPITests: XCTestCase { expectation.fulfill() } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift index 5bd01081e4..fedf7fcdbb 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift @@ -13,7 +13,7 @@ import XCTest class StoreAPITests: XCTestCase { let isoDateFormat = "yyyy-MM-dd'T'HH:mm:ssZ" - + let testTimeout = 10.0 func test1PlaceOrder() { @@ -27,45 +27,45 @@ class StoreAPITests: XCTestCase { XCTFail("error placing order: \(error.debugDescription)") return } - + if let order = order { XCTAssert(order.id == 1000, "invalid id") XCTAssert(order.quantity == 10, "invalid quantity") XCTAssert(order.status == .placed, "invalid status") XCTAssert(order.shipDate!.isEqual(shipDate, format: self.isoDateFormat), "Date should be idempotent") - + expectation.fulfill() } } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test2GetOrder() { let expectation = self.expectation(description: "testGetOrder") - + StoreAPI.getOrderById(orderId: 1000) { (order, error) in guard error == nil else { XCTFail("error retrieving order: \(error.debugDescription)") return } - + if let order = order { XCTAssert(order.id == 1000, "invalid id") XCTAssert(order.quantity == 10, "invalid quantity") XCTAssert(order.status == .placed, "invalid status") - + expectation.fulfill() } } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test3DeleteOrder() { let expectation = self.expectation(description: "testDeleteOrder") - + StoreAPI.deleteOrder(orderId: "1000") { (response, error) in guard error == nil else { XCTFail("error deleting order") @@ -79,7 +79,7 @@ class StoreAPITests: XCTestCase { expectation.fulfill() } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } @@ -92,7 +92,7 @@ class StoreAPITests: XCTestCase { progressExpectation.fulfill() } - requestBuilder.execute { (response, error) in + requestBuilder.execute { (_, _) in responseExpectation.fulfill() } diff --git a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift index 686bebec0a..0a1ca3902e 100644 --- a/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift +++ b/samples/client/petstore/swift4/default/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift @@ -11,22 +11,22 @@ import XCTest @testable import SwaggerClient class UserAPITests: XCTestCase { - + let testTimeout = 10.0 - + override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. } - + override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() } - + func testLogin() { let expectation = self.expectation(description: "testLogin") - + UserAPI.loginUser(username: "swiftTester", password: "swift") { (_, error) in guard error == nil else { XCTFail("error logging in") @@ -35,14 +35,14 @@ class UserAPITests: XCTestCase { expectation.fulfill() } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func testLogout() { let expectation = self.expectation(description: "testLogout") - - UserAPI.logoutUser { (response, error) in + + UserAPI.logoutUser { (_, error) in guard error == nil else { XCTFail("error logging out") return @@ -50,7 +50,7 @@ class UserAPITests: XCTestCase { expectation.fulfill() } - + self.waitForExpectations(timeout: testTimeout, handler: nil) } @@ -60,7 +60,7 @@ class UserAPITests: XCTestCase { // into the path. So we intentionally introduce a path with spaces. let userRequestBuilder = UserAPI.getUserByNameWithRequestBuilder(username: "User Name With Spaces") let urlContainsSpace = userRequestBuilder.URLString.contains(" ") - + XCTAssert(!urlContainsSpace, "Expected URL to be escaped, but it was not.") } diff --git a/samples/client/petstore/swift4/default/docs/CatAllOf.md b/samples/client/petstore/swift4/default/docs/CatAllOf.md new file mode 100644 index 0000000000..79789be61c --- /dev/null +++ b/samples/client/petstore/swift4/default/docs/CatAllOf.md @@ -0,0 +1,10 @@ +# CatAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**declawed** | **Bool** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/default/docs/DogAllOf.md b/samples/client/petstore/swift4/default/docs/DogAllOf.md new file mode 100644 index 0000000000..9302ef52e9 --- /dev/null +++ b/samples/client/petstore/swift4/default/docs/DogAllOf.md @@ -0,0 +1,10 @@ +# DogAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**breed** | **String** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/default/docs/UserAPI.md b/samples/client/petstore/swift4/default/docs/UserAPI.md index da20013482..380813bc68 100644 --- a/samples/client/petstore/swift4/default/docs/UserAPI.md +++ b/samples/client/petstore/swift4/default/docs/UserAPI.md @@ -95,7 +95,7 @@ UserAPI.createUsersWithArrayInput(body: body) { (response, error) in Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type @@ -143,7 +143,7 @@ UserAPI.createUsersWithListInput(body: body) { (response, error) in Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type diff --git a/samples/client/petstore/swift4/default/project.yml b/samples/client/petstore/swift4/default/project.yml new file mode 100644 index 0000000000..148b42517b --- /dev/null +++ b/samples/client/petstore/swift4/default/project.yml @@ -0,0 +1,15 @@ +name: PetstoreClient +targets: + PetstoreClient: + type: framework + platform: iOS + deploymentTarget: "10.0" + sources: [PetstoreClient] + info: + path: ./Info.plist + version: 1.0.0 + settings: + APPLICATION_EXTENSION_API_ONLY: true + scheme: {} + dependencies: + - carthage: Alamofire diff --git a/samples/client/petstore/swift4/objcCompatible/.openapi-generator/VERSION b/samples/client/petstore/swift4/objcCompatible/.openapi-generator/VERSION index afa6365606..83a328a922 100644 --- a/samples/client/petstore/swift4/objcCompatible/.openapi-generator/VERSION +++ b/samples/client/petstore/swift4/objcCompatible/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.0-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/swift4/objcCompatible/Info.plist b/samples/client/petstore/swift4/objcCompatible/Info.plist new file mode 100644 index 0000000000..323e5ecfc4 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/Info.plist @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.pbxproj b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.pbxproj new file mode 100644 index 0000000000..55021e5d19 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.pbxproj @@ -0,0 +1,601 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */; }; + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */; }; + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */; }; + 08F5828F0C2BCF07A9E4917DBBB993AE /* AdditionalPropertiesInteger.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */; }; + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */ = {isa = PBXBuildFile; fileRef = C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */; }; + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */; }; + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */; }; + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */; }; + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */; }; + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */ = {isa = PBXBuildFile; fileRef = 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */; }; + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */; }; + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */; }; + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */; }; + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */; }; + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */; }; + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */ = {isa = PBXBuildFile; fileRef = 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */; }; + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */; }; + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */; }; + 39F9FBA1AC5C2612ECA1FF715EBFC287 /* AdditionalPropertiesString.swift in Sources */ = {isa = PBXBuildFile; fileRef = FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */; }; + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */; }; + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */; }; + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */; }; + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */; }; + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */; }; + 52B5604F986335DB69CD2B430FB83BAB /* AdditionalPropertiesAnyType.swift in Sources */ = {isa = PBXBuildFile; fileRef = F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */; }; + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */; }; + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */; }; + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */ = {isa = PBXBuildFile; fileRef = 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */; }; + 59EAB3527305A37ED99FB210045B69EA /* AdditionalPropertiesNumber.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */; }; + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */; }; + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */; }; + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */; }; + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */; }; + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */ = {isa = PBXBuildFile; fileRef = A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */; }; + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */ = {isa = PBXBuildFile; fileRef = F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */; }; + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */; }; + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */ = {isa = PBXBuildFile; fileRef = A913A57E72D723632E9A718FF4525C81 /* Client.swift */; }; + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */; }; + 988F461F59E4E1091156840007CB3773 /* AdditionalPropertiesBoolean.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */; }; + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */; }; + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */ = {isa = PBXBuildFile; fileRef = 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */; }; + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */ = {isa = PBXBuildFile; fileRef = B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */; }; + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */; }; + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */; }; + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */; }; + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */; }; + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */; }; + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7A6070F581E611FF44AFD40A4315C49A /* List.swift */; }; + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */; }; + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */; }; + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */; }; + D68F23CD4B5178493CE7AE8DFB868EAE /* AdditionalPropertiesArray.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */; }; + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */ = {isa = PBXBuildFile; fileRef = C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */; }; + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */; }; + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */; }; + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */; }; + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */; }; + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */ = {isa = PBXBuildFile; fileRef = 386FD590658E90509C121118F057604D /* SpecialModelName.swift */; }; + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */ = {isa = PBXBuildFile; fileRef = B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */; }; + E57CD12D2F500D40B4135D0F5ECA9866 /* AdditionalPropertiesObject.swift in Sources */ = {isa = PBXBuildFile; fileRef = 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */; }; + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8699F7966F748ED026A6FB4CF550442B /* Models.swift */; }; + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */ = {isa = PBXBuildFile; fileRef = C81447828475F76C5CF4F08AA65292F7 /* Return.swift */; }; + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */ = {isa = PBXBuildFile; fileRef = 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */; }; + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CodableHelper.swift; sourceTree = ""; }; + 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesBoolean.swift; sourceTree = ""; }; + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumArrays.swift; sourceTree = ""; }; + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PetstoreClient.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderExample.swift; sourceTree = ""; }; + 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesNumber.swift; sourceTree = ""; }; + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Cat.swift; sourceTree = ""; }; + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Order.swift; sourceTree = ""; }; + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Configuration.swift; sourceTree = ""; }; + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FormatTest.swift; sourceTree = ""; }; + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodingHelper.swift; sourceTree = ""; }; + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIs.swift; sourceTree = ""; }; + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SpecialModelName.swift; sourceTree = ""; }; + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = File.swift; sourceTree = ""; }; + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesClass.swift; sourceTree = ""; }; + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CatAllOf.swift; sourceTree = ""; }; + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ClassModel.swift; sourceTree = ""; }; + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringBooleanMap.swift; sourceTree = ""; }; + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumClass.swift; sourceTree = ""; }; + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileSchemaTestClass.swift; sourceTree = ""; }; + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HasOnlyReadOnly.swift; sourceTree = ""; }; + 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesArray.swift; sourceTree = ""; }; + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Name.swift; sourceTree = ""; }; + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeAPI.swift; sourceTree = ""; }; + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Category.swift; sourceTree = ""; }; + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReadOnlyFirst.swift; sourceTree = ""; }; + 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesObject.swift; sourceTree = ""; }; + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MapTest.swift; sourceTree = ""; }; + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = List.swift; sourceTree = ""; }; + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfArrayOfNumberOnly.swift; sourceTree = ""; }; + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UserAPI.swift; sourceTree = ""; }; + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Model200Response.swift; sourceTree = ""; }; + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AlamofireImplementations.swift; sourceTree = ""; }; + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Models.swift; sourceTree = ""; }; + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIHelper.swift; sourceTree = ""; }; + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnimalFarm.swift; sourceTree = ""; }; + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Animal.swift; sourceTree = ""; }; + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodableEncoding.swift; sourceTree = ""; }; + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PetAPI.swift; sourceTree = ""; }; + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MixedPropertiesAndAdditionalPropertiesClass.swift; sourceTree = ""; }; + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnotherFakeAPI.swift; sourceTree = ""; }; + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DogAllOf.swift; sourceTree = ""; }; + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XmlItem.swift; sourceTree = ""; }; + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Alamofire.framework; sourceTree = ""; }; + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreAPI.swift; sourceTree = ""; }; + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Capitalization.swift; sourceTree = ""; }; + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApiResponse.swift; sourceTree = ""; }; + A913A57E72D723632E9A718FF4525C81 /* Client.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Client.swift; sourceTree = ""; }; + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Tag.swift; sourceTree = ""; }; + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeClassnameTags123API.swift; sourceTree = ""; }; + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfNumberOnly.swift; sourceTree = ""; }; + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Extensions.swift; sourceTree = ""; }; + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NumberOnly.swift; sourceTree = ""; }; + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterEnum.swift; sourceTree = ""; }; + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Dog.swift; sourceTree = ""; }; + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Return.swift; sourceTree = ""; }; + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = User.swift; sourceTree = ""; }; + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderDefault.swift; sourceTree = ""; }; + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pet.swift; sourceTree = ""; }; + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayTest.swift; sourceTree = ""; }; + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterComposite.swift; sourceTree = ""; }; + F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesAnyType.swift; sourceTree = ""; }; + FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesInteger.swift; sourceTree = ""; }; + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumTest.swift; sourceTree = ""; }; + FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesString.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */ = { + isa = PBXGroup; + children = ( + 7861EE241895128F64DD787367B3022D /* Carthage */, + ); + name = Frameworks; + sourceTree = ""; + }; + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */ = { + isa = PBXGroup; + children = ( + F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */, + 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */, + 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */, + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */, + FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */, + 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */, + 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */, + FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */, + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */, + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */, + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */, + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */, + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */, + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */, + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */, + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */, + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */, + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */, + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */, + A913A57E72D723632E9A718FF4525C81 /* Client.swift */, + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */, + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */, + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */, + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */, + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */, + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */, + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */, + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */, + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */, + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */, + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */, + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */, + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */, + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */, + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */, + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */, + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */, + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */, + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */, + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */, + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */, + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */, + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */, + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */, + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */, + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */, + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */, + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */, + ); + path = Models; + sourceTree = ""; + }; + 5FBA6AE5F64CD737F88B4565AC3CCD3B = { + isa = PBXGroup; + children = ( + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */, + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */, + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */, + ); + sourceTree = ""; + }; + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */ = { + isa = PBXGroup; + children = ( + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */, + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */, + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */, + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */, + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */, + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */, + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */, + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */, + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */, + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */, + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */, + ); + path = OpenAPIs; + sourceTree = ""; + }; + 7861EE241895128F64DD787367B3022D /* Carthage */ = { + isa = PBXGroup; + children = ( + A012205B41CB71A62B86EECDEAFB0990 /* iOS */, + ); + name = Carthage; + path = Carthage/Build; + sourceTree = ""; + }; + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */ = { + isa = PBXGroup; + children = ( + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */, + ); + name = Products; + sourceTree = ""; + }; + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */ = { + isa = PBXGroup; + children = ( + EF4C81BDD734856ED5023B777D35098B /* Classes */, + ); + path = PetstoreClient; + sourceTree = ""; + }; + A012205B41CB71A62B86EECDEAFB0990 /* iOS */ = { + isa = PBXGroup; + children = ( + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */, + ); + path = iOS; + sourceTree = ""; + }; + EF4C81BDD734856ED5023B777D35098B /* Classes */ = { + isa = PBXGroup; + children = ( + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */, + ); + path = Classes; + sourceTree = ""; + }; + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */ = { + isa = PBXGroup; + children = ( + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */, + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */, + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */, + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */, + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */, + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */, + ); + path = APIs; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */ = { + isa = PBXNativeTarget; + buildConfigurationList = B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */; + buildPhases = ( + E539708354CE60FE486F81EDE56D13C8 /* Sources */, + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = PetstoreClient; + productName = PetstoreClient; + productReference = 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + E7D276EE2369D8C455513C2E05F9AED0 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1000; + }; + buildConfigurationList = ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 5FBA6AE5F64CD737F88B4565AC3CCD3B; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + E539708354CE60FE486F81EDE56D13C8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */, + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */, + 52B5604F986335DB69CD2B430FB83BAB /* AdditionalPropertiesAnyType.swift in Sources */, + D68F23CD4B5178493CE7AE8DFB868EAE /* AdditionalPropertiesArray.swift in Sources */, + 988F461F59E4E1091156840007CB3773 /* AdditionalPropertiesBoolean.swift in Sources */, + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */, + 08F5828F0C2BCF07A9E4917DBBB993AE /* AdditionalPropertiesInteger.swift in Sources */, + 59EAB3527305A37ED99FB210045B69EA /* AdditionalPropertiesNumber.swift in Sources */, + E57CD12D2F500D40B4135D0F5ECA9866 /* AdditionalPropertiesObject.swift in Sources */, + 39F9FBA1AC5C2612ECA1FF715EBFC287 /* AdditionalPropertiesString.swift in Sources */, + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */, + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */, + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */, + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */, + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */, + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */, + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */, + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */, + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */, + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */, + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */, + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */, + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */, + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */, + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */, + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */, + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */, + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */, + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */, + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */, + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */, + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */, + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */, + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */, + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */, + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */, + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */, + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */, + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */, + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */, + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */, + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */, + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */, + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */, + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */, + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */, + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */, + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */, + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */, + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */, + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */, + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */, + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */, + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */, + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */, + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */, + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */, + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */, + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */, + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */, + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */, + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */, + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "$(inherited)", + "DEBUG=1", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 4.2; + }; + name = Debug; + }; + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 4.2; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */, + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = ""; + }; + ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */, + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = E7D276EE2369D8C455513C2E05F9AED0 /* Project object */; +} diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000000..919434a625 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme new file mode 100644 index 0000000000..7802e37945 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIHelper.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIHelper.swift index d94614b34f..75dea24395 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIHelper.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIHelper.swift @@ -7,7 +7,7 @@ import Foundation public struct APIHelper { - public static func rejectNil(_ source: [String:Any?]) -> [String:Any]? { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { let destination = source.reduce(into: [String: Any]()) { (result, item) in if let value = item.value { result[item.key] = value @@ -20,17 +20,17 @@ public struct APIHelper { return destination } - public static func rejectNilHeaders(_ source: [String:Any?]) -> [String:String] { + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { return source.reduce(into: [String: String]()) { (result, item) in if let collection = item.value as? Array { - result[item.key] = collection.filter({ $0 != nil }).map{ "\($0!)" }.joined(separator: ",") + result[item.key] = collection.filter({ $0 != nil }).map { "\($0!)" }.joined(separator: ",") } else if let value: Any = item.value { result[item.key] = "\(value)" } } } - public static func convertBoolToString(_ source: [String: Any]?) -> [String:Any]? { + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { guard let source = source else { return nil } @@ -52,7 +52,7 @@ public struct APIHelper { return source } - public static func mapValuesToQueryItems(_ source: [String:Any?]) -> [URLQueryItem]? { + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { let destination = source.filter({ $0.value != nil}).reduce(into: [URLQueryItem]()) { (result, item) in if let collection = item.value as? Array { let value = collection.filter({ $0 != nil }).map({"\($0!)"}).joined(separator: ",") @@ -68,4 +68,3 @@ public struct APIHelper { return destination } } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs.swift index 2890bffa27..9e4312f685 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs.swift @@ -9,22 +9,22 @@ import Foundation open class PetstoreClientAPI { public static var basePath = "http://petstore.swagger.io:80/v2" public static var credential: URLCredential? - public static var customHeaders: [String:String] = [:] + public static var customHeaders: [String: String] = [:] public static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory() } open class RequestBuilder { var credential: URLCredential? - var headers: [String:String] - public let parameters: [String:Any]? + var headers: [String: String] + public let parameters: [String: Any]? public let isBody: Bool public let method: String public let URLString: String /// Optional block to obtain a reference to the request's progress instance when available. - public var onProgressReady: ((Progress) -> ())? + public var onProgressReady: ((Progress) -> Void)? - required public init(method: String, URLString: String, parameters: [String:Any]?, isBody: Bool, headers: [String:String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { self.method = method self.URLString = URLString self.parameters = parameters @@ -34,7 +34,7 @@ open class RequestBuilder { addHeaders(PetstoreClientAPI.customHeaders) } - open func addHeaders(_ aHeaders:[String:String]) { + open func addHeaders(_ aHeaders: [String: String]) { for (header, value) in aHeaders { headers[header] = value } @@ -57,5 +57,5 @@ open class RequestBuilder { public protocol RequestBuilderFactory { func getNonDecodableBuilder() -> RequestBuilder.Type - func getBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift index ffecb66c48..30b346de0e 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class AnotherFakeAPI { /** To test special tags @@ -17,7 +15,7 @@ open class AnotherFakeAPI { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func call123testSpecialTags(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func call123testSpecialTags(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { call123testSpecialTagsWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift index 2bfd5a21d7..4198e76546 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class FakeAPI { /** creates an XmlItem @@ -17,7 +15,7 @@ open class FakeAPI { - parameter xmlItem: (body) XmlItem Body - parameter completion: completion handler to receive the data and the error objects */ - open class func createXmlItem(xmlItem: XmlItem, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createXmlItem(xmlItem: XmlItem, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createXmlItemWithRequestBuilder(xmlItem: xmlItem).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -51,7 +49,7 @@ open class FakeAPI { - parameter body: (body) Input boolean as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?,_ error: Error?) -> Void)) { + open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?, _ error: Error?) -> Void)) { fakeOuterBooleanSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -80,7 +78,7 @@ open class FakeAPI { - parameter body: (body) Input composite as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterCompositeSerialize(body: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?,_ error: Error?) -> Void)) { + open class func fakeOuterCompositeSerialize(body: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?, _ error: Error?) -> Void)) { fakeOuterCompositeSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -109,7 +107,7 @@ open class FakeAPI { - parameter body: (body) Input number as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?,_ error: Error?) -> Void)) { + open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?, _ error: Error?) -> Void)) { fakeOuterNumberSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -138,7 +136,7 @@ open class FakeAPI { - parameter body: (body) Input string as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { fakeOuterStringSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -167,7 +165,7 @@ open class FakeAPI { - parameter body: (body) - parameter completion: completion handler to receive the data and the error objects */ - open class func testBodyWithFileSchema(body: FileSchemaTestClass, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testBodyWithFileSchema(body: FileSchemaTestClass, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testBodyWithFileSchemaWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -201,7 +199,7 @@ open class FakeAPI { - parameter body: (body) - parameter completion: completion handler to receive the data and the error objects */ - open class func testBodyWithQueryParams(query: String, body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testBodyWithQueryParams(query: String, body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testBodyWithQueryParamsWithRequestBuilder(query: query, body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -238,7 +236,7 @@ open class FakeAPI { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClientModel(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClientModel(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClientModelWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -282,7 +280,7 @@ open class FakeAPI { - parameter callback: (form) None (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testEndpointParametersWithRequestBuilder(number: number, double: double, patternWithoutDelimiter: patternWithoutDelimiter, byte: byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -318,7 +316,7 @@ open class FakeAPI { open class func testEndpointParametersWithRequestBuilder(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "integer": integer?.encodeToJSON(), "int32": int32?.encodeToJSON(), "int64": int64?.encodeToJSON(), @@ -337,7 +335,7 @@ open class FakeAPI { let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -425,7 +423,7 @@ open class FakeAPI { - parameter enumFormString: (form) Form parameter enum test (string) (optional, default to .-efg) - parameter completion: completion handler to receive the data and the error objects */ - open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testEnumParametersWithRequestBuilder(enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -452,19 +450,19 @@ open class FakeAPI { open class func testEnumParametersWithRequestBuilder(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "enum_form_string_array": enumFormStringArray, "enum_form_string": enumFormString?.rawValue ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "enum_query_string_array": enumQueryStringArray, - "enum_query_string": enumQueryString?.rawValue, - "enum_query_integer": enumQueryInteger?.rawValue, + "enum_query_string_array": enumQueryStringArray, + "enum_query_string": enumQueryString?.rawValue, + "enum_query_integer": enumQueryInteger?.rawValue, "enum_query_double": enumQueryDouble?.rawValue ]) let nillableHeaders: [String: Any?] = [ @@ -489,7 +487,7 @@ open class FakeAPI { - parameter int64Group: (query) Integer in group parameters (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func testGroupParameters(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testGroupParameters(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testGroupParametersWithRequestBuilder(requiredStringGroup: requiredStringGroup, requiredBooleanGroup: requiredBooleanGroup, requiredInt64Group: requiredInt64Group, stringGroup: stringGroup, booleanGroup: booleanGroup, int64Group: int64Group).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -514,13 +512,13 @@ open class FakeAPI { open class func testGroupParametersWithRequestBuilder(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "required_string_group": requiredStringGroup.encodeToJSON(), - "required_int64_group": requiredInt64Group.encodeToJSON(), - "string_group": stringGroup?.encodeToJSON(), + "required_string_group": requiredStringGroup.encodeToJSON(), + "required_int64_group": requiredInt64Group.encodeToJSON(), + "string_group": stringGroup?.encodeToJSON(), "int64_group": int64Group?.encodeToJSON() ]) let nillableHeaders: [String: Any?] = [ @@ -540,7 +538,7 @@ open class FakeAPI { - parameter param: (body) request body - parameter completion: completion handler to receive the data and the error objects */ - open class func testInlineAdditionalProperties(param: [String:String], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testInlineAdditionalProperties(param: [String: String], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testInlineAdditionalPropertiesWithRequestBuilder(param: param).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -556,7 +554,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: RequestBuilder */ - open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String:String]) -> RequestBuilder { + open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String: String]) -> RequestBuilder { let path = "/fake/inline-additionalProperties" let URLString = PetstoreClientAPI.basePath + path let parameters = JSONEncodingHelper.encodingParameters(forEncodableObject: param) @@ -575,7 +573,7 @@ open class FakeAPI { - parameter param2: (form) field2 - parameter completion: completion handler to receive the data and the error objects */ - open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { testJsonFormDataWithRequestBuilder(param: param, param2: param2).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -595,14 +593,14 @@ open class FakeAPI { open class func testJsonFormDataWithRequestBuilder(param: String, param2: String) -> RequestBuilder { let path = "/fake/jsonFormData" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "param": param, "param2": param2 ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift index ddfeae23ed..6bfa09016f 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class FakeClassnameTags123API { /** To test class name in snake case @@ -17,7 +15,7 @@ open class FakeClassnameTags123API { - parameter body: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClassname(body: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClassname(body: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClassnameWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift index 0a5dfeb39b..896f151180 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class PetAPI { /** Add a new pet to the store @@ -17,7 +15,7 @@ open class PetAPI { - parameter body: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func addPet(body: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func addPet(body: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { addPetWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -55,7 +53,7 @@ open class PetAPI { - parameter apiKey: (header) (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deletePetWithRequestBuilder(petId: petId, apiKey: apiKey).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -81,8 +79,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let nillableHeaders: [String: Any?] = [ "api_key": apiKey @@ -109,7 +107,7 @@ open class PetAPI { - parameter status: (query) Status values that need to be considered for filter - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByStatusWithRequestBuilder(status: status).execute { (response, error) -> Void in completion(response?.body, error) } @@ -128,8 +126,8 @@ open class PetAPI { open class func findPetsByStatusWithRequestBuilder(status: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByStatus" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "status": status @@ -146,7 +144,7 @@ open class PetAPI { - parameter tags: (query) Tags to filter by - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByTagsWithRequestBuilder(tags: tags).execute { (response, error) -> Void in completion(response?.body, error) } @@ -165,8 +163,8 @@ open class PetAPI { open class func findPetsByTagsWithRequestBuilder(tags: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByTags" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "tags": tags @@ -183,7 +181,7 @@ open class PetAPI { - parameter petId: (path) ID of pet to return - parameter completion: completion handler to receive the data and the error objects */ - open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?,_ error: Error?) -> Void)) { + open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?, _ error: Error?) -> Void)) { getPetByIdWithRequestBuilder(petId: petId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -205,8 +203,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -220,7 +218,7 @@ open class PetAPI { - parameter body: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePet(body: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updatePet(body: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updatePetWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -259,7 +257,7 @@ open class PetAPI { - parameter status: (form) Updated status of the pet (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updatePetWithFormWithRequestBuilder(petId: petId, name: name, status: status).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -286,14 +284,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "name": name, "status": status ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -309,7 +307,7 @@ open class PetAPI { - parameter file: (form) file to upload (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?,_ error: Error?) -> Void)) { + open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?, _ error: Error?) -> Void)) { uploadFileWithRequestBuilder(petId: petId, additionalMetadata: additionalMetadata, file: file).execute { (response, error) -> Void in completion(response?.body, error) } @@ -332,14 +330,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "file": file ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -355,7 +353,7 @@ open class PetAPI { - parameter additionalMetadata: (form) Additional data to pass to server (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func uploadFileWithRequiredFile(petId: Int64, requiredFile: URL, additionalMetadata: String? = nil, completion: @escaping ((_ data: ApiResponse?,_ error: Error?) -> Void)) { + open class func uploadFileWithRequiredFile(petId: Int64, requiredFile: URL, additionalMetadata: String? = nil, completion: @escaping ((_ data: ApiResponse?, _ error: Error?) -> Void)) { uploadFileWithRequiredFileWithRequestBuilder(petId: petId, requiredFile: requiredFile, additionalMetadata: additionalMetadata).execute { (response, error) -> Void in completion(response?.body, error) } @@ -378,14 +376,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "requiredFile": requiredFile ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift index a2bced598f..71949b335d 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class StoreAPI { /** Delete purchase order by ID @@ -17,7 +15,7 @@ open class StoreAPI { - parameter orderId: (path) ID of the order that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deleteOrderWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -40,8 +38,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -54,7 +52,7 @@ open class StoreAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func getInventory(completion: @escaping ((_ data: [String:Int]?,_ error: Error?) -> Void)) { + open class func getInventory(completion: @escaping ((_ data: [String: Int]?, _ error: Error?) -> Void)) { getInventoryWithRequestBuilder().execute { (response, error) -> Void in completion(response?.body, error) } @@ -69,14 +67,14 @@ open class StoreAPI { - name: api_key - returns: RequestBuilder<[String:Int]> */ - open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String:Int]> { + open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String: Int]> { let path = "/store/inventory" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) - let requestBuilder: RequestBuilder<[String:Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() + let requestBuilder: RequestBuilder<[String: Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() return requestBuilder.init(method: "GET", URLString: (url?.string ?? URLString), parameters: parameters, isBody: false) } @@ -87,7 +85,7 @@ open class StoreAPI { - parameter orderId: (path) ID of pet that needs to be fetched - parameter completion: completion handler to receive the data and the error objects */ - open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { getOrderByIdWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -106,8 +104,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -121,7 +119,7 @@ open class StoreAPI { - parameter body: (body) order placed for purchasing the pet - parameter completion: completion handler to receive the data and the error objects */ - open class func placeOrder(body: Order, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func placeOrder(body: Order, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { placeOrderWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift index d8cafaf2c9..efeb64468a 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift @@ -8,8 +8,6 @@ import Foundation import Alamofire - - open class UserAPI { /** Create user @@ -17,7 +15,7 @@ open class UserAPI { - parameter body: (body) Created user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUser(body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUser(body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUserWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -52,7 +50,7 @@ open class UserAPI { - parameter body: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithArrayInput(body: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUsersWithArrayInput(body: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUsersWithArrayInputWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -86,7 +84,7 @@ open class UserAPI { - parameter body: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithListInput(body: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func createUsersWithListInput(body: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { createUsersWithListInputWithRequestBuilder(body: body).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -120,7 +118,7 @@ open class UserAPI { - parameter username: (path) The name that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteUser(username: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func deleteUser(username: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { deleteUserWithRequestBuilder(username: username).execute { (response, error) -> Void in if error == nil { completion((), error) @@ -143,8 +141,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -158,7 +156,7 @@ open class UserAPI { - parameter username: (path) The name that needs to be fetched. Use user1 for testing. - parameter completion: completion handler to receive the data and the error objects */ - open class func getUserByName(username: String, completion: @escaping ((_ data: User?,_ error: Error?) -> Void)) { + open class func getUserByName(username: String, completion: @escaping ((_ data: User?, _ error: Error?) -> Void)) { getUserByNameWithRequestBuilder(username: username).execute { (response, error) -> Void in completion(response?.body, error) } @@ -176,8 +174,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -192,7 +190,7 @@ open class UserAPI { - parameter password: (query) The password for login in clear text - parameter completion: completion handler to receive the data and the error objects */ - open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { loginUserWithRequestBuilder(username: username, password: password).execute { (response, error) -> Void in completion(response?.body, error) } @@ -209,11 +207,11 @@ open class UserAPI { open class func loginUserWithRequestBuilder(username: String, password: String) -> RequestBuilder { let path = "/user/login" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "username": username, + "username": username, "password": password ]) @@ -227,7 +225,7 @@ open class UserAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func logoutUser(completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func logoutUser(completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { logoutUserWithRequestBuilder().execute { (response, error) -> Void in if error == nil { completion((), error) @@ -245,8 +243,8 @@ open class UserAPI { open class func logoutUserWithRequestBuilder() -> RequestBuilder { let path = "/user/logout" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -261,7 +259,7 @@ open class UserAPI { - parameter body: (body) Updated user object - parameter completion: completion handler to receive the data and the error objects */ - open class func updateUser(username: String, body: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { + open class func updateUser(username: String, body: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { updateUserWithRequestBuilder(username: username, body: body).execute { (response, error) -> Void in if error == nil { completion((), error) diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift index dac40e9a31..04ad02a5ce 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift @@ -12,7 +12,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { return AlamofireRequestBuilder.self } - func getBuilder() -> RequestBuilder.Type { + func getBuilder() -> RequestBuilder.Type { return AlamofireDecodableRequestBuilder.self } } @@ -50,7 +50,7 @@ private struct SynchronizedDictionary { private var managerStore = SynchronizedDictionary() open class AlamofireRequestBuilder: RequestBuilder { - required public init(method: String, URLString: String, parameters: [String : Any]?, isBody: Bool, headers: [String : String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { super.init(method: method, URLString: URLString, parameters: parameters, isBody: isBody, headers: headers) } @@ -88,17 +88,17 @@ open class AlamofireRequestBuilder: RequestBuilder { May be overridden by a subclass if you want to control the request configuration (e.g. to override the cache policy). */ - open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String:String]) -> DataRequest { + open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) -> DataRequest { return manager.request(URLString, method: method, parameters: parameters, encoding: encoding, headers: headers) } override open func execute(_ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { - let managerId:String = UUID().uuidString + let managerId: String = UUID().uuidString // Create a new manager for each request to customize its request header let manager = createSessionManager() managerStore[managerId] = manager - let encoding:ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() + let encoding: ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() let xMethod = Alamofire.HTTPMethod(rawValue: method) let fileKeys = parameters == nil ? [] : parameters!.filter { $1 is NSURL } @@ -111,8 +111,7 @@ open class AlamofireRequestBuilder: RequestBuilder { case let fileURL as URL: if let mimeType = self.contentTypeForFormPart(fileURL: fileURL) { mpForm.append(fileURL, withName: k, fileName: fileURL.lastPathComponent, mimeType: mimeType) - } - else { + } else { mpForm.append(fileURL, withName: k) } case let string as String: @@ -276,7 +275,7 @@ open class AlamofireRequestBuilder: RequestBuilder { return httpHeaders } - fileprivate func getFileName(fromContentDisposition contentDisposition : String?) -> String? { + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { guard let contentDisposition = contentDisposition else { return nil @@ -284,7 +283,7 @@ open class AlamofireRequestBuilder: RequestBuilder { let items = contentDisposition.components(separatedBy: ";") - var filename : String? = nil + var filename: String? = nil for contentItem in items { @@ -304,7 +303,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getPath(from url : URL) throws -> String { + fileprivate func getPath(from url: URL) throws -> String { guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { throw DownloadException.requestMissingPath @@ -318,7 +317,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getURL(from urlRequest : URLRequest) throws -> URL { + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { guard let url = urlRequest.url else { throw DownloadException.requestMissingURL @@ -329,7 +328,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } -fileprivate enum DownloadException : Error { +private enum DownloadException: Error { case responseDataMissing case responseFailed case requestMissing @@ -344,7 +343,7 @@ public enum AlamofireDecodableRequestBuilderError: Error { case generalError(Error) } -open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { +open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { override fileprivate func processRequest(request: DataRequest, _ managerId: String, _ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { if let credential = self.credential { diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift index 584de8c3d5..111d5a3a8c 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift @@ -13,7 +13,7 @@ open class CodableHelper { public static var dateformatter: DateFormatter? - open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T : Decodable { + open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T: Decodable { var returnedDecodable: T? = nil var returnedError: Error? = nil @@ -39,7 +39,7 @@ open class CodableHelper { return (returnedDecodable, returnedError) } - open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T : Encodable { + open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T: Encodable { var returnedData: Data? var returnedError: Error? = nil diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Configuration.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Configuration.swift index 516590da5d..e1ecb39726 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Configuration.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Configuration.swift @@ -7,9 +7,9 @@ import Foundation open class Configuration { - + // This value is used to configure the date formatter that is used to serialize dates into JSON format. // You must set it prior to encoding any dates, and it will only be read once. public static var dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" - -} \ No newline at end of file + +} diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Extensions.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Extensions.swift index 8bf1829ba8..24c128daad 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Extensions.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Extensions.swift @@ -112,24 +112,24 @@ extension String: CodingKey { extension KeyedEncodingContainerProtocol { - public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { var arrayContainer = nestedUnkeyedContainer(forKey: key) try arrayContainer.encode(contentsOf: values) } - public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { if let values = values { try encodeArray(values, forKey: key) } } - public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T : Encodable { + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { for (key, value) in pairs { try encode(value, forKey: key) } } - public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T : Encodable { + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { if let pairs = pairs { try encodeMap(pairs) } @@ -139,7 +139,7 @@ extension KeyedEncodingContainerProtocol { extension KeyedDecodingContainerProtocol { - public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T : Decodable { + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { var tmpArray = [T]() var nestedContainer = try nestedUnkeyedContainer(forKey: key) @@ -151,7 +151,7 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T : Decodable { + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { var tmpArray: [T]? = nil if contains(key) { @@ -161,8 +161,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T : Decodable { - var map: [Self.Key : T] = [:] + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] for key in allKeys { if !excludedKeys.contains(key) { @@ -175,5 +175,3 @@ extension KeyedDecodingContainerProtocol { } } - - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift index 7044951584..3e68bb5d4a 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -10,7 +10,7 @@ import Alamofire open class JSONEncodingHelper { - open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { + open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { var params: Parameters? = nil // Encode the Encodable object @@ -39,5 +39,5 @@ open class JSONEncodingHelper { return params } - + } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models.swift index 4085638903..e87ce399c7 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models.swift @@ -10,7 +10,7 @@ protocol JSONEncodable { func encodeToJSON() -> Any } -public enum ErrorResponse : Error { +public enum ErrorResponse: Error { case error(Int, Data?, Error) } diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift index 796e46eca2..94295c495c 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesAnyType: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesAnyType: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Any] = [:] + public var additionalProperties: [String: Any] = [:] public subscript(key: String) -> Any? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesAnyType: Codable { additionalProperties = try container.decodeMap(Any.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift index 5e58839b5a..cde9824ddb 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesArray: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesArray: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Array] = [:] + public var additionalProperties: [String: Array] = [:] public subscript(key: String) -> Array? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesArray: Codable { additionalProperties = try container.decodeMap(Array.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift index d4c90829b4..76791a9ddd 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesBoolean: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesBoolean: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesBoolean: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift index 0e2263b14e..a4e11337fb 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift @@ -7,23 +7,21 @@ import Foundation - - public struct AdditionalPropertiesClass: Codable { - public var mapString: [String:String]? - public var mapNumber: [String:Double]? - public var mapInteger: [String:Int]? - public var mapBoolean: [String:Bool]? - public var mapArrayInteger: [String:[Int]]? - public var mapArrayAnytype: [String:[Any]]? - public var mapMapString: [String:[String:String]]? - public var mapMapAnytype: [String:[String:Any]]? + public var mapString: [String: String]? + public var mapNumber: [String: Double]? + public var mapInteger: [String: Int]? + public var mapBoolean: [String: Bool]? + public var mapArrayInteger: [String: [Int]]? + public var mapArrayAnytype: [String: [Any]]? + public var mapMapString: [String: [String: String]]? + public var mapMapAnytype: [String: [String: Any]]? public var anytype1: Any? public var anytype2: Any? public var anytype3: Any? - public init(mapString: [String:String]?, mapNumber: [String:Double]?, mapInteger: [String:Int]?, mapBoolean: [String:Bool]?, mapArrayInteger: [String:[Int]]?, mapArrayAnytype: [String:[Any]]?, mapMapString: [String:[String:String]]?, mapMapAnytype: [String:[String:Any]]?, anytype1: Any?, anytype2: Any?, anytype3: Any?) { + public init(mapString: [String: String]?, mapNumber: [String: Double]?, mapInteger: [String: Int]?, mapBoolean: [String: Bool]?, mapArrayInteger: [String: [Int]]?, mapArrayAnytype: [String: [Any]]?, mapMapString: [String: [String: String]]?, mapMapAnytype: [String: [String: Any]]?, anytype1: Any?, anytype2: Any?, anytype3: Any?) { self.mapString = mapString self.mapNumber = mapNumber self.mapInteger = mapInteger @@ -37,7 +35,7 @@ public struct AdditionalPropertiesClass: Codable { self.anytype3 = anytype3 } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapString = "map_string" case mapNumber = "map_number" case mapInteger = "map_integer" @@ -51,6 +49,4 @@ public struct AdditionalPropertiesClass: Codable { case anytype3 = "anytype_3" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift index b03bbe4456..4a0f2acaa4 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesInteger: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesInteger: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Int] = [:] + public var additionalProperties: [String: Int] = [:] public subscript(key: String) -> Int? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesInteger: Codable { additionalProperties = try container.decodeMap(Int.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift index 9701d54c9b..95e491000a 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesNumber: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesNumber: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Double] = [:] + public var additionalProperties: [String: Double] = [:] public subscript(key: String) -> Double? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesNumber: Codable { additionalProperties = try container.decodeMap(Double.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift index c6e1e670b8..f45888a410 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesObject: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesObject: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Dictionary] = [:] + public var additionalProperties: [String: Dictionary] = [:] public subscript(key: String) -> Dictionary? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesObject: Codable { additionalProperties = try container.decodeMap(Dictionary.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift index 6128dce7d4..7af63cc715 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesString: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesString: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:String] = [:] + public var additionalProperties: [String: String] = [:] public subscript(key: String) -> String? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesString: Codable { additionalProperties = try container.decodeMap(String.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift index 7221a1be09..5ed9f31e2a 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Animal: Codable { public var className: String @@ -19,6 +17,4 @@ public struct Animal: Codable { self.color = color } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift index e7bea63f8e..e09b0e9efd 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift @@ -7,5 +7,4 @@ import Foundation - public typealias AnimalFarm = [Animal] diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift index a22e9aaebb..ec270da890 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ApiResponse: Codable { public var code: Int? @@ -21,6 +19,4 @@ public struct ApiResponse: Codable { self.message = message } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift index 4e5a5ca144..3843287630 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfArrayOfNumberOnly: Codable { public var arrayArrayNumber: [[Double]]? @@ -17,10 +15,8 @@ public struct ArrayOfArrayOfNumberOnly: Codable { self.arrayArrayNumber = arrayArrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayArrayNumber = "ArrayArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift index 7d059d3683..f8b198e81f 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfNumberOnly: Codable { public var arrayNumber: [Double]? @@ -17,10 +15,8 @@ public struct ArrayOfNumberOnly: Codable { self.arrayNumber = arrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayNumber = "ArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift index 9c56fed50c..67f7f7e515 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayTest: Codable { public var arrayOfString: [String]? @@ -21,12 +19,10 @@ public struct ArrayTest: Codable { self.arrayArrayOfModel = arrayArrayOfModel } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayOfString = "array_of_string" case arrayArrayOfInteger = "array_array_of_integer" case arrayArrayOfModel = "array_array_of_model" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift index 98cda23dac..d576b50b1c 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Capitalization: Codable { public var smallCamel: String? @@ -28,7 +26,7 @@ public struct Capitalization: Codable { self.ATT_NAME = ATT_NAME } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case smallCamel case capitalCamel = "CapitalCamel" case smallSnake = "small_Snake" @@ -37,6 +35,4 @@ public struct Capitalization: Codable { case ATT_NAME } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift index 5675a05350..7d819cbcc8 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Cat: Codable { public var className: String @@ -26,6 +24,4 @@ public struct Cat: Codable { self.declawed = declawed } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift new file mode 100644 index 0000000000..a51ad0dffa --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift @@ -0,0 +1,18 @@ +// +// CatAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct CatAllOf: Codable { + + public var declawed: Bool? + + public init(declawed: Bool?) { + self.declawed = declawed + } + +} diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Category.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Category.swift index afdc89b6dd..abcd82b078 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Category.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Category.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Category: Codable { public var _id: Int64? @@ -19,11 +17,9 @@ public struct Category: Codable { self.name = name } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case name } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift index f673ed127c..28cb30ce7b 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model with \"_class\" property */ public struct ClassModel: Codable { @@ -18,6 +17,4 @@ public struct ClassModel: Codable { self._class = _class } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Client.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Client.swift index 51390b6c4e..00245ca372 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Client.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Client.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Client: Codable { public var client: String? @@ -17,6 +15,4 @@ public struct Client: Codable { self.client = client } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift index 239ce74dcc..492c122800 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Dog: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Dog: Codable { self.breed = breed } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift new file mode 100644 index 0000000000..7786f8acc5 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift @@ -0,0 +1,18 @@ +// +// DogAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct DogAllOf: Codable { + + public var breed: String? + + public init(breed: String?) { + self.breed = breed + } + +} diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift index 8713961520..5034ff0b8c 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumArrays: Codable { public enum JustSymbol: String, Codable { @@ -27,11 +25,9 @@ public struct EnumArrays: Codable { self.arrayEnum = arrayEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justSymbol = "just_symbol" case arrayEnum = "array_enum" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift index 7280a621fe..3c1dfcac57 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift @@ -7,7 +7,6 @@ import Foundation - public enum EnumClass: String, Codable { case abc = "_abc" case efg = "-efg" diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift index 0f546c76a2..6db9b34d18 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumTest: Codable { public enum EnumString: String, Codable { @@ -43,7 +41,7 @@ public struct EnumTest: Codable { self.outerEnum = outerEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case enumString = "enum_string" case enumStringRequired = "enum_string_required" case enumInteger = "enum_integer" @@ -51,6 +49,4 @@ public struct EnumTest: Codable { case outerEnum } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/File.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/File.swift index c8bd1f1958..ea3520f053 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/File.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/File.swift @@ -7,7 +7,6 @@ import Foundation - /** Must be named `File` for test. */ public struct File: Codable { @@ -19,6 +18,4 @@ public struct File: Codable { self.sourceURI = sourceURI } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift index 64d0250680..532f145793 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FileSchemaTestClass: Codable { public var file: File? @@ -19,6 +17,4 @@ public struct FileSchemaTestClass: Codable { self.files = files } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift index faa091b065..20bd6d103b 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FormatTest: Codable { public var integer: Int? @@ -41,6 +39,4 @@ public struct FormatTest: Codable { self.password = password } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift index 554aee1081..906ddb06fb 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct HasOnlyReadOnly: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct HasOnlyReadOnly: Codable { self.foo = foo } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/List.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/List.swift index 8997340ff4..08d5995387 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/List.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/List.swift @@ -7,8 +7,6 @@ import Foundation - - public struct List: Codable { public var _123list: String? @@ -17,10 +15,8 @@ public struct List: Codable { self._123list = _123list } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _123list = "123-list" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift index 392c1e4438..358ca7a58d 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift @@ -7,33 +7,29 @@ import Foundation - - public struct MapTest: Codable { public enum MapOfEnumString: String, Codable { case upper = "UPPER" case lower = "lower" } - public var mapMapOfString: [String:[String:String]]? - public var mapOfEnumString: [String:String]? - public var directMap: [String:Bool]? - public var indirectMap: [String:Bool]? + public var mapMapOfString: [String: [String: String]]? + public var mapOfEnumString: [String: String]? + public var directMap: [String: Bool]? + public var indirectMap: [String: Bool]? - public init(mapMapOfString: [String:[String:String]]?, mapOfEnumString: [String:String]?, directMap: [String:Bool]?, indirectMap: [String:Bool]?) { + public init(mapMapOfString: [String: [String: String]]?, mapOfEnumString: [String: String]?, directMap: [String: Bool]?, indirectMap: [String: Bool]?) { self.mapMapOfString = mapMapOfString self.mapOfEnumString = mapOfEnumString self.directMap = directMap self.indirectMap = indirectMap } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapMapOfString = "map_map_of_string" case mapOfEnumString = "map_of_enum_string" case directMap = "direct_map" case indirectMap = "indirect_map" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift index 7116108fd7..c3deb2f289 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift @@ -7,20 +7,16 @@ import Foundation - - public struct MixedPropertiesAndAdditionalPropertiesClass: Codable { public var uuid: UUID? public var dateTime: Date? - public var map: [String:Animal]? + public var map: [String: Animal]? - public init(uuid: UUID?, dateTime: Date?, map: [String:Animal]?) { + public init(uuid: UUID?, dateTime: Date?, map: [String: Animal]?) { self.uuid = uuid self.dateTime = dateTime self.map = map } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift index fc1d0606b7..7ed6aad907 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name starting with number */ public struct Model200Response: Codable { @@ -20,11 +19,9 @@ public struct Model200Response: Codable { self._class = _class } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case _class = "class" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Name.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Name.swift index cc165d767d..ce9ffe4fb3 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Name.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Name.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name same as property name */ public struct Name: Codable { @@ -24,13 +23,11 @@ public struct Name: Codable { self._123number = _123number } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case snakeCase = "snake_case" case property case _123number = "123Number" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift index e6fb206093..abd2269e8e 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct NumberOnly: Codable { public var justNumber: Double? @@ -17,10 +15,8 @@ public struct NumberOnly: Codable { self.justNumber = justNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justNumber = "JustNumber" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Order.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Order.swift index 5cad29458b..f2b7565e2d 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Order.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Order.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Order: Codable { public enum Status: String, Codable { @@ -33,7 +31,7 @@ public struct Order: Codable { self.complete = complete } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case petId case quantity @@ -42,6 +40,4 @@ public struct Order: Codable { case complete } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift index edc4523d9f..49aec001c5 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift @@ -7,8 +7,6 @@ import Foundation - - public struct OuterComposite: Codable { public var myNumber: Double? @@ -21,12 +19,10 @@ public struct OuterComposite: Codable { self.myBoolean = myBoolean } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case myNumber = "my_number" case myString = "my_string" case myBoolean = "my_boolean" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift index bd1643d279..9f80fc95ec 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift @@ -7,7 +7,6 @@ import Foundation - public enum OuterEnum: String, Codable { case placed = "placed" case approved = "approved" diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift index 3773bf5331..971ce9d4db 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Pet: Codable { public enum Status: String, Codable { @@ -33,7 +31,7 @@ public struct Pet: Codable { self.status = status } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case category case name @@ -42,6 +40,4 @@ public struct Pet: Codable { case status } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift index 48b655a5b0..0acd21fd10 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ReadOnlyFirst: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct ReadOnlyFirst: Codable { self.baz = baz } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Return.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Return.swift index de4b218999..076082af84 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Return.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Return.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing reserved words */ public struct Return: Codable { @@ -18,10 +17,8 @@ public struct Return: Codable { self._return = _return } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _return = "return" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift index 213d896ba9..e79fc45c0e 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift @@ -7,8 +7,6 @@ import Foundation - - public struct SpecialModelName: Codable { public var specialPropertyName: Int64? @@ -17,10 +15,8 @@ public struct SpecialModelName: Codable { self.specialPropertyName = specialPropertyName } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case specialPropertyName = "$special[property.name]" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift index ae15e87d94..3f1237fee4 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift @@ -7,12 +7,9 @@ import Foundation - - public struct StringBooleanMap: Codable { - - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -45,7 +42,4 @@ public struct StringBooleanMap: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift index 20f50efd3a..83efe72b8a 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Tag: Codable { public var _id: Int64? @@ -19,11 +17,9 @@ public struct Tag: Codable { self.name = name } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case name } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift index be1afdf026..bf0006e1a2 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderDefault: Codable { public var stringItem: String = "what" @@ -25,7 +23,7 @@ public struct TypeHolderDefault: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderDefault: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift index f46c8952e1..602a2a6d18 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderExample: Codable { public var stringItem: String @@ -25,7 +23,7 @@ public struct TypeHolderExample: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderExample: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/User.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/User.swift index d9c564d2a1..7d6b24b9e1 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/User.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/User.swift @@ -7,8 +7,6 @@ import Foundation - - public struct User: Codable { public var _id: Int64? @@ -32,7 +30,7 @@ public struct User: Codable { self.userStatus = userStatus } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case username case firstName @@ -43,6 +41,4 @@ public struct User: Codable { case userStatus } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift index e1b1ace8b1..aa01668350 100644 --- a/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift +++ b/samples/client/petstore/swift4/objcCompatible/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift @@ -7,8 +7,6 @@ import Foundation - - public struct XmlItem: Codable { public var attributeString: String? @@ -73,7 +71,7 @@ public struct XmlItem: Codable { self.prefixNsWrappedArray = prefixNsWrappedArray } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case attributeString = "attribute_string" case attributeNumber = "attribute_number" case attributeInteger = "attribute_integer" @@ -105,6 +103,4 @@ public struct XmlItem: Codable { case prefixNsWrappedArray = "prefix_ns_wrapped_array" } - } - diff --git a/samples/client/petstore/swift4/objcCompatible/README.md b/samples/client/petstore/swift4/objcCompatible/README.md index ac131d8fcd..8c1afe63fc 100644 --- a/samples/client/petstore/swift4/objcCompatible/README.md +++ b/samples/client/petstore/swift4/objcCompatible/README.md @@ -80,10 +80,12 @@ Class | Method | HTTP request | Description - [ArrayTest](docs/ArrayTest.md) - [Capitalization](docs/Capitalization.md) - [Cat](docs/Cat.md) + - [CatAllOf](docs/CatAllOf.md) - [Category](docs/Category.md) - [ClassModel](docs/ClassModel.md) - [Client](docs/Client.md) - [Dog](docs/Dog.md) + - [DogAllOf](docs/DogAllOf.md) - [EnumArrays](docs/EnumArrays.md) - [EnumClass](docs/EnumClass.md) - [EnumTest](docs/EnumTest.md) diff --git a/samples/client/petstore/swift4/objcCompatible/docs/CatAllOf.md b/samples/client/petstore/swift4/objcCompatible/docs/CatAllOf.md new file mode 100644 index 0000000000..79789be61c --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/docs/CatAllOf.md @@ -0,0 +1,10 @@ +# CatAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**declawed** | **Bool** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/objcCompatible/docs/DogAllOf.md b/samples/client/petstore/swift4/objcCompatible/docs/DogAllOf.md new file mode 100644 index 0000000000..9302ef52e9 --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/docs/DogAllOf.md @@ -0,0 +1,10 @@ +# DogAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**breed** | **String** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/objcCompatible/docs/UserAPI.md b/samples/client/petstore/swift4/objcCompatible/docs/UserAPI.md index 6a8e9dd372..18e233420a 100644 --- a/samples/client/petstore/swift4/objcCompatible/docs/UserAPI.md +++ b/samples/client/petstore/swift4/objcCompatible/docs/UserAPI.md @@ -95,7 +95,7 @@ UserAPI.createUsersWithArrayInput(body: body) { (response, error) in Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type @@ -143,7 +143,7 @@ UserAPI.createUsersWithListInput(body: body) { (response, error) in Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type diff --git a/samples/client/petstore/swift4/objcCompatible/project.yml b/samples/client/petstore/swift4/objcCompatible/project.yml new file mode 100644 index 0000000000..148b42517b --- /dev/null +++ b/samples/client/petstore/swift4/objcCompatible/project.yml @@ -0,0 +1,15 @@ +name: PetstoreClient +targets: + PetstoreClient: + type: framework + platform: iOS + deploymentTarget: "10.0" + sources: [PetstoreClient] + info: + path: ./Info.plist + version: 1.0.0 + settings: + APPLICATION_EXTENSION_API_ONLY: true + scheme: {} + dependencies: + - carthage: Alamofire diff --git a/samples/client/petstore/swift4/promisekit/.openapi-generator/VERSION b/samples/client/petstore/swift4/promisekit/.openapi-generator/VERSION index afa6365606..83a328a922 100644 --- a/samples/client/petstore/swift4/promisekit/.openapi-generator/VERSION +++ b/samples/client/petstore/swift4/promisekit/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.0-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/swift4/promisekit/Info.plist b/samples/client/petstore/swift4/promisekit/Info.plist new file mode 100644 index 0000000000..323e5ecfc4 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/Info.plist @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.pbxproj b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.pbxproj new file mode 100644 index 0000000000..89e8b9f238 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.pbxproj @@ -0,0 +1,577 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */; }; + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */; }; + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */; }; + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */ = {isa = PBXBuildFile; fileRef = C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */; }; + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */; }; + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */; }; + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */; }; + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */; }; + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */ = {isa = PBXBuildFile; fileRef = 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */; }; + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */; }; + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */; }; + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */; }; + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */; }; + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */; }; + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */ = {isa = PBXBuildFile; fileRef = 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */; }; + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */; }; + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */; }; + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */; }; + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */; }; + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */; }; + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */; }; + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */; }; + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */; }; + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */; }; + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */ = {isa = PBXBuildFile; fileRef = 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */; }; + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */; }; + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */; }; + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */; }; + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */; }; + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */ = {isa = PBXBuildFile; fileRef = A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */; }; + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */ = {isa = PBXBuildFile; fileRef = F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */; }; + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */; }; + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */ = {isa = PBXBuildFile; fileRef = A913A57E72D723632E9A718FF4525C81 /* Client.swift */; }; + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */; }; + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */; }; + A196B597ADCA20BEC280660B57FF7333 /* PromiseKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A586582C92491DF9C12D27E2CB7F0695 /* PromiseKit.framework */; }; + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */ = {isa = PBXBuildFile; fileRef = 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */; }; + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */ = {isa = PBXBuildFile; fileRef = B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */; }; + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */; }; + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */; }; + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */; }; + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */; }; + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */; }; + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7A6070F581E611FF44AFD40A4315C49A /* List.swift */; }; + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */; }; + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */; }; + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */; }; + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */ = {isa = PBXBuildFile; fileRef = C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */; }; + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */; }; + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */; }; + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */; }; + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */; }; + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */ = {isa = PBXBuildFile; fileRef = 386FD590658E90509C121118F057604D /* SpecialModelName.swift */; }; + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */ = {isa = PBXBuildFile; fileRef = B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */; }; + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8699F7966F748ED026A6FB4CF550442B /* Models.swift */; }; + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */ = {isa = PBXBuildFile; fileRef = C81447828475F76C5CF4F08AA65292F7 /* Return.swift */; }; + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */ = {isa = PBXBuildFile; fileRef = 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */; }; + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CodableHelper.swift; sourceTree = ""; }; + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumArrays.swift; sourceTree = ""; }; + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PetstoreClient.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderExample.swift; sourceTree = ""; }; + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Cat.swift; sourceTree = ""; }; + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Order.swift; sourceTree = ""; }; + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Configuration.swift; sourceTree = ""; }; + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FormatTest.swift; sourceTree = ""; }; + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodingHelper.swift; sourceTree = ""; }; + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIs.swift; sourceTree = ""; }; + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SpecialModelName.swift; sourceTree = ""; }; + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = File.swift; sourceTree = ""; }; + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesClass.swift; sourceTree = ""; }; + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CatAllOf.swift; sourceTree = ""; }; + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ClassModel.swift; sourceTree = ""; }; + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringBooleanMap.swift; sourceTree = ""; }; + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumClass.swift; sourceTree = ""; }; + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileSchemaTestClass.swift; sourceTree = ""; }; + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HasOnlyReadOnly.swift; sourceTree = ""; }; + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Name.swift; sourceTree = ""; }; + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeAPI.swift; sourceTree = ""; }; + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Category.swift; sourceTree = ""; }; + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReadOnlyFirst.swift; sourceTree = ""; }; + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MapTest.swift; sourceTree = ""; }; + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = List.swift; sourceTree = ""; }; + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfArrayOfNumberOnly.swift; sourceTree = ""; }; + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UserAPI.swift; sourceTree = ""; }; + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Model200Response.swift; sourceTree = ""; }; + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AlamofireImplementations.swift; sourceTree = ""; }; + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Models.swift; sourceTree = ""; }; + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIHelper.swift; sourceTree = ""; }; + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnimalFarm.swift; sourceTree = ""; }; + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Animal.swift; sourceTree = ""; }; + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodableEncoding.swift; sourceTree = ""; }; + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PetAPI.swift; sourceTree = ""; }; + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MixedPropertiesAndAdditionalPropertiesClass.swift; sourceTree = ""; }; + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnotherFakeAPI.swift; sourceTree = ""; }; + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DogAllOf.swift; sourceTree = ""; }; + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XmlItem.swift; sourceTree = ""; }; + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Alamofire.framework; sourceTree = ""; }; + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreAPI.swift; sourceTree = ""; }; + A586582C92491DF9C12D27E2CB7F0695 /* PromiseKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = PromiseKit.framework; sourceTree = ""; }; + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Capitalization.swift; sourceTree = ""; }; + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApiResponse.swift; sourceTree = ""; }; + A913A57E72D723632E9A718FF4525C81 /* Client.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Client.swift; sourceTree = ""; }; + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Tag.swift; sourceTree = ""; }; + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeClassnameTags123API.swift; sourceTree = ""; }; + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfNumberOnly.swift; sourceTree = ""; }; + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Extensions.swift; sourceTree = ""; }; + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NumberOnly.swift; sourceTree = ""; }; + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterEnum.swift; sourceTree = ""; }; + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Dog.swift; sourceTree = ""; }; + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Return.swift; sourceTree = ""; }; + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = User.swift; sourceTree = ""; }; + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderDefault.swift; sourceTree = ""; }; + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pet.swift; sourceTree = ""; }; + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayTest.swift; sourceTree = ""; }; + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterComposite.swift; sourceTree = ""; }; + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumTest.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */, + A196B597ADCA20BEC280660B57FF7333 /* PromiseKit.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */ = { + isa = PBXGroup; + children = ( + 7861EE241895128F64DD787367B3022D /* Carthage */, + ); + name = Frameworks; + sourceTree = ""; + }; + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */ = { + isa = PBXGroup; + children = ( + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */, + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */, + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */, + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */, + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */, + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */, + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */, + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */, + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */, + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */, + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */, + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */, + A913A57E72D723632E9A718FF4525C81 /* Client.swift */, + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */, + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */, + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */, + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */, + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */, + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */, + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */, + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */, + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */, + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */, + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */, + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */, + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */, + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */, + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */, + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */, + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */, + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */, + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */, + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */, + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */, + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */, + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */, + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */, + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */, + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */, + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */, + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */, + ); + path = Models; + sourceTree = ""; + }; + 5FBA6AE5F64CD737F88B4565AC3CCD3B = { + isa = PBXGroup; + children = ( + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */, + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */, + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */, + ); + sourceTree = ""; + }; + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */ = { + isa = PBXGroup; + children = ( + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */, + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */, + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */, + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */, + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */, + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */, + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */, + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */, + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */, + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */, + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */, + ); + path = OpenAPIs; + sourceTree = ""; + }; + 7861EE241895128F64DD787367B3022D /* Carthage */ = { + isa = PBXGroup; + children = ( + A012205B41CB71A62B86EECDEAFB0990 /* iOS */, + ); + name = Carthage; + path = Carthage/Build; + sourceTree = ""; + }; + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */ = { + isa = PBXGroup; + children = ( + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */, + ); + name = Products; + sourceTree = ""; + }; + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */ = { + isa = PBXGroup; + children = ( + EF4C81BDD734856ED5023B777D35098B /* Classes */, + ); + path = PetstoreClient; + sourceTree = ""; + }; + A012205B41CB71A62B86EECDEAFB0990 /* iOS */ = { + isa = PBXGroup; + children = ( + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */, + A586582C92491DF9C12D27E2CB7F0695 /* PromiseKit.framework */, + ); + path = iOS; + sourceTree = ""; + }; + EF4C81BDD734856ED5023B777D35098B /* Classes */ = { + isa = PBXGroup; + children = ( + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */, + ); + path = Classes; + sourceTree = ""; + }; + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */ = { + isa = PBXGroup; + children = ( + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */, + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */, + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */, + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */, + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */, + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */, + ); + path = APIs; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */ = { + isa = PBXNativeTarget; + buildConfigurationList = B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */; + buildPhases = ( + E539708354CE60FE486F81EDE56D13C8 /* Sources */, + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = PetstoreClient; + productName = PetstoreClient; + productReference = 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + E7D276EE2369D8C455513C2E05F9AED0 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1000; + }; + buildConfigurationList = ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 5FBA6AE5F64CD737F88B4565AC3CCD3B; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + E539708354CE60FE486F81EDE56D13C8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */, + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */, + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */, + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */, + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */, + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */, + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */, + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */, + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */, + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */, + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */, + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */, + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */, + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */, + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */, + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */, + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */, + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */, + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */, + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */, + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */, + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */, + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */, + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */, + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */, + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */, + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */, + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */, + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */, + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */, + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */, + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */, + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */, + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */, + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */, + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */, + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */, + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */, + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */, + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */, + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */, + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */, + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */, + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */, + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */, + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */, + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */, + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */, + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */, + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */, + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */, + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */, + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */, + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */, + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */, + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "$(inherited)", + "DEBUG=1", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 4.2; + }; + name = Debug; + }; + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 4.2; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */, + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = ""; + }; + ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */, + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = E7D276EE2369D8C455513C2E05F9AED0 /* Project object */; +} diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000000..919434a625 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme new file mode 100644 index 0000000000..7802e37945 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIHelper.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIHelper.swift index d94614b34f..75dea24395 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIHelper.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIHelper.swift @@ -7,7 +7,7 @@ import Foundation public struct APIHelper { - public static func rejectNil(_ source: [String:Any?]) -> [String:Any]? { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { let destination = source.reduce(into: [String: Any]()) { (result, item) in if let value = item.value { result[item.key] = value @@ -20,17 +20,17 @@ public struct APIHelper { return destination } - public static func rejectNilHeaders(_ source: [String:Any?]) -> [String:String] { + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { return source.reduce(into: [String: String]()) { (result, item) in if let collection = item.value as? Array { - result[item.key] = collection.filter({ $0 != nil }).map{ "\($0!)" }.joined(separator: ",") + result[item.key] = collection.filter({ $0 != nil }).map { "\($0!)" }.joined(separator: ",") } else if let value: Any = item.value { result[item.key] = "\(value)" } } } - public static func convertBoolToString(_ source: [String: Any]?) -> [String:Any]? { + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { guard let source = source else { return nil } @@ -52,7 +52,7 @@ public struct APIHelper { return source } - public static func mapValuesToQueryItems(_ source: [String:Any?]) -> [URLQueryItem]? { + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { let destination = source.filter({ $0.value != nil}).reduce(into: [URLQueryItem]()) { (result, item) in if let collection = item.value as? Array { let value = collection.filter({ $0 != nil }).map({"\($0!)"}).joined(separator: ",") @@ -68,4 +68,3 @@ public struct APIHelper { return destination } } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs.swift index 2890bffa27..9e4312f685 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs.swift @@ -9,22 +9,22 @@ import Foundation open class PetstoreClientAPI { public static var basePath = "http://petstore.swagger.io:80/v2" public static var credential: URLCredential? - public static var customHeaders: [String:String] = [:] + public static var customHeaders: [String: String] = [:] public static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory() } open class RequestBuilder { var credential: URLCredential? - var headers: [String:String] - public let parameters: [String:Any]? + var headers: [String: String] + public let parameters: [String: Any]? public let isBody: Bool public let method: String public let URLString: String /// Optional block to obtain a reference to the request's progress instance when available. - public var onProgressReady: ((Progress) -> ())? + public var onProgressReady: ((Progress) -> Void)? - required public init(method: String, URLString: String, parameters: [String:Any]?, isBody: Bool, headers: [String:String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { self.method = method self.URLString = URLString self.parameters = parameters @@ -34,7 +34,7 @@ open class RequestBuilder { addHeaders(PetstoreClientAPI.customHeaders) } - open func addHeaders(_ aHeaders:[String:String]) { + open func addHeaders(_ aHeaders: [String: String]) { for (header, value) in aHeaders { headers[header] = value } @@ -57,5 +57,5 @@ open class RequestBuilder { public protocol RequestBuilderFactory { func getNonDecodableBuilder() -> RequestBuilder.Type - func getBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type } diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift index 18204a2a75..2a2e7ab048 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class AnotherFakeAPI { /** To test special tags diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift index ed3c187e72..3fdda64aa2 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class FakeAPI { /** @@ -201,7 +199,7 @@ open class FakeAPI { - parameter body: (body) - returns: Promise */ - open class func testBodyWithQueryParams( query: String, body: User) -> Promise { + open class func testBodyWithQueryParams( query: String, body: User) -> Promise { let deferred = Promise.pending() testBodyWithQueryParamsWithRequestBuilder(query: query, body: body).execute { (response, error) -> Void in if let error = error { @@ -292,7 +290,7 @@ open class FakeAPI { - parameter callback: (form) None (optional) - returns: Promise */ - open class func testEndpointParameters( number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> Promise { + open class func testEndpointParameters( number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> Promise { let deferred = Promise.pending() testEndpointParametersWithRequestBuilder(number: number, double: double, patternWithoutDelimiter: patternWithoutDelimiter, byte: byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback).execute { (response, error) -> Void in if let error = error { @@ -330,7 +328,7 @@ open class FakeAPI { open class func testEndpointParametersWithRequestBuilder(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "integer": integer?.encodeToJSON(), "int32": int32?.encodeToJSON(), "int64": int64?.encodeToJSON(), @@ -349,7 +347,7 @@ open class FakeAPI { let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -437,7 +435,7 @@ open class FakeAPI { - parameter enumFormString: (form) Form parameter enum test (string) (optional, default to .-efg) - returns: Promise */ - open class func testEnumParameters( enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> Promise { + open class func testEnumParameters( enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> Promise { let deferred = Promise.pending() testEnumParametersWithRequestBuilder(enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString).execute { (response, error) -> Void in if let error = error { @@ -466,19 +464,19 @@ open class FakeAPI { open class func testEnumParametersWithRequestBuilder(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "enum_form_string_array": enumFormStringArray, "enum_form_string": enumFormString?.rawValue ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "enum_query_string_array": enumQueryStringArray, - "enum_query_string": enumQueryString?.rawValue, - "enum_query_integer": enumQueryInteger?.rawValue, + "enum_query_string_array": enumQueryStringArray, + "enum_query_string": enumQueryString?.rawValue, + "enum_query_integer": enumQueryInteger?.rawValue, "enum_query_double": enumQueryDouble?.rawValue ]) let nillableHeaders: [String: Any?] = [ @@ -503,7 +501,7 @@ open class FakeAPI { - parameter int64Group: (query) Integer in group parameters (optional) - returns: Promise */ - open class func testGroupParameters( requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> Promise { + open class func testGroupParameters( requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> Promise { let deferred = Promise.pending() testGroupParametersWithRequestBuilder(requiredStringGroup: requiredStringGroup, requiredBooleanGroup: requiredBooleanGroup, requiredInt64Group: requiredInt64Group, stringGroup: stringGroup, booleanGroup: booleanGroup, int64Group: int64Group).execute { (response, error) -> Void in if let error = error { @@ -530,13 +528,13 @@ open class FakeAPI { open class func testGroupParametersWithRequestBuilder(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "required_string_group": requiredStringGroup.encodeToJSON(), - "required_int64_group": requiredInt64Group.encodeToJSON(), - "string_group": stringGroup?.encodeToJSON(), + "required_string_group": requiredStringGroup.encodeToJSON(), + "required_int64_group": requiredInt64Group.encodeToJSON(), + "string_group": stringGroup?.encodeToJSON(), "int64_group": int64Group?.encodeToJSON() ]) let nillableHeaders: [String: Any?] = [ @@ -556,7 +554,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: Promise */ - open class func testInlineAdditionalProperties( param: [String:String]) -> Promise { + open class func testInlineAdditionalProperties( param: [String: String]) -> Promise { let deferred = Promise.pending() testInlineAdditionalPropertiesWithRequestBuilder(param: param).execute { (response, error) -> Void in if let error = error { @@ -574,7 +572,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: RequestBuilder */ - open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String:String]) -> RequestBuilder { + open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String: String]) -> RequestBuilder { let path = "/fake/inline-additionalProperties" let URLString = PetstoreClientAPI.basePath + path let parameters = JSONEncodingHelper.encodingParameters(forEncodableObject: param) @@ -593,7 +591,7 @@ open class FakeAPI { - parameter param2: (form) field2 - returns: Promise */ - open class func testJsonFormData( param: String, param2: String) -> Promise { + open class func testJsonFormData( param: String, param2: String) -> Promise { let deferred = Promise.pending() testJsonFormDataWithRequestBuilder(param: param, param2: param2).execute { (response, error) -> Void in if let error = error { @@ -615,14 +613,14 @@ open class FakeAPI { open class func testJsonFormDataWithRequestBuilder(param: String, param2: String) -> RequestBuilder { let path = "/fake/jsonFormData" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "param": param, "param2": param2 ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift index 51e1cd244b..a6bb118c58 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class FakeClassnameTags123API { /** To test class name in snake case diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift index 29fc9ba64f..a9c64e897b 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class PetAPI { /** Add a new pet to the store @@ -58,7 +56,7 @@ open class PetAPI { - parameter apiKey: (header) (optional) - returns: Promise */ - open class func deletePet( petId: Int64, apiKey: String? = nil) -> Promise { + open class func deletePet( petId: Int64, apiKey: String? = nil) -> Promise { let deferred = Promise.pending() deletePetWithRequestBuilder(petId: petId, apiKey: apiKey).execute { (response, error) -> Void in if let error = error { @@ -86,8 +84,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let nillableHeaders: [String: Any?] = [ "api_key": apiKey @@ -141,8 +139,8 @@ open class PetAPI { open class func findPetsByStatusWithRequestBuilder(status: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByStatus" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "status": status @@ -186,8 +184,8 @@ open class PetAPI { open class func findPetsByTagsWithRequestBuilder(tags: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByTags" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "tags": tags @@ -234,8 +232,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -290,7 +288,7 @@ open class PetAPI { - parameter status: (form) Updated status of the pet (optional) - returns: Promise */ - open class func updatePetWithForm( petId: Int64, name: String? = nil, status: String? = nil) -> Promise { + open class func updatePetWithForm( petId: Int64, name: String? = nil, status: String? = nil) -> Promise { let deferred = Promise.pending() updatePetWithFormWithRequestBuilder(petId: petId, name: name, status: status).execute { (response, error) -> Void in if let error = error { @@ -319,14 +317,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "name": name, "status": status ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -342,7 +340,7 @@ open class PetAPI { - parameter file: (form) file to upload (optional) - returns: Promise */ - open class func uploadFile( petId: Int64, additionalMetadata: String? = nil, file: URL? = nil) -> Promise { + open class func uploadFile( petId: Int64, additionalMetadata: String? = nil, file: URL? = nil) -> Promise { let deferred = Promise.pending() uploadFileWithRequestBuilder(petId: petId, additionalMetadata: additionalMetadata, file: file).execute { (response, error) -> Void in if let error = error { @@ -373,14 +371,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "file": file ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -396,7 +394,7 @@ open class PetAPI { - parameter additionalMetadata: (form) Additional data to pass to server (optional) - returns: Promise */ - open class func uploadFileWithRequiredFile( petId: Int64, requiredFile: URL, additionalMetadata: String? = nil) -> Promise { + open class func uploadFileWithRequiredFile( petId: Int64, requiredFile: URL, additionalMetadata: String? = nil) -> Promise { let deferred = Promise.pending() uploadFileWithRequiredFileWithRequestBuilder(petId: petId, requiredFile: requiredFile, additionalMetadata: additionalMetadata).execute { (response, error) -> Void in if let error = error { @@ -427,14 +425,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "requiredFile": requiredFile ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift index 2461befb0a..502f44af60 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class StoreAPI { /** Delete purchase order by ID @@ -43,8 +41,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -57,8 +55,8 @@ open class StoreAPI { - returns: Promise<[String:Int]> */ - open class func getInventory() -> Promise<[String:Int]> { - let deferred = Promise<[String:Int]>.pending() + open class func getInventory() -> Promise<[String: Int]> { + let deferred = Promise<[String: Int]>.pending() getInventoryWithRequestBuilder().execute { (response, error) -> Void in if let error = error { deferred.reject(error) @@ -80,14 +78,14 @@ open class StoreAPI { - name: api_key - returns: RequestBuilder<[String:Int]> */ - open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String:Int]> { + open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String: Int]> { let path = "/store/inventory" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) - let requestBuilder: RequestBuilder<[String:Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() + let requestBuilder: RequestBuilder<[String: Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() return requestBuilder.init(method: "GET", URLString: (url?.string ?? URLString), parameters: parameters, isBody: false) } @@ -125,8 +123,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift index a306c14e59..793c47447e 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import PromiseKit - - open class UserAPI { /** Create user @@ -152,8 +150,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -193,8 +191,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -209,7 +207,7 @@ open class UserAPI { - parameter password: (query) The password for login in clear text - returns: Promise */ - open class func loginUser( username: String, password: String) -> Promise { + open class func loginUser( username: String, password: String) -> Promise { let deferred = Promise.pending() loginUserWithRequestBuilder(username: username, password: password).execute { (response, error) -> Void in if let error = error { @@ -234,11 +232,11 @@ open class UserAPI { open class func loginUserWithRequestBuilder(username: String, password: String) -> RequestBuilder { let path = "/user/login" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "username": username, + "username": username, "password": password ]) @@ -272,8 +270,8 @@ open class UserAPI { open class func logoutUserWithRequestBuilder() -> RequestBuilder { let path = "/user/logout" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -288,7 +286,7 @@ open class UserAPI { - parameter body: (body) Updated user object - returns: Promise */ - open class func updateUser( username: String, body: User) -> Promise { + open class func updateUser( username: String, body: User) -> Promise { let deferred = Promise.pending() updateUserWithRequestBuilder(username: username, body: body).execute { (response, error) -> Void in if let error = error { diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift index dac40e9a31..04ad02a5ce 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift @@ -12,7 +12,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { return AlamofireRequestBuilder.self } - func getBuilder() -> RequestBuilder.Type { + func getBuilder() -> RequestBuilder.Type { return AlamofireDecodableRequestBuilder.self } } @@ -50,7 +50,7 @@ private struct SynchronizedDictionary { private var managerStore = SynchronizedDictionary() open class AlamofireRequestBuilder: RequestBuilder { - required public init(method: String, URLString: String, parameters: [String : Any]?, isBody: Bool, headers: [String : String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { super.init(method: method, URLString: URLString, parameters: parameters, isBody: isBody, headers: headers) } @@ -88,17 +88,17 @@ open class AlamofireRequestBuilder: RequestBuilder { May be overridden by a subclass if you want to control the request configuration (e.g. to override the cache policy). */ - open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String:String]) -> DataRequest { + open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) -> DataRequest { return manager.request(URLString, method: method, parameters: parameters, encoding: encoding, headers: headers) } override open func execute(_ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { - let managerId:String = UUID().uuidString + let managerId: String = UUID().uuidString // Create a new manager for each request to customize its request header let manager = createSessionManager() managerStore[managerId] = manager - let encoding:ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() + let encoding: ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() let xMethod = Alamofire.HTTPMethod(rawValue: method) let fileKeys = parameters == nil ? [] : parameters!.filter { $1 is NSURL } @@ -111,8 +111,7 @@ open class AlamofireRequestBuilder: RequestBuilder { case let fileURL as URL: if let mimeType = self.contentTypeForFormPart(fileURL: fileURL) { mpForm.append(fileURL, withName: k, fileName: fileURL.lastPathComponent, mimeType: mimeType) - } - else { + } else { mpForm.append(fileURL, withName: k) } case let string as String: @@ -276,7 +275,7 @@ open class AlamofireRequestBuilder: RequestBuilder { return httpHeaders } - fileprivate func getFileName(fromContentDisposition contentDisposition : String?) -> String? { + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { guard let contentDisposition = contentDisposition else { return nil @@ -284,7 +283,7 @@ open class AlamofireRequestBuilder: RequestBuilder { let items = contentDisposition.components(separatedBy: ";") - var filename : String? = nil + var filename: String? = nil for contentItem in items { @@ -304,7 +303,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getPath(from url : URL) throws -> String { + fileprivate func getPath(from url: URL) throws -> String { guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { throw DownloadException.requestMissingPath @@ -318,7 +317,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getURL(from urlRequest : URLRequest) throws -> URL { + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { guard let url = urlRequest.url else { throw DownloadException.requestMissingURL @@ -329,7 +328,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } -fileprivate enum DownloadException : Error { +private enum DownloadException: Error { case responseDataMissing case responseFailed case requestMissing @@ -344,7 +343,7 @@ public enum AlamofireDecodableRequestBuilderError: Error { case generalError(Error) } -open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { +open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { override fileprivate func processRequest(request: DataRequest, _ managerId: String, _ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { if let credential = self.credential { diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift index 584de8c3d5..111d5a3a8c 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift @@ -13,7 +13,7 @@ open class CodableHelper { public static var dateformatter: DateFormatter? - open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T : Decodable { + open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T: Decodable { var returnedDecodable: T? = nil var returnedError: Error? = nil @@ -39,7 +39,7 @@ open class CodableHelper { return (returnedDecodable, returnedError) } - open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T : Encodable { + open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T: Encodable { var returnedData: Data? var returnedError: Error? = nil diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Configuration.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Configuration.swift index 516590da5d..e1ecb39726 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Configuration.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Configuration.swift @@ -7,9 +7,9 @@ import Foundation open class Configuration { - + // This value is used to configure the date formatter that is used to serialize dates into JSON format. // You must set it prior to encoding any dates, and it will only be read once. public static var dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" - -} \ No newline at end of file + +} diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Extensions.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Extensions.swift index 97a90f9af4..d6202ace07 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Extensions.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Extensions.swift @@ -113,24 +113,24 @@ extension String: CodingKey { extension KeyedEncodingContainerProtocol { - public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { var arrayContainer = nestedUnkeyedContainer(forKey: key) try arrayContainer.encode(contentsOf: values) } - public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { if let values = values { try encodeArray(values, forKey: key) } } - public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T : Encodable { + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { for (key, value) in pairs { try encode(value, forKey: key) } } - public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T : Encodable { + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { if let pairs = pairs { try encodeMap(pairs) } @@ -140,7 +140,7 @@ extension KeyedEncodingContainerProtocol { extension KeyedDecodingContainerProtocol { - public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T : Decodable { + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { var tmpArray = [T]() var nestedContainer = try nestedUnkeyedContainer(forKey: key) @@ -152,7 +152,7 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T : Decodable { + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { var tmpArray: [T]? = nil if contains(key) { @@ -162,8 +162,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T : Decodable { - var map: [Self.Key : T] = [:] + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] for key in allKeys { if !excludedKeys.contains(key) { @@ -178,7 +178,7 @@ extension KeyedDecodingContainerProtocol { } extension RequestBuilder { - public func execute() -> Promise> { + public func execute() -> Promise> { let deferred = Promise>.pending() self.execute { (response: Response?, error: Error?) in if let response = response { diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift index 7044951584..3e68bb5d4a 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -10,7 +10,7 @@ import Alamofire open class JSONEncodingHelper { - open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { + open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { var params: Parameters? = nil // Encode the Encodable object @@ -39,5 +39,5 @@ open class JSONEncodingHelper { return params } - + } diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models.swift index 4085638903..e87ce399c7 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models.swift @@ -10,7 +10,7 @@ protocol JSONEncodable { func encodeToJSON() -> Any } -public enum ErrorResponse : Error { +public enum ErrorResponse: Error { case error(Int, Data?, Error) } diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift index 4db39adae8..83a06951cc 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift @@ -7,23 +7,19 @@ import Foundation - - public struct AdditionalPropertiesClass: Codable { - public var mapString: [String:String]? - public var mapMapString: [String:[String:String]]? + public var mapString: [String: String]? + public var mapMapString: [String: [String: String]]? - public init(mapString: [String:String]?, mapMapString: [String:[String:String]]?) { + public init(mapString: [String: String]?, mapMapString: [String: [String: String]]?) { self.mapString = mapString self.mapMapString = mapMapString } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapString = "map_string" case mapMapString = "map_map_string" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift index 7221a1be09..5ed9f31e2a 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Animal: Codable { public var className: String @@ -19,6 +17,4 @@ public struct Animal: Codable { self.color = color } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift index e7bea63f8e..e09b0e9efd 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift @@ -7,5 +7,4 @@ import Foundation - public typealias AnimalFarm = [Animal] diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift index a22e9aaebb..ec270da890 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ApiResponse: Codable { public var code: Int? @@ -21,6 +19,4 @@ public struct ApiResponse: Codable { self.message = message } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift index 4e5a5ca144..3843287630 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfArrayOfNumberOnly: Codable { public var arrayArrayNumber: [[Double]]? @@ -17,10 +15,8 @@ public struct ArrayOfArrayOfNumberOnly: Codable { self.arrayArrayNumber = arrayArrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayArrayNumber = "ArrayArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift index 7d059d3683..f8b198e81f 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfNumberOnly: Codable { public var arrayNumber: [Double]? @@ -17,10 +15,8 @@ public struct ArrayOfNumberOnly: Codable { self.arrayNumber = arrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayNumber = "ArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift index 9c56fed50c..67f7f7e515 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayTest: Codable { public var arrayOfString: [String]? @@ -21,12 +19,10 @@ public struct ArrayTest: Codable { self.arrayArrayOfModel = arrayArrayOfModel } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayOfString = "array_of_string" case arrayArrayOfInteger = "array_array_of_integer" case arrayArrayOfModel = "array_array_of_model" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift index 98cda23dac..d576b50b1c 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Capitalization: Codable { public var smallCamel: String? @@ -28,7 +26,7 @@ public struct Capitalization: Codable { self.ATT_NAME = ATT_NAME } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case smallCamel case capitalCamel = "CapitalCamel" case smallSnake = "small_Snake" @@ -37,6 +35,4 @@ public struct Capitalization: Codable { case ATT_NAME } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift index a116d964ea..7ab887f311 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Cat: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Cat: Codable { self.declawed = declawed } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift new file mode 100644 index 0000000000..a51ad0dffa --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift @@ -0,0 +1,18 @@ +// +// CatAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct CatAllOf: Codable { + + public var declawed: Bool? + + public init(declawed: Bool?) { + self.declawed = declawed + } + +} diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Category.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Category.swift index e8c489be46..eb8f7e5e19 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Category.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Category.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Category: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Category: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift index f673ed127c..28cb30ce7b 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model with \"_class\" property */ public struct ClassModel: Codable { @@ -18,6 +17,4 @@ public struct ClassModel: Codable { self._class = _class } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Client.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Client.swift index 51390b6c4e..00245ca372 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Client.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Client.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Client: Codable { public var client: String? @@ -17,6 +15,4 @@ public struct Client: Codable { self.client = client } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift index 239ce74dcc..492c122800 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Dog: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Dog: Codable { self.breed = breed } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift new file mode 100644 index 0000000000..7786f8acc5 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift @@ -0,0 +1,18 @@ +// +// DogAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct DogAllOf: Codable { + + public var breed: String? + + public init(breed: String?) { + self.breed = breed + } + +} diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift index 8713961520..5034ff0b8c 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumArrays: Codable { public enum JustSymbol: String, Codable { @@ -27,11 +25,9 @@ public struct EnumArrays: Codable { self.arrayEnum = arrayEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justSymbol = "just_symbol" case arrayEnum = "array_enum" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift index 7280a621fe..3c1dfcac57 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift @@ -7,7 +7,6 @@ import Foundation - public enum EnumClass: String, Codable { case abc = "_abc" case efg = "-efg" diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift index 0f546c76a2..6db9b34d18 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumTest: Codable { public enum EnumString: String, Codable { @@ -43,7 +41,7 @@ public struct EnumTest: Codable { self.outerEnum = outerEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case enumString = "enum_string" case enumStringRequired = "enum_string_required" case enumInteger = "enum_integer" @@ -51,6 +49,4 @@ public struct EnumTest: Codable { case outerEnum } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/File.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/File.swift index c8bd1f1958..ea3520f053 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/File.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/File.swift @@ -7,7 +7,6 @@ import Foundation - /** Must be named `File` for test. */ public struct File: Codable { @@ -19,6 +18,4 @@ public struct File: Codable { self.sourceURI = sourceURI } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift index 64d0250680..532f145793 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FileSchemaTestClass: Codable { public var file: File? @@ -19,6 +17,4 @@ public struct FileSchemaTestClass: Codable { self.files = files } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift index faa091b065..20bd6d103b 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FormatTest: Codable { public var integer: Int? @@ -41,6 +39,4 @@ public struct FormatTest: Codable { self.password = password } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift index 554aee1081..906ddb06fb 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct HasOnlyReadOnly: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct HasOnlyReadOnly: Codable { self.foo = foo } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/List.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/List.swift index 8997340ff4..08d5995387 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/List.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/List.swift @@ -7,8 +7,6 @@ import Foundation - - public struct List: Codable { public var _123list: String? @@ -17,10 +15,8 @@ public struct List: Codable { self._123list = _123list } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _123list = "123-list" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift index 2d3a45d35a..3a10a7dfca 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift @@ -7,33 +7,29 @@ import Foundation - - public struct MapTest: Codable { public enum MapOfEnumString: String, Codable { case upper = "UPPER" case lower = "lower" } - public var mapMapOfString: [String:[String:String]]? - public var mapOfEnumString: [String:String]? - public var directMap: [String:Bool]? + public var mapMapOfString: [String: [String: String]]? + public var mapOfEnumString: [String: String]? + public var directMap: [String: Bool]? public var indirectMap: StringBooleanMap? - public init(mapMapOfString: [String:[String:String]]?, mapOfEnumString: [String:String]?, directMap: [String:Bool]?, indirectMap: StringBooleanMap?) { + public init(mapMapOfString: [String: [String: String]]?, mapOfEnumString: [String: String]?, directMap: [String: Bool]?, indirectMap: StringBooleanMap?) { self.mapMapOfString = mapMapOfString self.mapOfEnumString = mapOfEnumString self.directMap = directMap self.indirectMap = indirectMap } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapMapOfString = "map_map_of_string" case mapOfEnumString = "map_of_enum_string" case directMap = "direct_map" case indirectMap = "indirect_map" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift index 7116108fd7..c3deb2f289 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift @@ -7,20 +7,16 @@ import Foundation - - public struct MixedPropertiesAndAdditionalPropertiesClass: Codable { public var uuid: UUID? public var dateTime: Date? - public var map: [String:Animal]? + public var map: [String: Animal]? - public init(uuid: UUID?, dateTime: Date?, map: [String:Animal]?) { + public init(uuid: UUID?, dateTime: Date?, map: [String: Animal]?) { self.uuid = uuid self.dateTime = dateTime self.map = map } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift index fc1d0606b7..7ed6aad907 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name starting with number */ public struct Model200Response: Codable { @@ -20,11 +19,9 @@ public struct Model200Response: Codable { self._class = _class } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case _class = "class" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Name.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Name.swift index cc165d767d..ce9ffe4fb3 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Name.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Name.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name same as property name */ public struct Name: Codable { @@ -24,13 +23,11 @@ public struct Name: Codable { self._123number = _123number } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case snakeCase = "snake_case" case property case _123number = "123Number" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift index e6fb206093..abd2269e8e 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct NumberOnly: Codable { public var justNumber: Double? @@ -17,10 +15,8 @@ public struct NumberOnly: Codable { self.justNumber = justNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justNumber = "JustNumber" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Order.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Order.swift index 83c3b85e66..a6e1b1d2e5 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Order.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Order.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Order: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Order: Codable { self.complete = complete } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift index edc4523d9f..49aec001c5 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift @@ -7,8 +7,6 @@ import Foundation - - public struct OuterComposite: Codable { public var myNumber: Double? @@ -21,12 +19,10 @@ public struct OuterComposite: Codable { self.myBoolean = myBoolean } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case myNumber = "my_number" case myString = "my_string" case myBoolean = "my_boolean" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift index bd1643d279..9f80fc95ec 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift @@ -7,7 +7,6 @@ import Foundation - public enum OuterEnum: String, Codable { case placed = "placed" case approved = "approved" diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift index 5e39abae6c..af60a550bb 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Pet: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Pet: Codable { self.status = status } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift index 48b655a5b0..0acd21fd10 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ReadOnlyFirst: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct ReadOnlyFirst: Codable { self.baz = baz } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Return.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Return.swift index de4b218999..076082af84 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Return.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Return.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing reserved words */ public struct Return: Codable { @@ -18,10 +17,8 @@ public struct Return: Codable { self._return = _return } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _return = "return" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift index 213d896ba9..e79fc45c0e 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift @@ -7,8 +7,6 @@ import Foundation - - public struct SpecialModelName: Codable { public var specialPropertyName: Int64? @@ -17,10 +15,8 @@ public struct SpecialModelName: Codable { self.specialPropertyName = specialPropertyName } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case specialPropertyName = "$special[property.name]" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift index ae15e87d94..3f1237fee4 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift @@ -7,12 +7,9 @@ import Foundation - - public struct StringBooleanMap: Codable { - - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -45,7 +42,4 @@ public struct StringBooleanMap: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift index 32ee33a1a1..4dd8a9a9f5 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Tag: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Tag: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift index be1afdf026..bf0006e1a2 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderDefault: Codable { public var stringItem: String = "what" @@ -25,7 +23,7 @@ public struct TypeHolderDefault: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderDefault: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift index f46c8952e1..602a2a6d18 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderExample: Codable { public var stringItem: String @@ -25,7 +23,7 @@ public struct TypeHolderExample: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderExample: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/User.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/User.swift index a61b584420..79f271ed73 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/User.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/User.swift @@ -7,8 +7,6 @@ import Foundation - - public struct User: Codable { public var id: Int64? @@ -32,6 +30,4 @@ public struct User: Codable { self.userStatus = userStatus } - } - diff --git a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift index e1b1ace8b1..aa01668350 100644 --- a/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift +++ b/samples/client/petstore/swift4/promisekit/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift @@ -7,8 +7,6 @@ import Foundation - - public struct XmlItem: Codable { public var attributeString: String? @@ -73,7 +71,7 @@ public struct XmlItem: Codable { self.prefixNsWrappedArray = prefixNsWrappedArray } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case attributeString = "attribute_string" case attributeNumber = "attribute_number" case attributeInteger = "attribute_integer" @@ -105,6 +103,4 @@ public struct XmlItem: Codable { case prefixNsWrappedArray = "prefix_ns_wrapped_array" } - } - diff --git a/samples/client/petstore/swift4/promisekit/README.md b/samples/client/petstore/swift4/promisekit/README.md index 1e7f0a59ea..0711eb8705 100644 --- a/samples/client/petstore/swift4/promisekit/README.md +++ b/samples/client/petstore/swift4/promisekit/README.md @@ -73,10 +73,12 @@ Class | Method | HTTP request | Description - [ArrayTest](docs/ArrayTest.md) - [Capitalization](docs/Capitalization.md) - [Cat](docs/Cat.md) + - [CatAllOf](docs/CatAllOf.md) - [Category](docs/Category.md) - [ClassModel](docs/ClassModel.md) - [Client](docs/Client.md) - [Dog](docs/Dog.md) + - [DogAllOf](docs/DogAllOf.md) - [EnumArrays](docs/EnumArrays.md) - [EnumClass](docs/EnumClass.md) - [EnumTest](docs/EnumTest.md) diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift index 2fcc05ca06..a411b77491 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift @@ -135,8 +135,7 @@ public func request( parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest -{ + -> DataRequest { return SessionManager.default.request( url, method: method, @@ -183,8 +182,7 @@ public func download( encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download( url, method: method, @@ -209,8 +207,7 @@ public func download( public func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(urlRequest, to: destination) } @@ -239,8 +236,7 @@ public func download( public func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(resumingWith: resumeData, to: destination) } @@ -263,8 +259,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(fileURL, to: url, method: method, headers: headers) } @@ -297,8 +292,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(data, to: url, method: method, headers: headers) } @@ -331,8 +325,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(stream, to: url, method: method, headers: headers) } @@ -379,8 +372,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, @@ -416,8 +408,7 @@ public func upload( multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift index 057e68b977..85a0685748 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift @@ -275,8 +275,7 @@ open class MultipartFormData { } bodyContentLength = fileSize.uint64Value - } - catch { + } catch { setBodyPartError(withReason: .bodyPartFileSizeQueryFailedWithError(forURL: fileURL, error: error)) return } @@ -312,8 +311,7 @@ open class MultipartFormData { withLength length: UInt64, name: String, fileName: String, - mimeType: String) - { + mimeType: String) { let headers = contentHeaders(withName: name, fileName: fileName, mimeType: mimeType) append(stream, withLength: length, headers: headers) } diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift index 3ff2e7fc27..60bda83d2f 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift @@ -146,8 +146,7 @@ open class NetworkReachabilityManager { context.info = Unmanaged.passUnretained(self).toOpaque() let callbackEnabled = SCNetworkReachabilitySetCallback( - reachability, - { (_, flags, info) in + reachability, { (_, flags, info) in let reachability = Unmanaged.fromOpaque(info!).takeUnretainedValue() reachability.notifyListener(flags) }, @@ -216,8 +215,7 @@ extension NetworkReachabilityManager.NetworkReachabilityStatus: Equatable {} public func ==( lhs: NetworkReachabilityManager.NetworkReachabilityStatus, rhs: NetworkReachabilityManager.NetworkReachabilityStatus) - -> Bool -{ + -> Bool { switch (lhs, rhs) { case (.unknown, .unknown): return true diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift index 4a54f2dd00..344a048cad 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift @@ -435,8 +435,7 @@ public struct PropertyListEncoding: ParameterEncoding { /// - returns: The new `PropertyListEncoding` instance. public init( format: PropertyListSerialization.PropertyListFormat = .xml, - options: PropertyListSerialization.WriteOptions = 0) - { + options: PropertyListSerialization.WriteOptions = 0) { self.format = format self.options = options } diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Request.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Request.swift index ea43411377..18b83a0e73 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Request.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Request.swift @@ -161,8 +161,7 @@ open class Request { user: String, password: String, persistence: URLCredential.Persistence = .forSession) - -> Self - { + -> Self { let credential = URLCredential(user: user, password: password, persistence: persistence) return authenticate(usingCredential: credential) } @@ -538,8 +537,7 @@ open class DownloadRequest: Request { open class func suggestedDownloadDestination( for directory: FileManager.SearchPathDirectory = .documentDirectory, in domain: FileManager.SearchPathDomainMask = .userDomainMask) - -> DownloadFileDestination - { + -> DownloadFileDestination { return { temporaryURL, response in let directoryURLs = FileManager.default.urls(for: directory, in: domain) diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Response.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Response.swift index 74b1ef54d0..23571383ba 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Response.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Response.swift @@ -58,8 +58,7 @@ public struct DefaultDataResponse { data: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.data = data @@ -109,8 +108,7 @@ public struct DataResponse { response: HTTPURLResponse?, data: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.data = data @@ -296,8 +294,7 @@ public struct DefaultDownloadResponse { resumeData: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.temporaryURL = temporaryURL @@ -359,8 +356,7 @@ public struct DownloadResponse { destinationURL: URL?, resumeData: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.temporaryURL = temporaryURL diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift index 3333726d5c..fd049edac1 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift @@ -144,8 +144,7 @@ extension DataRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -182,8 +181,7 @@ extension DownloadRequest { public func response( queue: DispatchQueue? = nil, completionHandler: @escaping (DefaultDownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { (queue ?? DispatchQueue.main).async { var downloadResponse = DefaultDownloadResponse( @@ -218,8 +216,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -289,8 +286,7 @@ extension DataRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.dataResponseSerializer(), @@ -329,8 +325,7 @@ extension DownloadRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.dataResponseSerializer(), @@ -356,8 +351,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success("") } @@ -411,8 +405,7 @@ extension DataRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.stringResponseSerializer(encoding: encoding), @@ -459,8 +452,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.stringResponseSerializer(encoding: encoding), @@ -486,8 +478,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -514,8 +505,7 @@ extension DataRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponseJSON(options: options, response: response, data: data, error: error) } @@ -532,8 +522,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.jsonResponseSerializer(options: options), @@ -551,8 +540,7 @@ extension DownloadRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -580,8 +568,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.jsonResponseSerializer(options: options), @@ -607,8 +594,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -635,8 +621,7 @@ extension DataRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponsePropertyList(options: options, response: response, data: data, error: error) } @@ -653,8 +638,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.propertyListResponseSerializer(options: options), @@ -672,8 +656,7 @@ extension DownloadRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -701,8 +684,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.propertyListResponseSerializer(options: options), diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift index 7f44c8d2c6..d50e941fab 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift @@ -249,7 +249,6 @@ public enum ServerTrustPolicy { let unspecified = SecTrustResultType.unspecified let proceed = SecTrustResultType.proceed - isValid = result == unspecified || result == proceed } diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift index 03bcb7ced6..17d0d9f150 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift @@ -255,8 +255,7 @@ extension SessionDelegate: URLSessionDelegate { open func urlSession( _ session: URLSession, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard sessionDidReceiveChallengeWithCompletion == nil else { sessionDidReceiveChallengeWithCompletion?(session, challenge, completionHandler) return @@ -315,8 +314,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { guard taskWillPerformHTTPRedirectionWithCompletion == nil else { taskWillPerformHTTPRedirectionWithCompletion?(session, task, response, request, completionHandler) return @@ -342,8 +340,7 @@ extension SessionDelegate: URLSessionTaskDelegate { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard taskDidReceiveChallengeWithCompletion == nil else { taskDidReceiveChallengeWithCompletion?(session, task, challenge, completionHandler) return @@ -372,8 +369,7 @@ extension SessionDelegate: URLSessionTaskDelegate { open func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { guard taskNeedNewBodyStreamWithCompletion == nil else { taskNeedNewBodyStreamWithCompletion?(session, task, completionHandler) return @@ -398,8 +394,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if let taskDidSendBodyData = taskDidSendBodyData { taskDidSendBodyData(session, task, bytesSent, totalBytesSent, totalBytesExpectedToSend) } else if let delegate = self[task]?.delegate as? UploadTaskDelegate { @@ -512,8 +507,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { guard dataTaskDidReceiveResponseWithCompletion == nil else { dataTaskDidReceiveResponseWithCompletion?(session, dataTask, response, completionHandler) return @@ -536,8 +530,7 @@ extension SessionDelegate: URLSessionDataDelegate { open func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { if let dataTaskDidBecomeDownloadTask = dataTaskDidBecomeDownloadTask { dataTaskDidBecomeDownloadTask(session, dataTask, downloadTask) } else { @@ -573,8 +566,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { guard dataTaskWillCacheResponseWithCompletion == nil else { dataTaskWillCacheResponseWithCompletion?(session, dataTask, proposedResponse, completionHandler) return @@ -608,8 +600,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { open func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { if let downloadTaskDidFinishDownloadingToURL = downloadTaskDidFinishDownloadingToURL { downloadTaskDidFinishDownloadingToURL(session, downloadTask, location) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -632,8 +623,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if let downloadTaskDidWriteData = downloadTaskDidWriteData { downloadTaskDidWriteData(session, downloadTask, bytesWritten, totalBytesWritten, totalBytesExpectedToWrite) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -661,8 +651,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -716,8 +705,7 @@ extension SessionDelegate: URLSessionStreamDelegate { _ session: URLSession, streamTask: URLSessionStreamTask, didBecome inputStream: InputStream, - outputStream: OutputStream) - { + outputStream: OutputStream) { streamTaskDidBecomeInputAndOutputStreams?(session, streamTask, inputStream, outputStream) } } diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift index 8779efdaa6..8c10706677 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift @@ -166,8 +166,7 @@ open class SessionManager { public init( configuration: URLSessionConfiguration = URLSessionConfiguration.default, delegate: SessionDelegate = SessionDelegate(), - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { self.delegate = delegate self.session = URLSession(configuration: configuration, delegate: delegate, delegateQueue: nil) @@ -185,8 +184,7 @@ open class SessionManager { public init?( session: URLSession, delegate: SessionDelegate, - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { guard delegate === session.delegate else { return nil } self.delegate = delegate @@ -229,8 +227,7 @@ open class SessionManager { parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest - { + -> DataRequest { var originalRequest: URLRequest? do { @@ -320,8 +317,7 @@ open class SessionManager { encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) let encodedURLRequest = try encoding.encode(urlRequest, with: parameters) @@ -347,8 +343,7 @@ open class SessionManager { open func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try urlRequest.asURLRequest() return download(.request(urlRequest), to: destination) @@ -384,8 +379,7 @@ open class SessionManager { open func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { return download(.resumeData(resumeData), to: destination) } @@ -394,8 +388,7 @@ open class SessionManager { private func download( _ downloadable: DownloadRequest.Downloadable, to destination: DownloadRequest.DownloadFileDestination?) - -> DownloadRequest - { + -> DownloadRequest { do { let task = try downloadable.task(session: session, adapter: adapter, queue: queue) let download = DownloadRequest(session: session, requestTask: .download(downloadable, task)) @@ -416,8 +409,7 @@ open class SessionManager { _ downloadable: DownloadRequest.Downloadable?, to destination: DownloadRequest.DownloadFileDestination?, failedWith error: Error) - -> DownloadRequest - { + -> DownloadRequest { var downloadTask: Request.RequestTask = .download(nil, nil) if let downloadable = downloadable { @@ -458,8 +450,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(fileURL, with: urlRequest) @@ -504,8 +495,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(data, with: urlRequest) @@ -550,8 +540,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(stream, with: urlRequest) @@ -611,8 +600,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) @@ -654,8 +642,7 @@ open class SessionManager { multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { DispatchQueue.global(qos: .utility).async { let formData = MultipartFormData() multipartFormData(formData) diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift index 8e19888fc8..12fcbe92d3 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift @@ -94,8 +94,7 @@ open class TaskDelegate: NSObject { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { var redirectRequest: URLRequest? = request if let taskWillPerformHTTPRedirection = taskWillPerformHTTPRedirection { @@ -110,8 +109,7 @@ open class TaskDelegate: NSObject { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { var disposition: URLSession.AuthChallengeDisposition = .performDefaultHandling var credential: URLCredential? @@ -150,8 +148,7 @@ open class TaskDelegate: NSObject { func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { var bodyStream: InputStream? if let taskNeedNewBodyStream = taskNeedNewBodyStream { @@ -237,8 +234,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { var disposition: URLSession.ResponseDisposition = .allow expectedContentLength = response.expectedContentLength @@ -253,8 +249,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { dataTaskDidBecomeDownloadTask?(session, dataTask, downloadTask) } @@ -287,8 +282,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { var cachedResponse: CachedURLResponse? = proposedResponse if let dataTaskWillCacheResponse = dataTaskWillCacheResponse { @@ -343,8 +337,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { temporaryURL = location guard @@ -379,8 +372,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let downloadTaskDidWriteData = downloadTaskDidWriteData { @@ -405,8 +397,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else { @@ -448,8 +439,7 @@ class UploadTaskDelegate: DataTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let taskDidSendBodyData = taskDidSendBodyData { diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift index 181c9883cb..b318b1ff48 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift @@ -64,8 +64,7 @@ public struct Timeline { requestStartTime: CFAbsoluteTime = 0.0, initialResponseTime: CFAbsoluteTime = 0.0, requestCompletedTime: CFAbsoluteTime = 0.0, - serializationCompletedTime: CFAbsoluteTime = 0.0) - { + serializationCompletedTime: CFAbsoluteTime = 0.0) { self.requestStartTime = requestStartTime self.initialResponseTime = initialResponseTime self.requestCompletedTime = requestCompletedTime diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift index ec2c5c35a0..deaee34ad8 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift @@ -94,8 +94,7 @@ extension Request { statusCode acceptableStatusCodes: S, response: HTTPURLResponse) -> ValidationResult - where S.Iterator.Element == Int - { + where S.Iterator.Element == Int { if acceptableStatusCodes.contains(response.statusCode) { return .success } else { @@ -111,8 +110,7 @@ extension Request { response: HTTPURLResponse, data: Data?) -> ValidationResult - where S.Iterator.Element == String - { + where S.Iterator.Element == String { guard let data = data, data.count > 0 else { return .success } guard diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/AnyPromise.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/AnyPromise.swift index 843f2c1fac..251659bc58 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/AnyPromise.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/AnyPromise.swift @@ -100,7 +100,7 @@ import Foundation state.catch(on: q, policy: policy, else: { _ in }, execute: body) } -//MARK: ObjC methods +// MARK: ObjC methods /** A promise starts pending and eventually resolves. @@ -254,7 +254,6 @@ import Foundation } } - extension AnyPromise { /** - Returns: A description of the state of this promise. diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Error.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Error.swift index 99e7d1f292..0c746ce45a 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Error.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Error.swift @@ -82,7 +82,6 @@ public enum JSONError: Error { case unexpectedRootNode(Any) } - //////////////////////////////////////////////////////////// Cancellation public protocol CancellableError: Error { @@ -129,12 +128,11 @@ extension NSError { private var cancelledErrorIdentifiers = Set([ ErrorPair(PMKErrorDomain, PMKOperationCancelled), ErrorPair(NSCocoaErrorDomain, NSUserCancelledError), - ErrorPair(NSURLErrorDomain, NSURLErrorCancelled), + ErrorPair(NSURLErrorDomain, NSURLErrorCancelled) ]) #endif - extension Error { public var isCancelledError: Bool { if let ce = self as? CancellableError { @@ -150,7 +148,6 @@ extension Error { } } - //////////////////////////////////////////////////////// Unhandled Errors class ErrorConsumptionToken { var consumed = false diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Promise.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Promise.swift index 12c85ce4f0..39cfd4ad29 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Promise.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Promise.swift @@ -2,7 +2,6 @@ import class Dispatch.DispatchQueue import class Foundation.NSError import func Foundation.NSLog - /** A *promise* represents the future value of a (usually) asynchronous task. @@ -171,7 +170,7 @@ open class Promise { */ public func then(on q: DispatchQueue = .default, execute body: @escaping (T) throws -> Promise) -> Promise { var resolve: ((Resolution) -> Void)! - let rv = Promise{ resolve = $0 } + let rv = Promise { resolve = $0 } state.then(on: q, else: resolve) { value in let promise = try body(value) guard promise !== rv else { throw PMKError.returnedSelf } @@ -268,7 +267,7 @@ open class Promise { */ public func recover(on q: DispatchQueue = .default, policy: CatchPolicy = .allErrorsExceptCancellation, execute body: @escaping (Error) throws -> Promise) -> Promise { var resolve: ((Resolution) -> Void)! - let rv = Promise{ resolve = $0 } + let rv = Promise { resolve = $0 } state.catch(on: q, policy: policy, else: resolve) { error in let promise = try body(error) guard promise !== rv else { throw PMKError.returnedSelf } @@ -319,7 +318,7 @@ open class Promise { */ @discardableResult public func always(on q: DispatchQueue = .default, execute body: @escaping () -> Void) -> Promise { - state.always(on: q) { resolution in + state.always(on: q) { _ in body() } return self @@ -354,7 +353,7 @@ open class Promise { return then(on: zalgo) { _ in return } } -//MARK: deprecations +// MARK: deprecations @available(*, unavailable, renamed: "always()") public func finally(on: DispatchQueue = DispatchQueue.main, execute body: () -> Void) -> Promise { fatalError() } @@ -386,7 +385,7 @@ open class Promise { @available(*, unavailable, renamed: "init(value:)") public init(_ value: T) { fatalError() } -//MARK: disallow `Promise` +// MARK: disallow `Promise` @available(*, unavailable, message: "cannot instantiate Promise") public init(resolvers: (_ fulfill: (T) -> Void, _ reject: (Error) -> Void) throws -> Void) { fatalError() } @@ -394,7 +393,7 @@ open class Promise { @available(*, unavailable, message: "cannot instantiate Promise") public class func pending() -> (promise: Promise, fulfill: (T) -> Void, reject: (Error) -> Void) { fatalError() } -//MARK: disallow returning `Error` +// MARK: disallow returning `Error` @available (*, unavailable, message: "instead of returning the error; throw") public func then(on: DispatchQueue = .default, execute body: (T) throws -> U) -> Promise { fatalError() } @@ -402,7 +401,7 @@ open class Promise { @available (*, unavailable, message: "instead of returning the error; throw") public func recover(on: DispatchQueue = .default, execute body: (Error) throws -> T) -> Promise { fatalError() } -//MARK: disallow returning `Promise?` +// MARK: disallow returning `Promise?` @available(*, unavailable, message: "unwrap the promise") public func then(on: DispatchQueue = .default, execute body: (T) throws -> Promise?) -> Promise { fatalError() } @@ -487,7 +486,7 @@ public func firstly(execute body: () throws -> (Promise, Promi } /// utility function to serve `firstly` implementations with `body` returning tuple of promises -fileprivate func firstly(execute body: () throws -> V, when: (V) -> Promise) -> Promise { +private func firstly(execute body: () throws -> V, when: (V) -> Promise) -> Promise { do { return when(try body()) } catch { @@ -509,7 +508,6 @@ public func dispatch_promise(_ on: DispatchQueue, _ body: @escaping () throws return Promise(value: ()).then(on: on, execute: body) } - /** The underlying resolved state of a promise. - Remark: Same as `Resolution` but without the associated `ErrorConsumptionToken`. @@ -603,7 +601,6 @@ extension Promise { } } - extension Promise where T: Collection { /** Transforms a `Promise` where `T` is a `Collection` into a `Promise<[U]>` @@ -627,7 +624,6 @@ extension Promise where T: Collection { } } - #if swift(>=3.1) public extension Promise where T == Void { convenience init() { diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/State.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/State.swift index cc1a19ce70..1a87b46af4 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/State.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/State.swift @@ -154,11 +154,11 @@ class UnsealedState: State { class SealedState: State { fileprivate let resolution: Resolution - + init(resolution: Resolution) { self.resolution = resolution } - + override func get() -> Resolution? { return resolution } @@ -168,7 +168,6 @@ class SealedState: State { } } - class Handlers: Sequence { var bodies: [(Resolution) -> Void] = [] @@ -185,7 +184,6 @@ class Handlers: Sequence { } } - extension Resolution: CustomStringConvertible { var description: String { switch self { diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Zalgo.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Zalgo.swift index e191df10d6..b5364fe81d 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Zalgo.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/Zalgo.swift @@ -64,7 +64,6 @@ public let zalgo = DispatchQueue(label: "Zalgo") */ public let waldo = DispatchQueue(label: "Waldo") - @inline(__always) func contain_zalgo(_ q: DispatchQueue, body: @escaping () -> Void) { if q === zalgo || q === waldo && !Thread.isMainThread { body() diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/join.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/join.swift index 8ff69b2c2c..a50c4665d4 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/join.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/join.swift @@ -32,7 +32,7 @@ public func join(_ promises: [Promise]) -> Promise { @available(*, deprecated: 4.0, message: "Use when(resolved:)") public func join(_ promises: [Promise]) -> Promise<[T]> { guard !promises.isEmpty else { return Promise(value: []) } - + var countdown = promises.count let barrier = DispatchQueue(label: "org.promisekit.barrier.join", attributes: .concurrent) var rejected = false @@ -50,7 +50,7 @@ public func join(_ promises: [Promise]) -> Promise<[T]> { if rejected { reject(PMKError.join(promises)) } else { - fulfill(promises.map{ $0.value! }) + fulfill(promises.map { $0.value! }) } } } diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/when.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/when.swift index 41943b88b7..2e48ea4d68 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/when.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/when.swift @@ -76,7 +76,7 @@ private func _when(_ promises: [Promise]) -> Promise { - SeeAlso: `when(resolved:)` */ public func when(fulfilled promises: [Promise]) -> Promise<[T]> { - return _when(promises).then(on: zalgo) { promises.map{ $0.value! } } + return _when(promises).then(on: zalgo) { promises.map { $0.value! } } } /// Wait for all promises in a set to fulfill. @@ -177,7 +177,7 @@ public func when(fulfilled promiseIterator func testDone() { barrier.sync { if pendingPromises == 0 { - root.fulfill(promises.flatMap{ $0.value }) + root.fulfill(promises.flatMap { $0.value }) } } } @@ -203,7 +203,7 @@ public func when(fulfilled promiseIterator dequeue() } - + dequeue() return root.promise @@ -237,7 +237,7 @@ public func when(resolved promises: [Promise]) -> Promise<[Result]> { var countdown = promises.count let barrier = DispatchQueue(label: "org.promisekit.barrier.join", attributes: .concurrent) - return Promise { fulfill, reject in + return Promise { fulfill, _ in for promise in promises { promise.state.pipe { resolution in if case .rejected(_, let token) = resolution { diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/wrap.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/wrap.swift index 7249df91d3..48bd4b1bee 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/wrap.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/Pods/PromiseKit/Sources/wrap.swift @@ -27,7 +27,7 @@ public func wrap(_ body: (@escaping (T?, Error?) -> Void) throws -> Void) -> } /// For completion-handlers that eg. provide an enum or an error. -public func wrap(_ body: (@escaping (T, Error?) -> Void) throws -> Void) -> Promise { +public func wrap(_ body: (@escaping (T, Error?) -> Void) throws -> Void) -> Promise { return Promise { fulfill, reject in try body { obj, err in if let err = err { diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/AppDelegate.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/AppDelegate.swift index 7fd6929617..821a4aea70 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/AppDelegate.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/AppDelegate.swift @@ -13,7 +13,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? - func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true @@ -41,6 +40,4 @@ class AppDelegate: UIResponder, UIApplicationDelegate { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } - } - diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/ViewController.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/ViewController.swift index cd7e9a1676..8dad16b10f 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/ViewController.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClient/ViewController.swift @@ -20,6 +20,4 @@ class ViewController: UIViewController { // Dispose of any resources that can be recreated. } - } - diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift index 8f58cc4d4f..22b2e7d605 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/PetAPITests.swift @@ -12,19 +12,19 @@ import XCTest @testable import SwaggerClient class PetAPITests: XCTestCase { - + let testTimeout = 10.0 override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. } - + override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() } - + func test1CreatePet() { let expectation = self.expectation(description: "testCreatePet") let category = PetstoreClient.Category(id: 1234, name: "eyeColor") @@ -35,12 +35,12 @@ class PetAPITests: XCTestCase { expectation.fulfill() }.always { // Noop for now - }.catch { errorType in + }.catch { _ in XCTFail("error creating pet") } self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test2GetPet() { let expectation = self.expectation(description: "testGetPet") PetAPI.getPetById(petId: 1000).then { pet -> Void in @@ -49,19 +49,19 @@ class PetAPITests: XCTestCase { expectation.fulfill() }.always { // Noop for now - }.catch { errorType in + }.catch { _ in XCTFail("error creating pet") } self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test3DeletePet() { let expectation = self.expectation(description: "testDeletePet") PetAPI.deletePet(petId: 1000).then { expectation.fulfill() }.always { // Noop for now - }.catch { (errorType) in + }.catch { (_) in XCTFail("error deleting pet") } self.waitForExpectations(timeout: testTimeout, handler: nil) diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift index 7d7ae16b83..abb0921471 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/StoreAPITests.swift @@ -16,7 +16,7 @@ class StoreAPITests: XCTestCase { let isoDateFormat = "yyyy-MM-dd'T'HH:mm:ssZ" let testTimeout = 10.0 - + func test1PlaceOrder() { // use explicit naming to reference the enum so that we test we don't regress on enum naming let shipDate = Date() @@ -32,12 +32,12 @@ class StoreAPITests: XCTestCase { expectation.fulfill() }.always { // Noop for now - }.catch { errorType in + }.catch { _ in XCTFail("error placing order") } self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test2GetOrder() { let expectation = self.expectation(description: "testGetOrder") StoreAPI.getOrderById(orderId: 1000).then { order -> Void in @@ -47,19 +47,19 @@ class StoreAPITests: XCTestCase { expectation.fulfill() }.always { // Noop for now - }.catch { errorType in + }.catch { _ in XCTFail("error placing order") } self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func test3DeleteOrder() { let expectation = self.expectation(description: "testDeleteOrder") StoreAPI.deleteOrder(orderId: "1000").then { expectation.fulfill() }.always { // Noop for now - }.catch { (error) in + }.catch { (_) in XCTFail("error deleting order") } self.waitForExpectations(timeout: testTimeout, handler: nil) diff --git a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift index f416f745b4..2fd0ff0fbb 100644 --- a/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift +++ b/samples/client/petstore/swift4/promisekit/SwaggerClientTests/SwaggerClientTests/UserAPITests.swift @@ -21,19 +21,19 @@ class UserAPITests: XCTestCase { expectation.fulfill() }.always { // Noop for now - }.catch { (error) in + }.catch { (_) in XCTFail("login error") } self.waitForExpectations(timeout: testTimeout, handler: nil) } - + func testLogout() { let expectation = self.expectation(description: "testLogout") UserAPI.logoutUser().then { expectation.fulfill() }.always { // Noop for now - }.catch { (error) in + }.catch { (_) in XCTFail("") } self.waitForExpectations(timeout: testTimeout, handler: nil) diff --git a/samples/client/petstore/swift4/promisekit/docs/CatAllOf.md b/samples/client/petstore/swift4/promisekit/docs/CatAllOf.md new file mode 100644 index 0000000000..79789be61c --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/docs/CatAllOf.md @@ -0,0 +1,10 @@ +# CatAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**declawed** | **Bool** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/promisekit/docs/DogAllOf.md b/samples/client/petstore/swift4/promisekit/docs/DogAllOf.md new file mode 100644 index 0000000000..9302ef52e9 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/docs/DogAllOf.md @@ -0,0 +1,10 @@ +# DogAllOf + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**breed** | **String** | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/samples/client/petstore/swift4/promisekit/docs/UserAPI.md b/samples/client/petstore/swift4/promisekit/docs/UserAPI.md index 2ec91cfda3..e18cc451e9 100644 --- a/samples/client/petstore/swift4/promisekit/docs/UserAPI.md +++ b/samples/client/petstore/swift4/promisekit/docs/UserAPI.md @@ -89,7 +89,7 @@ UserAPI.createUsersWithArrayInput(body: body).then { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type @@ -134,7 +134,7 @@ UserAPI.createUsersWithListInput(body: body).then { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **body** | [**[User]**](Array.md) | List of user object | + **body** | [**[User]**](User.md) | List of user object | ### Return type diff --git a/samples/client/petstore/swift4/promisekit/project.yml b/samples/client/petstore/swift4/promisekit/project.yml new file mode 100644 index 0000000000..e35045a1d0 --- /dev/null +++ b/samples/client/petstore/swift4/promisekit/project.yml @@ -0,0 +1,16 @@ +name: PetstoreClient +targets: + PetstoreClient: + type: framework + platform: iOS + deploymentTarget: "10.0" + sources: [PetstoreClient] + info: + path: ./Info.plist + version: 1.0.0 + settings: + APPLICATION_EXTENSION_API_ONLY: true + scheme: {} + dependencies: + - carthage: Alamofire + - carthage: PromiseKit diff --git a/samples/client/petstore/swift4/rxswift/.openapi-generator/VERSION b/samples/client/petstore/swift4/rxswift/.openapi-generator/VERSION index afa6365606..83a328a922 100644 --- a/samples/client/petstore/swift4/rxswift/.openapi-generator/VERSION +++ b/samples/client/petstore/swift4/rxswift/.openapi-generator/VERSION @@ -1 +1 @@ -4.0.0-SNAPSHOT \ No newline at end of file +4.1.0-SNAPSHOT \ No newline at end of file diff --git a/samples/client/petstore/swift4/rxswift/Info.plist b/samples/client/petstore/swift4/rxswift/Info.plist new file mode 100644 index 0000000000..323e5ecfc4 --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/Info.plist @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.pbxproj b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.pbxproj new file mode 100644 index 0000000000..578d38a3ff --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.pbxproj @@ -0,0 +1,605 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */; }; + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */ = {isa = PBXBuildFile; fileRef = 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */; }; + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */; }; + 08F5828F0C2BCF07A9E4917DBBB993AE /* AdditionalPropertiesInteger.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */; }; + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */ = {isa = PBXBuildFile; fileRef = C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */; }; + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */; }; + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */; }; + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */; }; + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */; }; + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */ = {isa = PBXBuildFile; fileRef = 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */; }; + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */; }; + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */; }; + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */; }; + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */; }; + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */; }; + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */ = {isa = PBXBuildFile; fileRef = 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */; }; + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */; }; + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */; }; + 39F9FBA1AC5C2612ECA1FF715EBFC287 /* AdditionalPropertiesString.swift in Sources */ = {isa = PBXBuildFile; fileRef = FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */; }; + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */; }; + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */; }; + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */; }; + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */; }; + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */; }; + 52B5604F986335DB69CD2B430FB83BAB /* AdditionalPropertiesAnyType.swift in Sources */ = {isa = PBXBuildFile; fileRef = F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */; }; + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */ = {isa = PBXBuildFile; fileRef = 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */; }; + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */; }; + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */ = {isa = PBXBuildFile; fileRef = 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */; }; + 59EAB3527305A37ED99FB210045B69EA /* AdditionalPropertiesNumber.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */; }; + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */; }; + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */; }; + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */; }; + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */; }; + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */ = {isa = PBXBuildFile; fileRef = A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */; }; + 79536B981ECC24C77EB665FDAC7CA7BD /* RxSwift.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 69DB3E1D94EB0566C0052331742B5012 /* RxSwift.framework */; }; + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */ = {isa = PBXBuildFile; fileRef = F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */; }; + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */; }; + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */ = {isa = PBXBuildFile; fileRef = A913A57E72D723632E9A718FF4525C81 /* Client.swift */; }; + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */; }; + 988F461F59E4E1091156840007CB3773 /* AdditionalPropertiesBoolean.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */; }; + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */; }; + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */ = {isa = PBXBuildFile; fileRef = 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */; }; + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */ = {isa = PBXBuildFile; fileRef = B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */; }; + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */; }; + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */; }; + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */; }; + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */; }; + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */; }; + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7A6070F581E611FF44AFD40A4315C49A /* List.swift */; }; + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */ = {isa = PBXBuildFile; fileRef = F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */; }; + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */; }; + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */; }; + D68F23CD4B5178493CE7AE8DFB868EAE /* AdditionalPropertiesArray.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */; }; + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */ = {isa = PBXBuildFile; fileRef = C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */; }; + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */; }; + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */; }; + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */; }; + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */; }; + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */ = {isa = PBXBuildFile; fileRef = 386FD590658E90509C121118F057604D /* SpecialModelName.swift */; }; + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */ = {isa = PBXBuildFile; fileRef = B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */; }; + E57CD12D2F500D40B4135D0F5ECA9866 /* AdditionalPropertiesObject.swift in Sources */ = {isa = PBXBuildFile; fileRef = 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */; }; + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8699F7966F748ED026A6FB4CF550442B /* Models.swift */; }; + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */ = {isa = PBXBuildFile; fileRef = C81447828475F76C5CF4F08AA65292F7 /* Return.swift */; }; + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */ = {isa = PBXBuildFile; fileRef = 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */; }; + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CodableHelper.swift; sourceTree = ""; }; + 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesBoolean.swift; sourceTree = ""; }; + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumArrays.swift; sourceTree = ""; }; + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PetstoreClient.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderExample.swift; sourceTree = ""; }; + 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesNumber.swift; sourceTree = ""; }; + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Cat.swift; sourceTree = ""; }; + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Order.swift; sourceTree = ""; }; + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Configuration.swift; sourceTree = ""; }; + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FormatTest.swift; sourceTree = ""; }; + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodingHelper.swift; sourceTree = ""; }; + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIs.swift; sourceTree = ""; }; + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SpecialModelName.swift; sourceTree = ""; }; + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = File.swift; sourceTree = ""; }; + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesClass.swift; sourceTree = ""; }; + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CatAllOf.swift; sourceTree = ""; }; + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ClassModel.swift; sourceTree = ""; }; + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringBooleanMap.swift; sourceTree = ""; }; + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumClass.swift; sourceTree = ""; }; + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileSchemaTestClass.swift; sourceTree = ""; }; + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HasOnlyReadOnly.swift; sourceTree = ""; }; + 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesArray.swift; sourceTree = ""; }; + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Name.swift; sourceTree = ""; }; + 69DB3E1D94EB0566C0052331742B5012 /* RxSwift.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = RxSwift.framework; sourceTree = ""; }; + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeAPI.swift; sourceTree = ""; }; + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Category.swift; sourceTree = ""; }; + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReadOnlyFirst.swift; sourceTree = ""; }; + 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesObject.swift; sourceTree = ""; }; + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MapTest.swift; sourceTree = ""; }; + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = List.swift; sourceTree = ""; }; + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfArrayOfNumberOnly.swift; sourceTree = ""; }; + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UserAPI.swift; sourceTree = ""; }; + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Model200Response.swift; sourceTree = ""; }; + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AlamofireImplementations.swift; sourceTree = ""; }; + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Models.swift; sourceTree = ""; }; + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIHelper.swift; sourceTree = ""; }; + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnimalFarm.swift; sourceTree = ""; }; + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Animal.swift; sourceTree = ""; }; + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JSONEncodableEncoding.swift; sourceTree = ""; }; + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PetAPI.swift; sourceTree = ""; }; + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MixedPropertiesAndAdditionalPropertiesClass.swift; sourceTree = ""; }; + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AnotherFakeAPI.swift; sourceTree = ""; }; + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DogAllOf.swift; sourceTree = ""; }; + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = XmlItem.swift; sourceTree = ""; }; + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = Alamofire.framework; sourceTree = ""; }; + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreAPI.swift; sourceTree = ""; }; + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Capitalization.swift; sourceTree = ""; }; + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApiResponse.swift; sourceTree = ""; }; + A913A57E72D723632E9A718FF4525C81 /* Client.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Client.swift; sourceTree = ""; }; + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Tag.swift; sourceTree = ""; }; + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FakeClassnameTags123API.swift; sourceTree = ""; }; + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayOfNumberOnly.swift; sourceTree = ""; }; + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Extensions.swift; sourceTree = ""; }; + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NumberOnly.swift; sourceTree = ""; }; + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterEnum.swift; sourceTree = ""; }; + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Dog.swift; sourceTree = ""; }; + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Return.swift; sourceTree = ""; }; + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = User.swift; sourceTree = ""; }; + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TypeHolderDefault.swift; sourceTree = ""; }; + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pet.swift; sourceTree = ""; }; + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayTest.swift; sourceTree = ""; }; + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OuterComposite.swift; sourceTree = ""; }; + F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesAnyType.swift; sourceTree = ""; }; + FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesInteger.swift; sourceTree = ""; }; + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EnumTest.swift; sourceTree = ""; }; + FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AdditionalPropertiesString.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4C28BFEC5E7C8150DEFD83E09C1A1D32 /* Alamofire.framework in Frameworks */, + 79536B981ECC24C77EB665FDAC7CA7BD /* RxSwift.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */ = { + isa = PBXGroup; + children = ( + 7861EE241895128F64DD787367B3022D /* Carthage */, + ); + name = Frameworks; + sourceTree = ""; + }; + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */ = { + isa = PBXGroup; + children = ( + F5AB1037D937AADF8B4A70C96D5E5D61 /* AdditionalPropertiesAnyType.swift */, + 4FEE553331890581C2FF366F9EA0956D /* AdditionalPropertiesArray.swift */, + 0CC24C01A55F644957196F9F81D10F81 /* AdditionalPropertiesBoolean.swift */, + 396DEF3156BA0D12D0FC5C3C3AAF52C4 /* AdditionalPropertiesClass.swift */, + FA2F3566156A4ABC465F201B4A1F6227 /* AdditionalPropertiesInteger.swift */, + 1E0512B3582586B4C0C598D5DB1C0D39 /* AdditionalPropertiesNumber.swift */, + 72FEDC94BA0E37214D360871B284BC8A /* AdditionalPropertiesObject.swift */, + FFE215C1B526E0418ED301B15357B970 /* AdditionalPropertiesString.swift */, + 95568E7C35F119EB4A12B4982B3FB31F /* Animal.swift */, + 8D22BE01748F51106DE0233299A9061E /* AnimalFarm.swift */, + A8E7B833748B4F0C7CDA90C6E500B199 /* ApiResponse.swift */, + 7B1B8B838B5D9D312F2002EBAD946378 /* ArrayOfArrayOfNumberOnly.swift */, + B65BB72353DA24536A9049BEC3D234C8 /* ArrayOfNumberOnly.swift */, + F1A0379CDFC55705AE76C99867B8DB08 /* ArrayTest.swift */, + A7B38FA00A494D13F4C382A3D87FBF59 /* Capitalization.swift */, + 212AA914B7F1793A4E32C119370FB05F /* Cat.swift */, + 3AD0F94F512DFBC09F9CC79AF4BD9BFD /* CatAllOf.swift */, + 6F2985D01F8D60A4B1925C694330E6CB /* Category.swift */, + 3C30827D8EAF8EA684E7BCEA5A1E93B2 /* ClassModel.swift */, + A913A57E72D723632E9A718FF4525C81 /* Client.swift */, + C6C3E1129526A353B963EFD74ED8419C /* Dog.swift */, + A21A69C8402A60E01116ABBDEE8943DB /* DogAllOf.swift */, + 10503995D9EFD031A2EFB57603B3132E /* EnumArrays.swift */, + 4B2C97AE6ACA1E5FB88F5BAA2DB76FDC /* EnumClass.swift */, + FD60AEA646791E0EDE885DE1E680A687 /* EnumTest.swift */, + 3933D3B2A3AC4577094D0C23D1C1B266 /* File.swift */, + 4B3666552AA854DAF9C480A3354C9D7C /* FileSchemaTestClass.swift */, + 3156CE41C001C80379B84BDB435DECCB /* FormatTest.swift */, + 4C7FBC641752D2E13B15097311139DDC /* HasOnlyReadOnly.swift */, + 7A6070F581E611FF44AFD40A4315C49A /* List.swift */, + 7986861626C2B1CB49AD7000C6343270 /* MapTest.swift */, + 9AD714C7CC59BDD18DE8DF4ED40B9DA9 /* MixedPropertiesAndAdditionalPropertiesClass.swift */, + 82A2C3DC2235F0114C2B08E553F46874 /* Model200Response.swift */, + 5AD994DFAA0DA93C188A4DBA16688767 /* Name.swift */, + B8E0B16084741FCB82389F5854AC5E26 /* NumberOnly.swift */, + 27B2E9EF856E89FEAA359A3AC4A2CF5D /* Order.swift */, + F4E0AD8F60A91F72C768756002C14BF9 /* OuterComposite.swift */, + C15008AABC804EB6FB4CDAC6B871E6B0 /* OuterEnum.swift */, + ECFEB4C6C257B3BB3CEA36D10A5EDC17 /* Pet.swift */, + 6FD42727E001E799E458C2924CF813CC /* ReadOnlyFirst.swift */, + C81447828475F76C5CF4F08AA65292F7 /* Return.swift */, + 386FD590658E90509C121118F057604D /* SpecialModelName.swift */, + 47B4DEBABEFE140768CFB70B19D23029 /* StringBooleanMap.swift */, + B2896F8BFD1AA2965C8A30158F0EDA8C /* Tag.swift */, + EBC76F6D4D2AA8084B7EB50E5C15E475 /* TypeHolderDefault.swift */, + 19B65C66C97F082718DDD703F39DE1C2 /* TypeHolderExample.swift */, + E5565A447062C7B8F695F4517DB5E4A5 /* User.swift */, + A2253391845B73B8BA3680491575CC07 /* XmlItem.swift */, + ); + path = Models; + sourceTree = ""; + }; + 5FBA6AE5F64CD737F88B4565AC3CCD3B = { + isa = PBXGroup; + children = ( + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */, + 1E464C0937FE0D3A7A0FE29AF446553C /* Frameworks */, + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */, + ); + sourceTree = ""; + }; + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */ = { + isa = PBXGroup; + children = ( + 84A201508DF2B697D65F263189C08721 /* AlamofireImplementations.swift */, + 897716962D472FE162B723CB713AA6D3 /* APIHelper.swift */, + 37DF825B8F3BADA2B2537D17CDC48633 /* APIs.swift */, + 02A6F6BB2152ACEE1416D44AB3955243 /* CodableHelper.swift */, + 28A444949BBC254798C3B3DD14AAF2CD /* Configuration.swift */, + B8C298FC8929DCB369053F118D7DF28F /* Extensions.swift */, + 9791B840B8D6EAA35343B00FA277963A /* JSONEncodableEncoding.swift */, + 35D710108A69DD8A5297F926A66DA21F /* JSONEncodingHelper.swift */, + 8699F7966F748ED026A6FB4CF550442B /* Models.swift */, + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */, + 4FBDCF1330A9AB9122780DB3FA21DE4C /* Models */, + ); + path = OpenAPIs; + sourceTree = ""; + }; + 7861EE241895128F64DD787367B3022D /* Carthage */ = { + isa = PBXGroup; + children = ( + A012205B41CB71A62B86EECDEAFB0990 /* iOS */, + ); + name = Carthage; + path = Carthage/Build; + sourceTree = ""; + }; + 857F0DEA1890CE66D6DAD556C55821A6 /* Products */ = { + isa = PBXGroup; + children = ( + 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */, + ); + name = Products; + sourceTree = ""; + }; + 9B364C01750D7AA4F983B9E77B01BCC6 /* PetstoreClient */ = { + isa = PBXGroup; + children = ( + EF4C81BDD734856ED5023B777D35098B /* Classes */, + ); + path = PetstoreClient; + sourceTree = ""; + }; + A012205B41CB71A62B86EECDEAFB0990 /* iOS */ = { + isa = PBXGroup; + children = ( + A235FA3FDFB086CC69CDE83DFC1F4BC9 /* Alamofire.framework */, + 69DB3E1D94EB0566C0052331742B5012 /* RxSwift.framework */, + ); + path = iOS; + sourceTree = ""; + }; + EF4C81BDD734856ED5023B777D35098B /* Classes */ = { + isa = PBXGroup; + children = ( + 67BF3478113E6B4DF1C4E04F40BF58C4 /* OpenAPIs */, + ); + path = Classes; + sourceTree = ""; + }; + F956D0CCAE23BCFD1C7BDD5D47944AA5 /* APIs */ = { + isa = PBXGroup; + children = ( + 9DF24D2714B9C4CF14146E88FDDC01A5 /* AnotherFakeAPI.swift */, + 6E00950725DC44436C5E238CDD2EC164 /* FakeAPI.swift */, + B42354B407EC173BEB54E0429D946F3B /* FakeClassnameTags123API.swift */, + 9A019F500E546A3292CE716AB967C673 /* PetAPI.swift */, + A53274D99BBDE1B79BF3521CD7CBC276 /* StoreAPI.swift */, + 7C8D5F382979854D47F18DB1543680FE /* UserAPI.swift */, + ); + path = APIs; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */ = { + isa = PBXNativeTarget; + buildConfigurationList = B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */; + buildPhases = ( + E539708354CE60FE486F81EDE56D13C8 /* Sources */, + D1990C2A394CCF025EF98A2FB828C79A /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = PetstoreClient; + productName = PetstoreClient; + productReference = 164AD6EC9C4CCF634D7C45905E99E3A7 /* PetstoreClient.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + E7D276EE2369D8C455513C2E05F9AED0 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1000; + }; + buildConfigurationList = ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 5FBA6AE5F64CD737F88B4565AC3CCD3B; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C1282C2230015E0D204BEAEDDFB49453 /* PetstoreClient */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + E539708354CE60FE486F81EDE56D13C8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2A35688C985E9CB1EB7732AC2AD46B82 /* APIHelper.swift in Sources */, + 0462F801432CF94C7EF51D0532737A7E /* APIs.swift in Sources */, + 52B5604F986335DB69CD2B430FB83BAB /* AdditionalPropertiesAnyType.swift in Sources */, + D68F23CD4B5178493CE7AE8DFB868EAE /* AdditionalPropertiesArray.swift in Sources */, + 988F461F59E4E1091156840007CB3773 /* AdditionalPropertiesBoolean.swift in Sources */, + 12327BF7304AA897C5D2A1250B1659B7 /* AdditionalPropertiesClass.swift in Sources */, + 08F5828F0C2BCF07A9E4917DBBB993AE /* AdditionalPropertiesInteger.swift in Sources */, + 59EAB3527305A37ED99FB210045B69EA /* AdditionalPropertiesNumber.swift in Sources */, + E57CD12D2F500D40B4135D0F5ECA9866 /* AdditionalPropertiesObject.swift in Sources */, + 39F9FBA1AC5C2612ECA1FF715EBFC287 /* AdditionalPropertiesString.swift in Sources */, + 58F9704B295AC436D6FB98FA669E2344 /* AlamofireImplementations.swift in Sources */, + 02903CEC38DC202565BC08CB040AC4E9 /* Animal.swift in Sources */, + DB1CE39011A741D07E187663291B5DE5 /* AnimalFarm.swift in Sources */, + 83A2D1863FB136C0DFC423319F4EED65 /* AnotherFakeAPI.swift in Sources */, + 97C99615237E1B662242E04F527B38B9 /* ApiResponse.swift in Sources */, + 3251A3722981CE46261615CFBA96A08D /* ArrayOfArrayOfNumberOnly.swift in Sources */, + A190AF5A3988639ED4B78163D0EA3CA4 /* ArrayOfNumberOnly.swift in Sources */, + C2EDEB747887399B13A6DFD72A219CB2 /* ArrayTest.swift in Sources */, + 7367A9D91D4B101F2D28AC56ED89F175 /* Capitalization.swift in Sources */, + 18F19872A0DFB4CC3D9C696BBCA64EFD /* Cat.swift in Sources */, + 41D8A105135868152A56E2AC475049BB /* CatAllOf.swift in Sources */, + 42C51BC034E8B0CAA29A068F6B0DC815 /* Category.swift in Sources */, + 5ACDD7CC312167589335E9CA5998E770 /* ClassModel.swift in Sources */, + 92FB161BF1E57D11B116AF0292D5835C /* Client.swift in Sources */, + 6CD20EE568DDAD2304BF0C4B1A70C8DC /* CodableHelper.swift in Sources */, + DEC892724574BB29BD65869374F83982 /* Configuration.swift in Sources */, + D70EC94E346077DE1482231DD4498BED /* Dog.swift in Sources */, + 271D94A05C47B602A2433B9CD3D9DCDC /* DogAllOf.swift in Sources */, + A438970025AE69ED407BC1E67CC6359E /* EnumArrays.swift in Sources */, + 59C00CBB07761CAC8DCE7054E34AD5D9 /* EnumClass.swift in Sources */, + 08D87E4FECF24910F0DA0F1D2E2D955A /* EnumTest.swift in Sources */, + C329EE55B2FCC9174ED3B128D67C5E8C /* Extensions.swift in Sources */, + 297E365D1E4672C43C56E0AFD855FFBF /* FakeAPI.swift in Sources */, + A9F1AAF6CE029DD3B4F8AC841F0B6BC6 /* FakeClassnameTags123API.swift in Sources */, + FECA03F0388E84AE1B22638605D8AC9F /* File.swift in Sources */, + 491676EC91BFEF95A12556888EED87B5 /* FileSchemaTestClass.swift in Sources */, + 36734C4EB3362A114A7CB5F25EE39E6D /* FormatTest.swift in Sources */, + DDBC3CF5E447D8D838F0FE200420EEE3 /* HasOnlyReadOnly.swift in Sources */, + 16E9A5E22B4823DE282E7F4C18A21EA8 /* JSONEncodableEncoding.swift in Sources */, + 12BB95C66D63090732BB9E0379836E3C /* JSONEncodingHelper.swift in Sources */, + C1CACABE18A7ADCE37D1CD9DC9128304 /* List.swift in Sources */, + 655AA371771C7BD72EE0AAC0C90DFFF0 /* MapTest.swift in Sources */, + D3A17B7FAFA8A7A210875BBCDCC30116 /* MixedPropertiesAndAdditionalPropertiesClass.swift in Sources */, + 2DF4544D4D3D6CF7047A59FB89ED31BD /* Model200Response.swift in Sources */, + F02BEF9A8503B3848B045370451E85F6 /* Models.swift in Sources */, + C15AC1CC631E96D0360EB8C15BF30452 /* Name.swift in Sources */, + AE9D2E1DB59AF6575AC4AC6756C5A937 /* NumberOnly.swift in Sources */, + 59C2F5495C98836BFA9E10BF5C13BC2C /* Order.swift in Sources */, + 82D4D0C8AD0354A700C8ACD421ABED55 /* OuterComposite.swift in Sources */, + 1143FFF06DEE01E5B0F1368AA05BE1B4 /* OuterEnum.swift in Sources */, + B399A1742F23330FDCA450EAB98F51F1 /* Pet.swift in Sources */, + 3D8E407B1DF4FA5A5F16B64E3A285781 /* PetAPI.swift in Sources */, + 293F4E0FBFC8297E414A3CDBB7F29A96 /* ReadOnlyFirst.swift in Sources */, + F21D10C71A9DE7D0467AFD23FD391D2E /* Return.swift in Sources */, + E2C40F0E34DB8C21A806262C72841A51 /* SpecialModelName.swift in Sources */, + 122BBAE8245606CC040EEB6B9254E376 /* StoreAPI.swift in Sources */, + 196E9846B27D736630CCF90497696859 /* StringBooleanMap.swift in Sources */, + E51ADEC931806B20A041303E539A8BE2 /* Tag.swift in Sources */, + 6600BB1500AE35A3C80F7C83F6444552 /* TypeHolderDefault.swift in Sources */, + FB4A053CDCD75E48B755CC22D463A3FC /* TypeHolderExample.swift in Sources */, + BF7D58FBCF5E4D3F2932FCC0E62BED40 /* User.swift in Sources */, + DB724C4F1AD5DF025B53A9A2E0A49E3D /* UserAPI.swift in Sources */, + BB02FDCF1B2B0E457E1C2BF39FBB599D /* XmlItem.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "$(inherited)", + "DEBUG=1", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 4.2; + }; + name = Debug; + }; + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + APPLICATION_EXTENSION_API_ONLY = YES; + CODE_SIGN_IDENTITY = ""; + CURRENT_PROJECT_VERSION = 1; + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + FRAMEWORK_SEARCH_PATHS = ( + "$(inherited)", + "$(PROJECT_DIR)/Carthage/Build/iOS", + ); + INFOPLIST_FILE = Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + IPHONEOS_DEPLOYMENT_TARGET = 10.0; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + SDKROOT = iphoneos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = "$(TARGET_NAME)"; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + SWIFT_VERSION = 4.2; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + B46EDEB1A7F0D78FE6394544C60169D1 /* Build configuration list for PBXNativeTarget "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + DD3EEB93949E9EBA4437E9CDBF4A26F6 /* Debug */, + 3B2C02AFB91CB5C82766ED5CF21FF628 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = ""; + }; + ECAB17FF35111B5E14DAAC0883031714 /* Build configuration list for PBXProject "PetstoreClient" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + A9EB0A02B94C427CBACFEC7CFFC6A816 /* Debug */, + F81D4E5FECD46E9AA6DD2C299CEBEF64 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = E7D276EE2369D8C455513C2E05F9AED0 /* Project object */; +} diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000000..919434a625 --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme new file mode 100644 index 0000000000..7802e37945 --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient.xcodeproj/xcshareddata/xcschemes/PetstoreClient.xcscheme @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIHelper.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIHelper.swift index d94614b34f..75dea24395 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIHelper.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIHelper.swift @@ -7,7 +7,7 @@ import Foundation public struct APIHelper { - public static func rejectNil(_ source: [String:Any?]) -> [String:Any]? { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { let destination = source.reduce(into: [String: Any]()) { (result, item) in if let value = item.value { result[item.key] = value @@ -20,17 +20,17 @@ public struct APIHelper { return destination } - public static func rejectNilHeaders(_ source: [String:Any?]) -> [String:String] { + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { return source.reduce(into: [String: String]()) { (result, item) in if let collection = item.value as? Array { - result[item.key] = collection.filter({ $0 != nil }).map{ "\($0!)" }.joined(separator: ",") + result[item.key] = collection.filter({ $0 != nil }).map { "\($0!)" }.joined(separator: ",") } else if let value: Any = item.value { result[item.key] = "\(value)" } } } - public static func convertBoolToString(_ source: [String: Any]?) -> [String:Any]? { + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { guard let source = source else { return nil } @@ -52,7 +52,7 @@ public struct APIHelper { return source } - public static func mapValuesToQueryItems(_ source: [String:Any?]) -> [URLQueryItem]? { + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { let destination = source.filter({ $0.value != nil}).reduce(into: [URLQueryItem]()) { (result, item) in if let collection = item.value as? Array { let value = collection.filter({ $0 != nil }).map({"\($0!)"}).joined(separator: ",") @@ -68,4 +68,3 @@ public struct APIHelper { return destination } } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs.swift index 2890bffa27..9e4312f685 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs.swift @@ -9,22 +9,22 @@ import Foundation open class PetstoreClientAPI { public static var basePath = "http://petstore.swagger.io:80/v2" public static var credential: URLCredential? - public static var customHeaders: [String:String] = [:] + public static var customHeaders: [String: String] = [:] public static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory() } open class RequestBuilder { var credential: URLCredential? - var headers: [String:String] - public let parameters: [String:Any]? + var headers: [String: String] + public let parameters: [String: Any]? public let isBody: Bool public let method: String public let URLString: String /// Optional block to obtain a reference to the request's progress instance when available. - public var onProgressReady: ((Progress) -> ())? + public var onProgressReady: ((Progress) -> Void)? - required public init(method: String, URLString: String, parameters: [String:Any]?, isBody: Bool, headers: [String:String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { self.method = method self.URLString = URLString self.parameters = parameters @@ -34,7 +34,7 @@ open class RequestBuilder { addHeaders(PetstoreClientAPI.customHeaders) } - open func addHeaders(_ aHeaders:[String:String]) { + open func addHeaders(_ aHeaders: [String: String]) { for (header, value) in aHeaders { headers[header] = value } @@ -57,5 +57,5 @@ open class RequestBuilder { public protocol RequestBuilderFactory { func getNonDecodableBuilder() -> RequestBuilder.Type - func getBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type } diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift index 1a95322a6b..0d88a4bad9 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class AnotherFakeAPI { /** To test special tags diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift index 05053aed92..8e6840eeaa 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class FakeAPI { /** @@ -346,7 +344,7 @@ open class FakeAPI { open class func testEndpointParametersWithRequestBuilder(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "integer": integer?.encodeToJSON(), "int32": int32?.encodeToJSON(), "int64": int64?.encodeToJSON(), @@ -365,7 +363,7 @@ open class FakeAPI { let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -484,19 +482,19 @@ open class FakeAPI { open class func testEnumParametersWithRequestBuilder(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "enum_form_string_array": enumFormStringArray, "enum_form_string": enumFormString?.rawValue ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "enum_query_string_array": enumQueryStringArray, - "enum_query_string": enumQueryString?.rawValue, - "enum_query_integer": enumQueryInteger?.rawValue, + "enum_query_string_array": enumQueryStringArray, + "enum_query_string": enumQueryString?.rawValue, + "enum_query_integer": enumQueryInteger?.rawValue, "enum_query_double": enumQueryDouble?.rawValue ]) let nillableHeaders: [String: Any?] = [ @@ -550,13 +548,13 @@ open class FakeAPI { open class func testGroupParametersWithRequestBuilder(requiredStringGroup: Int, requiredBooleanGroup: Bool, requiredInt64Group: Int64, stringGroup: Int? = nil, booleanGroup: Bool? = nil, int64Group: Int64? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "required_string_group": requiredStringGroup.encodeToJSON(), - "required_int64_group": requiredInt64Group.encodeToJSON(), - "string_group": stringGroup?.encodeToJSON(), + "required_string_group": requiredStringGroup.encodeToJSON(), + "required_int64_group": requiredInt64Group.encodeToJSON(), + "string_group": stringGroup?.encodeToJSON(), "int64_group": int64Group?.encodeToJSON() ]) let nillableHeaders: [String: Any?] = [ @@ -576,7 +574,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: Observable */ - open class func testInlineAdditionalProperties(param: [String:String]) -> Observable { + open class func testInlineAdditionalProperties(param: [String: String]) -> Observable { return Observable.create { observer -> Disposable in testInlineAdditionalPropertiesWithRequestBuilder(param: param).execute { (response, error) -> Void in if let error = error { @@ -596,7 +594,7 @@ open class FakeAPI { - parameter param: (body) request body - returns: RequestBuilder */ - open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String:String]) -> RequestBuilder { + open class func testInlineAdditionalPropertiesWithRequestBuilder(param: [String: String]) -> RequestBuilder { let path = "/fake/inline-additionalProperties" let URLString = PetstoreClientAPI.basePath + path let parameters = JSONEncodingHelper.encodingParameters(forEncodableObject: param) @@ -639,14 +637,14 @@ open class FakeAPI { open class func testJsonFormDataWithRequestBuilder(param: String, param2: String) -> RequestBuilder { let path = "/fake/jsonFormData" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "param": param, "param2": param2 ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift index 2784d5cfb6..a4e7d073c9 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class FakeClassnameTags123API { /** To test class name in snake case diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift index b9ca8262f4..fcbd3f3b00 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class PetAPI { /** Add a new pet to the store @@ -90,8 +88,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let nillableHeaders: [String: Any?] = [ "api_key": apiKey @@ -147,8 +145,8 @@ open class PetAPI { open class func findPetsByStatusWithRequestBuilder(status: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByStatus" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "status": status @@ -194,8 +192,8 @@ open class PetAPI { open class func findPetsByTagsWithRequestBuilder(tags: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByTags" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "tags": tags @@ -244,8 +242,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -333,14 +331,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "name": name, "status": status ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -389,14 +387,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "file": file ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -445,14 +443,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "requiredFile": requiredFile ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift index 4af70c9253..6171b68c85 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class StoreAPI { /** Delete purchase order by ID @@ -45,8 +43,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -59,7 +57,7 @@ open class StoreAPI { - returns: Observable<[String:Int]> */ - open class func getInventory() -> Observable<[String:Int]> { + open class func getInventory() -> Observable<[String: Int]> { return Observable.create { observer -> Disposable in getInventoryWithRequestBuilder().execute { (response, error) -> Void in if let error = error { @@ -84,14 +82,14 @@ open class StoreAPI { - name: api_key - returns: RequestBuilder<[String:Int]> */ - open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String:Int]> { + open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String: Int]> { let path = "/store/inventory" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) - let requestBuilder: RequestBuilder<[String:Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() + let requestBuilder: RequestBuilder<[String: Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() return requestBuilder.init(method: "GET", URLString: (url?.string ?? URLString), parameters: parameters, isBody: false) } @@ -131,8 +129,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift index 999b7791db..baeb80933a 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class UserAPI { /** Create user @@ -160,8 +158,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -203,8 +201,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -246,11 +244,11 @@ open class UserAPI { open class func loginUserWithRequestBuilder(username: String, password: String) -> RequestBuilder { let path = "/user/login" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "username": username, + "username": username, "password": password ]) @@ -286,8 +284,8 @@ open class UserAPI { open class func logoutUserWithRequestBuilder() -> RequestBuilder { let path = "/user/logout" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift index dac40e9a31..04ad02a5ce 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift @@ -12,7 +12,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { return AlamofireRequestBuilder.self } - func getBuilder() -> RequestBuilder.Type { + func getBuilder() -> RequestBuilder.Type { return AlamofireDecodableRequestBuilder.self } } @@ -50,7 +50,7 @@ private struct SynchronizedDictionary { private var managerStore = SynchronizedDictionary() open class AlamofireRequestBuilder: RequestBuilder { - required public init(method: String, URLString: String, parameters: [String : Any]?, isBody: Bool, headers: [String : String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { super.init(method: method, URLString: URLString, parameters: parameters, isBody: isBody, headers: headers) } @@ -88,17 +88,17 @@ open class AlamofireRequestBuilder: RequestBuilder { May be overridden by a subclass if you want to control the request configuration (e.g. to override the cache policy). */ - open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String:String]) -> DataRequest { + open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) -> DataRequest { return manager.request(URLString, method: method, parameters: parameters, encoding: encoding, headers: headers) } override open func execute(_ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { - let managerId:String = UUID().uuidString + let managerId: String = UUID().uuidString // Create a new manager for each request to customize its request header let manager = createSessionManager() managerStore[managerId] = manager - let encoding:ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() + let encoding: ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() let xMethod = Alamofire.HTTPMethod(rawValue: method) let fileKeys = parameters == nil ? [] : parameters!.filter { $1 is NSURL } @@ -111,8 +111,7 @@ open class AlamofireRequestBuilder: RequestBuilder { case let fileURL as URL: if let mimeType = self.contentTypeForFormPart(fileURL: fileURL) { mpForm.append(fileURL, withName: k, fileName: fileURL.lastPathComponent, mimeType: mimeType) - } - else { + } else { mpForm.append(fileURL, withName: k) } case let string as String: @@ -276,7 +275,7 @@ open class AlamofireRequestBuilder: RequestBuilder { return httpHeaders } - fileprivate func getFileName(fromContentDisposition contentDisposition : String?) -> String? { + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { guard let contentDisposition = contentDisposition else { return nil @@ -284,7 +283,7 @@ open class AlamofireRequestBuilder: RequestBuilder { let items = contentDisposition.components(separatedBy: ";") - var filename : String? = nil + var filename: String? = nil for contentItem in items { @@ -304,7 +303,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getPath(from url : URL) throws -> String { + fileprivate func getPath(from url: URL) throws -> String { guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { throw DownloadException.requestMissingPath @@ -318,7 +317,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getURL(from urlRequest : URLRequest) throws -> URL { + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { guard let url = urlRequest.url else { throw DownloadException.requestMissingURL @@ -329,7 +328,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } -fileprivate enum DownloadException : Error { +private enum DownloadException: Error { case responseDataMissing case responseFailed case requestMissing @@ -344,7 +343,7 @@ public enum AlamofireDecodableRequestBuilderError: Error { case generalError(Error) } -open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { +open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { override fileprivate func processRequest(request: DataRequest, _ managerId: String, _ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { if let credential = self.credential { diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift index 584de8c3d5..111d5a3a8c 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift @@ -13,7 +13,7 @@ open class CodableHelper { public static var dateformatter: DateFormatter? - open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T : Decodable { + open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T: Decodable { var returnedDecodable: T? = nil var returnedError: Error? = nil @@ -39,7 +39,7 @@ open class CodableHelper { return (returnedDecodable, returnedError) } - open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T : Encodable { + open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T: Encodable { var returnedData: Data? var returnedError: Error? = nil diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Configuration.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Configuration.swift index 516590da5d..e1ecb39726 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Configuration.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Configuration.swift @@ -7,9 +7,9 @@ import Foundation open class Configuration { - + // This value is used to configure the date formatter that is used to serialize dates into JSON format. // You must set it prior to encoding any dates, and it will only be read once. public static var dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" - -} \ No newline at end of file + +} diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Extensions.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Extensions.swift index 8bf1829ba8..24c128daad 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Extensions.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Extensions.swift @@ -112,24 +112,24 @@ extension String: CodingKey { extension KeyedEncodingContainerProtocol { - public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { var arrayContainer = nestedUnkeyedContainer(forKey: key) try arrayContainer.encode(contentsOf: values) } - public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { if let values = values { try encodeArray(values, forKey: key) } } - public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T : Encodable { + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { for (key, value) in pairs { try encode(value, forKey: key) } } - public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T : Encodable { + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { if let pairs = pairs { try encodeMap(pairs) } @@ -139,7 +139,7 @@ extension KeyedEncodingContainerProtocol { extension KeyedDecodingContainerProtocol { - public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T : Decodable { + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { var tmpArray = [T]() var nestedContainer = try nestedUnkeyedContainer(forKey: key) @@ -151,7 +151,7 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T : Decodable { + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { var tmpArray: [T]? = nil if contains(key) { @@ -161,8 +161,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T : Decodable { - var map: [Self.Key : T] = [:] + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] for key in allKeys { if !excludedKeys.contains(key) { @@ -175,5 +175,3 @@ extension KeyedDecodingContainerProtocol { } } - - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift index 7044951584..3e68bb5d4a 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -10,7 +10,7 @@ import Alamofire open class JSONEncodingHelper { - open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { + open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { var params: Parameters? = nil // Encode the Encodable object @@ -39,5 +39,5 @@ open class JSONEncodingHelper { return params } - + } diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models.swift index 4085638903..e87ce399c7 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models.swift @@ -10,7 +10,7 @@ protocol JSONEncodable { func encodeToJSON() -> Any } -public enum ErrorResponse : Error { +public enum ErrorResponse: Error { case error(Int, Data?, Error) } diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift index 796e46eca2..94295c495c 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesAnyType.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesAnyType: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesAnyType: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Any] = [:] + public var additionalProperties: [String: Any] = [:] public subscript(key: String) -> Any? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesAnyType: Codable { additionalProperties = try container.decodeMap(Any.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift index 5e58839b5a..cde9824ddb 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesArray.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesArray: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesArray: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Array] = [:] + public var additionalProperties: [String: Array] = [:] public subscript(key: String) -> Array? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesArray: Codable { additionalProperties = try container.decodeMap(Array.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift index d4c90829b4..76791a9ddd 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesBoolean.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesBoolean: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesBoolean: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesBoolean: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift index 4db39adae8..83a06951cc 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift @@ -7,23 +7,19 @@ import Foundation - - public struct AdditionalPropertiesClass: Codable { - public var mapString: [String:String]? - public var mapMapString: [String:[String:String]]? + public var mapString: [String: String]? + public var mapMapString: [String: [String: String]]? - public init(mapString: [String:String]?, mapMapString: [String:[String:String]]?) { + public init(mapString: [String: String]?, mapMapString: [String: [String: String]]?) { self.mapString = mapString self.mapMapString = mapMapString } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapString = "map_string" case mapMapString = "map_map_string" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift index b03bbe4456..4a0f2acaa4 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesInteger.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesInteger: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesInteger: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Int] = [:] + public var additionalProperties: [String: Int] = [:] public subscript(key: String) -> Int? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesInteger: Codable { additionalProperties = try container.decodeMap(Int.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift index 9701d54c9b..95e491000a 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesNumber.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesNumber: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesNumber: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Double] = [:] + public var additionalProperties: [String: Double] = [:] public subscript(key: String) -> Double? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesNumber: Codable { additionalProperties = try container.decodeMap(Double.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift index c6e1e670b8..f45888a410 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesObject.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesObject: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesObject: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:Dictionary] = [:] + public var additionalProperties: [String: Dictionary] = [:] public subscript(key: String) -> Dictionary? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesObject: Codable { additionalProperties = try container.decodeMap(Dictionary.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift index 6128dce7d4..7af63cc715 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesString.swift @@ -7,8 +7,6 @@ import Foundation - - public struct AdditionalPropertiesString: Codable { public var name: String? @@ -16,7 +14,7 @@ public struct AdditionalPropertiesString: Codable { public init(name: String?) { self.name = name } - public var additionalProperties: [String:String] = [:] + public var additionalProperties: [String: String] = [:] public subscript(key: String) -> String? { get { @@ -52,7 +50,4 @@ public struct AdditionalPropertiesString: Codable { additionalProperties = try container.decodeMap(String.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift index 7221a1be09..5ed9f31e2a 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Animal: Codable { public var className: String @@ -19,6 +17,4 @@ public struct Animal: Codable { self.color = color } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift index e7bea63f8e..e09b0e9efd 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift @@ -7,5 +7,4 @@ import Foundation - public typealias AnimalFarm = [Animal] diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift index a22e9aaebb..ec270da890 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ApiResponse: Codable { public var code: Int? @@ -21,6 +19,4 @@ public struct ApiResponse: Codable { self.message = message } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift index 4e5a5ca144..3843287630 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfArrayOfNumberOnly: Codable { public var arrayArrayNumber: [[Double]]? @@ -17,10 +15,8 @@ public struct ArrayOfArrayOfNumberOnly: Codable { self.arrayArrayNumber = arrayArrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayArrayNumber = "ArrayArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift index 7d059d3683..f8b198e81f 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfNumberOnly: Codable { public var arrayNumber: [Double]? @@ -17,10 +15,8 @@ public struct ArrayOfNumberOnly: Codable { self.arrayNumber = arrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayNumber = "ArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift index 9c56fed50c..67f7f7e515 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayTest: Codable { public var arrayOfString: [String]? @@ -21,12 +19,10 @@ public struct ArrayTest: Codable { self.arrayArrayOfModel = arrayArrayOfModel } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayOfString = "array_of_string" case arrayArrayOfInteger = "array_array_of_integer" case arrayArrayOfModel = "array_array_of_model" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift index 98cda23dac..d576b50b1c 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Capitalization: Codable { public var smallCamel: String? @@ -28,7 +26,7 @@ public struct Capitalization: Codable { self.ATT_NAME = ATT_NAME } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case smallCamel case capitalCamel = "CapitalCamel" case smallSnake = "small_Snake" @@ -37,6 +35,4 @@ public struct Capitalization: Codable { case ATT_NAME } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift index a116d964ea..7ab887f311 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Cat: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Cat: Codable { self.declawed = declawed } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift new file mode 100644 index 0000000000..a51ad0dffa --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/CatAllOf.swift @@ -0,0 +1,18 @@ +// +// CatAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct CatAllOf: Codable { + + public var declawed: Bool? + + public init(declawed: Bool?) { + self.declawed = declawed + } + +} diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Category.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Category.swift index e8c489be46..eb8f7e5e19 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Category.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Category.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Category: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Category: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift index f673ed127c..28cb30ce7b 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model with \"_class\" property */ public struct ClassModel: Codable { @@ -18,6 +17,4 @@ public struct ClassModel: Codable { self._class = _class } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Client.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Client.swift index 51390b6c4e..00245ca372 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Client.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Client.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Client: Codable { public var client: String? @@ -17,6 +15,4 @@ public struct Client: Codable { self.client = client } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift index 239ce74dcc..492c122800 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Dog: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Dog: Codable { self.breed = breed } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift new file mode 100644 index 0000000000..7786f8acc5 --- /dev/null +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/DogAllOf.swift @@ -0,0 +1,18 @@ +// +// DogAllOf.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct DogAllOf: Codable { + + public var breed: String? + + public init(breed: String?) { + self.breed = breed + } + +} diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift index 8713961520..5034ff0b8c 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumArrays: Codable { public enum JustSymbol: String, Codable { @@ -27,11 +25,9 @@ public struct EnumArrays: Codable { self.arrayEnum = arrayEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justSymbol = "just_symbol" case arrayEnum = "array_enum" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift index 7280a621fe..3c1dfcac57 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift @@ -7,7 +7,6 @@ import Foundation - public enum EnumClass: String, Codable { case abc = "_abc" case efg = "-efg" diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift index 0f546c76a2..6db9b34d18 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumTest: Codable { public enum EnumString: String, Codable { @@ -43,7 +41,7 @@ public struct EnumTest: Codable { self.outerEnum = outerEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case enumString = "enum_string" case enumStringRequired = "enum_string_required" case enumInteger = "enum_integer" @@ -51,6 +49,4 @@ public struct EnumTest: Codable { case outerEnum } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/File.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/File.swift index c8bd1f1958..ea3520f053 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/File.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/File.swift @@ -7,7 +7,6 @@ import Foundation - /** Must be named `File` for test. */ public struct File: Codable { @@ -19,6 +18,4 @@ public struct File: Codable { self.sourceURI = sourceURI } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift index 64d0250680..532f145793 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FileSchemaTestClass.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FileSchemaTestClass: Codable { public var file: File? @@ -19,6 +17,4 @@ public struct FileSchemaTestClass: Codable { self.files = files } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift index faa091b065..20bd6d103b 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FormatTest: Codable { public var integer: Int? @@ -41,6 +39,4 @@ public struct FormatTest: Codable { self.password = password } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift index 554aee1081..906ddb06fb 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct HasOnlyReadOnly: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct HasOnlyReadOnly: Codable { self.foo = foo } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/List.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/List.swift index 8997340ff4..08d5995387 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/List.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/List.swift @@ -7,8 +7,6 @@ import Foundation - - public struct List: Codable { public var _123list: String? @@ -17,10 +15,8 @@ public struct List: Codable { self._123list = _123list } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _123list = "123-list" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift index 2d3a45d35a..3a10a7dfca 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift @@ -7,33 +7,29 @@ import Foundation - - public struct MapTest: Codable { public enum MapOfEnumString: String, Codable { case upper = "UPPER" case lower = "lower" } - public var mapMapOfString: [String:[String:String]]? - public var mapOfEnumString: [String:String]? - public var directMap: [String:Bool]? + public var mapMapOfString: [String: [String: String]]? + public var mapOfEnumString: [String: String]? + public var directMap: [String: Bool]? public var indirectMap: StringBooleanMap? - public init(mapMapOfString: [String:[String:String]]?, mapOfEnumString: [String:String]?, directMap: [String:Bool]?, indirectMap: StringBooleanMap?) { + public init(mapMapOfString: [String: [String: String]]?, mapOfEnumString: [String: String]?, directMap: [String: Bool]?, indirectMap: StringBooleanMap?) { self.mapMapOfString = mapMapOfString self.mapOfEnumString = mapOfEnumString self.directMap = directMap self.indirectMap = indirectMap } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapMapOfString = "map_map_of_string" case mapOfEnumString = "map_of_enum_string" case directMap = "direct_map" case indirectMap = "indirect_map" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift index 7116108fd7..c3deb2f289 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift @@ -7,20 +7,16 @@ import Foundation - - public struct MixedPropertiesAndAdditionalPropertiesClass: Codable { public var uuid: UUID? public var dateTime: Date? - public var map: [String:Animal]? + public var map: [String: Animal]? - public init(uuid: UUID?, dateTime: Date?, map: [String:Animal]?) { + public init(uuid: UUID?, dateTime: Date?, map: [String: Animal]?) { self.uuid = uuid self.dateTime = dateTime self.map = map } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift index fc1d0606b7..7ed6aad907 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name starting with number */ public struct Model200Response: Codable { @@ -20,11 +19,9 @@ public struct Model200Response: Codable { self._class = _class } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case _class = "class" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Name.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Name.swift index cc165d767d..ce9ffe4fb3 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Name.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Name.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name same as property name */ public struct Name: Codable { @@ -24,13 +23,11 @@ public struct Name: Codable { self._123number = _123number } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case snakeCase = "snake_case" case property case _123number = "123Number" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift index e6fb206093..abd2269e8e 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct NumberOnly: Codable { public var justNumber: Double? @@ -17,10 +15,8 @@ public struct NumberOnly: Codable { self.justNumber = justNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justNumber = "JustNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Order.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Order.swift index 83c3b85e66..a6e1b1d2e5 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Order.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Order.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Order: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Order: Codable { self.complete = complete } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift index edc4523d9f..49aec001c5 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift @@ -7,8 +7,6 @@ import Foundation - - public struct OuterComposite: Codable { public var myNumber: Double? @@ -21,12 +19,10 @@ public struct OuterComposite: Codable { self.myBoolean = myBoolean } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case myNumber = "my_number" case myString = "my_string" case myBoolean = "my_boolean" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift index bd1643d279..9f80fc95ec 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift @@ -7,7 +7,6 @@ import Foundation - public enum OuterEnum: String, Codable { case placed = "placed" case approved = "approved" diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift index 5e39abae6c..af60a550bb 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Pet: Codable { public enum Status: String, Codable { @@ -33,6 +31,4 @@ public struct Pet: Codable { self.status = status } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift index 48b655a5b0..0acd21fd10 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ReadOnlyFirst: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct ReadOnlyFirst: Codable { self.baz = baz } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Return.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Return.swift index de4b218999..076082af84 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Return.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Return.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing reserved words */ public struct Return: Codable { @@ -18,10 +17,8 @@ public struct Return: Codable { self._return = _return } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _return = "return" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift index 213d896ba9..e79fc45c0e 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift @@ -7,8 +7,6 @@ import Foundation - - public struct SpecialModelName: Codable { public var specialPropertyName: Int64? @@ -17,10 +15,8 @@ public struct SpecialModelName: Codable { self.specialPropertyName = specialPropertyName } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case specialPropertyName = "$special[property.name]" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift index ae15e87d94..3f1237fee4 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/StringBooleanMap.swift @@ -7,12 +7,9 @@ import Foundation - - public struct StringBooleanMap: Codable { - - public var additionalProperties: [String:Bool] = [:] + public var additionalProperties: [String: Bool] = [:] public subscript(key: String) -> Bool? { get { @@ -45,7 +42,4 @@ public struct StringBooleanMap: Codable { additionalProperties = try container.decodeMap(Bool.self, excludedKeys: nonAdditionalPropertyKeys) } - - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift index 32ee33a1a1..4dd8a9a9f5 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Tag: Codable { public var id: Int64? @@ -19,6 +17,4 @@ public struct Tag: Codable { self.name = name } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift index be1afdf026..bf0006e1a2 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderDefault.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderDefault: Codable { public var stringItem: String = "what" @@ -25,7 +23,7 @@ public struct TypeHolderDefault: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderDefault: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift index f46c8952e1..602a2a6d18 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/TypeHolderExample.swift @@ -7,8 +7,6 @@ import Foundation - - public struct TypeHolderExample: Codable { public var stringItem: String @@ -25,7 +23,7 @@ public struct TypeHolderExample: Codable { self.arrayItem = arrayItem } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case stringItem = "string_item" case numberItem = "number_item" case integerItem = "integer_item" @@ -33,6 +31,4 @@ public struct TypeHolderExample: Codable { case arrayItem = "array_item" } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/User.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/User.swift index a61b584420..79f271ed73 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/User.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/User.swift @@ -7,8 +7,6 @@ import Foundation - - public struct User: Codable { public var id: Int64? @@ -32,6 +30,4 @@ public struct User: Codable { self.userStatus = userStatus } - } - diff --git a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift index e1b1ace8b1..aa01668350 100644 --- a/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift +++ b/samples/client/petstore/swift4/rxswift/PetstoreClient/Classes/OpenAPIs/Models/XmlItem.swift @@ -7,8 +7,6 @@ import Foundation - - public struct XmlItem: Codable { public var attributeString: String? @@ -73,7 +71,7 @@ public struct XmlItem: Codable { self.prefixNsWrappedArray = prefixNsWrappedArray } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case attributeString = "attribute_string" case attributeNumber = "attribute_number" case attributeInteger = "attribute_integer" @@ -105,6 +103,4 @@ public struct XmlItem: Codable { case prefixNsWrappedArray = "prefix_ns_wrapped_array" } - } - diff --git a/samples/client/petstore/swift4/rxswift/README.md b/samples/client/petstore/swift4/rxswift/README.md index 1e7f0a59ea..0711eb8705 100644 --- a/samples/client/petstore/swift4/rxswift/README.md +++ b/samples/client/petstore/swift4/rxswift/README.md @@ -73,10 +73,12 @@ Class | Method | HTTP request | Description - [ArrayTest](docs/ArrayTest.md) - [Capitalization](docs/Capitalization.md) - [Cat](docs/Cat.md) + - [CatAllOf](docs/CatAllOf.md) - [Category](docs/Category.md) - [ClassModel](docs/ClassModel.md) - [Client](docs/Client.md) - [Dog](docs/Dog.md) + - [DogAllOf](docs/DogAllOf.md) - [EnumArrays](docs/EnumArrays.md) - [EnumClass](docs/EnumClass.md) - [EnumTest](docs/EnumTest.md) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift index 2fcc05ca06..a411b77491 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Alamofire.swift @@ -135,8 +135,7 @@ public func request( parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest -{ + -> DataRequest { return SessionManager.default.request( url, method: method, @@ -183,8 +182,7 @@ public func download( encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download( url, method: method, @@ -209,8 +207,7 @@ public func download( public func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(urlRequest, to: destination) } @@ -239,8 +236,7 @@ public func download( public func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest -{ + -> DownloadRequest { return SessionManager.default.download(resumingWith: resumeData, to: destination) } @@ -263,8 +259,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(fileURL, to: url, method: method, headers: headers) } @@ -297,8 +292,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(data, to: url, method: method, headers: headers) } @@ -331,8 +325,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest -{ + -> UploadRequest { return SessionManager.default.upload(stream, to: url, method: method, headers: headers) } @@ -379,8 +372,7 @@ public func upload( to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, @@ -416,8 +408,7 @@ public func upload( multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) -{ + encodingCompletion: ((SessionManager.MultipartFormDataEncodingResult) -> Void)?) { return SessionManager.default.upload( multipartFormData: multipartFormData, usingThreshold: encodingMemoryThreshold, diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift index 057e68b977..85a0685748 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/MultipartFormData.swift @@ -275,8 +275,7 @@ open class MultipartFormData { } bodyContentLength = fileSize.uint64Value - } - catch { + } catch { setBodyPartError(withReason: .bodyPartFileSizeQueryFailedWithError(forURL: fileURL, error: error)) return } @@ -312,8 +311,7 @@ open class MultipartFormData { withLength length: UInt64, name: String, fileName: String, - mimeType: String) - { + mimeType: String) { let headers = contentHeaders(withName: name, fileName: fileName, mimeType: mimeType) append(stream, withLength: length, headers: headers) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift index 3ff2e7fc27..60bda83d2f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/NetworkReachabilityManager.swift @@ -146,8 +146,7 @@ open class NetworkReachabilityManager { context.info = Unmanaged.passUnretained(self).toOpaque() let callbackEnabled = SCNetworkReachabilitySetCallback( - reachability, - { (_, flags, info) in + reachability, { (_, flags, info) in let reachability = Unmanaged.fromOpaque(info!).takeUnretainedValue() reachability.notifyListener(flags) }, @@ -216,8 +215,7 @@ extension NetworkReachabilityManager.NetworkReachabilityStatus: Equatable {} public func ==( lhs: NetworkReachabilityManager.NetworkReachabilityStatus, rhs: NetworkReachabilityManager.NetworkReachabilityStatus) - -> Bool -{ + -> Bool { switch (lhs, rhs) { case (.unknown, .unknown): return true diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift index 4a54f2dd00..344a048cad 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ParameterEncoding.swift @@ -435,8 +435,7 @@ public struct PropertyListEncoding: ParameterEncoding { /// - returns: The new `PropertyListEncoding` instance. public init( format: PropertyListSerialization.PropertyListFormat = .xml, - options: PropertyListSerialization.WriteOptions = 0) - { + options: PropertyListSerialization.WriteOptions = 0) { self.format = format self.options = options } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Request.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Request.swift index ea43411377..18b83a0e73 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Request.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Request.swift @@ -161,8 +161,7 @@ open class Request { user: String, password: String, persistence: URLCredential.Persistence = .forSession) - -> Self - { + -> Self { let credential = URLCredential(user: user, password: password, persistence: persistence) return authenticate(usingCredential: credential) } @@ -538,8 +537,7 @@ open class DownloadRequest: Request { open class func suggestedDownloadDestination( for directory: FileManager.SearchPathDirectory = .documentDirectory, in domain: FileManager.SearchPathDomainMask = .userDomainMask) - -> DownloadFileDestination - { + -> DownloadFileDestination { return { temporaryURL, response in let directoryURLs = FileManager.default.urls(for: directory, in: domain) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Response.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Response.swift index 74b1ef54d0..23571383ba 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Response.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Response.swift @@ -58,8 +58,7 @@ public struct DefaultDataResponse { data: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.data = data @@ -109,8 +108,7 @@ public struct DataResponse { response: HTTPURLResponse?, data: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.data = data @@ -296,8 +294,7 @@ public struct DefaultDownloadResponse { resumeData: Data?, error: Error?, timeline: Timeline = Timeline(), - metrics: AnyObject? = nil) - { + metrics: AnyObject? = nil) { self.request = request self.response = response self.temporaryURL = temporaryURL @@ -359,8 +356,7 @@ public struct DownloadResponse { destinationURL: URL?, resumeData: Data?, result: Result, - timeline: Timeline = Timeline()) - { + timeline: Timeline = Timeline()) { self.request = request self.response = response self.temporaryURL = temporaryURL diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift index 3333726d5c..fd049edac1 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ResponseSerialization.swift @@ -144,8 +144,7 @@ extension DataRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -182,8 +181,7 @@ extension DownloadRequest { public func response( queue: DispatchQueue? = nil, completionHandler: @escaping (DefaultDownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { (queue ?? DispatchQueue.main).async { var downloadResponse = DefaultDownloadResponse( @@ -218,8 +216,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, responseSerializer: T, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { delegate.queue.addOperation { let result = responseSerializer.serializeResponse( self.request, @@ -289,8 +286,7 @@ extension DataRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.dataResponseSerializer(), @@ -329,8 +325,7 @@ extension DownloadRequest { public func responseData( queue: DispatchQueue? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.dataResponseSerializer(), @@ -356,8 +351,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success("") } @@ -411,8 +405,7 @@ extension DataRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.stringResponseSerializer(encoding: encoding), @@ -459,8 +452,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, encoding: String.Encoding? = nil, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.stringResponseSerializer(encoding: encoding), @@ -486,8 +478,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -514,8 +505,7 @@ extension DataRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponseJSON(options: options, response: response, data: data, error: error) } @@ -532,8 +522,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.jsonResponseSerializer(options: options), @@ -551,8 +540,7 @@ extension DownloadRequest { /// - returns: A JSON object response serializer. public static func jsonResponseSerializer( options: JSONSerialization.ReadingOptions = .allowFragments) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -580,8 +568,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: JSONSerialization.ReadingOptions = .allowFragments, completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.jsonResponseSerializer(options: options), @@ -607,8 +594,7 @@ extension Request { response: HTTPURLResponse?, data: Data?, error: Error?) - -> Result - { + -> Result { guard error == nil else { return .failure(error!) } if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(NSNull()) } @@ -635,8 +621,7 @@ extension DataRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DataResponseSerializer - { + -> DataResponseSerializer { return DataResponseSerializer { _, response, data, error in return Request.serializeResponsePropertyList(options: options, response: response, data: data, error: error) } @@ -653,8 +638,7 @@ extension DataRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DataResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DataRequest.propertyListResponseSerializer(options: options), @@ -672,8 +656,7 @@ extension DownloadRequest { /// - returns: A property list object response serializer. public static func propertyListResponseSerializer( options: PropertyListSerialization.ReadOptions = []) - -> DownloadResponseSerializer - { + -> DownloadResponseSerializer { return DownloadResponseSerializer { _, response, fileURL, error in guard error == nil else { return .failure(error!) } @@ -701,8 +684,7 @@ extension DownloadRequest { queue: DispatchQueue? = nil, options: PropertyListSerialization.ReadOptions = [], completionHandler: @escaping (DownloadResponse) -> Void) - -> Self - { + -> Self { return response( queue: queue, responseSerializer: DownloadRequest.propertyListResponseSerializer(options: options), diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift index 7f44c8d2c6..d50e941fab 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/ServerTrustPolicy.swift @@ -249,7 +249,6 @@ public enum ServerTrustPolicy { let unspecified = SecTrustResultType.unspecified let proceed = SecTrustResultType.proceed - isValid = result == unspecified || result == proceed } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift index 03bcb7ced6..17d0d9f150 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionDelegate.swift @@ -255,8 +255,7 @@ extension SessionDelegate: URLSessionDelegate { open func urlSession( _ session: URLSession, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard sessionDidReceiveChallengeWithCompletion == nil else { sessionDidReceiveChallengeWithCompletion?(session, challenge, completionHandler) return @@ -315,8 +314,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { guard taskWillPerformHTTPRedirectionWithCompletion == nil else { taskWillPerformHTTPRedirectionWithCompletion?(session, task, response, request, completionHandler) return @@ -342,8 +340,7 @@ extension SessionDelegate: URLSessionTaskDelegate { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { guard taskDidReceiveChallengeWithCompletion == nil else { taskDidReceiveChallengeWithCompletion?(session, task, challenge, completionHandler) return @@ -372,8 +369,7 @@ extension SessionDelegate: URLSessionTaskDelegate { open func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { guard taskNeedNewBodyStreamWithCompletion == nil else { taskNeedNewBodyStreamWithCompletion?(session, task, completionHandler) return @@ -398,8 +394,7 @@ extension SessionDelegate: URLSessionTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if let taskDidSendBodyData = taskDidSendBodyData { taskDidSendBodyData(session, task, bytesSent, totalBytesSent, totalBytesExpectedToSend) } else if let delegate = self[task]?.delegate as? UploadTaskDelegate { @@ -512,8 +507,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { guard dataTaskDidReceiveResponseWithCompletion == nil else { dataTaskDidReceiveResponseWithCompletion?(session, dataTask, response, completionHandler) return @@ -536,8 +530,7 @@ extension SessionDelegate: URLSessionDataDelegate { open func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { if let dataTaskDidBecomeDownloadTask = dataTaskDidBecomeDownloadTask { dataTaskDidBecomeDownloadTask(session, dataTask, downloadTask) } else { @@ -573,8 +566,7 @@ extension SessionDelegate: URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { guard dataTaskWillCacheResponseWithCompletion == nil else { dataTaskWillCacheResponseWithCompletion?(session, dataTask, proposedResponse, completionHandler) return @@ -608,8 +600,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { open func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { if let downloadTaskDidFinishDownloadingToURL = downloadTaskDidFinishDownloadingToURL { downloadTaskDidFinishDownloadingToURL(session, downloadTask, location) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -632,8 +623,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if let downloadTaskDidWriteData = downloadTaskDidWriteData { downloadTaskDidWriteData(session, downloadTask, bytesWritten, totalBytesWritten, totalBytesExpectedToWrite) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -661,8 +651,7 @@ extension SessionDelegate: URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else if let delegate = self[downloadTask]?.delegate as? DownloadTaskDelegate { @@ -716,8 +705,7 @@ extension SessionDelegate: URLSessionStreamDelegate { _ session: URLSession, streamTask: URLSessionStreamTask, didBecome inputStream: InputStream, - outputStream: OutputStream) - { + outputStream: OutputStream) { streamTaskDidBecomeInputAndOutputStreams?(session, streamTask, inputStream, outputStream) } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift index 8779efdaa6..8c10706677 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/SessionManager.swift @@ -166,8 +166,7 @@ open class SessionManager { public init( configuration: URLSessionConfiguration = URLSessionConfiguration.default, delegate: SessionDelegate = SessionDelegate(), - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { self.delegate = delegate self.session = URLSession(configuration: configuration, delegate: delegate, delegateQueue: nil) @@ -185,8 +184,7 @@ open class SessionManager { public init?( session: URLSession, delegate: SessionDelegate, - serverTrustPolicyManager: ServerTrustPolicyManager? = nil) - { + serverTrustPolicyManager: ServerTrustPolicyManager? = nil) { guard delegate === session.delegate else { return nil } self.delegate = delegate @@ -229,8 +227,7 @@ open class SessionManager { parameters: Parameters? = nil, encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil) - -> DataRequest - { + -> DataRequest { var originalRequest: URLRequest? do { @@ -320,8 +317,7 @@ open class SessionManager { encoding: ParameterEncoding = URLEncoding.default, headers: HTTPHeaders? = nil, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) let encodedURLRequest = try encoding.encode(urlRequest, with: parameters) @@ -347,8 +343,7 @@ open class SessionManager { open func download( _ urlRequest: URLRequestConvertible, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { do { let urlRequest = try urlRequest.asURLRequest() return download(.request(urlRequest), to: destination) @@ -384,8 +379,7 @@ open class SessionManager { open func download( resumingWith resumeData: Data, to destination: DownloadRequest.DownloadFileDestination? = nil) - -> DownloadRequest - { + -> DownloadRequest { return download(.resumeData(resumeData), to: destination) } @@ -394,8 +388,7 @@ open class SessionManager { private func download( _ downloadable: DownloadRequest.Downloadable, to destination: DownloadRequest.DownloadFileDestination?) - -> DownloadRequest - { + -> DownloadRequest { do { let task = try downloadable.task(session: session, adapter: adapter, queue: queue) let download = DownloadRequest(session: session, requestTask: .download(downloadable, task)) @@ -416,8 +409,7 @@ open class SessionManager { _ downloadable: DownloadRequest.Downloadable?, to destination: DownloadRequest.DownloadFileDestination?, failedWith error: Error) - -> DownloadRequest - { + -> DownloadRequest { var downloadTask: Request.RequestTask = .download(nil, nil) if let downloadable = downloadable { @@ -458,8 +450,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(fileURL, with: urlRequest) @@ -504,8 +495,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(data, with: urlRequest) @@ -550,8 +540,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil) - -> UploadRequest - { + -> UploadRequest { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) return upload(stream, with: urlRequest) @@ -611,8 +600,7 @@ open class SessionManager { to url: URLConvertible, method: HTTPMethod = .post, headers: HTTPHeaders? = nil, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { do { let urlRequest = try URLRequest(url: url, method: method, headers: headers) @@ -654,8 +642,7 @@ open class SessionManager { multipartFormData: @escaping (MultipartFormData) -> Void, usingThreshold encodingMemoryThreshold: UInt64 = SessionManager.multipartFormDataEncodingMemoryThreshold, with urlRequest: URLRequestConvertible, - encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) - { + encodingCompletion: ((MultipartFormDataEncodingResult) -> Void)?) { DispatchQueue.global(qos: .utility).async { let formData = MultipartFormData() multipartFormData(formData) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift index 8e19888fc8..12fcbe92d3 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/TaskDelegate.swift @@ -94,8 +94,7 @@ open class TaskDelegate: NSObject { task: URLSessionTask, willPerformHTTPRedirection response: HTTPURLResponse, newRequest request: URLRequest, - completionHandler: @escaping (URLRequest?) -> Void) - { + completionHandler: @escaping (URLRequest?) -> Void) { var redirectRequest: URLRequest? = request if let taskWillPerformHTTPRedirection = taskWillPerformHTTPRedirection { @@ -110,8 +109,7 @@ open class TaskDelegate: NSObject { _ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, - completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) - { + completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { var disposition: URLSession.AuthChallengeDisposition = .performDefaultHandling var credential: URLCredential? @@ -150,8 +148,7 @@ open class TaskDelegate: NSObject { func urlSession( _ session: URLSession, task: URLSessionTask, - needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) - { + needNewBodyStream completionHandler: @escaping (InputStream?) -> Void) { var bodyStream: InputStream? if let taskNeedNewBodyStream = taskNeedNewBodyStream { @@ -237,8 +234,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, didReceive response: URLResponse, - completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) - { + completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) { var disposition: URLSession.ResponseDisposition = .allow expectedContentLength = response.expectedContentLength @@ -253,8 +249,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { func urlSession( _ session: URLSession, dataTask: URLSessionDataTask, - didBecome downloadTask: URLSessionDownloadTask) - { + didBecome downloadTask: URLSessionDownloadTask) { dataTaskDidBecomeDownloadTask?(session, dataTask, downloadTask) } @@ -287,8 +282,7 @@ class DataTaskDelegate: TaskDelegate, URLSessionDataDelegate { _ session: URLSession, dataTask: URLSessionDataTask, willCacheResponse proposedResponse: CachedURLResponse, - completionHandler: @escaping (CachedURLResponse?) -> Void) - { + completionHandler: @escaping (CachedURLResponse?) -> Void) { var cachedResponse: CachedURLResponse? = proposedResponse if let dataTaskWillCacheResponse = dataTaskWillCacheResponse { @@ -343,8 +337,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { func urlSession( _ session: URLSession, downloadTask: URLSessionDownloadTask, - didFinishDownloadingTo location: URL) - { + didFinishDownloadingTo location: URL) { temporaryURL = location guard @@ -379,8 +372,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { downloadTask: URLSessionDownloadTask, didWriteData bytesWritten: Int64, totalBytesWritten: Int64, - totalBytesExpectedToWrite: Int64) - { + totalBytesExpectedToWrite: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let downloadTaskDidWriteData = downloadTaskDidWriteData { @@ -405,8 +397,7 @@ class DownloadTaskDelegate: TaskDelegate, URLSessionDownloadDelegate { _ session: URLSession, downloadTask: URLSessionDownloadTask, didResumeAtOffset fileOffset: Int64, - expectedTotalBytes: Int64) - { + expectedTotalBytes: Int64) { if let downloadTaskDidResumeAtOffset = downloadTaskDidResumeAtOffset { downloadTaskDidResumeAtOffset(session, downloadTask, fileOffset, expectedTotalBytes) } else { @@ -448,8 +439,7 @@ class UploadTaskDelegate: DataTaskDelegate { task: URLSessionTask, didSendBodyData bytesSent: Int64, totalBytesSent: Int64, - totalBytesExpectedToSend: Int64) - { + totalBytesExpectedToSend: Int64) { if initialResponseTime == nil { initialResponseTime = CFAbsoluteTimeGetCurrent() } if let taskDidSendBodyData = taskDidSendBodyData { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift index 181c9883cb..b318b1ff48 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Timeline.swift @@ -64,8 +64,7 @@ public struct Timeline { requestStartTime: CFAbsoluteTime = 0.0, initialResponseTime: CFAbsoluteTime = 0.0, requestCompletedTime: CFAbsoluteTime = 0.0, - serializationCompletedTime: CFAbsoluteTime = 0.0) - { + serializationCompletedTime: CFAbsoluteTime = 0.0) { self.requestStartTime = requestStartTime self.initialResponseTime = initialResponseTime self.requestCompletedTime = requestCompletedTime diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift index ec2c5c35a0..deaee34ad8 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/Alamofire/Source/Validation.swift @@ -94,8 +94,7 @@ extension Request { statusCode acceptableStatusCodes: S, response: HTTPURLResponse) -> ValidationResult - where S.Iterator.Element == Int - { + where S.Iterator.Element == Int { if acceptableStatusCodes.contains(response.statusCode) { return .success } else { @@ -111,8 +110,7 @@ extension Request { response: HTTPURLResponse, data: Data?) -> ValidationResult - where S.Iterator.Element == String - { + where S.Iterator.Element == String { guard let data = data, data.count > 0 else { return .success } guard diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIHelper.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIHelper.swift index 3c7b53f814..447a87c094 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIHelper.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIHelper.swift @@ -7,7 +7,7 @@ import Foundation public struct APIHelper { - public static func rejectNil(_ source: [String:Any?]) -> [String:Any]? { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { let destination = source.reduce(into: [String: Any]()) { (result, item) in if let value = item.value { result[item.key] = value @@ -20,17 +20,17 @@ public struct APIHelper { return destination } - public static func rejectNilHeaders(_ source: [String:Any?]) -> [String:String] { + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { return source.reduce(into: [String: String]()) { (result, item) in if let collection = item.value as? Array { - result[item.key] = collection.filter({ $0 != nil }).map{ "\($0!)" }.joined(separator: ",") + result[item.key] = collection.filter({ $0 != nil }).map { "\($0!)" }.joined(separator: ",") } else if let value: Any = item.value { result[item.key] = "\(value)" } } } - public static func convertBoolToString(_ source: [String: Any]?) -> [String:Any]? { + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { guard let source = source else { return nil } @@ -45,8 +45,7 @@ public struct APIHelper { }) } - - public static func mapValuesToQueryItems(_ source: [String:Any?]) -> [URLQueryItem]? { + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { let destination = source.filter({ $0.value != nil}).reduce(into: [URLQueryItem]()) { (result, item) in if let collection = item.value as? Array { let value = collection.filter({ $0 != nil }).map({"\($0!)"}).joined(separator: ",") @@ -62,4 +61,3 @@ public struct APIHelper { return destination } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs.swift index 8cae3aacfe..bb2f200ba3 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs.swift @@ -9,22 +9,22 @@ import Foundation open class PetstoreClientAPI { open static var basePath = "http://petstore.swagger.io:80/v2" open static var credential: URLCredential? - open static var customHeaders: [String:String] = [:] + open static var customHeaders: [String: String] = [:] open static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory() } open class RequestBuilder { var credential: URLCredential? - var headers: [String:String] - public let parameters: [String:Any]? + var headers: [String: String] + public let parameters: [String: Any]? public let isBody: Bool public let method: String public let URLString: String /// Optional block to obtain a reference to the request's progress instance when available. - public var onProgressReady: ((Progress) -> ())? + public var onProgressReady: ((Progress) -> Void)? - required public init(method: String, URLString: String, parameters: [String:Any]?, isBody: Bool, headers: [String:String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { self.method = method self.URLString = URLString self.parameters = parameters @@ -34,7 +34,7 @@ open class RequestBuilder { addHeaders(PetstoreClientAPI.customHeaders) } - open func addHeaders(_ aHeaders:[String:String]) { + open func addHeaders(_ aHeaders: [String: String]) { for (header, value) in aHeaders { headers[header] = value } @@ -57,5 +57,5 @@ open class RequestBuilder { public protocol RequestBuilderFactory { func getNonDecodableBuilder() -> RequestBuilder.Type - func getBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift index 637fa6df55..2fadeb51ce 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/AnotherFakeAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class AnotherFakeAPI { /** To test special tags @@ -18,7 +16,7 @@ open class AnotherFakeAPI { - parameter client: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testSpecialTags(client: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testSpecialTags(client: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testSpecialTagsWithRequestBuilder(client: client).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift index 31285485c0..404824a2c7 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeAPI.swift @@ -9,15 +9,13 @@ import Foundation import Alamofire import RxSwift - - open class FakeAPI { /** - parameter body: (body) Input boolean as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?,_ error: Error?) -> Void)) { + open class func fakeOuterBooleanSerialize(body: Bool? = nil, completion: @escaping ((_ data: Bool?, _ error: Error?) -> Void)) { fakeOuterBooleanSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -47,7 +45,7 @@ open class FakeAPI { - Test serialization of outer boolean types - examples: [{contentType=*/*, example=null}] - parameter body: (body) Input boolean as post body (optional) - - returns: RequestBuilder + - returns: RequestBuilder */ open class func fakeOuterBooleanSerializeWithRequestBuilder(body: Bool? = nil) -> RequestBuilder { let path = "/fake/outer/boolean" @@ -66,7 +64,7 @@ open class FakeAPI { - parameter outerComposite: (body) Input composite as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterCompositeSerialize(outerComposite: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?,_ error: Error?) -> Void)) { + open class func fakeOuterCompositeSerialize(outerComposite: OuterComposite? = nil, completion: @escaping ((_ data: OuterComposite?, _ error: Error?) -> Void)) { fakeOuterCompositeSerializeWithRequestBuilder(outerComposite: outerComposite).execute { (response, error) -> Void in completion(response?.body, error) } @@ -94,9 +92,9 @@ open class FakeAPI { /** - POST /fake/outer/composite - Test serialization of object with outer number type - - examples: [{contentType=*/*, example={ }}] + - examples: [{contentType=*/*, example= { }}] - parameter outerComposite: (body) Input composite as post body (optional) - - returns: RequestBuilder + - returns: RequestBuilder */ open class func fakeOuterCompositeSerializeWithRequestBuilder(outerComposite: OuterComposite? = nil) -> RequestBuilder { let path = "/fake/outer/composite" @@ -115,7 +113,7 @@ open class FakeAPI { - parameter body: (body) Input number as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?,_ error: Error?) -> Void)) { + open class func fakeOuterNumberSerialize(body: Double? = nil, completion: @escaping ((_ data: Double?, _ error: Error?) -> Void)) { fakeOuterNumberSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -145,7 +143,7 @@ open class FakeAPI { - Test serialization of outer number types - examples: [{contentType=*/*, example=null}] - parameter body: (body) Input number as post body (optional) - - returns: RequestBuilder + - returns: RequestBuilder */ open class func fakeOuterNumberSerializeWithRequestBuilder(body: Double? = nil) -> RequestBuilder { let path = "/fake/outer/number" @@ -164,7 +162,7 @@ open class FakeAPI { - parameter body: (body) Input string as post body (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func fakeOuterStringSerialize(body: String? = nil, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { fakeOuterStringSerializeWithRequestBuilder(body: body).execute { (response, error) -> Void in completion(response?.body, error) } @@ -194,7 +192,7 @@ open class FakeAPI { - Test serialization of outer string types - examples: [{contentType=*/*, example=null}] - parameter body: (body) Input string as post body (optional) - - returns: RequestBuilder + - returns: RequestBuilder */ open class func fakeOuterStringSerializeWithRequestBuilder(body: String? = nil) -> RequestBuilder { let path = "/fake/outer/string" @@ -214,8 +212,8 @@ open class FakeAPI { - parameter user: (body) - parameter completion: completion handler to receive the data and the error objects */ - open class func testBodyWithQueryParams(query: String, user: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - testBodyWithQueryParamsWithRequestBuilder(query: query, user: user).execute { (response, error) -> Void in + open class func testBodyWithQueryParams(query: String, user: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + testBodyWithQueryParamsWithRequestBuilder(query: query, user: user).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -271,7 +269,7 @@ open class FakeAPI { - parameter client: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClientModel(client: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClientModel(client: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClientModelWithRequestBuilder(client: client).execute { (response, error) -> Void in completion(response?.body, error) } @@ -338,8 +336,8 @@ open class FakeAPI { - parameter callback: (form) None (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - testEndpointParametersWithRequestBuilder(number: number, double: double, patternWithoutDelimiter: patternWithoutDelimiter, byte: byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback).execute { (response, error) -> Void in + open class func testEndpointParameters(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + testEndpointParametersWithRequestBuilder(number: number, double: double, patternWithoutDelimiter: patternWithoutDelimiter, byte: byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -407,7 +405,7 @@ open class FakeAPI { open class func testEndpointParametersWithRequestBuilder(number: Double, double: Double, patternWithoutDelimiter: String, byte: Data, integer: Int? = nil, int32: Int? = nil, int64: Int64? = nil, float: Float? = nil, string: String? = nil, binary: URL? = nil, date: Date? = nil, dateTime: Date? = nil, password: String? = nil, callback: String? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "integer": integer?.encodeToJSON(), "int32": int32?.encodeToJSON(), "int64": int64?.encodeToJSON(), @@ -426,7 +424,7 @@ open class FakeAPI { let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -514,8 +512,8 @@ open class FakeAPI { - parameter enumFormString: (form) Form parameter enum test (string) (optional, default to "-efg") - parameter completion: completion handler to receive the data and the error objects */ - open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - testEnumParametersWithRequestBuilder(enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString).execute { (response, error) -> Void in + open class func testEnumParameters(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + testEnumParametersWithRequestBuilder(enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -568,19 +566,19 @@ open class FakeAPI { open class func testEnumParametersWithRequestBuilder(enumHeaderStringArray: [String]? = nil, enumHeaderString: EnumHeaderString_testEnumParameters? = nil, enumQueryStringArray: [String]? = nil, enumQueryString: EnumQueryString_testEnumParameters? = nil, enumQueryInteger: EnumQueryInteger_testEnumParameters? = nil, enumQueryDouble: EnumQueryDouble_testEnumParameters? = nil, enumFormStringArray: [String]? = nil, enumFormString: EnumFormString_testEnumParameters? = nil) -> RequestBuilder { let path = "/fake" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "enum_form_string_array": enumFormStringArray, "enum_form_string": enumFormString?.rawValue ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "enum_query_string_array": enumQueryStringArray, - "enum_query_string": enumQueryString?.rawValue, - "enum_query_integer": enumQueryInteger?.rawValue, + "enum_query_string_array": enumQueryStringArray, + "enum_query_string": enumQueryString?.rawValue, + "enum_query_integer": enumQueryInteger?.rawValue, "enum_query_double": enumQueryDouble?.rawValue ]) let nillableHeaders: [String: Any?] = [ @@ -600,8 +598,8 @@ open class FakeAPI { - parameter requestBody: (body) request body - parameter completion: completion handler to receive the data and the error objects */ - open class func testInlineAdditionalProperties(requestBody: [String:String], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - testInlineAdditionalPropertiesWithRequestBuilder(requestBody: requestBody).execute { (response, error) -> Void in + open class func testInlineAdditionalProperties(requestBody: [String: String], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + testInlineAdditionalPropertiesWithRequestBuilder(requestBody: requestBody).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -616,7 +614,7 @@ open class FakeAPI { - parameter requestBody: (body) request body - returns: Observable */ - open class func testInlineAdditionalProperties(requestBody: [String:String]) -> Observable { + open class func testInlineAdditionalProperties(requestBody: [String: String]) -> Observable { return Observable.create { observer -> Disposable in testInlineAdditionalProperties(requestBody: requestBody) { data, error in if let error = error { @@ -636,7 +634,7 @@ open class FakeAPI { - parameter requestBody: (body) request body - returns: RequestBuilder */ - open class func testInlineAdditionalPropertiesWithRequestBuilder(requestBody: [String:String]) -> RequestBuilder { + open class func testInlineAdditionalPropertiesWithRequestBuilder(requestBody: [String: String]) -> RequestBuilder { let path = "/fake/inline-additionalProperties" let URLString = PetstoreClientAPI.basePath + path let parameters = JSONEncodingHelper.encodingParameters(forEncodableObject: requestBody) @@ -655,8 +653,8 @@ open class FakeAPI { - parameter param2: (form) field2 - parameter completion: completion handler to receive the data and the error objects */ - open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - testJsonFormDataWithRequestBuilder(param: param, param2: param2).execute { (response, error) -> Void in + open class func testJsonFormData(param: String, param2: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + testJsonFormDataWithRequestBuilder(param: param, param2: param2).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -696,14 +694,14 @@ open class FakeAPI { open class func testJsonFormDataWithRequestBuilder(param: String, param2: String) -> RequestBuilder { let path = "/fake/jsonFormData" let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "param": param, "param2": param2 ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift index b4003e2c25..b14e41a990 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/FakeClassnameTags123API.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class FakeClassnameTags123API { /** To test class name in snake case @@ -18,7 +16,7 @@ open class FakeClassnameTags123API { - parameter client: (body) client model - parameter completion: completion handler to receive the data and the error objects */ - open class func testClassname(client: Client, completion: @escaping ((_ data: Client?,_ error: Error?) -> Void)) { + open class func testClassname(client: Client, completion: @escaping ((_ data: Client?, _ error: Error?) -> Void)) { testClassnameWithRequestBuilder(client: client).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift index 59dab5ba43..5bfe5c64b2 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/PetAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class PetAPI { /** Add a new pet to the store @@ -18,8 +16,8 @@ open class PetAPI { - parameter pet: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func addPet(pet: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - addPetWithRequestBuilder(pet: pet).execute { (response, error) -> Void in + open class func addPet(pet: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + addPetWithRequestBuilder(pet: pet).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -76,8 +74,8 @@ open class PetAPI { - parameter apiKey: (header) (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - deletePetWithRequestBuilder(petId: petId, apiKey: apiKey).execute { (response, error) -> Void in + open class func deletePet(petId: Int64, apiKey: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + deletePetWithRequestBuilder(petId: petId, apiKey: apiKey).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -123,8 +121,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let nillableHeaders: [String: Any?] = [ "api_key": apiKey @@ -151,7 +149,7 @@ open class PetAPI { - parameter status: (query) Status values that need to be considered for filter - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByStatus(status: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByStatusWithRequestBuilder(status: status).execute { (response, error) -> Void in completion(response?.body, error) } @@ -216,8 +214,8 @@ open class PetAPI { open class func findPetsByStatusWithRequestBuilder(status: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByStatus" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "status": status @@ -234,7 +232,7 @@ open class PetAPI { - parameter tags: (query) Tags to filter by - parameter completion: completion handler to receive the data and the error objects */ - open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?,_ error: Error?) -> Void)) { + open class func findPetsByTags(tags: [String], completion: @escaping ((_ data: [Pet]?, _ error: Error?) -> Void)) { findPetsByTagsWithRequestBuilder(tags: tags).execute { (response, error) -> Void in completion(response?.body, error) } @@ -299,8 +297,8 @@ open class PetAPI { open class func findPetsByTagsWithRequestBuilder(tags: [String]) -> RequestBuilder<[Pet]> { let path = "/pet/findByTags" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ "tags": tags @@ -317,7 +315,7 @@ open class PetAPI { - parameter petId: (path) ID of pet to return - parameter completion: completion handler to receive the data and the error objects */ - open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?,_ error: Error?) -> Void)) { + open class func getPetById(petId: Int64, completion: @escaping ((_ data: Pet?, _ error: Error?) -> Void)) { getPetByIdWithRequestBuilder(petId: petId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -385,8 +383,8 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -400,8 +398,8 @@ open class PetAPI { - parameter pet: (body) Pet object that needs to be added to the store - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePet(pet: Pet, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - updatePetWithRequestBuilder(pet: pet).execute { (response, error) -> Void in + open class func updatePet(pet: Pet, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + updatePetWithRequestBuilder(pet: pet).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -459,8 +457,8 @@ open class PetAPI { - parameter status: (form) Updated status of the pet (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - updatePetWithFormWithRequestBuilder(petId: petId, name: name, status: status).execute { (response, error) -> Void in + open class func updatePetWithForm(petId: Int64, name: String? = nil, status: String? = nil, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + updatePetWithFormWithRequestBuilder(petId: petId, name: name, status: status).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -508,14 +506,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "name": name, "status": status ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -531,7 +529,7 @@ open class PetAPI { - parameter file: (form) file to upload (optional) - parameter completion: completion handler to receive the data and the error objects */ - open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?,_ error: Error?) -> Void)) { + open class func uploadFile(petId: Int64, additionalMetadata: String? = nil, file: URL? = nil, completion: @escaping ((_ data: ApiResponse?, _ error: Error?) -> Void)) { uploadFileWithRequestBuilder(petId: petId, additionalMetadata: additionalMetadata, file: file).execute { (response, error) -> Void in completion(response?.body, error) } @@ -581,14 +579,14 @@ open class PetAPI { let petIdPostEscape = petIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{petId}", with: petIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let formParams: [String:Any?] = [ + let formParams: [String: Any?] = [ "additionalMetadata": additionalMetadata, "file": file ] let nonNullParameters = APIHelper.rejectNil(formParams) let parameters = APIHelper.convertBoolToString(nonNullParameters) - + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift index b4e23ae435..4fb14bc42d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/StoreAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class StoreAPI { /** Delete purchase order by ID @@ -18,8 +16,8 @@ open class StoreAPI { - parameter orderId: (path) ID of the order that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - deleteOrderWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in + open class func deleteOrder(orderId: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + deleteOrderWithRequestBuilder(orderId: orderId).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -61,8 +59,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -75,7 +73,7 @@ open class StoreAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func getInventory(completion: @escaping ((_ data: [String:Int]?,_ error: Error?) -> Void)) { + open class func getInventory(completion: @escaping ((_ data: [String: Int]?, _ error: Error?) -> Void)) { getInventoryWithRequestBuilder().execute { (response, error) -> Void in completion(response?.body, error) } @@ -86,9 +84,9 @@ open class StoreAPI { - returns: Observable<[String:Int]> */ - open class func getInventory() -> Observable<[String:Int]> { + open class func getInventory() -> Observable<[String: Int]> { return Observable.create { observer -> Disposable in - getInventory() { data, error in + getInventory { data, error in if let error = error { observer.on(.error(error)) } else { @@ -109,14 +107,14 @@ open class StoreAPI { - name: api_key - returns: RequestBuilder<[String:Int]> */ - open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String:Int]> { + open class func getInventoryWithRequestBuilder() -> RequestBuilder<[String: Int]> { let path = "/store/inventory" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) - let requestBuilder: RequestBuilder<[String:Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() + let requestBuilder: RequestBuilder<[String: Int]>.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() return requestBuilder.init(method: "GET", URLString: (url?.string ?? URLString), parameters: parameters, isBody: false) } @@ -127,7 +125,7 @@ open class StoreAPI { - parameter orderId: (path) ID of pet that needs to be fetched - parameter completion: completion handler to receive the data and the error objects */ - open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func getOrderById(orderId: Int64, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { getOrderByIdWithRequestBuilder(orderId: orderId).execute { (response, error) -> Void in completion(response?.body, error) } @@ -181,8 +179,8 @@ open class StoreAPI { let orderIdPostEscape = orderIdPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{order_id}", with: orderIdPostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -196,7 +194,7 @@ open class StoreAPI { - parameter order: (body) order placed for purchasing the pet - parameter completion: completion handler to receive the data and the error objects */ - open class func placeOrder(order: Order, completion: @escaping ((_ data: Order?,_ error: Error?) -> Void)) { + open class func placeOrder(order: Order, completion: @escaping ((_ data: Order?, _ error: Error?) -> Void)) { placeOrderWithRequestBuilder(order: order).execute { (response, error) -> Void in completion(response?.body, error) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift index 7a2e5332ad..9f5e670bfc 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/APIs/UserAPI.swift @@ -9,8 +9,6 @@ import Foundation import Alamofire import RxSwift - - open class UserAPI { /** Create user @@ -18,8 +16,8 @@ open class UserAPI { - parameter user: (body) Created user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUser(user: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - createUserWithRequestBuilder(user: user).execute { (response, error) -> Void in + open class func createUser(user: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + createUserWithRequestBuilder(user: user).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -73,8 +71,8 @@ open class UserAPI { - parameter user: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithArrayInput(user: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - createUsersWithArrayInputWithRequestBuilder(user: user).execute { (response, error) -> Void in + open class func createUsersWithArrayInput(user: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + createUsersWithArrayInputWithRequestBuilder(user: user).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -127,8 +125,8 @@ open class UserAPI { - parameter user: (body) List of user object - parameter completion: completion handler to receive the data and the error objects */ - open class func createUsersWithListInput(user: [User], completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - createUsersWithListInputWithRequestBuilder(user: user).execute { (response, error) -> Void in + open class func createUsersWithListInput(user: [User], completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + createUsersWithListInputWithRequestBuilder(user: user).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -181,8 +179,8 @@ open class UserAPI { - parameter username: (path) The name that needs to be deleted - parameter completion: completion handler to receive the data and the error objects */ - open class func deleteUser(username: String, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - deleteUserWithRequestBuilder(username: username).execute { (response, error) -> Void in + open class func deleteUser(username: String, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + deleteUserWithRequestBuilder(username: username).execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -224,8 +222,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -239,7 +237,7 @@ open class UserAPI { - parameter username: (path) The name that needs to be fetched. Use user1 for testing. - parameter completion: completion handler to receive the data and the error objects */ - open class func getUserByName(username: String, completion: @escaping ((_ data: User?,_ error: Error?) -> Void)) { + open class func getUserByName(username: String, completion: @escaping ((_ data: User?, _ error: Error?) -> Void)) { getUserByNameWithRequestBuilder(username: username).execute { (response, error) -> Void in completion(response?.body, error) } @@ -296,8 +294,8 @@ open class UserAPI { let usernamePostEscape = usernamePreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" path = path.replacingOccurrences(of: "{username}", with: usernamePostEscape, options: .literal, range: nil) let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getBuilder() @@ -312,7 +310,7 @@ open class UserAPI { - parameter password: (query) The password for login in clear text - parameter completion: completion handler to receive the data and the error objects */ - open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?,_ error: Error?) -> Void)) { + open class func loginUser(username: String, password: String, completion: @escaping ((_ data: String?, _ error: Error?) -> Void)) { loginUserWithRequestBuilder(username: username, password: password).execute { (response, error) -> Void in completion(response?.body, error) } @@ -350,11 +348,11 @@ open class UserAPI { open class func loginUserWithRequestBuilder(username: String, password: String) -> RequestBuilder { let path = "/user/login" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + var url = URLComponents(string: URLString) url?.queryItems = APIHelper.mapValuesToQueryItems([ - "username": username, + "username": username, "password": password ]) @@ -368,8 +366,8 @@ open class UserAPI { - parameter completion: completion handler to receive the data and the error objects */ - open class func logoutUser(completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - logoutUserWithRequestBuilder().execute { (response, error) -> Void in + open class func logoutUser(completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + logoutUserWithRequestBuilder().execute { (_, error) -> Void in if error == nil { completion((), error) } else { @@ -385,7 +383,7 @@ open class UserAPI { */ open class func logoutUser() -> Observable { return Observable.create { observer -> Disposable in - logoutUser() { data, error in + logoutUser { data, error in if let error = error { observer.on(.error(error)) } else { @@ -405,8 +403,8 @@ open class UserAPI { open class func logoutUserWithRequestBuilder() -> RequestBuilder { let path = "/user/logout" let URLString = PetstoreClientAPI.basePath + path - let parameters: [String:Any]? = nil - + let parameters: [String: Any]? = nil + let url = URLComponents(string: URLString) let requestBuilder: RequestBuilder.Type = PetstoreClientAPI.requestBuilderFactory.getNonDecodableBuilder() @@ -421,8 +419,8 @@ open class UserAPI { - parameter user: (body) Updated user object - parameter completion: completion handler to receive the data and the error objects */ - open class func updateUser(username: String, user: User, completion: @escaping ((_ data: Void?,_ error: Error?) -> Void)) { - updateUserWithRequestBuilder(username: username, user: user).execute { (response, error) -> Void in + open class func updateUser(username: String, user: User, completion: @escaping ((_ data: Void?, _ error: Error?) -> Void)) { + updateUserWithRequestBuilder(username: username, user: user).execute { (_, error) -> Void in if error == nil { completion((), error) } else { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift index 280b4e5338..8fc48ccbed 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/AlamofireImplementations.swift @@ -12,7 +12,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { return AlamofireRequestBuilder.self } - func getBuilder() -> RequestBuilder.Type { + func getBuilder() -> RequestBuilder.Type { return AlamofireDecodableRequestBuilder.self } } @@ -21,7 +21,7 @@ class AlamofireRequestBuilderFactory: RequestBuilderFactory { private var managerStore: [String: Alamofire.SessionManager] = [:] open class AlamofireRequestBuilder: RequestBuilder { - required public init(method: String, URLString: String, parameters: [String : Any]?, isBody: Bool, headers: [String : String] = [:]) { + required public init(method: String, URLString: String, parameters: [String: Any]?, isBody: Bool, headers: [String: String] = [:]) { super.init(method: method, URLString: URLString, parameters: parameters, isBody: isBody, headers: headers) } @@ -50,17 +50,17 @@ open class AlamofireRequestBuilder: RequestBuilder { May be overridden by a subclass if you want to control the request configuration (e.g. to override the cache policy). */ - open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String:String]) -> DataRequest { + open func makeRequest(manager: SessionManager, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) -> DataRequest { return manager.request(URLString, method: method, parameters: parameters, encoding: encoding, headers: headers) } override open func execute(_ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { - let managerId:String = UUID().uuidString + let managerId: String = UUID().uuidString // Create a new manager for each request to customize its request header let manager = createSessionManager() managerStore[managerId] = manager - let encoding:ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() + let encoding: ParameterEncoding = isBody ? JSONDataEncoding() : URLEncoding() let xMethod = Alamofire.HTTPMethod(rawValue: method) let fileKeys = parameters == nil ? [] : parameters!.filter { $1 is NSURL } @@ -73,8 +73,7 @@ open class AlamofireRequestBuilder: RequestBuilder { case let fileURL as URL: if let mimeType = self.contentTypeForFormPart(fileURL: fileURL) { mpForm.append(fileURL, withName: k, fileName: fileURL.lastPathComponent, mimeType: mimeType) - } - else { + } else { mpForm.append(fileURL, withName: k) } case let string as String: @@ -238,7 +237,7 @@ open class AlamofireRequestBuilder: RequestBuilder { return httpHeaders } - fileprivate func getFileName(fromContentDisposition contentDisposition : String?) -> String? { + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { guard let contentDisposition = contentDisposition else { return nil @@ -246,7 +245,7 @@ open class AlamofireRequestBuilder: RequestBuilder { let items = contentDisposition.components(separatedBy: ";") - var filename : String? = nil + var filename: String? for contentItem in items { @@ -257,7 +256,7 @@ open class AlamofireRequestBuilder: RequestBuilder { filename = contentItem return filename? - .replacingCharacters(in: range, with:"") + .replacingCharacters(in: range, with: "") .replacingOccurrences(of: "\"", with: "") .trimmingCharacters(in: .whitespacesAndNewlines) } @@ -266,7 +265,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getPath(from url : URL) throws -> String { + fileprivate func getPath(from url: URL) throws -> String { guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { throw DownloadException.requestMissingPath @@ -280,7 +279,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } - fileprivate func getURL(from urlRequest : URLRequest) throws -> URL { + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { guard let url = urlRequest.url else { throw DownloadException.requestMissingURL @@ -291,7 +290,7 @@ open class AlamofireRequestBuilder: RequestBuilder { } -fileprivate enum DownloadException : Error { +private enum DownloadException: Error { case responseDataMissing case responseFailed case requestMissing @@ -306,7 +305,7 @@ public enum AlamofireDecodableRequestBuilderError: Error { case generalError(Error) } -open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { +open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilder { override fileprivate func processRequest(request: DataRequest, _ managerId: String, _ completion: @escaping (_ response: Response?, _ error: Error?) -> Void) { if let credential = self.credential { @@ -398,7 +397,7 @@ open class AlamofireDecodableRequestBuilder: AlamofireRequestBuilde return } - var responseObj: Response? = nil + var responseObj: Response? let decodeResult: (decodableObj: T?, error: Error?) = CodableHelper.decode(T.self, from: data) if decodeResult.error == nil { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift index 2d50e463ae..27e6a28761 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/CodableHelper.swift @@ -13,9 +13,9 @@ open class CodableHelper { open static var dateformatter: DateFormatter? - open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T : Decodable { - var returnedDecodable: T? = nil - var returnedError: Error? = nil + open class func decode(_ type: T.Type, from data: Data) -> (decodableObj: T?, error: Error?) where T: Decodable { + var returnedDecodable: T? + var returnedError: Error? let decoder = JSONDecoder() if let df = self.dateformatter { @@ -39,9 +39,9 @@ open class CodableHelper { return (returnedDecodable, returnedError) } - open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T : Encodable { + open class func encode(_ value: T, prettyPrint: Bool = false) -> EncodeResult where T: Encodable { var returnedData: Data? - var returnedError: Error? = nil + var returnedError: Error? let encoder = JSONEncoder() if prettyPrint { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Configuration.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Configuration.swift index f8180752b6..eb61a73c0b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Configuration.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Configuration.swift @@ -7,9 +7,9 @@ import Foundation open class Configuration { - + // This value is used to configure the date formatter that is used to serialize dates into JSON format. // You must set it prior to encoding any dates, and it will only be read once. open static var dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" - -} \ No newline at end of file + +} diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Extensions.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Extensions.swift index abe218b4e7..47967f9248 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Extensions.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Extensions.swift @@ -106,24 +106,24 @@ extension String: CodingKey { extension KeyedEncodingContainerProtocol { - public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { var arrayContainer = nestedUnkeyedContainer(forKey: key) try arrayContainer.encode(contentsOf: values) } - public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T : Encodable { + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { if let values = values { try encodeArray(values, forKey: key) } } - public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T : Encodable { + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { for (key, value) in pairs { try encode(value, forKey: key) } } - public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T : Encodable { + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { if let pairs = pairs { try encodeMap(pairs) } @@ -133,7 +133,7 @@ extension KeyedEncodingContainerProtocol { extension KeyedDecodingContainerProtocol { - public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T : Decodable { + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { var tmpArray = [T]() var nestedContainer = try nestedUnkeyedContainer(forKey: key) @@ -145,8 +145,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T : Decodable { - var tmpArray: [T]? = nil + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { + var tmpArray: [T]? if contains(key) { tmpArray = try decodeArray(T.self, forKey: key) @@ -155,8 +155,8 @@ extension KeyedDecodingContainerProtocol { return tmpArray } - public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T : Decodable { - var map: [Self.Key : T] = [:] + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] for key in allKeys { if !excludedKeys.contains(key) { @@ -169,5 +169,3 @@ extension KeyedDecodingContainerProtocol { } } - - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodableEncoding.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodableEncoding.swift index ca05906d42..fb76bbed26 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodableEncoding.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodableEncoding.swift @@ -42,7 +42,7 @@ public struct JSONDataEncoding: ParameterEncoding { } public static func encodingParameters(jsonData: Data?) -> Parameters? { - var returnedParams: Parameters? = nil + var returnedParams: Parameters? if let jsonData = jsonData, !jsonData.isEmpty { var params = Parameters() params[jsonDataKey] = jsonData diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift index 7044951584..7bd1267e95 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -10,8 +10,8 @@ import Alamofire open class JSONEncodingHelper { - open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { - var params: Parameters? = nil + open class func encodingParameters(forEncodableObject encodableObj: T?) -> Parameters? { + var params: Parameters? // Encode the Encodable object if let encodableObj = encodableObj { @@ -25,7 +25,7 @@ open class JSONEncodingHelper { } open class func encodingParameters(forEncodableObject encodableObj: Any?) -> Parameters? { - var params: Parameters? = nil + var params: Parameters? if let encodableObj = encodableObj { do { @@ -39,5 +39,5 @@ open class JSONEncodingHelper { return params } - + } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models.swift index 42f8186ae4..9d4101c3cd 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models.swift @@ -10,7 +10,7 @@ protocol JSONEncodable { func encodeToJSON() -> Any } -public enum ErrorResponse : Error { +public enum ErrorResponse: Error { case error(Int, Data?, Error) } @@ -27,7 +27,7 @@ open class Response { public convenience init(response: HTTPURLResponse, body: T?) { let rawHeader = response.allHeaderFields - var header = [String:String]() + var header = [String: String]() for case let (key, value) as (String, String) in rawHeader { header[key] = value } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift index 4e018486ad..52c1d3bd2b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AdditionalPropertiesClass.swift @@ -7,23 +7,19 @@ import Foundation - - public struct AdditionalPropertiesClass: Codable { - public var mapProperty: [String:String]? - public var mapOfMapProperty: [String:[String:String]]? + public var mapProperty: [String: String]? + public var mapOfMapProperty: [String: [String: String]]? - public init(mapProperty: [String:String]?, mapOfMapProperty: [String:[String:String]]?) { + public init(mapProperty: [String: String]?, mapOfMapProperty: [String: [String: String]]?) { self.mapProperty = mapProperty self.mapOfMapProperty = mapOfMapProperty } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapProperty = "map_property" case mapOfMapProperty = "map_of_map_property" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift index 7221a1be09..5ed9f31e2a 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Animal.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Animal: Codable { public var className: String @@ -19,6 +17,4 @@ public struct Animal: Codable { self.color = color } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift index e7bea63f8e..e09b0e9efd 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/AnimalFarm.swift @@ -7,5 +7,4 @@ import Foundation - public typealias AnimalFarm = [Animal] diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift index a22e9aaebb..ec270da890 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ApiResponse.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ApiResponse: Codable { public var code: Int? @@ -21,6 +19,4 @@ public struct ApiResponse: Codable { self.message = message } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift index 4e5a5ca144..3843287630 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfArrayOfNumberOnly: Codable { public var arrayArrayNumber: [[Double]]? @@ -17,10 +15,8 @@ public struct ArrayOfArrayOfNumberOnly: Codable { self.arrayArrayNumber = arrayArrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayArrayNumber = "ArrayArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift index 7d059d3683..f8b198e81f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayOfNumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayOfNumberOnly: Codable { public var arrayNumber: [Double]? @@ -17,10 +15,8 @@ public struct ArrayOfNumberOnly: Codable { self.arrayNumber = arrayNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayNumber = "ArrayNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift index 9c56fed50c..67f7f7e515 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ArrayTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ArrayTest: Codable { public var arrayOfString: [String]? @@ -21,12 +19,10 @@ public struct ArrayTest: Codable { self.arrayArrayOfModel = arrayArrayOfModel } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case arrayOfString = "array_of_string" case arrayArrayOfInteger = "array_array_of_integer" case arrayArrayOfModel = "array_array_of_model" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift index 98cda23dac..d576b50b1c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Capitalization.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Capitalization: Codable { public var smallCamel: String? @@ -28,7 +26,7 @@ public struct Capitalization: Codable { self.ATT_NAME = ATT_NAME } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case smallCamel case capitalCamel = "CapitalCamel" case smallSnake = "small_Snake" @@ -37,6 +35,4 @@ public struct Capitalization: Codable { case ATT_NAME } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift index a116d964ea..7ab887f311 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Cat.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Cat: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Cat: Codable { self.declawed = declawed } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Category.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Category.swift index 77fba95c1d..399a062cfa 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Category.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Category.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Category: Codable { public var _id: Int64? @@ -19,11 +17,9 @@ public struct Category: Codable { self.name = name } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case name } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift index f673ed127c..28cb30ce7b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ClassModel.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model with \"_class\" property */ public struct ClassModel: Codable { @@ -18,6 +17,4 @@ public struct ClassModel: Codable { self._class = _class } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Client.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Client.swift index 51390b6c4e..00245ca372 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Client.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Client.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Client: Codable { public var client: String? @@ -17,6 +15,4 @@ public struct Client: Codable { self.client = client } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift index 239ce74dcc..492c122800 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Dog.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Dog: Codable { public var className: String @@ -21,6 +19,4 @@ public struct Dog: Codable { self.breed = breed } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift index 8713961520..5034ff0b8c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumArrays.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumArrays: Codable { public enum JustSymbol: String, Codable { @@ -27,11 +25,9 @@ public struct EnumArrays: Codable { self.arrayEnum = arrayEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justSymbol = "just_symbol" case arrayEnum = "array_enum" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift index 7280a621fe..3c1dfcac57 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumClass.swift @@ -7,7 +7,6 @@ import Foundation - public enum EnumClass: String, Codable { case abc = "_abc" case efg = "-efg" diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift index 0f546c76a2..6db9b34d18 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/EnumTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct EnumTest: Codable { public enum EnumString: String, Codable { @@ -43,7 +41,7 @@ public struct EnumTest: Codable { self.outerEnum = outerEnum } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case enumString = "enum_string" case enumStringRequired = "enum_string_required" case enumInteger = "enum_integer" @@ -51,6 +49,4 @@ public struct EnumTest: Codable { case outerEnum } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift index faa091b065..20bd6d103b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/FormatTest.swift @@ -7,8 +7,6 @@ import Foundation - - public struct FormatTest: Codable { public var integer: Int? @@ -41,6 +39,4 @@ public struct FormatTest: Codable { self.password = password } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift index 554aee1081..906ddb06fb 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/HasOnlyReadOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct HasOnlyReadOnly: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct HasOnlyReadOnly: Codable { self.foo = foo } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/List.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/List.swift index 8997340ff4..08d5995387 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/List.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/List.swift @@ -7,8 +7,6 @@ import Foundation - - public struct List: Codable { public var _123list: String? @@ -17,10 +15,8 @@ public struct List: Codable { self._123list = _123list } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _123list = "123-list" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift index dfbbee8428..2860f90785 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MapTest.swift @@ -7,27 +7,23 @@ import Foundation - - public struct MapTest: Codable { public enum MapOfEnumString: String, Codable { case upper = "UPPER" case lower = "lower" } - public var mapMapOfString: [String:[String:String]]? - public var mapOfEnumString: [String:String]? + public var mapMapOfString: [String: [String: String]]? + public var mapOfEnumString: [String: String]? - public init(mapMapOfString: [String:[String:String]]?, mapOfEnumString: [String:String]?) { + public init(mapMapOfString: [String: [String: String]]?, mapOfEnumString: [String: String]?) { self.mapMapOfString = mapMapOfString self.mapOfEnumString = mapOfEnumString } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case mapMapOfString = "map_map_of_string" case mapOfEnumString = "map_of_enum_string" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift index 7116108fd7..c3deb2f289 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/MixedPropertiesAndAdditionalPropertiesClass.swift @@ -7,20 +7,16 @@ import Foundation - - public struct MixedPropertiesAndAdditionalPropertiesClass: Codable { public var uuid: UUID? public var dateTime: Date? - public var map: [String:Animal]? + public var map: [String: Animal]? - public init(uuid: UUID?, dateTime: Date?, map: [String:Animal]?) { + public init(uuid: UUID?, dateTime: Date?, map: [String: Animal]?) { self.uuid = uuid self.dateTime = dateTime self.map = map } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift index fc1d0606b7..7ed6aad907 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Model200Response.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name starting with number */ public struct Model200Response: Codable { @@ -20,11 +19,9 @@ public struct Model200Response: Codable { self._class = _class } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case _class = "class" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Name.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Name.swift index cc165d767d..ce9ffe4fb3 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Name.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Name.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing model name same as property name */ public struct Name: Codable { @@ -24,13 +23,11 @@ public struct Name: Codable { self._123number = _123number } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case name case snakeCase = "snake_case" case property case _123number = "123Number" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift index e6fb206093..abd2269e8e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/NumberOnly.swift @@ -7,8 +7,6 @@ import Foundation - - public struct NumberOnly: Codable { public var justNumber: Double? @@ -17,10 +15,8 @@ public struct NumberOnly: Codable { self.justNumber = justNumber } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case justNumber = "JustNumber" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Order.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Order.swift index 5cad29458b..f2b7565e2d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Order.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Order.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Order: Codable { public enum Status: String, Codable { @@ -33,7 +31,7 @@ public struct Order: Codable { self.complete = complete } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case petId case quantity @@ -42,6 +40,4 @@ public struct Order: Codable { case complete } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift index edc4523d9f..49aec001c5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterComposite.swift @@ -7,8 +7,6 @@ import Foundation - - public struct OuterComposite: Codable { public var myNumber: Double? @@ -21,12 +19,10 @@ public struct OuterComposite: Codable { self.myBoolean = myBoolean } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case myNumber = "my_number" case myString = "my_string" case myBoolean = "my_boolean" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift index bd1643d279..9f80fc95ec 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/OuterEnum.swift @@ -7,7 +7,6 @@ import Foundation - public enum OuterEnum: String, Codable { case placed = "placed" case approved = "approved" diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift index 3773bf5331..971ce9d4db 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Pet.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Pet: Codable { public enum Status: String, Codable { @@ -33,7 +31,7 @@ public struct Pet: Codable { self.status = status } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case category case name @@ -42,6 +40,4 @@ public struct Pet: Codable { case status } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift index 48b655a5b0..0acd21fd10 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/ReadOnlyFirst.swift @@ -7,8 +7,6 @@ import Foundation - - public struct ReadOnlyFirst: Codable { public var bar: String? @@ -19,6 +17,4 @@ public struct ReadOnlyFirst: Codable { self.baz = baz } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Return.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Return.swift index de4b218999..076082af84 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Return.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Return.swift @@ -7,7 +7,6 @@ import Foundation - /** Model for testing reserved words */ public struct Return: Codable { @@ -18,10 +17,8 @@ public struct Return: Codable { self._return = _return } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _return = "return" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift index 213d896ba9..e79fc45c0e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/SpecialModelName.swift @@ -7,8 +7,6 @@ import Foundation - - public struct SpecialModelName: Codable { public var specialPropertyName: Int64? @@ -17,10 +15,8 @@ public struct SpecialModelName: Codable { self.specialPropertyName = specialPropertyName } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case specialPropertyName = "$special[property.name]" } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift index 20f50efd3a..83efe72b8a 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/Tag.swift @@ -7,8 +7,6 @@ import Foundation - - public struct Tag: Codable { public var _id: Int64? @@ -19,11 +17,9 @@ public struct Tag: Codable { self.name = name } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case name } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/User.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/User.swift index d9c564d2a1..7d6b24b9e1 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/User.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/PetstoreClient/Classes/OpenAPIs/Models/User.swift @@ -7,8 +7,6 @@ import Foundation - - public struct User: Codable { public var _id: Int64? @@ -32,7 +30,7 @@ public struct User: Codable { self.userStatus = userStatus } - public enum CodingKeys: String, CodingKey { + public enum CodingKeys: String, CodingKey { case _id = "id" case username case firstName @@ -43,6 +41,4 @@ public struct User: Codable { case userStatus } - } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/AtomicInt.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/AtomicInt.swift index 28ed4ad65a..2f405c8a0e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/AtomicInt.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/AtomicInt.swift @@ -30,4 +30,3 @@ extension AtomicInt { return (self.load() & mask) != 0 } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Bag.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Bag.swift index 22d82d51fb..6b92b4011d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Bag.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Bag.swift @@ -32,29 +32,29 @@ It is suitable for storing small number of elements. struct Bag : CustomDebugStringConvertible { /// Type of identifier for inserted elements. typealias KeyType = BagKey - + typealias Entry = (key: BagKey, value: T) - + fileprivate var _nextKey: BagKey = BagKey(rawValue: 0) // data // first fill inline variables - var _key0: BagKey? = nil - var _value0: T? = nil + var _key0: BagKey? + var _value0: T? // then fill "array dictionary" var _pairs = ContiguousArray() // last is sparse dictionary - var _dictionary: [BagKey : T]? = nil + var _dictionary: [BagKey: T]? var _onlyFastPath = true /// Creates new empty `Bag`. init() { } - + /** Inserts `value` into bag. @@ -83,18 +83,18 @@ struct Bag : CustomDebugStringConvertible { _pairs.append((key: key, value: element)) return key } - + _dictionary = [key: element] - + return key } - + /// - returns: Number of elements in bag. var count: Int { let dictionaryCount: Int = _dictionary?.count ?? 0 return (_value0 != nil ? 1 : 0) + _pairs.count + dictionaryCount } - + /// Removes all elements from bag and clears capacity. mutating func removeAll() { _key0 = nil @@ -103,7 +103,7 @@ struct Bag : CustomDebugStringConvertible { _pairs.removeAll(keepingCapacity: false) _dictionary?.removeAll(keepingCapacity: false) } - + /** Removes element with a specific `key` from bag. @@ -136,7 +136,7 @@ struct Bag : CustomDebugStringConvertible { extension Bag { /// A textual representation of `self`, suitable for debugging. - var debugDescription : String { + var debugDescription: String { return "\(self.count) elements in Bag" } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift index 5a573a0de1..a46e74827c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift @@ -10,13 +10,13 @@ struct InfiniteSequence : Sequence { typealias Element = E typealias Iterator = AnyIterator - + private let _repeatedValue: E - + init(repeatedValue: E) { _repeatedValue = repeatedValue } - + func makeIterator() -> Iterator { let repeatedValue = _repeatedValue return AnyIterator { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift index 9b2c370ec4..7d174fd7be 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift @@ -116,7 +116,7 @@ struct PriorityQueue { } } -extension PriorityQueue : CustomDebugStringConvertible { +extension PriorityQueue: CustomDebugStringConvertible { var debugDescription: String { return _elements.debugDescription } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Queue.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Queue.swift index d05726c7b9..b9b3ae2e8b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Queue.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DataStructures/Queue.swift @@ -19,7 +19,7 @@ struct Queue: Sequence { typealias Generator = AnyIterator private let _resizeFactor = 2 - + private var _storage: ContiguousArray private var _count = 0 private var _pushNextIndex = 0 @@ -35,50 +35,50 @@ struct Queue: Sequence { _storage = ContiguousArray(repeating: nil, count: capacity) } - + private var dequeueIndex: Int { let index = _pushNextIndex - count return index < 0 ? index + _storage.count : index } - + /// - returns: Is queue empty. var isEmpty: Bool { return count == 0 } - + /// - returns: Number of elements inside queue. var count: Int { return _count } - + /// - returns: Element in front of a list of elements to `dequeue`. func peek() -> T { precondition(count > 0) - + return _storage[dequeueIndex]! } - + mutating private func resizeTo(_ size: Int) { var newStorage = ContiguousArray(repeating: nil, count: size) - + let count = _count - + let dequeueIndex = self.dequeueIndex let spaceToEndOfQueue = _storage.count - dequeueIndex - + // first batch is from dequeue index to end of array let countElementsInFirstBatch = Swift.min(count, spaceToEndOfQueue) // second batch is wrapped from start of array to end of queue let numberOfElementsInSecondBatch = count - countElementsInFirstBatch - + newStorage[0 ..< countElementsInFirstBatch] = _storage[dequeueIndex ..< (dequeueIndex + countElementsInFirstBatch)] newStorage[countElementsInFirstBatch ..< (countElementsInFirstBatch + numberOfElementsInSecondBatch)] = _storage[0 ..< numberOfElementsInSecondBatch] - + _count = count _pushNextIndex = count _storage = newStorage } - + /// Enqueues `element`. /// /// - parameter element: Element to enqueue. @@ -86,19 +86,19 @@ struct Queue: Sequence { if count == _storage.count { resizeTo(Swift.max(_storage.count, 1) * _resizeFactor) } - + _storage[_pushNextIndex] = element _pushNextIndex += 1 _count += 1 - + if _pushNextIndex >= _storage.count { _pushNextIndex -= _storage.count } } - + private mutating func dequeueElementOnly() -> T { precondition(count > 0) - + let index = dequeueIndex defer { @@ -126,7 +126,7 @@ struct Queue: Sequence { return dequeueElementOnly() } - + /// - returns: Generator of contained elements. func makeIterator() -> AnyIterator { var i = dequeueIndex diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DeprecationWarner.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DeprecationWarner.swift index 863636b7b7..d2ede7fb48 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DeprecationWarner.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/DeprecationWarner.swift @@ -12,23 +12,23 @@ import Foundation class DeprecationWarner { private static var warned = Set() private static var _lock = NSRecursiveLock() - + static func warnIfNeeded(_ kind: Kind) { _lock.lock(); defer { _lock.unlock() } guard !warned.contains(kind) else { return } - + warned.insert(kind) print("ℹ️ [DEPRECATED] \(kind.message)") } } - + extension DeprecationWarner { enum Kind { case variable case globalTestFunctionNext case globalTestFunctionError case globalTestFunctionCompleted - + var message: String { switch self { case .variable: return "`Variable` is planned for future deprecation. Please consider `BehaviorRelay` as a replacement. Read more at: https://git.io/vNqvx" @@ -40,4 +40,3 @@ import Foundation } } #endif - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Darwin.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Darwin.swift index 6dc36add7b..f75007f442 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Darwin.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Darwin.swift @@ -19,8 +19,7 @@ if let newValue = value { threadDictionary[key] = newValue - } - else { + } else { threadDictionary[key] = nil } } @@ -28,7 +27,7 @@ static func getThreadLocalStorageValueForKey(_ key: NSCopying) -> T? { let currentThread = Thread.current let threadDictionary = currentThread.threadDictionary - + return threadDictionary[key] as? T } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Linux.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Linux.swift index 570f8f00fa..125fe8863f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Linux.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/Platform/Platform.Linux.swift @@ -18,8 +18,7 @@ if let newValue = value { threadDictionary[key] = newValue - } - else { + } else { threadDictionary[key] = nil } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/AnyObserver.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/AnyObserver.swift index dd4f9c4086..4516036439 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/AnyObserver.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/AnyObserver.swift @@ -12,7 +12,7 @@ public struct AnyObserver : ObserverType { /// The type of elements in sequence that observer can observe. public typealias E = Element - + /// Anonymous event handler type. public typealias EventHandler = (Event) -> Void @@ -24,14 +24,14 @@ public struct AnyObserver : ObserverType { public init(eventHandler: @escaping EventHandler) { self.observer = eventHandler } - + /// Construct an instance whose `on(event)` calls `observer.on(event)` /// /// - parameter observer: Observer that receives sequence events. - public init(_ observer: O) where O.E == Element { + public init(_ observer: O) where O.E == Element { self.observer = observer.on } - + /// Send `event` to this observer. /// /// - parameter event: Event instance. @@ -49,7 +49,7 @@ public struct AnyObserver : ObserverType { extension AnyObserver { /// Collection of `AnyObserver`s - typealias s = Bag<(Event) -> ()> + typealias s = Bag<(Event) -> Void> } extension ObserverType { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Cancelable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Cancelable.swift index 1fa7a67726..341807c18c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Cancelable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Cancelable.swift @@ -7,7 +7,7 @@ // /// Represents disposable resource with state tracking. -public protocol Cancelable : Disposable { +public protocol Cancelable: Disposable { /// Was resource disposed. var isDisposed: Bool { get } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift index 7fbf8c9c6a..7d040e7bf1 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift @@ -17,13 +17,11 @@ and pending work. That means that enqueued work could possibly be executed later on a different thread. */ final class AsyncLock - : Disposable - , Lock - , SynchronizedDisposeType { + : Disposable, Lock, SynchronizedDisposeType { typealias Action = () -> Void - + var _lock = SpinLock() - + private var _queue: Queue = Queue(capacity: 0) private var _isExecuting: Bool = false @@ -60,8 +58,7 @@ final class AsyncLock _lock.lock(); defer { _lock.unlock() } // { if !_queue.isEmpty { return _queue.dequeue() - } - else { + } else { _isExecuting = false return nil } @@ -70,27 +67,25 @@ final class AsyncLock func invoke(_ action: I) { let firstEnqueuedAction = enqueue(action) - + if let firstEnqueuedAction = firstEnqueuedAction { firstEnqueuedAction.invoke() - } - else { + } else { // action is enqueued, it's somebody else's concern now return } - + while true { let nextAction = dequeue() if let nextAction = nextAction { nextAction.invoke() - } - else { + } else { return } } } - + func dispose() { synchronizedDispose() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/Lock.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/Lock.swift index 52afc1cb87..6f9ff8e4e4 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/Lock.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/Lock.swift @@ -14,7 +14,7 @@ protocol Lock { // https://lists.swift.org/pipermail/swift-dev/Week-of-Mon-20151214/000321.html typealias SpinLock = RecursiveLock -extension RecursiveLock : Lock { +extension RecursiveLock: Lock { @inline(__always) final func performLocked(_ action: () -> Void) { lock(); defer { unlock() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift index eca8d8e120..0f6efdff4a 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol LockOwnerType : class, Lock { +protocol LockOwnerType: class, Lock { var _lock: RecursiveLock { get } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift index af9548f6ed..ba729399b5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol SynchronizedDisposeType : class, Disposable, Lock { +protocol SynchronizedDisposeType: class, Disposable, Lock { func _synchronized_dispose() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift index 8dfc556841..d7923769e2 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol SynchronizedOnType : class, ObserverType, Lock { +protocol SynchronizedOnType: class, ObserverType, Lock { func _synchronized_on(_ event: Event) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift index bb1aa7e47d..29897d4bdb 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol SynchronizedUnsubscribeType : class { +protocol SynchronizedUnsubscribeType: class { associatedtype DisposeKey func synchronizedUnsubscribe(_ disposeKey: DisposeKey) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ConnectableObservableType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ConnectableObservableType.swift index 52bf93c568..239455a0f9 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ConnectableObservableType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ConnectableObservableType.swift @@ -9,7 +9,7 @@ /** Represents an observable sequence wrapper that can be connected and disconnected from its underlying observable sequence. */ -public protocol ConnectableObservableType : ObservableType { +public protocol ConnectableObservableType: ObservableType { /** Connects the observable wrapper to its source. All subscribed observers will receive values from the underlying observable sequence as long as the connection is established. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Deprecated.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Deprecated.swift index 0337d82c9e..2ec47b3109 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Deprecated.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Deprecated.swift @@ -51,7 +51,6 @@ extension ObservableType { return enumerated().map { try selector($0.element, $0.index) } } - /** Projects each element of an observable sequence to an observable sequence by incorporating the element's index and merges the resulting observable sequences into one observable sequence. @@ -82,7 +81,6 @@ extension ObservableType { return enumerated().skipWhile { try predicate($0.element, $0.index) }.map { $0.element } } - /** Returns elements from an observable sequence as long as a specified condition is true. @@ -113,7 +111,6 @@ extension Disposable { } } - extension ObservableType { /** @@ -132,7 +129,6 @@ extension ObservableType { } } - extension ObservableType { /** diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift index 449ee3da17..73a8db7927 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift @@ -9,7 +9,7 @@ /// Represents an Action-based disposable. /// /// When dispose method is called, disposal action will be dereferenced. -fileprivate final class AnonymousDisposable : DisposeBase, Cancelable { +fileprivate final class AnonymousDisposable: DisposeBase, Cancelable { public typealias DisposeAction = () -> Void private var _isDisposed = AtomicInt(0) @@ -27,13 +27,13 @@ fileprivate final class AnonymousDisposable : DisposeBase, Cancelable { _disposeAction = disposeAction super.init() } - + // Non-deprecated version of the constructor, used by `Disposables.create(with:)` fileprivate init(disposeAction: @escaping DisposeAction) { _disposeAction = disposeAction super.init() } - + /// Calls the disposal action if and only if the current instance hasn't been disposed yet. /// /// After invoking disposal action, disposal action will be dereferenced. @@ -50,12 +50,12 @@ fileprivate final class AnonymousDisposable : DisposeBase, Cancelable { } extension Disposables { - + /// Constructs a new disposable with the given action used for disposal. /// /// - parameter dispose: Disposal action which will be run upon calling `dispose`. - public static func create(with dispose: @escaping () -> ()) -> Cancelable { + public static func create(with dispose: @escaping () -> Void) -> Cancelable { return AnonymousDisposable(disposeAction: dispose) } - + } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift index 949476cf12..ee95e422e9 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift @@ -7,7 +7,7 @@ // /// Represents two disposable resources that are disposed together. -private final class BinaryDisposable : DisposeBase, Cancelable { +private final class BinaryDisposable: DisposeBase, Cancelable { private var _isDisposed = AtomicInt(0) @@ -44,10 +44,10 @@ private final class BinaryDisposable : DisposeBase, Cancelable { } extension Disposables { - + /// Creates a disposable with the given disposables. public static func create(_ disposable1: Disposable, _ disposable2: Disposable) -> Cancelable { return BinaryDisposable(disposable1, disposable2) } - + } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift index efae55e410..0e6a7da9cf 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift @@ -7,25 +7,25 @@ // /// Represents a disposable resource that can be checked for disposal status. -public final class BooleanDisposable : Cancelable { +public final class BooleanDisposable: Cancelable { internal static let BooleanDisposableTrue = BooleanDisposable(isDisposed: true) private var _isDisposed = false - + /// Initializes a new instance of the `BooleanDisposable` class public init() { } - + /// Initializes a new instance of the `BooleanDisposable` class with given value public init(isDisposed: Bool) { self._isDisposed = isDisposed } - + /// - returns: Was resource disposed. public var isDisposed: Bool { return _isDisposed } - + /// Sets the status to disposed, which can be observer through the `isDisposed` property. public func dispose() { _isDisposed = true diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift index b057817238..46790ac8f6 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift @@ -7,7 +7,7 @@ // /// Represents a group of disposable resources that are disposed together. -public final class CompositeDisposable : DisposeBase, Cancelable { +public final class CompositeDisposable: DisposeBase, Cancelable { /// Key used to remove disposable from composite disposable public struct DisposeKey { fileprivate let key: BagKey @@ -17,7 +17,7 @@ public final class CompositeDisposable : DisposeBase, Cancelable { } private var _lock = SpinLock() - + // state private var _disposables: Bag? = Bag() @@ -25,42 +25,42 @@ public final class CompositeDisposable : DisposeBase, Cancelable { _lock.lock(); defer { _lock.unlock() } return _disposables == nil } - + public override init() { } - + /// Initializes a new instance of composite disposable with the specified number of disposables. public init(_ disposable1: Disposable, _ disposable2: Disposable) { // This overload is here to make sure we are using optimized version up to 4 arguments. - let _ = _disposables!.insert(disposable1) - let _ = _disposables!.insert(disposable2) + _ = _disposables!.insert(disposable1) + _ = _disposables!.insert(disposable2) } - + /// Initializes a new instance of composite disposable with the specified number of disposables. public init(_ disposable1: Disposable, _ disposable2: Disposable, _ disposable3: Disposable) { // This overload is here to make sure we are using optimized version up to 4 arguments. - let _ = _disposables!.insert(disposable1) - let _ = _disposables!.insert(disposable2) - let _ = _disposables!.insert(disposable3) + _ = _disposables!.insert(disposable1) + _ = _disposables!.insert(disposable2) + _ = _disposables!.insert(disposable3) } - + /// Initializes a new instance of composite disposable with the specified number of disposables. public init(_ disposable1: Disposable, _ disposable2: Disposable, _ disposable3: Disposable, _ disposable4: Disposable, _ disposables: Disposable...) { // This overload is here to make sure we are using optimized version up to 4 arguments. - let _ = _disposables!.insert(disposable1) - let _ = _disposables!.insert(disposable2) - let _ = _disposables!.insert(disposable3) - let _ = _disposables!.insert(disposable4) - + _ = _disposables!.insert(disposable1) + _ = _disposables!.insert(disposable2) + _ = _disposables!.insert(disposable3) + _ = _disposables!.insert(disposable4) + for disposable in disposables { - let _ = _disposables!.insert(disposable) + _ = _disposables!.insert(disposable) } } - + /// Initializes a new instance of composite disposable with the specified number of disposables. public init(disposables: [Disposable]) { for disposable in disposables { - let _ = _disposables!.insert(disposable) + _ = _disposables!.insert(disposable) } } @@ -73,39 +73,39 @@ public final class CompositeDisposable : DisposeBase, Cancelable { */ public func insert(_ disposable: Disposable) -> DisposeKey? { let key = _insert(disposable) - + if key == nil { disposable.dispose() } - + return key } - + private func _insert(_ disposable: Disposable) -> DisposeKey? { _lock.lock(); defer { _lock.unlock() } let bagKey = _disposables?.insert(disposable) return bagKey.map(DisposeKey.init) } - + /// - returns: Gets the number of disposables contained in the `CompositeDisposable`. public var count: Int { _lock.lock(); defer { _lock.unlock() } return _disposables?.count ?? 0 } - + /// Removes and disposes the disposable identified by `disposeKey` from the CompositeDisposable. /// /// - parameter disposeKey: Key used to identify disposable to be removed. public func remove(for disposeKey: DisposeKey) { _remove(for: disposeKey)?.dispose() } - + private func _remove(for disposeKey: DisposeKey) -> Disposable? { _lock.lock(); defer { _lock.unlock() } return _disposables?.removeKey(disposeKey.key) } - + /// Disposes all disposables in the group and removes them from the group. public func dispose() { if let disposables = _dispose() { @@ -129,7 +129,7 @@ extension Disposables { public static func create(_ disposable1: Disposable, _ disposable2: Disposable, _ disposable3: Disposable) -> Cancelable { return CompositeDisposable(disposable1, disposable2, disposable3) } - + /// Creates a disposable with the given disposables. public static func create(_ disposable1: Disposable, _ disposable2: Disposable, _ disposable3: Disposable, _ disposables: Disposable ...) -> Cancelable { var disposables = disposables @@ -138,7 +138,7 @@ extension Disposables { disposables.append(disposable3) return CompositeDisposable(disposables: disposables) } - + /// Creates a disposable with the given disposables. public static func create(_ disposables: [Disposable]) -> Cancelable { switch disposables.count { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/Disposables.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/Disposables.swift index 8cd6e28c3c..fbee0bc5b8 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/Disposables.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/Disposables.swift @@ -10,4 +10,3 @@ public struct Disposables { private init() {} } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift index 9a2386d159..edb449d467 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift @@ -28,13 +28,13 @@ or create a new one in its place. In case explicit disposal is necessary, there is also `CompositeDisposable`. */ public final class DisposeBag: DisposeBase { - + private var _lock = SpinLock() - + // state fileprivate var _disposables = [Disposable]() fileprivate var _isDisposed = false - + /// Constructs new empty dispose bag. public override init() { super.init() @@ -46,7 +46,7 @@ public final class DisposeBag: DisposeBase { public func insert(_ disposable: Disposable) { _insert(disposable)?.dispose() } - + private func _insert(_ disposable: Disposable) -> Disposable? { _lock.lock(); defer { _lock.unlock() } if _isDisposed { @@ -71,13 +71,13 @@ public final class DisposeBag: DisposeBase { _lock.lock(); defer { _lock.unlock() } let disposables = _disposables - + _disposables.removeAll(keepingCapacity: false) _isDisposed = true - + return disposables } - + deinit { dispose() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift index 8c6a44f0b8..08cd2dd263 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift @@ -10,13 +10,13 @@ public class DisposeBase { init() { #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } - + deinit { #if TRACE_RESOURCES - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() #endif } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift index 149f866434..24fb5acc61 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift @@ -9,14 +9,14 @@ /// Represents a disposable that does nothing on disposal. /// /// Nop = No Operation -fileprivate struct NopDisposable : Disposable { - +private struct NopDisposable: Disposable { + fileprivate static let noOp: Disposable = NopDisposable() - + fileprivate init() { - + } - + /// Does nothing. public func dispose() { } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift index 664603c878..f40fd84ff4 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift @@ -7,7 +7,7 @@ // /// Represents a disposable resource that only disposes its underlying disposable resource when all dependent disposable objects have been disposed. -public final class RefCountDisposable : DisposeBase, Cancelable { +public final class RefCountDisposable: DisposeBase, Cancelable { private var _lock = SpinLock() private var _disposable = nil as Disposable? private var _primaryDisposed = false @@ -35,7 +35,7 @@ public final class RefCountDisposable : DisposeBase, Cancelable { if let _ = _disposable { do { - let _ = try incrementChecked(&_count) + _ = try incrementChecked(&_count) } catch (_) { rxFatalError("RefCountDisposable increment failed") } @@ -50,12 +50,10 @@ public final class RefCountDisposable : DisposeBase, Cancelable { /// Disposes the underlying disposable only when all dependent disposables have been disposed. public func dispose() { let oldDisposable: Disposable? = _lock.calculateLocked { - if let oldDisposable = _disposable, !_primaryDisposed - { + if let oldDisposable = _disposable, !_primaryDisposed { _primaryDisposed = true - if (_count == 0) - { + if (_count == 0) { _disposable = nil return oldDisposable } @@ -73,7 +71,7 @@ public final class RefCountDisposable : DisposeBase, Cancelable { let oldDisposable: Disposable? = _lock.calculateLocked { if let oldDisposable = _disposable { do { - let _ = try decrementChecked(&_count) + _ = try decrementChecked(&_count) } catch (_) { rxFatalError("RefCountDisposable decrement on release failed") } @@ -97,19 +95,16 @@ public final class RefCountDisposable : DisposeBase, Cancelable { } } -internal final class RefCountInnerDisposable: DisposeBase, Disposable -{ +internal final class RefCountInnerDisposable: DisposeBase, Disposable { private let _parent: RefCountDisposable private var _isDisposed = AtomicInt(0) - init(_ parent: RefCountDisposable) - { + init(_ parent: RefCountDisposable) { _parent = parent super.init() } - internal func dispose() - { + internal func dispose() { if _isDisposed.fetchOr(1) == 0 { _parent.release() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift index 564a3a263b..fffd5881c3 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift @@ -12,7 +12,7 @@ private let disposeScheduledDisposable: (ScheduledDisposable) -> Disposable = { } /// Represents a disposable resource whose disposal invocation will be scheduled on the specified scheduler. -public final class ScheduledDisposable : Cancelable { +public final class ScheduledDisposable: Cancelable { public let scheduler: ImmediateSchedulerType private var _isDisposed = AtomicInt(0) @@ -38,7 +38,7 @@ public final class ScheduledDisposable : Cancelable { /// Disposes the wrapped disposable on the provided scheduler. public func dispose() { - let _ = scheduler.schedule(self, action: disposeScheduledDisposable) + _ = scheduler.schedule(self, action: disposeScheduledDisposable) } func disposeInner() { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift index 6373d2bba5..0932f568ec 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift @@ -7,23 +7,23 @@ // /// Represents a disposable resource whose underlying disposable resource can be replaced by another disposable resource, causing automatic disposal of the previous underlying disposable resource. -public final class SerialDisposable : DisposeBase, Cancelable { +public final class SerialDisposable: DisposeBase, Cancelable { private var _lock = SpinLock() - + // state private var _current = nil as Disposable? private var _isDisposed = false - + /// - returns: Was resource disposed. public var isDisposed: Bool { return _isDisposed } - + /// Initializes a new instance of the `SerialDisposable`. override public init() { super.init() } - + /** Gets or sets the underlying disposable. @@ -41,20 +41,19 @@ public final class SerialDisposable : DisposeBase, Cancelable { let disposable: Disposable? = _lock.calculateLocked { if _isDisposed { return newDisposable - } - else { + } else { let toDispose = _current _current = newDisposable return toDispose } } - + if let disposable = disposable { disposable.dispose() } } } - + /// Disposes the underlying disposable as well as all future replacements. public func dispose() { _dispose()?.dispose() @@ -64,8 +63,7 @@ public final class SerialDisposable : DisposeBase, Cancelable { _lock.lock(); defer { _lock.unlock() } if _isDisposed { return nil - } - else { + } else { _isDisposed = true let current = _current _current = nil diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift index f34fac6bbd..6ff65235df 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift @@ -11,7 +11,7 @@ Represents a disposable resource which only allows a single assignment of its un If an underlying disposable resource has already been set, future attempts to set the underlying disposable resource will throw an exception. */ -public final class SingleAssignmentDisposable : DisposeBase, Cancelable { +public final class SingleAssignmentDisposable: DisposeBase, Cancelable { fileprivate enum DisposeState: Int32 { case disposed = 1 @@ -39,7 +39,7 @@ public final class SingleAssignmentDisposable : DisposeBase, Cancelable { _disposable = disposable let previousState = _state.fetchOr(DisposeState.disposableSet.rawValue) - + if (previousState & DisposeState.disposableSet.rawValue) != 0 { rxFatalError("oldState.disposable != nil") } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Errors.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Errors.swift index f17b52d882..648918e16f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Errors.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Errors.swift @@ -10,9 +10,7 @@ let RxErrorDomain = "RxErrorDomain" let RxCompositeFailures = "RxCompositeFailures" /// Generic Rx error codes. -public enum RxError - : Swift.Error - , CustomDebugStringConvertible { +public enum RxError: Swift.Error, CustomDebugStringConvertible { /// Unknown error occurred. case unknown /// Performing an action on disposed object. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Event.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Event.swift index 9193e3504d..1386ba8a49 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Event.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Event.swift @@ -21,7 +21,7 @@ public enum Event { case completed } -extension Event : CustomDebugStringConvertible { +extension Event: CustomDebugStringConvertible { /// Description of event. public var debugDescription: String { switch self { @@ -82,8 +82,7 @@ extension Event { case .completed: return .completed } - } - catch let e { + } catch let e { return .error(e) } } @@ -98,7 +97,7 @@ public protocol EventConvertible { var event: Event { get } } -extension Event : EventConvertible { +extension Event: EventConvertible { /// Event representation of this instance public var event: Event { return self diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift index 748578d918..0b228b8a3f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift @@ -6,11 +6,10 @@ // Copyright © 2016 Krunoslav Zaher. All rights reserved. // - // MARK: forEach @inline(__always) -func dispatch(_ bag: Bag<(Event) -> ()>, _ event: Event) { +func dispatch(_ bag: Bag<(Event) -> Void>, _ event: Event) { bag._value0?(event) if bag._onlyFastPath { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/GroupedObservable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/GroupedObservable.swift index d87e0bad02..432f50d23b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/GroupedObservable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/GroupedObservable.swift @@ -26,7 +26,7 @@ public struct GroupedObservable : ObservableType { } /// Subscribes `observer` to receive events for this sequence. - public func subscribe(_ observer: O) -> Disposable where O.E == E { + public func subscribe(_ observer: O) -> Disposable where O.E == E { return self.source.subscribe(observer) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift index 8dc2a85c49..de9f9ee925 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift @@ -26,11 +26,11 @@ extension ImmediateSchedulerType { - parameter action: Action to execute recursively. The last parameter passed to the action is used to trigger recursive scheduling of the action, passing in recursive invocation state. - returns: The disposable object used to cancel the scheduled action (best effort). */ - public func scheduleRecursive(_ state: State, action: @escaping (_ state: State, _ recurse: (State) -> ()) -> ()) -> Disposable { + public func scheduleRecursive(_ state: State, action: @escaping (_ state: State, _ recurse: (State) -> Void) -> Void) -> Disposable { let recursiveScheduler = RecursiveImmediateScheduler(action: action, scheduler: self) - + recursiveScheduler.schedule(state) - + return Disposables.create(with: recursiveScheduler.dispose) } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observable.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observable.swift index f0c55af714..6ba34b1fbe 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observable.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observable.swift @@ -12,24 +12,24 @@ public class Observable : ObservableType { /// Type of elements in sequence. public typealias E = Element - + init() { #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } - + public func subscribe(_ observer: O) -> Disposable where O.E == E { rxAbstractMethod() } - + public func asObservable() -> Observable { return self } - + deinit { #if TRACE_RESOURCES - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() #endif } @@ -41,4 +41,3 @@ public class Observable : ObservableType { return _map(source: self, transform: transform) } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift index 29ed8a29f2..0d07788cbd 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift @@ -24,8 +24,7 @@ extension ObservableType { } return self.asObservable().subscribe(observer) } - - + /** Subscribes an element handler, an error handler, a completion handler and disposed handler to an observable sequence. @@ -39,35 +38,33 @@ extension ObservableType { public func subscribe(onNext: ((E) -> Void)? = nil, onError: ((Swift.Error) -> Void)? = nil, onCompleted: (() -> Void)? = nil, onDisposed: (() -> Void)? = nil) -> Disposable { let disposable: Disposable - + if let disposed = onDisposed { disposable = Disposables.create(with: disposed) - } - else { + } else { disposable = Disposables.create() } - + #if DEBUG let synchronizationTracker = SynchronizationTracker() #endif - + let callStack = Hooks.recordCallStackOnError ? Hooks.customCaptureSubscriptionCallstack() : [] - + let observer = AnonymousObserver { event in - + #if DEBUG synchronizationTracker.register(synchronizationErrorMessage: .default) defer { synchronizationTracker.unregister() } #endif - + switch event { case .next(let value): onNext?(value) case .error(let error): if let onError = onError { onError(error) - } - else { + } else { Hooks.defaultErrorHandler(callStack, error) } disposable.dispose() @@ -86,7 +83,7 @@ extension ObservableType { import class Foundation.NSRecursiveLock extension Hooks { - public typealias DefaultErrorHandler = (_ subscriptionCallStack: [String], _ error: Error) -> () + public typealias DefaultErrorHandler = (_ subscriptionCallStack: [String], _ error: Error) -> Void public typealias CustomCaptureSubscriptionCallstack = () -> [String] fileprivate static let _lock = RecursiveLock() @@ -115,7 +112,7 @@ extension Hooks { _defaultErrorHandler = newValue } } - + /// Subscription callstack block to fetch custom callstack information. public static var customCaptureSubscriptionCallstack: CustomCaptureSubscriptionCallstack { get { @@ -128,4 +125,3 @@ extension Hooks { } } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType.swift index e41a36a1ae..5f2a0219ab 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObservableType.swift @@ -7,7 +7,7 @@ // /// Represents a push style sequence. -public protocol ObservableType : ObservableConvertibleType { +public protocol ObservableType: ObservableConvertibleType { /** Subscribes `observer` to receive events for this sequence. @@ -35,7 +35,7 @@ public protocol ObservableType : ObservableConvertibleType { } extension ObservableType { - + /// Default implementation of converting `ObservableType` to `Observable`. public func asObservable() -> Observable { // temporary workaround diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AddRef.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AddRef.swift index b782c13f49..2d107dc49b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AddRef.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AddRef.swift @@ -8,16 +8,16 @@ final class AddRefSink : Sink, ObserverType { typealias Element = O.E - + override init(observer: O, cancel: Cancelable) { super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { - case .next(_): + case .next: forwardOn(event) - case .completed, .error(_): + case .completed, .error: forwardOn(event) dispose() } @@ -26,15 +26,15 @@ final class AddRefSink : Sink, ObserverType { final class AddRef : Producer { typealias EventHandler = (Event) throws -> Void - + private let _source: Observable private let _refCount: RefCountDisposable - + init(source: Observable, refCount: RefCountDisposable) { _source = source _refCount = refCount } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let releaseDisposable = _refCount.retain() let sink = AddRefSink(observer: observer, cancel: cancel) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Amb.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Amb.swift index 08ec04e1ca..93b49fcfad 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Amb.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Amb.swift @@ -39,67 +39,67 @@ extension ObservableType { } } -fileprivate enum AmbState { +private enum AmbState { case neither case left case right } -final fileprivate class AmbObserver : ObserverType { +final private class AmbObserver : ObserverType { typealias Element = O.E typealias Parent = AmbSink typealias This = AmbObserver typealias Sink = (This, Event) -> Void - + fileprivate let _parent: Parent fileprivate var _sink: Sink fileprivate var _cancel: Disposable - + init(parent: Parent, cancel: Disposable, sink: @escaping Sink) { #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif - + _parent = parent _sink = sink _cancel = cancel } - + func on(_ event: Event) { _sink(self, event) if event.isStopEvent { _cancel.dispose() } } - + deinit { #if TRACE_RESOURCES - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() #endif } } -final fileprivate class AmbSink : Sink { +final private class AmbSink : Sink { typealias ElementType = O.E typealias Parent = Amb typealias AmbObserverType = AmbObserver private let _parent: Parent - + private let _lock = RecursiveLock() // state private var _choice = AmbState.neither - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { let subscription1 = SingleAssignmentDisposable() let subscription2 = SingleAssignmentDisposable() let disposeAll = Disposables.create(subscription1, subscription2) - + let forwardEvent = { (o: AmbObserverType, event: Event) -> Void in self.forwardOn(event) if event.isStopEvent { @@ -115,7 +115,7 @@ final fileprivate class AmbSink : Sink { o._cancel = disposeAll otherSubscription.dispose() } - + if self._choice == me { self.forwardOn(event) if event.isStopEvent { @@ -124,32 +124,32 @@ final fileprivate class AmbSink : Sink { } } } - + let sink1 = AmbObserver(parent: self, cancel: subscription1) { o, e in decide(o, e, .left, subscription2) } - + let sink2 = AmbObserver(parent: self, cancel: subscription1) { o, e in decide(o, e, .right, subscription1) } - + subscription1.setDisposable(_parent._left.subscribe(sink1)) subscription2.setDisposable(_parent._right.subscribe(sink2)) - + return disposeAll } } -final fileprivate class Amb: Producer { +final private class Amb: Producer { fileprivate let _left: Observable fileprivate let _right: Observable - + init(left: Observable, right: Observable) { _left = left _right = right } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = AmbSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift index 36fa685fa8..d2c169c426 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift @@ -10,7 +10,7 @@ fileprivate final class AsMaybeSink : Sink, ObserverType { typealias ElementType = O.E typealias E = ElementType - private var _element: Event? = nil + private var _element: Event? func on(_ event: Event) { switch event { @@ -41,7 +41,7 @@ final class AsMaybe: Producer { _source = source } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = AsMaybeSink(observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsSingle.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsSingle.swift index 080aa8e1a1..61e3e6eb9d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsSingle.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/AsSingle.swift @@ -10,7 +10,7 @@ fileprivate final class AsSingleSink : Sink, ObserverType { typealias ElementType = O.E typealias E = ElementType - private var _element: Event? = nil + private var _element: Event? func on(_ event: Event) { switch event { @@ -28,8 +28,7 @@ fileprivate final class AsSingleSink : Sink, ObserverType { if let element = _element { forwardOn(element) forwardOn(.completed) - } - else { + } else { forwardOn(.error(RxError.noElements)) } dispose() @@ -44,7 +43,7 @@ final class AsSingle: Producer { _source = source } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = AsSingleSink(observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Buffer.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Buffer.swift index b8c33ae818..f270c3807d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Buffer.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Buffer.swift @@ -26,65 +26,62 @@ extension ObservableType { } } -final fileprivate class BufferTimeCount : Producer<[Element]> { - +final private class BufferTimeCount : Producer<[Element]> { + fileprivate let _timeSpan: RxTimeInterval fileprivate let _count: Int fileprivate let _scheduler: SchedulerType fileprivate let _source: Observable - + init(source: Observable, timeSpan: RxTimeInterval, count: Int, scheduler: SchedulerType) { _source = source _timeSpan = timeSpan _count = count _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == [Element] { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == [Element] { let sink = BufferTimeCountSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) } } -final fileprivate class BufferTimeCountSink - : Sink - , LockOwnerType - , ObserverType - , SynchronizedOnType where O.E == [Element] { +final private class BufferTimeCountSink + : Sink, LockOwnerType, ObserverType, SynchronizedOnType where O.E == [Element] { typealias Parent = BufferTimeCount typealias E = Element - + private let _parent: Parent - + let _lock = RecursiveLock() - + // state private let _timerD = SerialDisposable() private var _buffer = [Element]() private var _windowID = 0 - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { createTimer(_windowID) return Disposables.create(_timerD, _parent._source.subscribe(self)) } - + func startNewWindowAndSendCurrentOne() { _windowID = _windowID &+ 1 let windowID = _windowID - + let buffer = _buffer _buffer = [] forwardOn(.next(buffer)) - + createTimer(windowID) } - + func on(_ event: Event) { synchronizedOn(event) } @@ -93,11 +90,11 @@ final fileprivate class BufferTimeCountSink switch event { case .next(let element): _buffer.append(element) - + if _buffer.count == _parent._count { startNewWindowAndSendCurrentOne() } - + case .error(let error): _buffer = [] forwardOn(.error(error)) @@ -108,18 +105,18 @@ final fileprivate class BufferTimeCountSink dispose() } } - + func createTimer(_ windowID: Int) { if _timerD.isDisposed { return } - + if _windowID != windowID { return } let nextTimer = SingleAssignmentDisposable() - + _timerD.disposable = nextTimer let disposable = _parent._scheduler.scheduleRelative(windowID, dueTime: _parent._timeSpan) { previousWindowID in @@ -127,10 +124,10 @@ final fileprivate class BufferTimeCountSink if previousWindowID != self._windowID { return } - + self.startNewWindowAndSendCurrentOne() } - + return Disposables.create() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Catch.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Catch.swift index 187eb8a988..447d9e30ce 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Catch.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Catch.swift @@ -33,7 +33,7 @@ extension ObservableType { -> Observable { return Catch(source: asObservable(), handler: { _ in Observable.just(element) }) } - + } extension ObservableType { @@ -83,19 +83,19 @@ extension ObservableType { // catch with callback -final fileprivate class CatchSinkProxy : ObserverType { +final private class CatchSinkProxy : ObserverType { typealias E = O.E typealias Parent = CatchSink - + private let _parent: Parent - + init(parent: Parent) { _parent = parent } - + func on(_ event: Event) { _parent.forwardOn(event) - + switch event { case .next: break @@ -105,18 +105,18 @@ final fileprivate class CatchSinkProxy : ObserverType { } } -final fileprivate class CatchSink : Sink, ObserverType { +final private class CatchSink : Sink, ObserverType { typealias E = O.E typealias Parent = Catch - + private let _parent: Parent private let _subscription = SerialDisposable() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { let d1 = SingleAssignmentDisposable() _subscription.disposable = d1 @@ -124,7 +124,7 @@ final fileprivate class CatchSink : Sink, ObserverType { return _subscription } - + func on(_ event: Event) { switch event { case .next: @@ -137,10 +137,9 @@ final fileprivate class CatchSink : Sink, ObserverType { let catchSequence = try _parent._handler(error) let observer = CatchSinkProxy(parent: self) - + _subscription.disposable = catchSequence.subscribe(observer) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -148,17 +147,17 @@ final fileprivate class CatchSink : Sink, ObserverType { } } -final fileprivate class Catch : Producer { +final private class Catch : Producer { typealias Handler = (Swift.Error) throws -> Observable - + fileprivate let _source: Observable fileprivate let _handler: Handler - + init(source: Observable, handler: @escaping Handler) { _source = source _handler = handler } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = CatchSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() @@ -168,18 +167,17 @@ final fileprivate class Catch : Producer { // catch enumerable -final fileprivate class CatchSequenceSink - : TailRecursiveSink - , ObserverType where S.Iterator.Element : ObservableConvertibleType, S.Iterator.Element.E == O.E { +final private class CatchSequenceSink + : TailRecursiveSink, ObserverType where S.Iterator.Element: ObservableConvertibleType, S.Iterator.Element.E == O.E { typealias Element = O.E typealias Parent = CatchSequence - + private var _lastError: Swift.Error? - + override init(observer: O, cancel: Cancelable) { super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next: @@ -196,38 +194,36 @@ final fileprivate class CatchSequenceSink override func subscribeToNext(_ source: Observable) -> Disposable { return source.subscribe(self) } - + override func done() { if let lastError = _lastError { forwardOn(.error(lastError)) - } - else { + } else { forwardOn(.completed) } - + self.dispose() } - + override func extract(_ observable: Observable) -> SequenceGenerator? { if let onError = observable as? CatchSequence { return (onError.sources.makeIterator(), nil) - } - else { + } else { return nil } } } -final fileprivate class CatchSequence : Producer where S.Iterator.Element : ObservableConvertibleType { +final private class CatchSequence : Producer where S.Iterator.Element: ObservableConvertibleType { typealias Element = S.Iterator.Element.E - + let sources: S - + init(sources: S) { self.sources = sources } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = CatchSequenceSink(observer: observer, cancel: cancel) let subscription = sink.run((self.sources.makeIterator(), nil)) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift index 45e01737ee..f063c6439b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift @@ -33,14 +33,14 @@ extension ObservableType { } } -final fileprivate class CombineLatestCollectionTypeSink - : Sink where C.Iterator.Element : ObservableConvertibleType { +final private class CombineLatestCollectionTypeSink + : Sink where C.Iterator.Element: ObservableConvertibleType { typealias R = O.E typealias Parent = CombineLatestCollectionType typealias SourceElement = C.Iterator.Element.E - + let _parent: Parent - + let _lock = RecursiveLock() // state @@ -49,21 +49,21 @@ final fileprivate class CombineLatestCollectionTypeSink() _subscriptions.reserveCapacity(parent._count) - + for _ in 0 ..< parent._count { _subscriptions.append(SingleAssignmentDisposable()) } - + super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event, atIndex: Int) { _lock.lock(); defer { _lock.unlock() } // { switch event { @@ -71,9 +71,9 @@ final fileprivate class CombineLatestCollectionTypeSink Disposable { var j = 0 for i in _parent._sources { @@ -124,21 +122,21 @@ final fileprivate class CombineLatestCollectionTypeSink : Producer where C.Iterator.Element : ObservableConvertibleType { +final private class CombineLatestCollectionType : Producer where C.Iterator.Element: ObservableConvertibleType { typealias ResultSelector = ([C.Iterator.Element.E]) throws -> R - + let _sources: C let _resultSelector: ResultSelector let _count: Int @@ -148,8 +146,8 @@ final fileprivate class CombineLatestCollectionType : Producer _resultSelector = resultSelector _count = Int(Int64(self._sources.count)) } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == R { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == R { let sink = CombineLatestCollectionTypeSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift index aad2255487..465a0b578c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift @@ -7,8 +7,6 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // - - // 2 extension ObservableType { @@ -105,8 +103,6 @@ final class CombineLatest2 : Producer { } } - - // 3 extension ObservableType { @@ -210,8 +206,6 @@ final class CombineLatest3 : Producer { } } - - // 4 extension ObservableType { @@ -322,8 +316,6 @@ final class CombineLatest4 : Producer { } } - - // 5 extension ObservableType { @@ -441,8 +433,6 @@ final class CombineLatest5 : Producer { } } - - // 6 extension ObservableType { @@ -567,8 +557,6 @@ final class CombineLatest6 : Producer { } } - - // 7 extension ObservableType { @@ -700,8 +688,6 @@ final class CombineLatest7 : Producer { } } - - // 8 extension ObservableType { @@ -839,5 +825,3 @@ final class CombineLatest8 : Producer { return (sink: sink, subscription: subscription) } } - - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift index 8c03e8c38c..0d846b3d94 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift @@ -6,17 +6,16 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol CombineLatestProtocol : class { +protocol CombineLatestProtocol: class { func next(_ index: Int) func fail(_ error: Swift.Error) func done(_ index: Int) } class CombineLatestSink - : Sink - , CombineLatestProtocol { + : Sink, CombineLatestProtocol { typealias Element = O.E - + let _lock = RecursiveLock() private let _arity: Int @@ -24,19 +23,19 @@ class CombineLatestSink private var _numberOfDone = 0 private var _hasValue: [Bool] private var _isDone: [Bool] - + init(arity: Int, observer: O, cancel: Cancelable) { _arity = arity _hasValue = [Bool](repeating: false, count: arity) _isDone = [Bool](repeating: false, count: arity) - + super.init(observer: observer, cancel: cancel) } - + func getResult() throws -> Element { rxAbstractMethod() } - + func next(_ index: Int) { if !_hasValue[index] { _hasValue[index] = true @@ -47,13 +46,11 @@ class CombineLatestSink do { let result = try getResult() forwardOn(.next(result)) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } - } - else { + } else { var allOthersDone = true for i in 0 ..< _arity { @@ -62,19 +59,19 @@ class CombineLatestSink break } } - + if allOthersDone { forwardOn(.completed) dispose() } } } - + func fail(_ error: Swift.Error) { forwardOn(.error(error)) dispose() } - + func done(_ index: Int) { if _isDone[index] { return @@ -91,19 +88,17 @@ class CombineLatestSink } final class CombineLatestObserver - : ObserverType - , LockOwnerType - , SynchronizedOnType { + : ObserverType, LockOwnerType, SynchronizedOnType { typealias Element = ElementType typealias ValueSetter = (Element) -> Void - + private let _parent: CombineLatestProtocol - + let _lock: RecursiveLock private let _index: Int private let _this: Disposable private let _setLatestValue: ValueSetter - + init(lock: RecursiveLock, parent: CombineLatestProtocol, index: Int, setLatestValue: @escaping ValueSetter, this: Disposable) { _lock = lock _parent = parent @@ -111,7 +106,7 @@ final class CombineLatestObserver _this = this _setLatestValue = setLatestValue } - + func on(_ event: Event) { synchronizedOn(event) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Concat.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Concat.swift index 35ef0e1f78..24ce36840f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Concat.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Concat.swift @@ -76,16 +76,15 @@ extension ObservableType { } } -final fileprivate class ConcatSink - : TailRecursiveSink - , ObserverType where S.Iterator.Element : ObservableConvertibleType, S.Iterator.Element.E == O.E { +final private class ConcatSink + : TailRecursiveSink, ObserverType where S.Iterator.Element: ObservableConvertibleType, S.Iterator.Element.E == O.E { typealias Element = O.E - + override init(observer: O, cancel: Cancelable) { super.init(observer: observer, cancel: cancel) } - - func on(_ event: Event){ + + func on(_ event: Event) { switch event { case .next: forwardOn(event) @@ -100,20 +99,19 @@ final fileprivate class ConcatSink override func subscribeToNext(_ source: Observable) -> Disposable { return source.subscribe(self) } - + override func extract(_ observable: Observable) -> SequenceGenerator? { if let source = observable as? Concat { return (source._sources.makeIterator(), source._count) - } - else { + } else { return nil } } } -final fileprivate class Concat : Producer where S.Iterator.Element : ObservableConvertibleType { +final private class Concat : Producer where S.Iterator.Element: ObservableConvertibleType { typealias Element = S.Iterator.Element.E - + fileprivate let _sources: S fileprivate let _count: IntMax? @@ -121,11 +119,10 @@ final fileprivate class Concat : Producer whe _sources = sources _count = count } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = ConcatSink(observer: observer, cancel: cancel) let subscription = sink.run((_sources.makeIterator(), _count)) return (sink: sink, subscription: subscription) } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Create.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Create.swift index 507c8e6d9c..5a362145b8 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Create.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Create.swift @@ -22,7 +22,7 @@ extension ObservableType { } } -final fileprivate class AnonymousObservableSink : Sink, ObserverType { +final private class AnonymousObservableSink : Sink, ObserverType { typealias E = O.E typealias Parent = AnonymousObservable @@ -61,7 +61,7 @@ final fileprivate class AnonymousObservableSink : Sink, Obse } } -final fileprivate class AnonymousObservable : Producer { +final private class AnonymousObservable : Producer { typealias SubscribeHandler = (AnyObserver) -> Disposable let _subscribeHandler: SubscribeHandler @@ -70,7 +70,7 @@ final fileprivate class AnonymousObservable : Producer { _subscribeHandler = subscribeHandler } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = AnonymousObservableSink(observer: observer, cancel: cancel) let subscription = sink.run(self) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debounce.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debounce.swift index 866427a0d4..22931d09d5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debounce.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debounce.swift @@ -23,11 +23,8 @@ extension ObservableType { } } -final fileprivate class DebounceSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class DebounceSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType { typealias Element = O.E typealias ParentType = Debounce @@ -37,7 +34,7 @@ final fileprivate class DebounceSink // state private var _id = 0 as UInt64 - private var _value: Element? = nil + private var _value: Element? let cancellable = SerialDisposable() @@ -64,7 +61,6 @@ final fileprivate class DebounceSink let currentId = _id _value = element - let scheduler = _parent._scheduler let dueTime = _parent._dueTime @@ -98,7 +94,7 @@ final fileprivate class DebounceSink } } -final fileprivate class Debounce : Producer { +final private class Debounce : Producer { fileprivate let _source: Observable fileprivate let _dueTime: RxTimeInterval @@ -115,5 +111,5 @@ final fileprivate class Debounce : Producer { let subscription = sink.run() return (sink: sink, subscription: subscription) } - + } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debug.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debug.swift index 85b8af7575..8a1183a631 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debug.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Debug.swift @@ -26,19 +26,19 @@ extension ObservableType { } } -fileprivate let dateFormat = "yyyy-MM-dd HH:mm:ss.SSS" +private let dateFormat = "yyyy-MM-dd HH:mm:ss.SSS" -fileprivate func logEvent(_ identifier: String, dateFormat: DateFormatter, content: String) { +private func logEvent(_ identifier: String, dateFormat: DateFormatter, content: String) { print("\(dateFormat.string(from: Date())): \(identifier) -> \(content)") } -final fileprivate class DebugSink : Sink, ObserverType where O.E == Source.E { +final private class DebugSink : Sink, ObserverType where O.E == Source.E { typealias Element = O.E typealias Parent = Debug - + private let _parent: Parent private let _timestampFormatter = DateFormatter() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _timestampFormatter.dateFormat = dateFormat @@ -47,7 +47,7 @@ final fileprivate class DebugSink : Sin super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { let maxEventTextLength = 40 let eventText = "\(event)" @@ -63,7 +63,7 @@ final fileprivate class DebugSink : Sin dispose() } } - + override func dispose() { if !self.disposed { logEvent(_parent._identifier, dateFormat: _timestampFormatter, content: "isDisposed") @@ -72,7 +72,7 @@ final fileprivate class DebugSink : Sin } } -final fileprivate class Debug : Producer { +final private class Debug : Producer { fileprivate let _identifier: String fileprivate let _trimOutput: Bool fileprivate let _source: Source @@ -81,20 +81,18 @@ final fileprivate class Debug : Producer { _trimOutput = trimOutput if let identifier = identifier { _identifier = identifier - } - else { + } else { let trimmedFile: String if let lastIndex = file.lastIndexOf("/") { trimmedFile = String(file[file.index(after: lastIndex) ..< file.endIndex]) - } - else { + } else { trimmedFile = file } _identifier = "\(trimmedFile):\(line) (\(function))" } _source = source } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Source.E { let sink = DebugSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift index 696361fdd3..69d369a1d7 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift @@ -21,22 +21,22 @@ extension ObservableType { } } -final fileprivate class DefaultIfEmptySink: Sink, ObserverType { +final private class DefaultIfEmptySink: Sink, ObserverType { typealias E = O.E private let _default: E private var _isEmpty = true - + init(default: E, observer: O, cancel: Cancelable) { _default = `default` super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { - case .next(_): + case .next: _isEmpty = false forwardOn(event) - case .error(_): + case .error: forwardOn(event) dispose() case .completed: @@ -49,15 +49,15 @@ final fileprivate class DefaultIfEmptySink: Sink, ObserverTy } } -final fileprivate class DefaultIfEmpty: Producer { +final private class DefaultIfEmpty: Producer { private let _source: Observable private let _default: SourceType - + init(source: Observable, `default`: SourceType) { _source = source _default = `default` } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceType { let sink = DefaultIfEmptySink(default: _default, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Deferred.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Deferred.swift index 947f604a5c..df0cbbdcd9 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Deferred.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Deferred.swift @@ -21,7 +21,7 @@ extension ObservableType { } } -final fileprivate class DeferredSink : Sink, ObserverType where S.E == O.E { +final private class DeferredSink : Sink, ObserverType where S.E == O.E { typealias E = O.E private let _observableFactory: () throws -> S @@ -30,22 +30,21 @@ final fileprivate class DeferredSink : Sink< _observableFactory = observableFactory super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { do { let result = try _observableFactory() return result.subscribe(self) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() return Disposables.create() } } - + func on(_ event: Event) { forwardOn(event) - + switch event { case .next: break @@ -57,15 +56,15 @@ final fileprivate class DeferredSink : Sink< } } -final fileprivate class Deferred : Producer { +final private class Deferred : Producer { typealias Factory = () throws -> S - - private let _observableFactory : Factory - + + private let _observableFactory: Factory + init(observableFactory: @escaping Factory) { _observableFactory = observableFactory } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == S.E { let sink = DeferredSink(observableFactory: _observableFactory, observer: observer, cancel: cancel) let subscription = sink.run() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Delay.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Delay.swift index 13955a3524..0b35a626e5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Delay.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Delay.swift @@ -25,18 +25,17 @@ extension ObservableType { } } -final fileprivate class DelaySink - : Sink - , ObserverType { +final private class DelaySink + : Sink, ObserverType { typealias E = O.E typealias Source = Observable typealias DisposeKey = Bag.KeyType - + private let _lock = RecursiveLock() private let _dueTime: RxTimeInterval private let _scheduler: SchedulerType - + private let _sourceSubscription = SingleAssignmentDisposable() private let _cancelable = SerialDisposable() @@ -44,12 +43,12 @@ final fileprivate class DelaySink private var _active = false // is "run loop" on different scheduler running private var _running = false - private var _errorEvent: Event? = nil + private var _errorEvent: Event? // state private var _queue = Queue<(eventTime: RxTime, event: Event)>(capacity: 0) private var _disposed = false - + init(observer: O, dueTime: RxTimeInterval, scheduler: SchedulerType, cancel: Cancelable) { _dueTime = dueTime _scheduler = scheduler @@ -84,14 +83,11 @@ final fileprivate class DelaySink let nextEventToScheduleOriginalTime: Date? = ranAtLeastOnce && !_queue.isEmpty ? _queue.peek().eventTime : nil if let _ = errorEvent { - } - else { + } else { if let _ = eventToForwardImmediately { - } - else if let _ = nextEventToScheduleOriginalTime { + } else if let _ = nextEventToScheduleOriginalTime { _running = false - } - else { + } else { _running = false _active = false } @@ -102,8 +98,7 @@ final fileprivate class DelaySink self.forwardOn(errorEvent) self.dispose() return - } - else { + } else { if let eventToForwardImmediately = eventToForwardImmediately { ranAtLeastOnce = true self.forwardOn(eventToForwardImmediately) @@ -111,28 +106,26 @@ final fileprivate class DelaySink self.dispose() return } - } - else if let nextEventToScheduleOriginalTime = nextEventToScheduleOriginalTime { + } else if let nextEventToScheduleOriginalTime = nextEventToScheduleOriginalTime { let elapsedTime = _scheduler.now.timeIntervalSince(nextEventToScheduleOriginalTime) let interval = _dueTime - elapsedTime let normalizedInterval = interval < 0.0 ? 0.0 : interval scheduler.schedule((), dueTime: normalizedInterval) return - } - else { + } else { return } } } } - + func on(_ event: Event) { if event.isStopEvent { _sourceSubscription.dispose() } switch event { - case .error(_): + case .error: _lock.lock() // { let shouldSendImmediately = !_running _queue = Queue(capacity: 0) @@ -155,25 +148,25 @@ final fileprivate class DelaySink } } } - + func run(source: Observable) -> Disposable { _sourceSubscription.setDisposable(source.subscribe(self)) return Disposables.create(_sourceSubscription, _cancelable) } } -final fileprivate class Delay: Producer { +final private class Delay: Producer { private let _source: Observable private let _dueTime: RxTimeInterval private let _scheduler: SchedulerType - + init(source: Observable, dueTime: RxTimeInterval, scheduler: SchedulerType) { _source = source _dueTime = dueTime _scheduler = scheduler } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = DelaySink(observer: observer, dueTime: _dueTime, scheduler: _scheduler, cancel: cancel) let subscription = sink.run(source: _source) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift index 9225a196c7..253808bc01 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift @@ -23,39 +23,39 @@ extension ObservableType { } } -final fileprivate class DelaySubscriptionSink +final private class DelaySubscriptionSink : Sink, ObserverType { typealias E = O.E typealias Parent = DelaySubscription - + private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { forwardOn(event) if event.isStopEvent { dispose() } } - + } -final fileprivate class DelaySubscription: Producer { +final private class DelaySubscription: Producer { private let _source: Observable private let _dueTime: RxTimeInterval private let _scheduler: SchedulerType - + init(source: Observable, dueTime: RxTimeInterval, scheduler: SchedulerType) { _source = source _dueTime = dueTime _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = DelaySubscriptionSink(parent: self, observer: observer, cancel: cancel) let subscription = _scheduler.scheduleRelative((), dueTime: _dueTime) { _ in return self._source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift index d142249a96..9c5ea9a6c6 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift @@ -36,14 +36,14 @@ fileprivate final class DematerializeSink: Producer { +final private class Dematerialize: Producer { private let _source: Observable - + init(source: Observable) { _source = source } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element.ElementType { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element.ElementType { let sink = DematerializeSink(observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift index f72f52014d..e1aef7c33e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift @@ -63,17 +63,17 @@ extension ObservableType { } } -final fileprivate class DistinctUntilChangedSink: Sink, ObserverType { +final private class DistinctUntilChangedSink: Sink, ObserverType { typealias E = O.E - + private let _parent: DistinctUntilChanged - private var _currentKey: Key? = nil - + private var _currentKey: Key? + init(parent: DistinctUntilChanged, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): @@ -83,16 +83,15 @@ final fileprivate class DistinctUntilChangedSink: Sink, if let currentKey = _currentKey { areEqual = try _parent._comparer(currentKey, key) } - + if areEqual { return } - + _currentKey = key - + forwardOn(event) - } - catch let error { + } catch let error { forwardOn(.error(error)) dispose() } @@ -103,20 +102,20 @@ final fileprivate class DistinctUntilChangedSink: Sink, } } -final fileprivate class DistinctUntilChanged: Producer { +final private class DistinctUntilChanged: Producer { typealias KeySelector = (Element) throws -> Key typealias EqualityComparer = (Key, Key) throws -> Bool - + fileprivate let _source: Observable fileprivate let _selector: KeySelector fileprivate let _comparer: EqualityComparer - + init(source: Observable, selector: @escaping KeySelector, comparer: @escaping EqualityComparer) { _source = source _selector = selector _comparer = comparer } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = DistinctUntilChangedSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Do.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Do.swift index 2be6d58328..22ef161a78 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Do.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Do.swift @@ -20,7 +20,7 @@ extension ObservableType { - parameter onDispose: Action to invoke after subscription to source observable has been disposed for any reason. It can be either because sequence terminates for some reason or observer subscription being disposed. - returns: The source sequence with the side-effecting behavior applied. */ - public func `do`(onNext: ((E) throws -> Void)? = nil, onError: ((Swift.Error) throws -> Void)? = nil, onCompleted: (() throws -> Void)? = nil, onSubscribe: (() -> ())? = nil, onSubscribed: (() -> ())? = nil, onDispose: (() -> ())? = nil) + public func `do`(onNext: ((E) throws -> Void)? = nil, onError: ((Swift.Error) throws -> Void)? = nil, onCompleted: (() throws -> Void)? = nil, onSubscribe: (() -> Void)? = nil, onSubscribed: (() -> Void)? = nil, onDispose: (() -> Void)? = nil) -> Observable { return Do(source: self.asObservable(), eventHandler: { e in switch e { @@ -35,17 +35,17 @@ extension ObservableType { } } -final fileprivate class DoSink : Sink, ObserverType { +final private class DoSink : Sink, ObserverType { typealias Element = O.E typealias EventHandler = (Event) throws -> Void - + private let _eventHandler: EventHandler - + init(eventHandler: @escaping EventHandler, observer: O, cancel: Cancelable) { _eventHandler = eventHandler super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { do { try _eventHandler(event) @@ -53,31 +53,30 @@ final fileprivate class DoSink : Sink, ObserverType { if event.isStopEvent { dispose() } - } - catch let error { + } catch let error { forwardOn(.error(error)) dispose() } } } -final fileprivate class Do : Producer { +final private class Do : Producer { typealias EventHandler = (Event) throws -> Void - + fileprivate let _source: Observable fileprivate let _eventHandler: EventHandler - fileprivate let _onSubscribe: (() -> ())? - fileprivate let _onSubscribed: (() -> ())? - fileprivate let _onDispose: (() -> ())? - - init(source: Observable, eventHandler: @escaping EventHandler, onSubscribe: (() -> ())?, onSubscribed: (() -> ())?, onDispose: (() -> ())?) { + fileprivate let _onSubscribe: (() -> Void)? + fileprivate let _onSubscribed: (() -> Void)? + fileprivate let _onDispose: (() -> Void)? + + init(source: Observable, eventHandler: @escaping EventHandler, onSubscribe: (() -> Void)?, onSubscribed: (() -> Void)?, onDispose: (() -> Void)?) { _source = source _eventHandler = eventHandler _onSubscribe = onSubscribe _onSubscribed = onSubscribed _onDispose = onDispose } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { _onSubscribe?() let sink = DoSink(eventHandler: _eventHandler, observer: observer, cancel: cancel) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ElementAt.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ElementAt.swift index 500a0442e4..a8609a9c68 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ElementAt.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ElementAt.swift @@ -22,38 +22,38 @@ extension ObservableType { } } -final fileprivate class ElementAtSink : Sink, ObserverType { +final private class ElementAtSink : Sink, ObserverType { typealias SourceType = O.E typealias Parent = ElementAt - + let _parent: Parent var _i: Int - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _i = parent._index - + super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { - case .next(_): + case .next: if (_i == 0) { forwardOn(event) forwardOn(.completed) self.dispose() } - + do { - let _ = try decrementChecked(&_i) + _ = try decrementChecked(&_i) } catch(let e) { forwardOn(.error(e)) dispose() return } - + case .error(let e): forwardOn(.error(e)) self.dispose() @@ -63,18 +63,18 @@ final fileprivate class ElementAtSink : Sink, ObserverType { } else { forwardOn(.completed) } - + self.dispose() } } } -final fileprivate class ElementAt : Producer { - +final private class ElementAt : Producer { + let _source: Observable let _throwOnEmpty: Bool let _index: Int - + init(source: Observable, index: Int, throwOnEmpty: Bool) { if index < 0 { rxFatalError("index can't be negative") @@ -84,7 +84,7 @@ final fileprivate class ElementAt : Producer { self._index = index self._throwOnEmpty = throwOnEmpty } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceType { let sink = ElementAtSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Empty.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Empty.swift index d2dcdb0096..abaeab1b8b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Empty.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Empty.swift @@ -19,8 +19,8 @@ extension ObservableType { } } -final fileprivate class EmptyProducer : Producer { - override func subscribe(_ observer: O) -> Disposable where O.E == Element { +final private class EmptyProducer : Producer { + override func subscribe(_ observer: O) -> Disposable where O.E == Element { observer.on(.completed) return Disposables.create() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Enumerated.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Enumerated.swift index 2a6cd98084..c86560e51f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Enumerated.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Enumerated.swift @@ -21,10 +21,10 @@ extension ObservableType { } } -final fileprivate class EnumeratedSink: Sink, ObserverType where O.E == (index: Int, element: Element) { +final private class EnumeratedSink: Sink, ObserverType where O.E == (index: Int, element: Element) { typealias E = Element var index = 0 - + func on(_ event: Event) { switch event { case .next(let value): @@ -32,8 +32,7 @@ final fileprivate class EnumeratedSink: Sink, Obse let nextIndex = try incrementChecked(&index) let next = (index: nextIndex, element: value) forwardOn(.next(next)) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -47,7 +46,7 @@ final fileprivate class EnumeratedSink: Sink, Obse } } -final fileprivate class Enumerated : Producer<(index: Int, element: Element)> { +final private class Enumerated : Producer<(index: Int, element: Element)> { private let _source: Observable init(source: Observable) { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Error.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Error.swift index a15942bb51..2e7be595f8 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Error.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Error.swift @@ -19,14 +19,14 @@ extension ObservableType { } } -final fileprivate class ErrorProducer : Producer { +final private class ErrorProducer : Producer { private let _error: Swift.Error - + init(error: Swift.Error) { _error = error } - - override func subscribe(_ observer: O) -> Disposable where O.E == Element { + + override func subscribe(_ observer: O) -> Disposable where O.E == Element { observer.on(.error(_error)) return Disposables.create() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Filter.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Filter.swift index 05dc8a4b7f..45113c9b72 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Filter.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Filter.swift @@ -40,17 +40,17 @@ extension ObservableType { } } -final fileprivate class FilterSink: Sink, ObserverType { +final private class FilterSink: Sink, ObserverType { typealias Predicate = (Element) throws -> Bool typealias Element = O.E - + private let _predicate: Predicate - + init(predicate: @escaping Predicate, observer: O, cancel: Cancelable) { _predicate = predicate super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): @@ -59,8 +59,7 @@ final fileprivate class FilterSink: Sink, ObserverType { if satisfies { forwardOn(.next(value)) } - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -71,17 +70,17 @@ final fileprivate class FilterSink: Sink, ObserverType { } } -final fileprivate class Filter : Producer { +final private class Filter : Producer { typealias Predicate = (Element) throws -> Bool - + private let _source: Observable private let _predicate: Predicate - + init(source: Observable, predicate: @escaping Predicate) { _source = source _predicate = predicate } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = FilterSink(predicate: _predicate, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/First.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/First.swift index 4a72ba0d14..2dbdc79597 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/First.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/First.swift @@ -34,7 +34,7 @@ final class First: Producer { _source = source } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element? { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element? { let sink = FirstSink(observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Generate.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Generate.swift index 6469937dbd..4c1d48274e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Generate.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Generate.swift @@ -24,38 +24,36 @@ extension ObservableType { } } -final fileprivate class GenerateSink : Sink { +final private class GenerateSink : Sink { typealias Parent = Generate - + private let _parent: Parent - + private var _state: S - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _state = parent._initialState super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { return _parent._scheduler.scheduleRecursive(true) { (isFirst, recurse) -> Void in do { if !isFirst { self._state = try self._parent._iterate(self._state) } - + if try self._parent._condition(self._state) { let result = try self._parent._resultSelector(self._state) self.forwardOn(.next(result)) - + recurse(false) - } - else { + } else { self.forwardOn(.completed) self.dispose() } - } - catch let error { + } catch let error { self.forwardOn(.error(error)) self.dispose() } @@ -63,13 +61,13 @@ final fileprivate class GenerateSink : Sink { } } -final fileprivate class Generate : Producer { +final private class Generate : Producer { fileprivate let _initialState: S fileprivate let _condition: (S) throws -> Bool fileprivate let _iterate: (S) throws -> S fileprivate let _resultSelector: (S) throws -> E fileprivate let _scheduler: ImmediateSchedulerType - + init(initialState: S, condition: @escaping (S) throws -> Bool, iterate: @escaping (S) throws -> S, resultSelector: @escaping (S) throws -> E, scheduler: ImmediateSchedulerType) { _initialState = initialState _condition = condition @@ -78,8 +76,8 @@ final fileprivate class Generate : Producer { _scheduler = scheduler super.init() } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = GenerateSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/GroupBy.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/GroupBy.swift index a8a0e78afd..6ce5fd8301 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/GroupBy.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/GroupBy.swift @@ -16,15 +16,15 @@ extension ObservableType { - returns: A sequence of observable groups, each of which corresponds to a unique key value, containing all elements that share that same key value. */ public func groupBy(keySelector: @escaping (E) throws -> K) - -> Observable> { + -> Observable> { return GroupBy(source: self.asObservable(), selector: keySelector) } } -final fileprivate class GroupedObservableImpl : Observable { +final private class GroupedObservableImpl : Observable { private var _subject: PublishSubject private var _refCount: RefCountDisposable - + init(key: Key, subject: PublishSubject, refCount: RefCountDisposable) { _subject = subject _refCount = refCount @@ -37,10 +37,8 @@ final fileprivate class GroupedObservableImpl : Observable - : Sink - , ObserverType where O.E == GroupedObservable { +final private class GroupBySink + : Sink, ObserverType where O.E == GroupedObservable { typealias E = Element typealias ResultType = O.E typealias Parent = GroupBy @@ -49,33 +47,33 @@ final fileprivate class GroupBySink private let _subscription = SingleAssignmentDisposable() private var _refCountDisposable: RefCountDisposable! private var _groupedSubjectTable: [Key: PublishSubject] - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _groupedSubjectTable = [Key: PublishSubject]() super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { _refCountDisposable = RefCountDisposable(disposable: _subscription) - + _subscription.setDisposable(_parent._source.subscribe(self)) - + return _refCountDisposable } - + private func onGroupEvent(key: Key, value: Element) { if let writer = _groupedSubjectTable[key] { writer.on(.next(value)) } else { let writer = PublishSubject() _groupedSubjectTable[key] = writer - + let group = GroupedObservable( key: key, source: GroupedObservableImpl(key: key, subject: writer, refCount: _refCountDisposable) ) - + forwardOn(.next(group)) writer.on(.next(value)) } @@ -87,8 +85,7 @@ final fileprivate class GroupBySink do { let groupKey = try _parent._selector(value) onGroupEvent(key: groupKey, value: value) - } - catch let e { + } catch let e { error(e) return } @@ -108,7 +105,7 @@ final fileprivate class GroupBySink _subscription.dispose() dispose() } - + final func forwardOnGroups(event: Event) { for writer in _groupedSubjectTable.values { writer.on(event) @@ -116,18 +113,18 @@ final fileprivate class GroupBySink } } -final fileprivate class GroupBy: Producer> { +final private class GroupBy: Producer> { typealias KeySelector = (Element) throws -> Key fileprivate let _source: Observable fileprivate let _selector: KeySelector - + init(source: Observable, selector: @escaping KeySelector) { _source = source _selector = selector } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == GroupedObservable { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == GroupedObservable { let sink = GroupBySink(parent: self, observer: observer, cancel: cancel) return (sink: sink, subscription: sink.run()) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Just.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Just.swift index 4e49059bc6..466de2bd04 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Just.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Just.swift @@ -33,7 +33,7 @@ extension ObservableType { } } -final fileprivate class JustScheduledSink : Sink { +final private class JustScheduledSink : Sink { typealias Parent = JustScheduled private let _parent: Parent @@ -56,7 +56,7 @@ final fileprivate class JustScheduledSink : Sink { } } -final fileprivate class JustScheduled : Producer { +final private class JustScheduled : Producer { fileprivate let _scheduler: ImmediateSchedulerType fileprivate let _element: Element @@ -65,21 +65,21 @@ final fileprivate class JustScheduled : Producer { _element = element } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = JustScheduledSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) } } -final fileprivate class Just : Producer { +final private class Just : Producer { private let _element: Element - + init(element: Element) { _element = element } - - override func subscribe(_ observer: O) -> Disposable where O.E == Element { + + override func subscribe(_ observer: O) -> Disposable where O.E == Element { observer.on(.next(_element)) observer.on(.completed) return Disposables.create() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Map.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Map.swift index c513218f66..fd7f266860 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Map.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Map.swift @@ -23,14 +23,14 @@ extension ObservableType { } } -final fileprivate class MapSink : Sink, ObserverType { +final private class MapSink : Sink, ObserverType { typealias Transform = (SourceType) throws -> ResultType typealias ResultType = O.E typealias Element = SourceType private let _transform: Transform - + init(transform: @escaping Transform, observer: O, cancel: Cancelable) { _transform = transform super.init(observer: observer, cancel: cancel) @@ -42,8 +42,7 @@ final fileprivate class MapSink : Sink, Observe do { let mappedElement = try _transform(element) forwardOn(.next(mappedElement)) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -58,7 +57,7 @@ final fileprivate class MapSink : Sink, Observe } #if TRACE_RESOURCES - fileprivate var _numberOfMapOperators = AtomicInt(0) + private var _numberOfMapOperators = AtomicInt(0) extension Resources { public static var numberOfMapOperators: Int32 { return _numberOfMapOperators.load() @@ -70,7 +69,7 @@ internal func _map(source: Observable, transform: @escaping return Map(source: source, transform: transform) } -final fileprivate class Map: Producer { +final private class Map: Producer { typealias Transform = (SourceType) throws -> ResultType private let _source: Observable @@ -82,7 +81,7 @@ final fileprivate class Map: Producer { _transform = transform #if TRACE_RESOURCES - let _ = _numberOfMapOperators.increment() + _ = _numberOfMapOperators.increment() #endif } @@ -93,7 +92,7 @@ final fileprivate class Map: Producer { return try selector(r) }) } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == ResultType { let sink = MapSink(transform: _transform, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) @@ -102,7 +101,7 @@ final fileprivate class Map: Producer { #if TRACE_RESOURCES deinit { - let _ = _numberOfMapOperators.decrement() + _ = _numberOfMapOperators.decrement() } #endif } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Materialize.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Materialize.swift index cf19b6da9b..18e549d979 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Materialize.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Materialize.swift @@ -18,7 +18,7 @@ extension ObservableType { } fileprivate final class MaterializeSink: Sink, ObserverType where O.E == Event { - + func on(_ event: Event) { forwardOn(.next(event)) if event.isStopEvent { @@ -28,9 +28,9 @@ fileprivate final class MaterializeSink: Sink, Obse } } -final fileprivate class Materialize: Producer> { +final private class Materialize: Producer> { private let _source: Observable - + init(source: Observable) { _source = source } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Merge.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Merge.swift index b2f9a0d9fc..3790efd647 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Merge.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Merge.swift @@ -40,7 +40,7 @@ extension ObservableType { } } -extension ObservableType where E : ObservableConvertibleType { +extension ObservableType where E: ObservableConvertibleType { /** Merges elements from all observable sequences in the given enumerable sequence into a single observable sequence. @@ -67,7 +67,7 @@ extension ObservableType where E : ObservableConvertibleType { } } -extension ObservableType where E : ObservableConvertibleType { +extension ObservableType where E: ObservableConvertibleType { /** Concatenates all inner observable sequences, as long as the previous observable sequence terminated successfully. @@ -129,7 +129,7 @@ extension ObservableType { - returns: An observable sequence that contains the elements of each observed inner sequence, in sequential order. */ - + public func concatMap(_ selector: @escaping (E) throws -> O) -> Observable { return ConcatMap(source: asObservable(), selector: selector) @@ -137,25 +137,23 @@ extension ObservableType { } fileprivate final class MergeLimitedSinkIter - : ObserverType - , LockOwnerType - , SynchronizedOnType where SourceSequence.E == Observer.E { + : ObserverType, LockOwnerType, SynchronizedOnType where SourceSequence.E == Observer.E { typealias E = Observer.E typealias DisposeKey = CompositeDisposable.DisposeKey typealias Parent = MergeLimitedSink - + private let _parent: Parent private let _disposeKey: DisposeKey var _lock: RecursiveLock { return _parent._lock } - + init(parent: Parent, disposeKey: DisposeKey) { _parent = parent _disposeKey = disposeKey } - + func on(_ event: Event) { synchronizedOn(event) } @@ -171,10 +169,9 @@ fileprivate final class MergeLimitedSinkIter: MergeLimitedSink where Observer.E == SourceSequence.E { typealias Selector = (SourceElement) throws -> SourceSequence - + private let _selector: Selector - + init(selector: @escaping Selector, observer: Observer, cancel: Cancelable) { _selector = selector super.init(maxConcurrent: 1, observer: observer, cancel: cancel) } - + override func performMap(_ element: SourceElement) throws -> SourceSequence { return try _selector(element) } } fileprivate final class MergeLimitedBasicSink: MergeLimitedSink where Observer.E == SourceSequence.E { - + override func performMap(_ element: SourceSequence) throws -> SourceSequence { return element } } -fileprivate class MergeLimitedSink - : Sink - , ObserverType where Observer.E == SourceSequence.E { +private class MergeLimitedSink + : Sink, ObserverType where Observer.E == SourceSequence.E { typealias QueueType = Queue let _maxConcurrent: Int @@ -219,36 +215,36 @@ fileprivate class MergeLimitedSink) -> Disposable { - let _ = _group.insert(_sourceSubscription) - + _ = _group.insert(_sourceSubscription) + let disposable = source.subscribe(self) _sourceSubscription.setDisposable(disposable) return _group } - + func subscribe(_ innerSource: SourceSequence, group: CompositeDisposable) { let subscription = SingleAssignmentDisposable() - + let key = group.insert(subscription) - + if let key = key { let observer = MergeLimitedSinkIter(parent: self, disposeKey: key) - + let disposable = innerSource.asObservable().subscribe(observer) subscription.setDisposable(disposable) } } - + func performMap(_ element: SourceElement) throws -> SourceSequence { rxAbstractMethod() } @@ -260,8 +256,7 @@ fileprivate class MergeLimitedSink : Producer { +final private class MergeLimited : Producer { private let _source: Observable private let _maxConcurrent: Int - + init(source: Observable, maxConcurrent: Int) { _source = source _maxConcurrent = maxConcurrent } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceSequence.E { let sink = MergeLimitedBasicSink(maxConcurrent: _maxConcurrent, observer: observer, cancel: cancel) let subscription = sink.run(_source) @@ -378,7 +372,7 @@ fileprivate final class MergeSinkIter typealias DisposeKey = CompositeDisposable.DisposeKey typealias E = Observer.E - + private let _parent: Parent private let _disposeKey: DisposeKey @@ -386,7 +380,7 @@ fileprivate final class MergeSinkIter) { _parent._lock.lock(); defer { _parent._lock.unlock() } // lock { switch event { @@ -404,10 +398,8 @@ fileprivate final class MergeSinkIter - : Sink - , ObserverType where Observer.E == SourceSequence.E { +private class MergeSink + : Sink, ObserverType where Observer.E == SourceSequence.E { typealias ResultType = Observer.E typealias Element = SourceElement @@ -443,15 +435,14 @@ fileprivate class MergeSink) { switch event { case .next(let element): @@ -500,31 +491,31 @@ fileprivate class MergeSink) -> Disposable { - let _ = _group.insert(_sourceSubscription) + _ = _group.insert(_sourceSubscription) let subscription = source.subscribe(self) _sourceSubscription.setDisposable(subscription) - + return _group } } // MARK: Producers -final fileprivate class FlatMap: Producer { +final private class FlatMap: Producer { typealias Selector = (SourceElement) throws -> SourceSequence private let _source: Observable - + private let _selector: Selector init(source: Observable, selector: @escaping Selector) { _source = source _selector = selector } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceSequence.E { let sink = FlatMapSink(selector: _selector, observer: observer, cancel: cancel) let subscription = sink.run(_source) @@ -532,7 +523,7 @@ final fileprivate class FlatMap: Producer { +final private class FlatMapFirst: Producer { typealias Selector = (SourceElement) throws -> SourceSequence private let _source: Observable @@ -553,15 +544,15 @@ final fileprivate class FlatMapFirst: Producer { typealias Selector = (SourceElement) throws -> SourceSequence - + private let _source: Observable private let _selector: Selector - + init(source: Observable, selector: @escaping Selector) { _source = source _selector = selector } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceSequence.E { let sink = ConcatMapSink(selector: _selector, observer: observer, cancel: cancel) let subscription = sink.run(_source) @@ -575,7 +566,7 @@ final class Merge : Producer) { _source = source } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == SourceSequence.E { let sink = MergeBasicSink(observer: observer, cancel: cancel) let subscription = sink.run(_source) @@ -583,7 +574,7 @@ final class Merge : Producer : Producer { +final private class MergeArray : Producer { private let _sources: [Observable] init(sources: [Observable]) { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Multicast.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Multicast.swift index a027c4f69c..5eaf9e9810 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Multicast.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Multicast.swift @@ -10,8 +10,7 @@ Represents an observable wrapper that can be connected and disconnected from its underlying observable sequence. */ public class ConnectableObservable - : Observable - , ConnectableObservableType { + : Observable, ConnectableObservableType { /** Connects the observable wrapper to its source. All subscribed observers will receive values from the underlying observable sequence as long as the connection is established. @@ -24,7 +23,7 @@ public class ConnectableObservable } extension ObservableType { - + /** Multicasts the source sequence notifications through an instantiated subject into all uses of the sequence within a selector function. @@ -49,7 +48,7 @@ extension ObservableType { } extension ObservableType { - + /** Returns a connectable observable sequence that shares a single subscription to the underlying sequence. @@ -97,7 +96,7 @@ extension ObservableType { } extension ConnectableObservableType { - + /** Returns an observable sequence that stays connected to the source as long as there is at least one subscription to the observable sequence. @@ -147,13 +146,13 @@ extension ObservableType { } } -final fileprivate class Connection : ObserverType, Disposable { +final private class Connection : ObserverType, Disposable { typealias E = S.SubjectObserverType.E private var _lock: RecursiveLock // state private var _parent: ConnectableObservableAdapter? - private var _subscription : Disposable? + private var _subscription: Disposable? private var _subjectObserver: S.SubjectObserverType private var _disposed: Bool = false @@ -194,7 +193,7 @@ final fileprivate class Connection : ObserverType, Disposable { } } -final fileprivate class ConnectableObservableAdapter +final private class ConnectableObservableAdapter : ConnectableObservable { typealias ConnectionType = Connection @@ -239,14 +238,13 @@ final fileprivate class ConnectableObservableAdapter return subject } - override func subscribe(_ observer: O) -> Disposable where O.E == S.E { + override func subscribe(_ observer: O) -> Disposable where O.E == S.E { return self.lazySubject.subscribe(observer) } } -final fileprivate class RefCountSink - : Sink - , ObserverType where CO.E == O.E { +final private class RefCountSink + : Sink, ObserverType where CO.E == O.E { typealias Element = O.E typealias Parent = RefCount @@ -272,8 +270,7 @@ final fileprivate class RefCountSink 1 { + } else if self._parent._count > 1 { self._parent._count = self._parent._count - 1 - } - else { + } else { rxFatalError("Something went wrong with RefCount disposing mechanism") } // } @@ -324,7 +319,7 @@ final fileprivate class RefCountSink: Producer { +final private class RefCount: Producer { fileprivate let _lock = RecursiveLock() // state @@ -345,37 +340,36 @@ final fileprivate class RefCount: Producer } } -final fileprivate class MulticastSink: Sink, ObserverType { +final private class MulticastSink: Sink, ObserverType { typealias Element = O.E typealias ResultType = Element typealias MutlicastType = Multicast - + private let _parent: MutlicastType - + init(parent: MutlicastType, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { do { let subject = try _parent._subjectSelector() let connectable = ConnectableObservableAdapter(source: _parent._source, makeSubject: { subject }) - + let observable = try _parent._selector(connectable) - + let subscription = observable.subscribe(self) let connection = connectable.connect() - + return Disposables.create(subscription, connection) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() return Disposables.create() } } - + func on(_ event: Event) { forwardOn(event) switch event { @@ -386,20 +380,20 @@ final fileprivate class MulticastSink: Sink, } } -final fileprivate class Multicast: Producer { +final private class Multicast: Producer { typealias SubjectSelectorType = () throws -> S typealias SelectorType = (Observable) throws -> Observable - + fileprivate let _source: Observable fileprivate let _subjectSelector: SubjectSelectorType fileprivate let _selector: SelectorType - + init(source: Observable, subjectSelector: @escaping SubjectSelectorType, selector: @escaping SelectorType) { _source = source _subjectSelector = subjectSelector _selector = selector } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == R { let sink = MulticastSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Never.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Never.swift index d98a7a8fa4..77ac7303b4 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Never.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Never.swift @@ -20,8 +20,8 @@ extension ObservableType { } } -final fileprivate class NeverProducer : Producer { - override func subscribe(_ observer: O) -> Disposable where O.E == Element { +final private class NeverProducer : Producer { + override func subscribe(_ observer: O) -> Disposable where O.E == Element { return Disposables.create() } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift index 82147a0fb2..552ce7dc2d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift @@ -23,49 +23,48 @@ extension ObservableType { -> Observable { if let scheduler = scheduler as? SerialDispatchQueueScheduler { return ObserveOnSerialDispatchQueue(source: self.asObservable(), scheduler: scheduler) - } - else { + } else { return ObserveOn(source: self.asObservable(), scheduler: scheduler) } } } -final fileprivate class ObserveOn : Producer { +final private class ObserveOn : Producer { let scheduler: ImmediateSchedulerType let source: Observable - + init(source: Observable, scheduler: ImmediateSchedulerType) { self.scheduler = scheduler self.source = source - + #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = ObserveOnSink(scheduler: scheduler, observer: observer, cancel: cancel) let subscription = source.subscribe(sink) return (sink: sink, subscription: subscription) } - + #if TRACE_RESOURCES deinit { - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() } #endif } -enum ObserveOnState : Int32 { +enum ObserveOnState: Int32 { // pump is not running case stopped = 0 // pump is running case running = 1 } -final fileprivate class ObserveOnSink : ObserverBase { +final private class ObserveOnSink : ObserverBase { typealias E = O.E - + let _scheduler: ImmediateSchedulerType var _lock = SpinLock() @@ -87,7 +86,7 @@ final fileprivate class ObserveOnSink : ObserverBase { override func onCore(_ event: Event) { let shouldStart = _lock.calculateLocked { () -> Bool in self._queue.enqueue(event) - + switch self._state { case .stopped: self._state = .running @@ -96,18 +95,17 @@ final fileprivate class ObserveOnSink : ObserverBase { return false } } - + if shouldStart { _scheduleDisposable.disposable = self._scheduler.scheduleRecursive((), action: self.run) } } - - func run(_ state: (), _ recurse: (()) -> ()) { + + func run(_ state: (), _ recurse: (()) -> Void) { let (nextEvent, observer) = self._lock.calculateLocked { () -> (Event?, O) in if !self._queue.isEmpty { return (self._queue.dequeue(), self._observer) - } - else { + } else { self._state = .stopped return (nil, self._observer) } @@ -118,8 +116,7 @@ final fileprivate class ObserveOnSink : ObserverBase { if nextEvent.isStopEvent { dispose() } - } - else { + } else { return } @@ -134,14 +131,13 @@ final fileprivate class ObserveOnSink : ObserverBase { _lock.lock(); defer { _lock.unlock() } // { if !self._queue.isEmpty { return true - } - else { + } else { self._state = .stopped return false } // } } - + override func dispose() { super.dispose() @@ -151,7 +147,7 @@ final fileprivate class ObserveOnSink : ObserverBase { } #if TRACE_RESOURCES - fileprivate var _numberOfSerialDispatchQueueObservables = AtomicInt(0) + private var _numberOfSerialDispatchQueueObservables = AtomicInt(0) extension Resources { /** Counts number of `SerialDispatchQueueObservables`. @@ -164,7 +160,7 @@ final fileprivate class ObserveOnSink : ObserverBase { } #endif -final fileprivate class ObserveOnSerialDispatchQueueSink : ObserverBase { +final private class ObserveOnSerialDispatchQueueSink : ObserverBase { let scheduler: SerialDispatchQueueScheduler let observer: O @@ -192,7 +188,7 @@ final fileprivate class ObserveOnSerialDispatchQueueSink : Obse } override func onCore(_ event: Event) { - let _ = self.scheduler.schedule((self, event), action: cachedScheduleLambda!) + _ = self.scheduler.schedule((self, event), action: cachedScheduleLambda!) } override func dispose() { @@ -202,7 +198,7 @@ final fileprivate class ObserveOnSerialDispatchQueueSink : Obse } } -final fileprivate class ObserveOnSerialDispatchQueue : Producer { +final private class ObserveOnSerialDispatchQueue : Producer { let scheduler: SerialDispatchQueueScheduler let source: Observable @@ -211,12 +207,12 @@ final fileprivate class ObserveOnSerialDispatchQueue : Producer { self.source = source #if TRACE_RESOURCES - let _ = Resources.incrementTotal() - let _ = _numberOfSerialDispatchQueueObservables.increment() + _ = Resources.incrementTotal() + _ = _numberOfSerialDispatchQueueObservables.increment() #endif } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = ObserveOnSerialDispatchQueueSink(scheduler: scheduler, observer: observer, cancel: cancel) let subscription = source.subscribe(sink) return (sink: sink, subscription: subscription) @@ -224,8 +220,8 @@ final fileprivate class ObserveOnSerialDispatchQueue : Producer { #if TRACE_RESOURCES deinit { - let _ = Resources.decrementTotal() - let _ = _numberOfSerialDispatchQueueObservables.decrement() + _ = Resources.decrementTotal() + _ = _numberOfSerialDispatchQueueObservables.decrement() } #endif } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Optional.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Optional.swift index 8cd6a16baf..4f40fe14e3 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Optional.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Optional.swift @@ -33,7 +33,7 @@ extension ObservableType { } } -final fileprivate class ObservableOptionalScheduledSink : Sink { +final private class ObservableOptionalScheduledSink : Sink { typealias E = O.E typealias Parent = ObservableOptionalScheduled @@ -62,7 +62,7 @@ final fileprivate class ObservableOptionalScheduledSink : Sink< } } -final fileprivate class ObservableOptionalScheduled : Producer { +final private class ObservableOptionalScheduled : Producer { fileprivate let _optional: E? fileprivate let _scheduler: ImmediateSchedulerType @@ -71,21 +71,21 @@ final fileprivate class ObservableOptionalScheduled : Producer { _scheduler = scheduler } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = ObservableOptionalScheduledSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) } } -final fileprivate class ObservableOptional: Producer { +final private class ObservableOptional: Producer { private let _optional: E? - + init(optional: E?) { _optional = optional } - - override func subscribe(_ observer: O) -> Disposable where O.E == E { + + override func subscribe(_ observer: O) -> Disposable where O.E == E { if let element = _optional { observer.on(.next(element)) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Producer.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Producer.swift index 2b60fbf8ed..a1199e9796 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Producer.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Producer.swift @@ -10,8 +10,8 @@ class Producer : Observable { override init() { super.init() } - - override func subscribe(_ observer: O) -> Disposable where O.E == Element { + + override func subscribe(_ observer: O) -> Disposable where O.E == Element { if !CurrentThreadScheduler.isScheduleRequired { // The returned disposable needs to release all references once it was disposed. let disposer = SinkDisposer() @@ -19,8 +19,7 @@ class Producer : Observable { disposer.setSinkAndSubscription(sink: sinkAndSubscription.sink, subscription: sinkAndSubscription.subscription) return disposer - } - else { + } else { return CurrentThreadScheduler.instance.schedule(()) { _ in let disposer = SinkDisposer() let sinkAndSubscription = self.run(observer, cancel: disposer) @@ -30,8 +29,8 @@ class Producer : Observable { } } } - - func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { rxAbstractMethod() } } @@ -43,8 +42,8 @@ fileprivate final class SinkDisposer: Cancelable { } private var _state = AtomicInt(0) - private var _sink: Disposable? = nil - private var _subscription: Disposable? = nil + private var _sink: Disposable? + private var _subscription: Disposable? var isDisposed: Bool { return _state.isFlagSet(DisposeState.disposed.rawValue) @@ -66,7 +65,7 @@ fileprivate final class SinkDisposer: Cancelable { _subscription = nil } } - + func dispose() { let previousState = _state.fetchOr(DisposeState.disposed.rawValue) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Range.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Range.swift index 9b85554eb7..8d455cae4f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Range.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Range.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -extension ObservableType where E : RxAbstractInteger { +extension ObservableType where E: RxAbstractInteger { /** Generates an observable sequence of integral numbers within a specified range, using the specified scheduler to generate and send out observer messages. @@ -22,7 +22,7 @@ extension ObservableType where E : RxAbstractInteger { } } -final fileprivate class RangeProducer : Producer { +final private class RangeProducer : Producer { fileprivate let _start: E fileprivate let _count: E fileprivate let _scheduler: ImmediateSchedulerType @@ -40,31 +40,30 @@ final fileprivate class RangeProducer : Producer { _count = count _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = RangeSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) } } -final fileprivate class RangeSink : Sink where O.E: RxAbstractInteger { +final private class RangeSink : Sink where O.E: RxAbstractInteger { typealias Parent = RangeProducer - + private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { return _parent._scheduler.scheduleRecursive(0 as O.E) { i, recurse in if i < self._parent._count { self.forwardOn(.next(self._parent._start + i)) recurse(i + 1) - } - else { + } else { self.forwardOn(.completed) self.dispose() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Reduce.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Reduce.swift index 3e4a7b9de9..964d6c6632 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Reduce.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Reduce.swift @@ -6,7 +6,6 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // - extension ObservableType { /** Applies an `accumulator` function over an observable sequence, returning the result of the aggregation as a single element in the result sequence. The specified `seed` value is used as the initial accumulator value. @@ -42,27 +41,26 @@ extension ObservableType { } } -final fileprivate class ReduceSink : Sink, ObserverType { +final private class ReduceSink : Sink, ObserverType { typealias ResultType = O.E typealias Parent = Reduce - + private let _parent: Parent private var _accumulation: AccumulateType - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _accumulation = parent._seed - + super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): do { _accumulation = try _parent._accumulator(_accumulation, value) - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -75,8 +73,7 @@ final fileprivate class ReduceSink forwardOn(.next(result)) forwardOn(.completed) dispose() - } - catch let e { + } catch let e { forwardOn(.error(e)) dispose() } @@ -84,15 +81,15 @@ final fileprivate class ReduceSink } } -final fileprivate class Reduce : Producer { +final private class Reduce : Producer { typealias AccumulatorType = (AccumulateType, SourceType) throws -> AccumulateType typealias ResultSelectorType = (AccumulateType) throws -> ResultType - + fileprivate let _source: Observable fileprivate let _seed: AccumulateType fileprivate let _accumulator: AccumulatorType fileprivate let _mapResult: ResultSelectorType - + init(source: Observable, seed: AccumulateType, accumulator: @escaping AccumulatorType, mapResult: @escaping ResultSelectorType) { _source = source _seed = seed @@ -106,4 +103,3 @@ final fileprivate class Reduce : Produce return (sink: sink, subscription: subscription) } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Repeat.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Repeat.swift index 6892ec128b..f66adb29d4 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Repeat.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Repeat.swift @@ -21,16 +21,16 @@ extension ObservableType { } } -final fileprivate class RepeatElement : Producer { +final private class RepeatElement : Producer { fileprivate let _element: Element fileprivate let _scheduler: ImmediateSchedulerType - + init(element: Element, scheduler: ImmediateSchedulerType) { _element = element _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = RepeatElementSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() @@ -38,16 +38,16 @@ final fileprivate class RepeatElement : Producer { } } -final fileprivate class RepeatElementSink : Sink { +final private class RepeatElementSink : Sink { typealias Parent = RepeatElement - + private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { return _parent._scheduler.scheduleRecursive(_parent._element) { e, recurse in self.forwardOn(.next(e)) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift index 268b399a8c..39a3e4ba39 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift @@ -37,12 +37,12 @@ extension ObservableType { } } -final fileprivate class RetryTriggerSink - : ObserverType where S.Iterator.Element : ObservableType, S.Iterator.Element.E == O.E { +final private class RetryTriggerSink + : ObserverType where S.Iterator.Element: ObservableType, S.Iterator.Element.E == O.E { typealias E = TriggerObservable.E - + typealias Parent = RetryWhenSequenceSinkIter - + fileprivate let _parent: Parent init(parent: Parent) { @@ -64,9 +64,8 @@ final fileprivate class RetryTriggerSink - : ObserverType - , Disposable where S.Iterator.Element : ObservableType, S.Iterator.Element.E == O.E { +final private class RetryWhenSequenceSinkIter + : ObserverType, Disposable where S.Iterator.Element: ObservableType, S.Iterator.Element.E == O.E { typealias E = O.E typealias Parent = RetryWhenSequenceSink @@ -93,8 +92,7 @@ final fileprivate class RetryWhenSequenceSinkIter - : TailRecursiveSink where S.Iterator.Element : ObservableType, S.Iterator.Element.E == O.E { +final private class RetryWhenSequenceSink + : TailRecursiveSink where S.Iterator.Element: ObservableType, S.Iterator.Element.E == O.E { typealias Element = O.E typealias Parent = RetryWhenSequence - + let _lock = RecursiveLock() - + fileprivate let _parent: Parent - + fileprivate var _lastError: Swift.Error? fileprivate let _errorSubject = PublishSubject() fileprivate let _handler: Observable @@ -129,19 +127,18 @@ final fileprivate class RetryWhenSequenceSink) -> SequenceGenerator? { // It is important to always return `nil` here because there are sideffects in the `run` method // that are dependant on particular `retryWhen` operator so single operator stack can't be reused in this @@ -163,18 +160,18 @@ final fileprivate class RetryWhenSequenceSink : Producer where S.Iterator.Element : ObservableType { +final private class RetryWhenSequence : Producer where S.Iterator.Element: ObservableType { typealias Element = S.Iterator.Element.E - + fileprivate let _sources: S fileprivate let _notificationHandler: (Observable) -> TriggerObservable - + init(sources: S, notificationHandler: @escaping (Observable) -> TriggerObservable) { _sources = sources _notificationHandler = notificationHandler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = RetryWhenSequenceSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run((self._sources.makeIterator(), nil)) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sample.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sample.swift index 31f8b625d6..4d479b1e9a 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sample.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sample.swift @@ -26,24 +26,22 @@ extension ObservableType { } } -final fileprivate class SamplerSink - : ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class SamplerSink + : ObserverType, LockOwnerType, SynchronizedOnType { typealias E = SampleType - + typealias Parent = SampleSequenceSink - + fileprivate let _parent: Parent var _lock: RecursiveLock { return _parent._lock } - + init(parent: Parent) { _parent = parent } - + func on(_ event: Event) { synchronizedOn(event) } @@ -76,36 +74,33 @@ final fileprivate class SamplerSink } } -final fileprivate class SampleSequenceSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class SampleSequenceSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType { typealias Element = O.E typealias Parent = Sample - + fileprivate let _parent: Parent let _lock = RecursiveLock() - + // state fileprivate var _element = nil as Element? fileprivate var _atEnd = false - + fileprivate let _sourceSubscription = SingleAssignmentDisposable() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { _sourceSubscription.setDisposable(_parent._source.subscribe(self)) let samplerSubscription = _parent._sampler.subscribe(SamplerSink(parent: self)) - + return Disposables.create(_sourceSubscription, samplerSubscription) } - + func on(_ event: Event) { synchronizedOn(event) } @@ -122,10 +117,10 @@ final fileprivate class SampleSequenceSink _sourceSubscription.dispose() } } - + } -final fileprivate class Sample : Producer { +final private class Sample : Producer { fileprivate let _source: Observable fileprivate let _sampler: Observable @@ -133,7 +128,7 @@ final fileprivate class Sample : Producer { _source = source _sampler = sampler } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SampleSequenceSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Scan.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Scan.swift index 39d5e92f4e..56877b2703 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Scan.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Scan.swift @@ -19,7 +19,7 @@ extension ObservableType { - parameter accumulator: An accumulator function to be invoked on each element. - returns: An observable sequence containing the accumulated values. */ - public func scan(into seed: A, accumulator: @escaping (inout A, E) throws -> ()) + public func scan(into seed: A, accumulator: @escaping (inout A, E) throws -> Void) -> Observable { return Scan(source: self.asObservable(), seed: seed, accumulator: accumulator) } @@ -44,28 +44,27 @@ extension ObservableType { } } -final fileprivate class ScanSink : Sink, ObserverType { +final private class ScanSink : Sink, ObserverType { typealias Accumulate = O.E typealias Parent = Scan typealias E = ElementType - + fileprivate let _parent: Parent fileprivate var _accumulate: Accumulate - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _accumulate = parent._seed super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let element): do { try _parent._accumulator(&_accumulate, element) forwardOn(.next(_accumulate)) - } - catch let error { + } catch let error { forwardOn(.error(error)) dispose() } @@ -77,23 +76,23 @@ final fileprivate class ScanSink : Sink, Observ dispose() } } - + } -final fileprivate class Scan: Producer { - typealias Accumulator = (inout Accumulate, Element) throws -> () - +final private class Scan: Producer { + typealias Accumulator = (inout Accumulate, Element) throws -> Void + fileprivate let _source: Observable fileprivate let _seed: Accumulate fileprivate let _accumulator: Accumulator - + init(source: Observable, seed: Accumulate, accumulator: @escaping Accumulator) { _source = source _seed = seed _accumulator = accumulator } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Accumulate { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Accumulate { let sink = ScanSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sequence.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sequence.swift index e141bc72f7..79b0af4e39 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sequence.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sequence.swift @@ -47,7 +47,7 @@ extension ObservableType { } } -final fileprivate class ObservableSequenceSink : Sink where S.Iterator.Element == O.E { +final private class ObservableSequenceSink : Sink where S.Iterator.Element == O.E { typealias Parent = ObservableSequence private let _parent: Parent @@ -63,8 +63,7 @@ final fileprivate class ObservableSequenceSink : S if let next = mutableIterator.0.next() { self.forwardOn(.next(next)) recurse(mutableIterator) - } - else { + } else { self.forwardOn(.completed) self.dispose() } @@ -72,7 +71,7 @@ final fileprivate class ObservableSequenceSink : S } } -final fileprivate class ObservableSequence : Producer { +final private class ObservableSequence : Producer { fileprivate let _elements: S fileprivate let _scheduler: ImmediateSchedulerType @@ -81,7 +80,7 @@ final fileprivate class ObservableSequence : Producer(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = ObservableSequenceSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift index 5af102f02f..f32fedb194 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift @@ -157,8 +157,7 @@ extension ObservableType { } fileprivate final class ShareReplay1WhileConnectedConnection - : ObserverType - , SynchronizedUnsubscribeType { + : ObserverType, SynchronizedUnsubscribeType { typealias E = Element typealias Observers = AnyObserver.s typealias DisposeKey = Observers.KeyType @@ -208,7 +207,7 @@ fileprivate final class ShareReplay1WhileConnectedConnection _subscription.setDisposable(_parent._source.subscribe(self)) } - final func _synchronized_subscribe(_ observer: O) -> Disposable where O.E == Element { + final func _synchronized_subscribe(_ observer: O) -> Disposable where O.E == Element { _lock.lock(); defer { _lock.unlock() } if let element = _element { observer.on(.next(element)) @@ -259,7 +258,7 @@ fileprivate final class ShareReplay1WhileConnectedConnection } // optimized version of share replay for most common case -final fileprivate class ShareReplay1WhileConnected +final private class ShareReplay1WhileConnected : Observable { fileprivate typealias Connection = ShareReplay1WhileConnectedConnection @@ -274,7 +273,7 @@ final fileprivate class ShareReplay1WhileConnected self._source = source } - override func subscribe(_ observer: O) -> Disposable where O.E == E { + override func subscribe(_ observer: O) -> Disposable where O.E == E { _lock.lock() let connection = _synchronized_subscribe(observer) @@ -283,7 +282,7 @@ final fileprivate class ShareReplay1WhileConnected let disposable = connection._synchronized_subscribe(observer) _lock.unlock() - + if count == 0 { connection.connect() } @@ -292,13 +291,12 @@ final fileprivate class ShareReplay1WhileConnected } @inline(__always) - private func _synchronized_subscribe(_ observer: O) -> Connection where O.E == E { + private func _synchronized_subscribe(_ observer: O) -> Connection where O.E == E { let connection: Connection if let existingConnection = _connection { connection = existingConnection - } - else { + } else { connection = ShareReplay1WhileConnectedConnection( parent: self, lock: _lock) @@ -310,8 +308,7 @@ final fileprivate class ShareReplay1WhileConnected } fileprivate final class ShareWhileConnectedConnection - : ObserverType - , SynchronizedUnsubscribeType { + : ObserverType, SynchronizedUnsubscribeType { typealias E = Element typealias Observers = AnyObserver.s typealias DisposeKey = Observers.KeyType @@ -359,7 +356,7 @@ fileprivate final class ShareWhileConnectedConnection _subscription.setDisposable(_parent._source.subscribe(self)) } - final func _synchronized_subscribe(_ observer: O) -> Disposable where O.E == Element { + final func _synchronized_subscribe(_ observer: O) -> Disposable where O.E == Element { _lock.lock(); defer { _lock.unlock() } let disposeKey = _observers.insert(observer.on) @@ -407,7 +404,7 @@ fileprivate final class ShareWhileConnectedConnection } // optimized version of share replay for most common case -final fileprivate class ShareWhileConnected +final private class ShareWhileConnected : Observable { fileprivate typealias Connection = ShareWhileConnectedConnection @@ -422,7 +419,7 @@ final fileprivate class ShareWhileConnected self._source = source } - override func subscribe(_ observer: O) -> Disposable where O.E == E { + override func subscribe(_ observer: O) -> Disposable where O.E == E { _lock.lock() let connection = _synchronized_subscribe(observer) @@ -440,19 +437,18 @@ final fileprivate class ShareWhileConnected } @inline(__always) - private func _synchronized_subscribe(_ observer: O) -> Connection where O.E == E { + private func _synchronized_subscribe(_ observer: O) -> Connection where O.E == E { let connection: Connection if let existingConnection = _connection { connection = existingConnection - } - else { + } else { connection = ShareWhileConnectedConnection( parent: self, lock: _lock) _connection = connection } - + return connection } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift index 1419a93fc8..265e877443 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift @@ -40,15 +40,15 @@ fileprivate final class SingleAsyncSink : Sink, ObserverType typealias ElementType = O.E typealias Parent = SingleAsync typealias E = ElementType - + private let _parent: Parent private var _seenValue: Bool = false - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): @@ -57,8 +57,7 @@ fileprivate final class SingleAsyncSink : Sink, ObserverType if !forward { return } - } - catch let error { + } catch let error { forwardOn(.error(error as Swift.Error)) dispose() return @@ -88,16 +87,16 @@ fileprivate final class SingleAsyncSink : Sink, ObserverType final class SingleAsync: Producer { typealias Predicate = (Element) throws -> Bool - + fileprivate let _source: Observable fileprivate let _predicate: Predicate? - + init(source: Observable, predicate: Predicate? = nil) { _source = source _predicate = predicate } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SingleAsyncSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sink.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sink.swift index 214cfda326..88c3e86dad 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sink.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Sink.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -class Sink : Disposable { +class Sink : Disposable { fileprivate let _observer: O fileprivate let _cancel: Cancelable fileprivate var _disposed: Bool @@ -17,13 +17,13 @@ class Sink : Disposable { init(observer: O, cancel: Cancelable) { #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif _observer = observer _cancel = cancel _disposed = false } - + final func forwardOn(_ event: Event) { #if DEBUG _synchronizationTracker.register(synchronizationErrorMessage: .default) @@ -34,7 +34,7 @@ class Sink : Disposable { } _observer.on(event) } - + final func forwarder() -> SinkForward { return SinkForward(forward: self) } @@ -50,20 +50,20 @@ class Sink : Disposable { deinit { #if TRACE_RESOURCES - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() #endif } } final class SinkForward: ObserverType { typealias E = O.E - + private let _forward: Sink - + init(forward: Sink) { _forward = forward } - + final func on(_ event: Event) { switch event { case .next: diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Skip.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Skip.swift index fcac9d4a02..96186c7dde 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Skip.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Skip.swift @@ -41,28 +41,27 @@ extension ObservableType { // count version -final fileprivate class SkipCountSink : Sink, ObserverType { +final private class SkipCountSink : Sink, ObserverType { typealias Element = O.E typealias Parent = SkipCount - + let parent: Parent - + var remaining: Int - + init(parent: Parent, observer: O, cancel: Cancelable) { self.parent = parent self.remaining = parent.count super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): - + if remaining <= 0 { forwardOn(.next(value)) - } - else { + } else { remaining -= 1 } case .error: @@ -73,19 +72,19 @@ final fileprivate class SkipCountSink : Sink, ObserverType { self.dispose() } } - + } -final fileprivate class SkipCount: Producer { +final private class SkipCount: Producer { let source: Observable let count: Int - + init(source: Observable, count: Int) { self.source = source self.count = count } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SkipCountSink(parent: self, observer: observer, cancel: cancel) let subscription = source.subscribe(sink) @@ -95,20 +94,20 @@ final fileprivate class SkipCount: Producer { // time version -final fileprivate class SkipTimeSink : Sink, ObserverType where O.E == ElementType { +final private class SkipTimeSink : Sink, ObserverType where O.E == ElementType { typealias Parent = SkipTime typealias Element = ElementType let parent: Parent - + // state var open = false - + init(parent: Parent, observer: O, cancel: Cancelable) { self.parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): @@ -123,35 +122,35 @@ final fileprivate class SkipTimeSink : Sink, Ob self.dispose() } } - + func tick() { open = true } - + func run() -> Disposable { - let disposeTimer = parent.scheduler.scheduleRelative((), dueTime: self.parent.duration) { _ in + let disposeTimer = parent.scheduler.scheduleRelative((), dueTime: self.parent.duration) { _ in self.tick() return Disposables.create() } - + let disposeSubscription = parent.source.subscribe(self) - + return Disposables.create(disposeTimer, disposeSubscription) } } -final fileprivate class SkipTime: Producer { +final private class SkipTime: Producer { let source: Observable let duration: RxTimeInterval let scheduler: SchedulerType - + init(source: Observable, duration: RxTimeInterval, scheduler: SchedulerType) { self.source = source self.scheduler = scheduler self.duration = duration } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SkipTimeSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift index f35f1fd8ae..d466cce36f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift @@ -22,25 +22,23 @@ extension ObservableType { } } -final fileprivate class SkipUntilSinkOther - : ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class SkipUntilSinkOther + : ObserverType, LockOwnerType, SynchronizedOnType { typealias Parent = SkipUntilSink typealias E = Other - + fileprivate let _parent: Parent var _lock: RecursiveLock { return _parent._lock } - + let _subscription = SingleAssignmentDisposable() init(parent: Parent) { _parent = parent #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } @@ -60,35 +58,31 @@ final fileprivate class SkipUntilSinkOther _subscription.dispose() } } - + #if TRACE_RESOURCES deinit { - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() } #endif } - -final fileprivate class SkipUntilSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class SkipUntilSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType { typealias E = O.E typealias Parent = SkipUntil - + let _lock = RecursiveLock() fileprivate let _parent: Parent fileprivate var _forwardElements = false - + fileprivate let _sourceSubscription = SingleAssignmentDisposable() init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { synchronizedOn(event) } @@ -109,29 +103,29 @@ final fileprivate class SkipUntilSink self.dispose() } } - + func run() -> Disposable { let sourceSubscription = _parent._source.subscribe(self) let otherObserver = SkipUntilSinkOther(parent: self) let otherSubscription = _parent._other.subscribe(otherObserver) _sourceSubscription.setDisposable(sourceSubscription) otherObserver._subscription.setDisposable(otherSubscription) - + return Disposables.create(_sourceSubscription, otherObserver._subscription) } } -final fileprivate class SkipUntil: Producer { - +final private class SkipUntil: Producer { + fileprivate let _source: Observable fileprivate let _other: Observable - + init(source: Observable, other: Observable) { _source = source _other = other } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SkipUntilSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift index 4bb394b964..5fb122fe5c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift @@ -21,7 +21,7 @@ extension ObservableType { } } -final fileprivate class SkipWhileSink : Sink, ObserverType { +final private class SkipWhileSink : Sink, ObserverType { typealias Element = O.E typealias Parent = SkipWhile @@ -57,7 +57,7 @@ final fileprivate class SkipWhileSink : Sink, ObserverType { } } -final fileprivate class SkipWhile: Producer { +final private class SkipWhile: Producer { typealias Predicate = (Element) throws -> Bool typealias PredicateWithIndex = (Element, Int) throws -> Bool @@ -69,7 +69,7 @@ final fileprivate class SkipWhile: Producer { _predicate = predicate } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SkipWhileSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/StartWith.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/StartWith.swift index 14776f9e65..deebf4b52e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/StartWith.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/StartWith.swift @@ -22,7 +22,7 @@ extension ObservableType { } } -final fileprivate class StartWith: Producer { +final private class StartWith: Producer { let elements: [Element] let source: Observable @@ -32,7 +32,7 @@ final fileprivate class StartWith: Producer { super.init() } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { for e in elements { observer.on(.next(e)) } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift index 2a33e03e5a..aad97d65e1 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift @@ -29,31 +29,31 @@ extension ObservableType { } } -final fileprivate class SubscribeOnSink : Sink, ObserverType where Ob.E == O.E { +final private class SubscribeOnSink : Sink, ObserverType where Ob.E == O.E { typealias Element = O.E typealias Parent = SubscribeOn - + let parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { self.parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { forwardOn(event) - + if event.isStopEvent { self.dispose() } } - + func run() -> Disposable { let disposeEverything = SerialDisposable() let cancelSchedule = SingleAssignmentDisposable() - + disposeEverything.disposable = cancelSchedule - + let disposeSchedule = parent.scheduler.schedule(()) { (_) -> Disposable in let subscription = self.parent.source.subscribe(self) disposeEverything.disposable = ScheduledDisposable(scheduler: self.parent.scheduler, disposable: subscription) @@ -61,21 +61,21 @@ final fileprivate class SubscribeOnSink : S } cancelSchedule.setDisposable(disposeSchedule) - + return disposeEverything } } -final fileprivate class SubscribeOn : Producer { +final private class SubscribeOn : Producer { let source: Ob let scheduler: ImmediateSchedulerType - + init(source: Ob, scheduler: ImmediateSchedulerType) { self.source = source self.scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Ob.E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Ob.E { let sink = SubscribeOnSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Switch.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Switch.swift index 2da100053e..204a3b0775 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Switch.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Switch.swift @@ -25,7 +25,7 @@ extension ObservableType { } } -extension ObservableType where E : ObservableConvertibleType { +extension ObservableType where E: ObservableConvertibleType { /** Transforms an observable sequence of observable sequences into an observable sequence @@ -43,25 +43,24 @@ extension ObservableType where E : ObservableConvertibleType { } } -fileprivate class SwitchSink - : Sink - , ObserverType where S.E == O.E { +private class SwitchSink + : Sink, ObserverType where S.E == O.E { typealias E = SourceType fileprivate let _subscriptions: SingleAssignmentDisposable = SingleAssignmentDisposable() fileprivate let _innerSubscription: SerialDisposable = SerialDisposable() let _lock = RecursiveLock() - + // state fileprivate var _stopped = false fileprivate var _latest = 0 fileprivate var _hasLatest = false - + override init(observer: O, cancel: Cancelable) { super.init(observer: observer, cancel: cancel) } - + func run(_ source: Observable) -> Disposable { let subscription = source.subscribe(self) _subscriptions.setDisposable(subscription) @@ -80,8 +79,7 @@ fileprivate class SwitchSink - : ObserverType - , LockOwnerType - , SynchronizedOnType where S.E == O.E { +final private class SwitchSinkIter + : ObserverType, LockOwnerType, SynchronizedOnType where S.E == O.E { typealias E = S.E typealias Parent = SwitchSink - + fileprivate let _parent: Parent fileprivate let _id: Int fileprivate let _self: Disposable @@ -139,7 +135,7 @@ final fileprivate class SwitchSinkIter) { synchronizedOn(event) } @@ -150,11 +146,11 @@ final fileprivate class SwitchSinkIter : SwitchSink where O.E == S.E { +final private class SwitchIdentitySink : SwitchSink where O.E == S.E { override init(observer: O, cancel: Cancelable) { super.init(observer: observer, cancel: cancel) } @@ -183,7 +179,7 @@ final fileprivate class SwitchIdentitySink : SwitchSink where O.E == S.E { +final private class MapSwitchSink : SwitchSink where O.E == S.E { typealias Selector = (SourceType) throws -> S fileprivate let _selector: Selector @@ -200,21 +196,21 @@ final fileprivate class MapSwitchSink : Producer { +final private class Switch : Producer { fileprivate let _source: Observable - + init(source: Observable) { _source = source } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == S.E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == S.E { let sink = SwitchIdentitySink(observer: observer, cancel: cancel) let subscription = sink.run(_source) return (sink: sink, subscription: subscription) } } -final fileprivate class FlatMapLatest : Producer { +final private class FlatMapLatest : Producer { typealias Selector = (SourceType) throws -> S fileprivate let _source: Observable @@ -225,7 +221,7 @@ final fileprivate class FlatMapLatest _selector = selector } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == S.E { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == S.E { let sink = MapSwitchSink(selector: _selector, observer: observer, cancel: cancel) let subscription = sink.run(_source) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift index 0b10dc614a..9ee3b30ee5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift @@ -20,44 +20,43 @@ extension ObservableType { } } -final fileprivate class SwitchIfEmpty: Producer { - +final private class SwitchIfEmpty: Producer { + private let _source: Observable private let _ifEmpty: Observable - + init(source: Observable, ifEmpty: Observable) { _source = source _ifEmpty = ifEmpty } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = SwitchIfEmptySink(ifEmpty: _ifEmpty, observer: observer, cancel: cancel) let subscription = sink.run(_source.asObservable()) - + return (sink: sink, subscription: subscription) } } -final fileprivate class SwitchIfEmptySink: Sink - , ObserverType { +final private class SwitchIfEmptySink: Sink, ObserverType { typealias E = O.E - + private let _ifEmpty: Observable private var _isEmpty = true private let _ifEmptySubscription = SingleAssignmentDisposable() - + init(ifEmpty: Observable, observer: O, cancel: Cancelable) { _ifEmpty = ifEmpty super.init(observer: observer, cancel: cancel) } - + func run(_ source: Observable) -> Disposable { let subscription = source.subscribe(self) return Disposables.create(subscription, _ifEmptySubscription) } - + func on(_ event: Event) { switch event { case .next: @@ -78,17 +77,17 @@ final fileprivate class SwitchIfEmptySink: Sink } } -final fileprivate class SwitchIfEmptySinkIter +final private class SwitchIfEmptySinkIter : ObserverType { typealias E = O.E typealias Parent = SwitchIfEmptySink - + private let _parent: Parent init(parent: Parent) { _parent = parent } - + func on(_ event: Event) { switch event { case .next: diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Take.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Take.swift index 661f8582d6..4c1e00f747 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Take.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Take.swift @@ -20,8 +20,7 @@ extension ObservableType { -> Observable { if count == 0 { return Observable.empty() - } - else { + } else { return TakeCount(source: asObservable(), count: count) } } @@ -46,29 +45,29 @@ extension ObservableType { // count version -final fileprivate class TakeCountSink : Sink, ObserverType { +final private class TakeCountSink : Sink, ObserverType { typealias E = O.E typealias Parent = TakeCount - + private let _parent: Parent - + private var _remaining: Int - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _remaining = parent._count super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): - + if _remaining > 0 { _remaining -= 1 - + forwardOn(.next(value)) - + if _remaining == 0 { forwardOn(.completed) dispose() @@ -82,13 +81,13 @@ final fileprivate class TakeCountSink : Sink, ObserverType { dispose() } } - + } -final fileprivate class TakeCount: Producer { +final private class TakeCount: Producer { fileprivate let _source: Observable fileprivate let _count: Int - + init(source: Observable, count: Int) { if count < 0 { rxFatalError("count can't be negative") @@ -96,8 +95,8 @@ final fileprivate class TakeCount: Producer { _source = source _count = count } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TakeCountSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) @@ -106,23 +105,20 @@ final fileprivate class TakeCount: Producer { // time version -final fileprivate class TakeTimeSink - : Sink - , LockOwnerType - , ObserverType - , SynchronizedOnType where O.E == ElementType { +final private class TakeTimeSink + : Sink, LockOwnerType, ObserverType, SynchronizedOnType where O.E == ElementType { typealias Parent = TakeTime typealias E = ElementType fileprivate let _parent: Parent - + let _lock = RecursiveLock() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { synchronizedOn(event) } @@ -139,40 +135,40 @@ final fileprivate class TakeTimeSink dispose() } } - + func tick() { _lock.lock(); defer { _lock.unlock() } forwardOn(.completed) dispose() } - + func run() -> Disposable { let disposeTimer = _parent._scheduler.scheduleRelative((), dueTime: _parent._duration) { _ in self.tick() return Disposables.create() } - + let disposeSubscription = _parent._source.subscribe(self) - + return Disposables.create(disposeTimer, disposeSubscription) } } -final fileprivate class TakeTime : Producer { +final private class TakeTime : Producer { typealias TimeInterval = RxTimeInterval - + fileprivate let _source: Observable fileprivate let _duration: TimeInterval fileprivate let _scheduler: SchedulerType - + init(source: Observable, duration: TimeInterval, scheduler: SchedulerType) { _source = source _scheduler = scheduler _duration = duration } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TakeTimeSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeLast.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeLast.swift index 7bf1664bfd..4da8bb6eed 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeLast.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeLast.swift @@ -24,26 +24,26 @@ extension ObservableType { } } -final fileprivate class TakeLastSink : Sink, ObserverType { +final private class TakeLastSink : Sink, ObserverType { typealias E = O.E typealias Parent = TakeLast - + private let _parent: Parent - + private var _elements: Queue - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _elements = Queue(capacity: parent._count + 1) super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): _elements.enqueue(value) if _elements.count > self._parent._count { - let _ = _elements.dequeue() + _ = _elements.dequeue() } case .error: forwardOn(event) @@ -58,10 +58,10 @@ final fileprivate class TakeLastSink : Sink, ObserverType { } } -final fileprivate class TakeLast: Producer { +final private class TakeLast: Producer { fileprivate let _source: Observable fileprivate let _count: Int - + init(source: Observable, count: Int) { if count < 0 { rxFatalError("count can't be negative") @@ -69,8 +69,8 @@ final fileprivate class TakeLast: Producer { _source = source _count = count } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TakeLastSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift index f2e5f98b01..e53c709591 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift @@ -22,28 +22,26 @@ extension ObservableType { } } -final fileprivate class TakeUntilSinkOther - : ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class TakeUntilSinkOther + : ObserverType, LockOwnerType, SynchronizedOnType { typealias Parent = TakeUntilSink typealias E = Other - + fileprivate let _parent: Parent var _lock: RecursiveLock { return _parent._lock } - + fileprivate let _subscription = SingleAssignmentDisposable() - + init(parent: Parent) { _parent = parent #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } - + func on(_ event: Event) { synchronizedOn(event) } @@ -60,32 +58,28 @@ final fileprivate class TakeUntilSinkOther _subscription.dispose() } } - + #if TRACE_RESOURCES deinit { - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() } #endif } -final fileprivate class TakeUntilSink - : Sink - , LockOwnerType - , ObserverType - , SynchronizedOnType { +final private class TakeUntilSink + : Sink, LockOwnerType, ObserverType, SynchronizedOnType { typealias E = O.E typealias Parent = TakeUntil - + fileprivate let _parent: Parent - + let _lock = RecursiveLock() - - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { synchronizedOn(event) } @@ -102,28 +96,28 @@ final fileprivate class TakeUntilSink dispose() } } - + func run() -> Disposable { let otherObserver = TakeUntilSinkOther(parent: self) let otherSubscription = _parent._other.subscribe(otherObserver) otherObserver._subscription.setDisposable(otherSubscription) let sourceSubscription = _parent._source.subscribe(self) - + return Disposables.create(sourceSubscription, otherObserver._subscription) } } -final fileprivate class TakeUntil: Producer { - +final private class TakeUntil: Producer { + fileprivate let _source: Observable fileprivate let _other: Observable - + init(source: Observable, other: Observable) { _source = source _other = other } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TakeUntilSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift index 2b7b55101a..5318f2c566 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift @@ -22,9 +22,8 @@ extension ObservableType { } } -final fileprivate class TakeWhileSink - : Sink - , ObserverType { +final private class TakeWhileSink + : Sink, ObserverType { typealias Element = O.E typealias Parent = TakeWhile @@ -36,14 +35,14 @@ final fileprivate class TakeWhileSink _parent = parent super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): if !_running { return } - + do { _running = try _parent._predicate(value) } catch let e { @@ -51,7 +50,7 @@ final fileprivate class TakeWhileSink dispose() return } - + if _running { forwardOn(.next(value)) } else { @@ -63,10 +62,10 @@ final fileprivate class TakeWhileSink dispose() } } - + } -final fileprivate class TakeWhile: Producer { +final private class TakeWhile: Producer { typealias Predicate = (Element) throws -> Bool fileprivate let _source: Observable @@ -77,7 +76,7 @@ final fileprivate class TakeWhile: Producer { _predicate = predicate } - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TakeWhileSink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Throttle.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Throttle.swift index 0c4ca7466f..6a02ff41a5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Throttle.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Throttle.swift @@ -28,34 +28,31 @@ extension ObservableType { } } -final fileprivate class ThrottleSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class ThrottleSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType { typealias Element = O.E typealias ParentType = Throttle - + private let _parent: ParentType - + let _lock = RecursiveLock() - + // state - private var _lastUnsentElement: Element? = nil - private var _lastSentTime: Date? = nil + private var _lastUnsentElement: Element? + private var _lastSentTime: Date? private var _completed: Bool = false let cancellable = SerialDisposable() - + init(parent: ParentType, observer: O, cancel: Cancelable) { _parent = parent - + super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { let subscription = _parent._source.subscribe(self) - + return Disposables.create(subscription, cancellable) } @@ -72,8 +69,7 @@ final fileprivate class ThrottleSink if let lastSendingTime = _lastSentTime { timeIntervalSinceLast = now.timeIntervalSince(lastSendingTime) - } - else { + } else { timeIntervalSinceLast = _parent._dueTime } @@ -89,7 +85,7 @@ final fileprivate class ThrottleSink } let isThereAlreadyInFlightRequest = _lastUnsentElement != nil - + _lastUnsentElement = element if isThereAlreadyInFlightRequest { @@ -110,8 +106,7 @@ final fileprivate class ThrottleSink case .completed: if let _ = _lastUnsentElement { _completed = true - } - else { + } else { forwardOn(.completed) dispose() } @@ -124,7 +119,7 @@ final fileprivate class ThrottleSink // in case element processing takes a while, this should give some more room _lastSentTime = _parent._scheduler.now } - + func propagate(_: Int) -> Disposable { _lock.lock(); defer { _lock.unlock() } // { if let lastUnsentElement = _lastUnsentElement { @@ -140,8 +135,8 @@ final fileprivate class ThrottleSink } } -final fileprivate class Throttle : Producer { - +final private class Throttle : Producer { + fileprivate let _source: Observable fileprivate let _dueTime: RxTimeInterval fileprivate let _latest: Bool @@ -153,11 +148,11 @@ final fileprivate class Throttle : Producer { _latest = latest _scheduler = scheduler } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = ThrottleSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) } - + } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timeout.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timeout.swift index 7008de8286..16b79ff4be 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timeout.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timeout.swift @@ -38,33 +38,33 @@ extension ObservableType { } } -final fileprivate class TimeoutSink: Sink, LockOwnerType, ObserverType { +final private class TimeoutSink: Sink, LockOwnerType, ObserverType { typealias E = O.E typealias Parent = Timeout - + private let _parent: Parent - + let _lock = RecursiveLock() private let _timerD = SerialDisposable() private let _subscription = SerialDisposable() - + private var _id = 0 private var _switched = false - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { let original = SingleAssignmentDisposable() _subscription.disposable = original - + _createTimeoutTimer() - + original.setDisposable(_parent._source.subscribe(self)) - + return Disposables.create(_subscription, _timerD) } @@ -72,56 +72,56 @@ final fileprivate class TimeoutSink: Sink, LockOwnerType, Ob switch event { case .next: var onNextWins = false - - _lock.performLocked() { + + _lock.performLocked { onNextWins = !self._switched if onNextWins { self._id = self._id &+ 1 } } - + if onNextWins { forwardOn(event) self._createTimeoutTimer() } case .error, .completed: var onEventWins = false - - _lock.performLocked() { + + _lock.performLocked { onEventWins = !self._switched if onEventWins { self._id = self._id &+ 1 } } - + if onEventWins { forwardOn(event) self.dispose() } } } - + private func _createTimeoutTimer() { if _timerD.isDisposed { return } - + let nextTimer = SingleAssignmentDisposable() _timerD.disposable = nextTimer - + let disposeSchedule = _parent._scheduler.scheduleRelative(_id, dueTime: _parent._dueTime) { state in - + var timerWins = false - - self._lock.performLocked() { + + self._lock.performLocked { self._switched = (state == self._id) timerWins = self._switched } - + if timerWins { self._subscription.disposable = self._parent._other.subscribe(self.forwarder()) } - + return Disposables.create() } @@ -129,22 +129,21 @@ final fileprivate class TimeoutSink: Sink, LockOwnerType, Ob } } +final private class Timeout : Producer { -final fileprivate class Timeout : Producer { - fileprivate let _source: Observable fileprivate let _dueTime: RxTimeInterval fileprivate let _other: Observable fileprivate let _scheduler: SchedulerType - + init(source: Observable, dueTime: RxTimeInterval, other: Observable, scheduler: SchedulerType) { _source = source _dueTime = dueTime _other = other _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Element { let sink = TimeoutSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timer.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timer.swift index dec69e12d0..77a0b88137 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timer.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Timer.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -extension ObservableType where E : RxAbstractInteger { +extension ObservableType where E: RxAbstractInteger { /** Returns an observable sequence that produces a value after each period, using the specified scheduler to run timers and to send out observer messages. @@ -46,16 +46,16 @@ extension ObservableType where E: RxAbstractInteger { } } -final fileprivate class TimerSink : Sink where O.E : RxAbstractInteger { +final private class TimerSink : Sink where O.E: RxAbstractInteger { typealias Parent = Timer - + private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { return _parent._scheduler.schedulePeriodic(0 as O.E, startAfter: _parent._dueTime, period: _parent._period!) { state in self.forwardOn(.next(state)) @@ -64,18 +64,18 @@ final fileprivate class TimerSink : Sink where O.E : RxAbstr } } -final fileprivate class TimerOneOffSink : Sink where O.E : RxAbstractInteger { +final private class TimerOneOffSink : Sink where O.E: RxAbstractInteger { typealias Parent = Timer - + private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { - return _parent._scheduler.scheduleRelative(self, dueTime: _parent._dueTime) { (`self`) -> Disposable in + return _parent._scheduler.scheduleRelative(self, dueTime: _parent._dueTime) { (_f`) -> Disposable in self.forwardOn(.next(0)) self.forwardOn(.completed) self.dispose() @@ -85,24 +85,23 @@ final fileprivate class TimerOneOffSink : Sink where O.E : R } } -final fileprivate class Timer: Producer { +final private class Timer: Producer { fileprivate let _scheduler: SchedulerType fileprivate let _dueTime: RxTimeInterval fileprivate let _period: RxTimeInterval? - + init(dueTime: RxTimeInterval, period: RxTimeInterval?, scheduler: SchedulerType) { _scheduler = scheduler _dueTime = dueTime _period = period } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { if let _ = _period { let sink = TimerSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) - } - else { + } else { let sink = TimerOneOffSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ToArray.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ToArray.swift index 93fcb80e11..d760f2197f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ToArray.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/ToArray.swift @@ -6,7 +6,6 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // - extension ObservableType { /** @@ -24,18 +23,18 @@ extension ObservableType { } } -final fileprivate class ToArraySink : Sink, ObserverType where O.E == [SourceType] { +final private class ToArraySink : Sink, ObserverType where O.E == [SourceType] { typealias Parent = ToArray - + let _parent: Parent var _list = Array() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent - + super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event) { switch event { case .next(let value): @@ -51,13 +50,13 @@ final fileprivate class ToArraySink : Sink, Obse } } -final fileprivate class ToArray : Producer<[SourceType]> { +final private class ToArray : Producer<[SourceType]> { let _source: Observable init(source: Observable) { _source = source } - + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == [SourceType] { let sink = ToArraySink(parent: self, observer: observer, cancel: cancel) let subscription = _source.subscribe(sink) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Using.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Using.swift index 8ea832678b..a8213b9247 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Using.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Using.swift @@ -21,25 +21,25 @@ extension ObservableType { } } -final fileprivate class UsingSink : Sink, ObserverType { +final private class UsingSink : Sink, ObserverType { typealias SourceType = O.E typealias Parent = Using private let _parent: Parent - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { var disposable = Disposables.create() - + do { let resource = try _parent._resourceFactory() disposable = resource let source = try _parent._observableFactory(resource) - + return Disposables.create( source.subscribe(self), disposable @@ -51,7 +51,7 @@ final fileprivate class UsingSink : S ) } } - + func on(_ event: Event) { switch event { case let .next(value): @@ -66,23 +66,22 @@ final fileprivate class UsingSink : S } } -final fileprivate class Using: Producer { - +final private class Using: Producer { + typealias E = SourceType - + typealias ResourceFactory = () throws -> ResourceType typealias ObservableFactory = (ResourceType) throws -> Observable - + fileprivate let _resourceFactory: ResourceFactory fileprivate let _observableFactory: ObservableFactory - - + init(resourceFactory: @escaping ResourceFactory, observableFactory: @escaping ObservableFactory) { _resourceFactory = resourceFactory _observableFactory = observableFactory } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == E { let sink = UsingSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Window.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Window.swift index c862dfba78..0c6e7b2b24 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Window.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Window.swift @@ -24,48 +24,45 @@ extension ObservableType { } } -final fileprivate class WindowTimeCountSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType where O.E == Observable { +final private class WindowTimeCountSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType where O.E == Observable { typealias Parent = WindowTimeCount typealias E = Element - + private let _parent: Parent - + let _lock = RecursiveLock() - + private var _subject = PublishSubject() private var _count = 0 private var _windowId = 0 - + private let _timerD = SerialDisposable() private let _refCountDisposable: RefCountDisposable private let _groupDisposable = CompositeDisposable() - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent - - let _ = _groupDisposable.insert(_timerD) - + + _ = _groupDisposable.insert(_timerD) + _refCountDisposable = RefCountDisposable(disposable: _groupDisposable) super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { - + forwardOn(.next(AddRef(source: _subject, refCount: _refCountDisposable).asObservable())) createTimer(_windowId) - - let _ = _groupDisposable.insert(_parent._source.subscribe(self)) + + _ = _groupDisposable.insert(_parent._source.subscribe(self)) return _refCountDisposable } - + func startNewWindowAndCompleteCurrentOne() { _subject.on(.completed) _subject = PublishSubject() - + forwardOn(.next(AddRef(source: _subject, refCount: _refCountDisposable).asObservable())) } @@ -76,18 +73,18 @@ final fileprivate class WindowTimeCountSink func _synchronized_on(_ event: Event) { var newWindow = false var newId = 0 - + switch event { case .next(let element): _subject.on(.next(element)) - + do { - let _ = try incrementChecked(&_count) + _ = try incrementChecked(&_count) } catch (let e) { _subject.on(.error(e as Swift.Error)) dispose() } - + if (_count == _parent._count) { newWindow = true _count = 0 @@ -95,7 +92,7 @@ final fileprivate class WindowTimeCountSink newId = _windowId self.startNewWindowAndCompleteCurrentOne() } - + case .error(let error): _subject.on(.error(error)) forwardOn(.error(error)) @@ -110,12 +107,12 @@ final fileprivate class WindowTimeCountSink createTimer(newId) } } - + func createTimer(_ windowId: Int) { if _timerD.isDisposed { return } - + if _windowId != windowId { return } @@ -125,22 +122,22 @@ final fileprivate class WindowTimeCountSink _timerD.disposable = nextTimer let scheduledRelative = _parent._scheduler.scheduleRelative(windowId, dueTime: _parent._timeSpan) { previousWindowId in - + var newId = 0 - + self._lock.performLocked { if previousWindowId != self._windowId { return } - + self._count = 0 self._windowId = self._windowId &+ 1 newId = self._windowId self.startNewWindowAndCompleteCurrentOne() } - + self.createTimer(newId) - + return Disposables.create() } @@ -148,21 +145,21 @@ final fileprivate class WindowTimeCountSink } } -final fileprivate class WindowTimeCount : Producer> { - +final private class WindowTimeCount : Producer> { + fileprivate let _timeSpan: RxTimeInterval fileprivate let _count: Int fileprivate let _scheduler: SchedulerType fileprivate let _source: Observable - + init(source: Observable, timeSpan: RxTimeInterval, count: Int, scheduler: SchedulerType) { _source = source _timeSpan = timeSpan _count = count _scheduler = scheduler } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Observable { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == Observable { let sink = WindowTimeCountSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift index bd22e2f01b..b938aa1d6e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift @@ -34,30 +34,27 @@ extension ObservableType { } } -final fileprivate class WithLatestFromSink - : Sink - , ObserverType - , LockOwnerType - , SynchronizedOnType { +final private class WithLatestFromSink + : Sink, ObserverType, LockOwnerType, SynchronizedOnType { typealias ResultType = O.E typealias Parent = WithLatestFrom typealias E = FirstType - + fileprivate let _parent: Parent - + var _lock = RecursiveLock() fileprivate var _latest: SecondType? init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent - + super.init(observer: observer, cancel: cancel) } - + func run() -> Disposable { let sndSubscription = SingleAssignmentDisposable() let sndO = WithLatestFromSecond(parent: self, disposable: sndSubscription) - + sndSubscription.setDisposable(_parent._second.subscribe(sndO)) let fstSubscription = _parent._first.subscribe(self) @@ -74,7 +71,7 @@ final fileprivate class WithLatestFromSink - : ObserverType - , LockOwnerType - , SynchronizedOnType { - +final private class WithLatestFromSecond + : ObserverType, LockOwnerType, SynchronizedOnType { + typealias ResultType = O.E typealias Parent = WithLatestFromSink typealias E = SecondType - + private let _parent: Parent private let _disposable: Disposable @@ -110,7 +105,7 @@ final fileprivate class WithLatestFromSecond) { synchronizedOn(event) } @@ -128,9 +123,9 @@ final fileprivate class WithLatestFromSecond: Producer { +final private class WithLatestFrom: Producer { typealias ResultSelector = (FirstType, SecondType) throws -> ResultType - + fileprivate let _first: Observable fileprivate let _second: Observable fileprivate let _resultSelector: ResultSelector @@ -140,8 +135,8 @@ final fileprivate class WithLatestFrom: Produ _second = second _resultSelector = resultSelector } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == ResultType { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == ResultType { let sink = WithLatestFromSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift index 1a871c1ee0..fd465e7366 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift @@ -31,50 +31,50 @@ extension ObservableType { where C.Iterator.Element: ObservableType, C.Iterator.Element.E == E { return ZipCollectionType(sources: collection, resultSelector: { $0 }) } - + } -final fileprivate class ZipCollectionTypeSink - : Sink where C.Iterator.Element : ObservableConvertibleType { +final private class ZipCollectionTypeSink + : Sink where C.Iterator.Element: ObservableConvertibleType { typealias R = O.E typealias Parent = ZipCollectionType typealias SourceElement = C.Iterator.Element.E - + private let _parent: Parent - + private let _lock = RecursiveLock() - + // state private var _numberOfValues = 0 private var _values: [Queue] private var _isDone: [Bool] private var _numberOfDone = 0 private var _subscriptions: [SingleAssignmentDisposable] - + init(parent: Parent, observer: O, cancel: Cancelable) { _parent = parent _values = [Queue](repeating: Queue(capacity: 4), count: parent.count) _isDone = [Bool](repeating: false, count: parent.count) _subscriptions = Array() _subscriptions.reserveCapacity(parent.count) - + for _ in 0 ..< parent.count { _subscriptions.append(SingleAssignmentDisposable()) } - + super.init(observer: observer, cancel: cancel) } - + func on(_ event: Event, atIndex: Int) { _lock.lock(); defer { _lock.unlock() } // { switch event { case .next(let element): _values[atIndex].enqueue(element) - + if _values[atIndex].count == 1 { _numberOfValues += 1 } - + if _numberOfValues < _parent.count { if _numberOfDone == _parent.count - 1 { self.forwardOn(.completed) @@ -82,29 +82,28 @@ final fileprivate class ZipCollectionTypeSink } return } - + do { var arguments = [SourceElement]() arguments.reserveCapacity(_parent.count) - + // recalculate number of values _numberOfValues = 0 - + for i in 0 ..< _values.count { arguments.append(_values[i].dequeue()!) if !_values[i].isEmpty { _numberOfValues += 1 } } - + let result = try _parent.resultSelector(arguments) self.forwardOn(.next(result)) - } - catch let error { + } catch let error { self.forwardOn(.error(error)) self.dispose() } - + case .error(let error): self.forwardOn(.error(error)) self.dispose() @@ -112,21 +111,20 @@ final fileprivate class ZipCollectionTypeSink if _isDone[atIndex] { return } - + _isDone[atIndex] = true _numberOfDone += 1 - + if _numberOfDone == _parent.count { self.forwardOn(.completed) self.dispose() - } - else { + } else { _subscriptions[atIndex].dispose() } } // } } - + func run() -> Disposable { var j = 0 for i in _parent.sources { @@ -143,25 +141,25 @@ final fileprivate class ZipCollectionTypeSink if _parent.sources.isEmpty { self.forwardOn(.completed) } - + return Disposables.create(_subscriptions) } } -final fileprivate class ZipCollectionType : Producer where C.Iterator.Element : ObservableConvertibleType { +final private class ZipCollectionType : Producer where C.Iterator.Element: ObservableConvertibleType { typealias ResultSelector = ([C.Iterator.Element.E]) throws -> R - + let sources: C let resultSelector: ResultSelector let count: Int - + init(sources: C, resultSelector: @escaping ResultSelector) { self.sources = sources self.resultSelector = resultSelector self.count = Int(Int64(self.sources.count)) } - - override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == R { + + override func run(_ observer: O, cancel: Cancelable) -> (sink: Disposable, subscription: Disposable) where O.E == R { let sink = ZipCollectionTypeSink(parent: self, observer: observer, cancel: cancel) let subscription = sink.run() return (sink: sink, subscription: subscription) diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift index 434543e758..945adc3af6 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift @@ -7,8 +7,6 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // - - // 2 extension ObservableType { @@ -117,8 +115,6 @@ final class Zip2 : Producer { } } - - // 3 extension ObservableType { @@ -235,8 +231,6 @@ final class Zip3 : Producer { } } - - // 4 extension ObservableType { @@ -361,8 +355,6 @@ final class Zip4 : Producer { } } - - // 5 extension ObservableType { @@ -495,8 +487,6 @@ final class Zip5 : Producer { } } - - // 6 extension ObservableType { @@ -637,8 +627,6 @@ final class Zip6 : Producer { } } - - // 7 extension ObservableType { @@ -787,8 +775,6 @@ final class Zip7 : Producer { } } - - // 8 extension ObservableType { @@ -944,5 +930,3 @@ final class Zip8 : Producer { return (sink: sink, subscription: subscription) } } - - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip.swift index a283bf2b23..de65c27cfc 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observables/Zip.swift @@ -6,8 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol ZipSinkProtocol : class -{ +protocol ZipSinkProtocol: class { func next(_ index: Int) func fail(_ error: Swift.Error) func done(_ index: Int) @@ -15,52 +14,50 @@ protocol ZipSinkProtocol : class class ZipSink : Sink, ZipSinkProtocol { typealias Element = O.E - + let _arity: Int let _lock = RecursiveLock() // state private var _isDone: [Bool] - + init(arity: Int, observer: O, cancel: Cancelable) { _isDone = [Bool](repeating: false, count: arity) _arity = arity - + super.init(observer: observer, cancel: cancel) } func getResult() throws -> Element { rxAbstractMethod() } - + func hasElements(_ index: Int) -> Bool { rxAbstractMethod() } - + func next(_ index: Int) { var hasValueAll = true - + for i in 0 ..< _arity { if !hasElements(i) { hasValueAll = false break } } - + if hasValueAll { do { let result = try getResult() self.forwardOn(.next(result)) - } - catch let e { + } catch let e { self.forwardOn(.error(e)) dispose() } - } - else { + } else { var allOthersDone = true - + let arity = _isDone.count for i in 0 ..< arity { if i != index && !_isDone[i] { @@ -68,31 +65,31 @@ class ZipSink : Sink, ZipSinkProtocol { break } } - + if allOthersDone { forwardOn(.completed) self.dispose() } } } - + func fail(_ error: Swift.Error) { forwardOn(.error(error)) dispose() } - + func done(_ index: Int) { _isDone[index] = true - + var allDone = true - + for done in _isDone { if !done { allDone = false break } } - + if allDone { forwardOn(.completed) dispose() @@ -101,21 +98,19 @@ class ZipSink : Sink, ZipSinkProtocol { } final class ZipObserver - : ObserverType - , LockOwnerType - , SynchronizedOnType { + : ObserverType, LockOwnerType, SynchronizedOnType { typealias E = ElementType - typealias ValueSetter = (ElementType) -> () + typealias ValueSetter = (ElementType) -> Void private var _parent: ZipSinkProtocol? - + let _lock: RecursiveLock - + // state private let _index: Int private let _this: Disposable private let _setNextValue: ValueSetter - + init(lock: RecursiveLock, parent: ZipSinkProtocol, index: Int, setNextValue: @escaping ValueSetter, this: Disposable) { _lock = lock _parent = parent @@ -123,7 +118,7 @@ final class ZipObserver _this = this _setNextValue = setNextValue } - + func on(_ event: Event) { synchronizedOn(event) } @@ -131,15 +126,15 @@ final class ZipObserver func _synchronized_on(_ event: Event) { if let _ = _parent { switch event { - case .next(_): + case .next: break - case .error(_): + case .error: _this.dispose() case .completed: _this.dispose() } } - + if let parent = _parent { switch event { case .next(let value): diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObserverType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObserverType.swift index e3ed7aa886..5a9b84b2db 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObserverType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/ObserverType.swift @@ -19,19 +19,19 @@ public protocol ObserverType { /// Convenience API extensions to provide alternate next, error, completed events extension ObserverType { - + /// Convenience method equivalent to `on(.next(element: E))` /// /// - parameter element: Next element to send to observer(s) public func onNext(_ element: E) { on(.next(element)) } - + /// Convenience method equivalent to `on(.completed)` public func onCompleted() { on(.completed) } - + /// Convenience method equivalent to `on(.error(Swift.Error))` /// - parameter error: Swift.Error to send to observer(s) public func onError(_ error: Swift.Error) { diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift index 54e83f5485..8a54b7dcd1 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift @@ -8,14 +8,14 @@ final class AnonymousObserver : ObserverBase { typealias Element = ElementType - + typealias EventHandler = (Event) -> Void - - private let _eventHandler : EventHandler - + + private let _eventHandler: EventHandler + init(_ eventHandler: @escaping EventHandler) { #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif _eventHandler = eventHandler } @@ -23,10 +23,10 @@ final class AnonymousObserver : ObserverBase { override func onCore(_ event: Event) { return _eventHandler(event) } - + #if TRACE_RESOURCES deinit { - let _ = Resources.decrementTotal() + _ = Resources.decrementTotal() } #endif } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift index 48a599dd3a..23bdbbd30c 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift @@ -17,8 +17,7 @@ enum TailRecursiveSinkCommand { /// This class is usually used with `Generator` version of the operators. class TailRecursiveSink - : Sink - , InvocableWithValueType where S.Iterator.Element: ObservableConvertibleType, S.Iterator.Element.E == O.E { + : Sink, InvocableWithValueType where S.Iterator.Element: ObservableConvertibleType, S.Iterator.Element.E == O.E { typealias Value = TailRecursiveSinkCommand typealias E = O.E typealias SequenceGenerator = (generator: S.Iterator, remaining: IntMax?) @@ -68,19 +67,19 @@ class TailRecursiveSink // should be done on gate locked private func moveNextCommand() { - var next: Observable? = nil + var next: Observable? repeat { guard let (g, left) = _generators.last else { break } - + if _isDisposed { return } _generators.removeLast() - + var e = g guard let nextCandidate = e.next()?.asObservable() else { @@ -100,8 +99,7 @@ class TailRecursiveSink if knownOriginalLeft - 1 >= 1 { _generators.append((e, knownOriginalLeft - 1)) } - } - else { + } else { _generators.append((e, nil)) } @@ -114,13 +112,12 @@ class TailRecursiveSink maxTailRecursiveSinkStackSize = _generators.count } #endif - } - else { + } else { next = nextCandidate } } while next == nil - guard let existingNext = next else { + guard let existingNext = next else { done() return } @@ -141,11 +138,10 @@ class TailRecursiveSink override func dispose() { super.dispose() - + _subscription.dispose() _gate.dispose() - + schedule(.dispose) } } - diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Rx.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Rx.swift index af948fcb86..7f5b11a184 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Rx.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Rx.swift @@ -7,7 +7,7 @@ // #if TRACE_RESOURCES - fileprivate var resourceCount = AtomicInt(0) + private var resourceCount = AtomicInt(0) /// Resource utilization information public struct Resources { @@ -37,7 +37,7 @@ func rxAbstractMethod(file: StaticString = #file, line: UInt = #line) -> Swift.N rxFatalError("Abstract method", file: file, line: line) } -func rxFatalError(_ lastMessage: @autoclosure () -> String, file: StaticString = #file, line: UInt = #line) -> Swift.Never { +func rxFatalError(_ lastMessage: @autoclosure () -> String, file: StaticString = #file, line: UInt = #line) -> Swift.Never { // The temptation to comment this line is great, but please don't, it's for your own good. The choice is yours. fatalError(lastMessage(), file: file, line: line) } @@ -85,7 +85,7 @@ func decrementChecked(_ i: inout Int) throws -> Int { print(message) #endif } - + func register(synchronizationErrorMessage: SynchronizationErrorMessages) { _lock.lock(); defer { _lock.unlock() } let pointer = Unmanaged.passUnretained(Thread.current).toOpaque() @@ -104,7 +104,7 @@ func decrementChecked(_ i: inout Int) throws -> Int { " or by enqueing sequence events in some other way.\n" ) } - + _threads[pointer] = count if _threads.count > 1 { @@ -135,7 +135,7 @@ func decrementChecked(_ i: inout Int) throws -> Int { /// RxSwift global hooks public enum Hooks { - + // Should capture call stack public static var recordCallStackOnError: Bool = false diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/RxMutableBox.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/RxMutableBox.swift index 7f3c333baa..bd88886766 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/RxMutableBox.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/RxMutableBox.swift @@ -9,8 +9,8 @@ /// Creates mutable reference wrapper for any type. final class RxMutableBox : CustomDebugStringConvertible { /// Wrapped value - var value : T - + var value: T + /// Creates reference wrapper for `value`. /// /// - parameter value: Value to wrap. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/SchedulerType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/SchedulerType.swift index bdfcf8b017..d765c9a45d 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/SchedulerType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/SchedulerType.swift @@ -19,7 +19,7 @@ public typealias RxTime = Date public protocol SchedulerType: ImmediateSchedulerType { /// - returns: Current time. - var now : RxTime { + var now: RxTime { get } @@ -32,7 +32,7 @@ public protocol SchedulerType: ImmediateSchedulerType { - returns: The disposable object used to cancel the scheduled action (best effort). */ func scheduleRelative(_ state: StateType, dueTime: RxTimeInterval, action: @escaping (StateType) -> Disposable) -> Disposable - + /** Schedules a periodic piece of work. @@ -57,15 +57,15 @@ extension SchedulerType { */ public func schedulePeriodic(_ state: StateType, startAfter: RxTimeInterval, period: RxTimeInterval, action: @escaping (StateType) -> StateType) -> Disposable { let schedule = SchedulePeriodicRecursive(scheduler: self, startAfter: startAfter, period: period, action: action, state: state) - + return schedule.start() } - func scheduleRecursive(_ state: State, dueTime: RxTimeInterval, action: @escaping (State, AnyRecursiveScheduler) -> ()) -> Disposable { + func scheduleRecursive(_ state: State, dueTime: RxTimeInterval, action: @escaping (State, AnyRecursiveScheduler) -> Void) -> Disposable { let scheduler = AnyRecursiveScheduler(scheduler: self, action: action) - + scheduler.schedule(state, dueTime: dueTime) - + return Disposables.create(with: scheduler.dispose) } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift index aa1f480e52..b800097983 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift @@ -16,13 +16,13 @@ import Dispatch public class ConcurrentDispatchQueueScheduler: SchedulerType { public typealias TimeInterval = Foundation.TimeInterval public typealias Time = Date - - public var now : Date { + + public var now: Date { return Date() } let configuration: DispatchQueueConfiguration - + /// Constructs new `ConcurrentDispatchQueueScheduler` that wraps `queue`. /// /// - parameter queue: Target dispatch queue. @@ -30,7 +30,7 @@ public class ConcurrentDispatchQueueScheduler: SchedulerType { public init(queue: DispatchQueue, leeway: DispatchTimeInterval = DispatchTimeInterval.nanoseconds(0)) { configuration = DispatchQueueConfiguration(queue: queue, leeway: leeway) } - + /// Convenience init for scheduler that wraps one of the global concurrent dispatch queues. /// /// - parameter qos: Target global dispatch queue, by quality of service class. @@ -56,7 +56,7 @@ public class ConcurrentDispatchQueueScheduler: SchedulerType { public final func schedule(_ state: StateType, action: @escaping (StateType) -> Disposable) -> Disposable { return self.configuration.schedule(state, action: action) } - + /** Schedules an action to be executed. @@ -68,7 +68,7 @@ public class ConcurrentDispatchQueueScheduler: SchedulerType { public final func scheduleRelative(_ state: StateType, dueTime: Foundation.TimeInterval, action: @escaping (StateType) -> Disposable) -> Disposable { return self.configuration.scheduleRelative(state, dueTime: dueTime, action: action) } - + /** Schedules a periodic piece of work. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift index a98ad218a0..c717147bd5 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift @@ -16,7 +16,7 @@ Abstracts work that needs to be performed on `MainThread`. In case `schedule` me This scheduler is optimized for `subscribeOn` operator. If you want to observe observable sequence elements on main thread using `observeOn` operator, `MainScheduler` is more suitable for that purpose. */ -public final class ConcurrentMainScheduler : SchedulerType { +public final class ConcurrentMainScheduler: SchedulerType { public typealias TimeInterval = Foundation.TimeInterval public typealias Time = Date @@ -24,7 +24,7 @@ public final class ConcurrentMainScheduler : SchedulerType { private let _mainQueue: DispatchQueue /// - returns: Current time. - public var now : Date { + public var now: Date { return _mainScheduler.now as Date } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift index 0676444def..2d85097458 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift @@ -16,12 +16,12 @@ import Dispatch import func Foundation.pthread_setspecific import func Foundation.pthread_getspecific import func Foundation.pthread_key_create - - fileprivate enum CurrentThreadSchedulerQueueKey { + + private enum CurrentThreadSchedulerQueueKey { fileprivate static let instance = "RxSwift.CurrentThreadScheduler.Queue" } #else - fileprivate class CurrentThreadSchedulerQueueKey: NSObject, NSCopying { + private class CurrentThreadSchedulerQueueKey: NSObject, NSCopying { static let instance = CurrentThreadSchedulerQueueKey() private override init() { super.init() @@ -42,7 +42,7 @@ import Dispatch /// This is the default scheduler for operators that generate elements. /// /// This scheduler is also sometimes called `trampoline scheduler`. -public class CurrentThreadScheduler : ImmediateSchedulerType { +public class CurrentThreadScheduler: ImmediateSchedulerType { typealias ScheduleQueue = RxMutableBox> /// The singleton instance of the current thread scheduler. @@ -57,7 +57,7 @@ public class CurrentThreadScheduler : ImmediateSchedulerType { key.deallocate(capacity: 1) #endif } - + guard pthread_key_create(key, nil) == 0 else { rxFatalError("isScheduleRequired key creation failed") } @@ -69,7 +69,7 @@ public class CurrentThreadScheduler : ImmediateSchedulerType { return UnsafeRawPointer(UnsafeMutablePointer.allocate(capacity: 1)) }() - static var queue : ScheduleQueue? { + static var queue: ScheduleQueue? { get { return Thread.getThreadLocalStorageValueForKey(CurrentThreadSchedulerQueueKey.instance) } @@ -130,8 +130,7 @@ public class CurrentThreadScheduler : ImmediateSchedulerType { let queue: RxMutableBox> if let existingQueue = existingQueue { queue = existingQueue - } - else { + } else { queue = RxMutableBox(Queue(capacity: 1)) CurrentThreadScheduler.queue = queue } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift index 11af238a3b..8f76a1407b 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift @@ -9,7 +9,7 @@ import struct Foundation.Date /// Provides a virtual time scheduler that uses `Date` for absolute time and `NSTimeInterval` for relative time. -public class HistoricalScheduler : VirtualTimeScheduler { +public class HistoricalScheduler: VirtualTimeScheduler { /** Creates a new historical scheduler with initial clock value. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift index 930ca37762..260f5a2bd8 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift @@ -11,7 +11,7 @@ import struct Foundation.Date /// Converts historical virtual time into real time. /// /// Since historical virtual time is also measured in `Date`, this converter is identity function. -public struct HistoricalSchedulerTimeConverter : VirtualTimeConverterType { +public struct HistoricalSchedulerTimeConverter: VirtualTimeConverterType { /// Virtual time unit used that represents ticks of virtual clock. public typealias VirtualTimeUnit = RxTime diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift index f2dfb90f27..d16434d234 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift @@ -30,7 +30,6 @@ extension DispatchQueueConfiguration { return } - cancel.setDisposable(action(state)) } @@ -78,7 +77,7 @@ extension DispatchQueueConfiguration { let timer = DispatchSource.makeTimerSource(queue: queue) timer.schedule(deadline: initial, repeating: dispatchInterval(period), leeway: leeway) - + // TODO: // This looks horrible, and yes, it is. // It looks like Apple has made a conceputal change here, and I'm unsure why. @@ -98,7 +97,7 @@ extension DispatchQueueConfiguration { timerState = action(timerState) }) timer.resume() - + return cancelTimer } } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift index 454fb34bb7..8b01608a65 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift @@ -7,10 +7,9 @@ // struct ScheduledItem - : ScheduledItemType - , InvocableType { + : ScheduledItemType, InvocableType { typealias Action = (T) -> Disposable - + private let _action: Action private let _state: T @@ -19,16 +18,16 @@ struct ScheduledItem var isDisposed: Bool { return _disposable.isDisposed } - + init(action: @escaping Action, state: T) { _action = action _state = state } - + func invoke() { _disposable.setDisposable(_action(_state)) } - + func dispose() { _disposable.dispose() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift index d2b16cab70..ec05efda62 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift @@ -6,8 +6,6 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -protocol ScheduledItemType - : Cancelable - , InvocableType { +protocol ScheduledItemType: Cancelable, InvocableType { func invoke() } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift index 2a72137520..421659f71f 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift @@ -18,7 +18,7 @@ Main scheduler is a specialization of `SerialDispatchQueueScheduler`. This scheduler is optimized for `observeOn` operator. To ensure observable sequence is subscribed on main thread using `subscribeOn` operator please use `ConcurrentMainScheduler` because it is more optimized for that purpose. */ -public final class MainScheduler : SerialDispatchQueueScheduler { +public final class MainScheduler: SerialDispatchQueueScheduler { private let _mainQueue: DispatchQueue diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift index 81ba59f34e..a7dc1b8e3e 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift @@ -17,7 +17,7 @@ import Dispatch public class OperationQueueScheduler: ImmediateSchedulerType { public let operationQueue: OperationQueue public let queuePriority: Operation.QueuePriority - + /// Constructs new instance of `OperationQueueScheduler` that performs work on `operationQueue`. /// /// - parameter operationQueue: Operation queue targeted to perform work on. @@ -26,7 +26,7 @@ public class OperationQueueScheduler: ImmediateSchedulerType { self.operationQueue = operationQueue self.queuePriority = queuePriority } - + /** Schedules an action to be executed recursively. @@ -42,14 +42,13 @@ public class OperationQueueScheduler: ImmediateSchedulerType { return } - cancel.setDisposable(action(state)) } operation.queuePriority = self.queuePriority self.operationQueue.addOperation(operation) - + return cancel } diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift index 24d19cc677..f0e4a5d18a 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift @@ -6,7 +6,7 @@ // Copyright © 2015 Krunoslav Zaher. All rights reserved. // -fileprivate enum ScheduleState { +private enum ScheduleState { case initial case added(CompositeDisposable.DisposeKey) case done @@ -14,17 +14,17 @@ fileprivate enum ScheduleState { /// Type erased recursive scheduler. final class AnyRecursiveScheduler { - + typealias Action = (State, AnyRecursiveScheduler) -> Void private let _lock = RecursiveLock() - + // state private let _group = CompositeDisposable() private var _scheduler: SchedulerType private var _action: Action? - + init(scheduler: SchedulerType, action: @escaping Action) { _action = action _scheduler = scheduler @@ -44,7 +44,7 @@ final class AnyRecursiveScheduler { if self._group.isDisposed { return Disposables.create() } - + let action = self._lock.calculateLocked { () -> Action? in switch scheduleState { case let .added(removeKey): @@ -59,14 +59,14 @@ final class AnyRecursiveScheduler { return self._action } - + if let action = action { action(state, self) } - + return Disposables.create() } - + _lock.performLocked { switch scheduleState { case .added: @@ -75,8 +75,7 @@ final class AnyRecursiveScheduler { case .initial: if let removeKey = _group.insert(d) { scheduleState = .added(removeKey) - } - else { + } else { scheduleState = .done } break @@ -97,7 +96,7 @@ final class AnyRecursiveScheduler { if self._group.isDisposed { return Disposables.create() } - + let action = self._lock.calculateLocked { () -> Action? in switch scheduleState { case let .added(removeKey): @@ -109,17 +108,17 @@ final class AnyRecursiveScheduler { } scheduleState = .done - + return self._action } - + if let action = action { action(state, self) } - + return Disposables.create() } - + _lock.performLocked { switch scheduleState { case .added: @@ -128,8 +127,7 @@ final class AnyRecursiveScheduler { case .initial: if let removeKey = _group.insert(d) { scheduleState = .added(removeKey) - } - else { + } else { scheduleState = .done } break @@ -138,7 +136,7 @@ final class AnyRecursiveScheduler { } } } - + func dispose() { _lock.performLocked { _action = nil @@ -150,20 +148,20 @@ final class AnyRecursiveScheduler { /// Type erased recursive scheduler. final class RecursiveImmediateScheduler { typealias Action = (_ state: State, _ recurse: (State) -> Void) -> Void - + private var _lock = SpinLock() private let _group = CompositeDisposable() - + private var _action: Action? private let _scheduler: ImmediateSchedulerType - + init(action: @escaping Action, scheduler: ImmediateSchedulerType) { _action = action _scheduler = scheduler } - + // immediate scheduling - + /// Schedules an action to be executed recursively. /// /// - parameter state: State passed to the action to be executed. @@ -175,7 +173,7 @@ final class RecursiveImmediateScheduler { if self._group.isDisposed { return Disposables.create() } - + let action = self._lock.calculateLocked { () -> Action? in switch scheduleState { case let .added(removeKey): @@ -190,14 +188,14 @@ final class RecursiveImmediateScheduler { return self._action } - + if let action = action { action(state, self.schedule) } - + return Disposables.create() } - + _lock.performLocked { switch scheduleState { case .added: @@ -206,8 +204,7 @@ final class RecursiveImmediateScheduler { case .initial: if let removeKey = _group.insert(d) { scheduleState = .added(removeKey) - } - else { + } else { scheduleState = .done } break @@ -216,7 +213,7 @@ final class RecursiveImmediateScheduler { } } } - + func dispose() { _lock.performLocked { _action = nil diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift index ca0a04a8ae..2e6bd76c36 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift @@ -35,7 +35,7 @@ final class SchedulePeriodicRecursive { return _scheduler.scheduleRecursive(SchedulePeriodicRecursiveCommand.tick, dueTime: _startAfter, action: self.tick) } - func tick(_ command: SchedulePeriodicRecursiveCommand, scheduler: RecursiveScheduler) -> Void { + func tick(_ command: SchedulePeriodicRecursiveCommand, scheduler: RecursiveScheduler) { // Tries to emulate periodic scheduling as best as possible. // The problem that could arise is if handling periodic ticks take too long, or // tick interval is short. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift index 1a38a73968..33dfc6e8d4 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift @@ -27,17 +27,17 @@ In case some customization need to be made on it before usage, internal serial queue can be customized using `serialQueueConfiguration` callback. */ -public class SerialDispatchQueueScheduler : SchedulerType { +public class SerialDispatchQueueScheduler: SchedulerType { public typealias TimeInterval = Foundation.TimeInterval public typealias Time = Date - + /// - returns: Current time. - public var now : Date { + public var now: Date { return Date() } let configuration: DispatchQueueConfiguration - + /** Constructs new `SerialDispatchQueueScheduler` that wraps `serialQueue`. @@ -62,7 +62,7 @@ public class SerialDispatchQueueScheduler : SchedulerType { serialQueueConfiguration?(queue) self.init(serialQueue: queue, leeway: leeway) } - + /** Constructs new `SerialDispatchQueueScheduler` named `internalSerialQueueName` that wraps `queue`. @@ -89,7 +89,7 @@ public class SerialDispatchQueueScheduler : SchedulerType { public convenience init(qos: DispatchQoS, internalSerialQueueName: String = "rx.global_dispatch_queue.serial", leeway: DispatchTimeInterval = DispatchTimeInterval.nanoseconds(0)) { self.init(queue: DispatchQueue.global(qos: qos.qosClass), internalSerialQueueName: internalSerialQueueName, leeway: leeway) } - + /** Schedules an action to be executed immediately. @@ -116,7 +116,7 @@ public class SerialDispatchQueueScheduler : SchedulerType { public final func scheduleRelative(_ state: StateType, dueTime: Foundation.TimeInterval, action: @escaping (StateType) -> Disposable) -> Disposable { return self.configuration.scheduleRelative(state, dueTime: dueTime, action: action) } - + /** Schedules a periodic piece of work. diff --git a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift index c0e1aa5624..0c86a089ae 100644 --- a/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift +++ b/samples/client/petstore/swift4/rxswift/SwaggerClientTests/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift @@ -13,11 +13,11 @@ open class VirtualTimeScheduler public typealias VirtualTime = Converter.VirtualTimeUnit public typealias VirtualTimeInterval = Converter.VirtualTimeIntervalUnit - private var _running : Bool + private var _running: Bool private var _clock: VirtualTime - fileprivate var _schedulerQueue : PriorityQueue> + fileprivate var _schedulerQueue: PriorityQueue> private var _converter: Converter private var _nextId = 0 @@ -50,7 +50,7 @@ open class VirtualTimeScheduler } }, isEqual: { $0 === $1 }) #if TRACE_RESOURCES - let _ = Resources.incrementTotal() + _ = Resources.incrementTotal() #endif } @@ -116,9 +116,9 @@ open class VirtualTimeScheduler _nextId += 1 _schedulerQueue.enqueue(item) - + _ = compositeDisposable.insert(item) - + return compositeDisposable } @@ -141,7 +141,7 @@ open class VirtualTimeScheduler break } - if _converter.compareVirtualTime(next.time, self.clock).greaterThan { + if _converter.compareVirtualTime(next.time, self.clock).greaterThan { _clock = next.time } @@ -185,7 +185,7 @@ open class VirtualTimeScheduler break } - if _converter.compareVirtualTime(next.time, self.clock).greaterThan { + if _converter.compareVirtualTime(next.time, self.clock).greaterThan { _clock = next.time } @@ -235,7 +235,7 @@ extension VirtualTimeScheduler: CustomDebugStringConvertible { final class VirtualSchedulerItem