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4*q%q@XlMH}Ug=!MZvO8rCa7Z#B6Kx_)}a!O z47!U!MZ#t?6!xQ)R}6|ao{3bIXh#Q=SD+IiS`~`u!fUiE!2zR~KX??;2UiegF$ej7 zXsRQRBYE`XacuMvnnE?lmoe1iYhS_XsRmzZxWVTO=W%u!kxMLed}{3Rvp?H^Vi2Fv zk4EwVTd|$RHuBhldVYP>VSrbn )RJMsuS zI}PqJVyjc3(r`#X&k5)b0X_Qo* z*`5qqk@ 8@2x}JIo zREf3?24D$#EYuQu)flLyHdNu6u%qrMpw<)hh9~Mx1N8}~SfGwLP?L7lmLh7(LJgIL zL*)d{*nywAfIA2rB19L9?j}Nr--QQkz$3_7z@b&(CJXqu4Y=L~EIf5j;9UgHc>>=y zfS)qI0FF9<7wo{DMc^d|aL6AH1;U{!f&QKy{fP_x5Ydki{V36UaDwNf9M_`OQG8&b zA6`Xov(V4l&|6&S!t+B<^j4yO p=n!6ZiyyM~FPk zzf(5g5!`=it?%P=Phg?-7oNahZlLv7c3_*<4;;XDt-rOSyS0uGeT?W)qMv62#;EnU Y4Lyp7FRk@MeCLTSp5otgr363x2kaOsng9R* diff --git a/bin/Main.class b/bin/Main.class deleted file mode 100644 index 9b0a08dd115d5958866c789a9a2bee81ded5cfd6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3643 zcmaJ^TW}QD5j}TUX=X hg^l4PCw}k^*Nced`FA1 zU@)DfwNCN1nRbRbD%3R`?kxH22{LIfwORa_+s`E3ks$4RSsgVBwI!{hM8_N&+MjhZ zCTbDaaVz)r1b)WtI_=3~oh;5%u-XTP(_S{nI24+wm*s_A-sTStIsJaLyg-(11$`vr z59E@8iN&&Vo5C%j^IVV~YUxQj9&N|594mFKm_k|4*=*nrTWG*41x>W@>r1i4 z!d9?2bk98#ba+I`GU+hz2?e{?C!`>k@$A622mN8!9&u8xy*)&?w#_zhm%_3s$epb1 z*q(dZ&M~Q_I1Jpa&^WzjR`PB8lJF8V13MI&rr%Ir3(<~N0kf02v<37|f!dvNT$>@* zVwZ*8=u|K!`DM*Dbgb%=^4cZEw97!Z!om_mVH8r9 @dJ!(2atWd=#QQWZ|$xSrOth@JWUF v0mloneYDp-dAyDyZsI5gEVy!$ z)SMQLz!#szBUp=+g+UR|lA55qqNoms;-vqCg&_ Vr(DA#e#ycQMJ)WbXG;m-1?6N? zd~Iu|d0crwa`F!EXHNJIE2>$YrM $L z#W4%BX{4I-7$vuenb`X@PF?NHIBE}G}p_I*xPqjH908{JrB?z;RJqY#fU@S<+T9 zV?*UQmL9x}WmmDfO}~uhnss@!%D9PRy`IPB4MxI OUQ89Y+v2yEOk=1?C*b|NW zITj$5yd2 AjotVl zgnLEcrW2Ky(9nDZ$1kBq?0dA=l*h;zYGgICn2o$mQk09nPe M871m(ZnNV6*iS_NiBJuX+tV>P_rdZ=+BB4hPgbIH>-B zL+V}Jul~#y=5Op$-p5h(5A>^lA*nvVG5+02X_Xk%s*u*IaYCDmA ?Z#CM^9I_a-HD&$7rbA( zwdHsn $&(TTd7OuV7vH#%x{ z)aj_#u|UUSrL%Fz1bI}Z`5|UrX9lh_L$g1GwS3lf=D~{3j`L&Ab>=WGGsf~ZZECpo EU!c;O3jhEB diff --git a/bin/ProductEntity.class b/bin/ProductEntity.class deleted file mode 100644 index 374dda0d06371c6fa9409218a118ed042caa4f21..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1237 zcmbV~&2G~`5Xb+UIJWD!Y3e4S359+@OJY89=?&CN1s9^WQc>=X>jqb;ja&z*Hy#Nj zA|wtx01t(jS-TB&Hy18Dvoo_ZznR(Je}4V~u#c{RlECsw5}!@|^lg-e>9qk(pnl fFxfakO?~*L~n=lH~ z1A+J5`w#!m(i>9t!}u()P)5y$g%yEvw>MmZz^aWU=&Y^TFf*-b!^pG;HY(5sRt8}d z98E7rLGr;HO^DMO#J)EfdP&Il+^D4=!z+%yGa>5N7zgQ*?61-7-S2_|u5JRFioUsn zDy2BQomQ3N=QoplC;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%4B>fbzT=4y*Z_h!ykNoLAe~wCa&WseLi{xk3~Lv)m&UQ}S90kZKMh=xODHhBYSM0NbC>$Pk6 zjSTss44DTQgUr`+F!{ZOPg|KcJ-ie3@;isU=!1oRl=!s3jD3=qqPMXVf99&c@cDDx zjxTWs{>E(lJM#Dk)8Jp&B@(<|WI1l&*o)m_2ksI(F)a3ARQT8{p5^!)#}_!hjD6w) zU(vD#&a-BjE{z%>lC{r7Bl;~7Yk=r&BGv%WJ4CDjqNoOlq8cE2ms$-m@jBka`|>_0 zUd0DQY5rF5JN%wia)$SXKPdE1R$wUmBO~EG=qngPi2vYF+q&Vlf1^9~U$l!8;%jPG av9vTyto-8w{$C;t&VP(?f5^FQxb%M*7#`OE diff --git a/bin/ProductOfStoreownerEntity.class b/bin/ProductOfStoreownerEntity.class deleted file mode 100644 index ee42c9fa42af0ffe520296d18897dece071364b7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2054 zcmchXTTc^F5Xb+g^v*&rP;jXQL6mkW6b11{&`9)&fQsRLTh_V+c5&Hic=Q`-;>N@n zKY$;~ICHj8vOW9iOJ~mPoSENTPXGM<`5V9n9%Yaa&|iD*QLp3gzd!I@&vHLImiN-} zZT}*Jq(Jf5{A9LHOsCu0Zy#G7Uts*49rxLB&pfpR%DV%n1K+cq?o)wm$MmhP>s<(> z&OEzAeo05V7tX?rAA6?EBamx*rgId29h3Uta(c^lY=2weOMN)a|Fkp?se&E%$jV~` zB@JUJ3yjnohdBsLYDgi?+LVS|sNK+z3AGsw*-*QwAs=e98b(9ymIe)Jfx@osSbM$G zw&lGu+b6QIZpS=1G(DToePh!9V4n+AcVh=f-7lUEHM!Kad^zH4lbftJhFd65Iv;ke zDB900$xzsE4Kj4AzYt{W)4jPGa+y948Ar);=W0<#$z^cL$|!PkvhuD}HL||obqP~x z^yS*Ic=>e@rg-TwFy#;2p4YKn+1%vW*gmfET4SDuIzkVIUJK8dv;@ypN}8&aG;t|u zwo=k$rKGu%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.class b/bin/User.class deleted file mode 100644 index 2119f7fba5734735311be550d08d1f4098c27aaf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1404 zcmcIk+fEZv6kP|}PAS7h?ghm`MJTtb#S0WKfS_mvk_v`IAExaHgY8T+7lB9oBYA*C z5 Wd!K#QUT5$A`u*c4fLY`eGzmnuT*FZi5lFa4u4hyv7KkmF zmgzkcXdX{()3 vk}R(a42)kH zlG>Ix46C>ajXK!A*O+Y6F|B&CIBt>Pj_o^|WNzsdLo?m^1n%Ijg3-EMq|k6m#Tdo~ zl&VZrmPBhb0#!-Vw05(pZAo-O#U!Q#;+ApfNl68I##15b#^^X^1cvjT?HHPUK#4TH zShRi18*{ZfsW|SDPk`*tT1{ceHjW1ZeR@U4YZopz^v$xs`k{iOTcvRO5t*=nBJcYr z*%Ny5duFxDGBmwZatt>}rC?q_UGk5N(q{O)3Cuy2pQkFG;W?Y_;^_sBuTbT3<^OLd z=zjUCLHA^+U3gbxC$eRuTT&g_-wnMOz9F6Y&>7tfSEUfjOiv-)iB$s?IWcZcvzla7 zBhS7n8mp!ppB6bGGx7?IfKACk2AXJb+_)-45u!K}v@)~=*XYC Sz zMp?%+eHl(pmYzlQV2zW!fj)ddKRz+iKoVath+_-|8hi|^t7*`R1H9ll{xx79OIW62 uqdfPLRx|T%V1-tM5sO%*73EF_uV}>>HHz1?6z1>ey~|Wi;0>8J;q4#AX-KC4 diff --git a/bin/UserEntity.class b/bin/UserEntity.class deleted file mode 100644 index e6fd4c41ca7ad296998891f136852ad2932c13a7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 795 zcmZ`#OHaZ;7@P%Ku+&oV{fwRjG;;B#@nZBu)C48*Sg^qoD5fnM|CJ^Z6A%6Xf0S`{ zX)F=UCcEEj=9}5C?~hLahuF#@C1BiyZgA#DUi6$rM!@bkk50Ag`0eUtv*WfRf!u&2 zzSDCBinXL&j{?tcAF==7gyB;^xD(KiJ>QE?1a?c4lar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.class b/bin/sprint4/NumberOfAddedAccounts.class new file mode 100644 index 0000000000000000000000000000000000000000..33d7833da54be0a4abfe36c3a70051a178fff686 GIT binary patch literal 1535 zcmb`G+foxj6h(K341sY3B;3ONo& f}9GUr|OyvZ^w*g+OQaKk_Nhb|V zVVX$nj DmTRj z&9Ra|)79}(WhOr6b<`}Dd6{ppw&iv_$CasLTe_Eh*MPSIBQ-sAGe|WOU(t?JbTd*F z73i)xa+z&fQDX?a3%+6SOG&7Q4*|~noHan_XpSSnzcz7(d*3+l;Xc1Q|3D)Hbu@8g zl!MTW7S3q;EvbH$3IN-6%NJ kp^PO921? literal 0 HcmV?d00001 diff --git a/bin/sprint4/StatisticsStoreOwner.class b/bin/sprint4/StatisticsStoreOwner.class new file mode 100644 index 0000000000000000000000000000000000000000..bce10c22660b581fac65a29ba4e877d51f131e1d GIT binary patch literal 1245 zcmaJ=Yg5xe6g^vtX=4x!Efj$oe73x*fG>)u<)LB)#ws&>Oxp#*l%$hvc>FB=(9Xz= zKfv)fIo?hB5Mi87H@kb!-Fwb`{QUj>2Y>~9P!M4l^Xjf;i-lZCn8NaeRq;x~arxGX z&0PgihJi!#*v!>Tdq1~TKI9d_aBa!5EwRkdlgaKdsB5PcUKf^QdkW$VgI$k~g(14) zRJn>CXc~HPjiJA2*?iMKDs%U YAC-{+uDNIv&9G|L{3|)!Dwk$O<<>pad!7Rh@zXA%rRipgG z@Q5K3*2Zx5j4v{^#<9guc-0UG+^D-w)vpN8u)IY>#SBK}GOtlzJ)!ve8d8D_3Z z(Iq9Vpn3VkGY!uJ@xlpHs$vmK3aG$gTV0f);iW8v5;Sqmj^P!F3V9bCfB!&iheX5L zB`_L8fx+l13!26#`)6%Qfg*-T*=0y|GIz0kh)lE=6h^-!hHO1$caEV~A{J;mN{;VV zxNHE1k*mgRR#pKMAWxc1AVNEu5c(=~iqa_tm3H&AWAyEvY~uRY0N6*XN |(SHena4qXb0WpnGWRiAw|r_iQ7DMtkSe>APJM^N^)Na mS+%&Q$hJZlM))=Qt&`GKr16&49 -FFj39KDk!nRHo7O+U!eQY{FyNE=& f@b_CzC=nMJe`X)q*}Cl=WOu61loJXh*ImyI?+T18ES3d~2gi {d z@H@9DFjxFPrFm{{YxSXjME#Av{t1EUNR8`fH(Irt3e^51W$&v%Vv2kEYnyIeb-$-@ zQDD^ZTVA*v9)|`dVQIma1f~{>gUU)FeLKi6mJOsas}Yx3c@M$Ux@^7mw@ti*d4W{G zvvt`5lM9QlvuUoYCf?QdB%He6q+!>wAaO(Bt-;v^FH{FAFtLc6ByHG1Q}Nq>C@g4> zTPBvUOmOITm1}U}4H6{Y7cl?ni-9aGiQE6OYcFs^6&P5>9bNqgR5++!`x(`~ijPcu ztldkr^#+Z t3rWdm2POTLBf%4m)3i_7c8O1$(Ch_S|{z}iAp*l3Nf&0v!-_jL# zO{C$wI>)R{*@t-p5AcP=W 4kwIud#4}v9s-w5oB)j#)m$3?IT~T8gQQ`6*ylCZRh(fyAfqyVsE(oD01w# zlHUp(rKtt1H#P3EmWFw-9QHa8c7gCvJ9d?&k=2o=<~7V3a@u zV;q@X5H4VxGhX!TRN^VAQ(XOFWc?KB$|)u*>FEwK9n5UqI>FpFA6J%M;M)3+Ld?9t zd)ueTMv#?U{1mGdE8f9cE@35>PVk|XI6 2k@RaPAk}wd4stx02+p z K89iCGnE=lGT o9up^VL_~M=gxpsUd!-j8gpf!}lqIqftKBj1CwB-uB{GJ}-=4!r_W%F@ literal 0 HcmV?d00001 diff --git a/bin/sprint4/numberOfBoughtProducts.class b/bin/sprint4/numberOfBoughtProducts.class new file mode 100644 index 0000000000000000000000000000000000000000..8ee2a382d00b57b82232e8e9b8cc5c03ef89e6ff GIT binary patch literal 1212 zcmaJ=?NZZF5Ir|E1Y!hi`6?iSptJ~7J}gQrXc4qpiX%=PemQA-Tf)SINfY1!d?Ej| zjGgfTd;lNEac@#7NXI|P-MeRZ&z{};^Y`~30M_tMfy6LbJ8=xlT}xQrmm+ueD;e9X z9=Y!wyX=+Rnt~9+z_EU+CrsU{CiaWRyyP-;rwz++HyOHO@dAUob6(;nu3=jg(aR8N zM_hUsLfdwktLTEJK}I)2f6lOY-Y@)7FPfYooU=>1S Ue)+g(J+=W{abM8>OBxWmgIxL)Rtf*~sV*SBk!Jh<<{2*XG~?wTe`?zyXC z5K+;@7{gF3*Y5VfB{i$5ctJ%N69RFU)Mz27c96T}zo%ge(+oWhF%eQQ494O&vx!_Y z8fJxLa>=x7B;rHF6wEQ)Y1htLF0XP&LmcxA%BgO8e80jl*NNbjDy_JbNV=e55lcjg zcA_8>_!G_w*JBOKSRt2d2VIKRvmNLvSYyzxDym`?Q3dP&2>r=1T<)ky;+artgSu%e zB_`qPltfy?bD^|+CISS0MhIbh7HuNSGDt;-VKivz#(-%pWRt{Q7TeWUt2HUw$_iCt z=(`N}D^ub#8ppNEfG_1!4{XmVaRFo)@BDI>L@7*z1f=H%NOYp5r@um0h^!u{bXuho zqrW`gz^!jS@HTx_0s_4RRMAH#EdZe(17wj>9a8=B3jq19bQ9sjCI%0~!wrl!Fuu1? z$7G&9_ZKhlppHlBuZ)dfAdzok)ki(q2sM#BjD{L`x* #p`o5Yn^wYW>jVGA#)hX_)5Noa|%No?a4 ZNwrR~JJ_YZGgRp{<&g=QrFaQ%{{YuG53c|K literal 0 HcmV?d00001 diff --git a/bin/systemUser.class b/bin/systemUser.class deleted file mode 100644 index d7cc0c8c5fe2a2834dc42e5591a91315d6cef0da..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4669 zcmb7HTXYlG72Q`7NQeOwhwyTsgE3&6R}w-JY#uQNii5!fgL$@OERF2}X~v93fC)|F zh9o5+Z5q @ z&b?>uIrp5s&%L_wpN~HUa6f(%MnEB&>PdNKa(l{j!w4x%+HV{(mLv?jb4g44elzAN zXlYKaH9Vu;NSO+EHTx!M&q^$5a9yLP*-Cl!3gcR>PTTO(E^X$FWV51KysWc5%j>CM z#V;l_#FLg?Sb1Wr=eTA|VPJC1NhFMR$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I`%PjW?br; zDmH#!!v|ugm)Z^QvJrg9nhoKZ<<^si7wZxr5YoH_u=;s!FnLG#H1Q!hC$xG-?7$|Y zJ9iw7NjROB9mdBzl8Re)6qhhPg3H`wcDa(C#Fpdt9$|7XeyZV09=iFUBDl(qxywoG z1{p~won~CO> ub#=|n&>ZIM6 znLXdi3g_rz0U~B|i6Adw5x#k-^EXT_Ks_Kwdy&qSO7xH%^F{LkIU@LNNDh7f%_HA` z^T7AtY;L%d>rT#TcVQ}}x9C5__rtXVm{vQ8id_Sk*^gNTQ7?#<1+l7jK|kizF6>8j z?V^6ve!w*XSjgXbj2ygXgt(V7?qmk_xs3iE`d`Kf>KMUlOu-^r)n jto~ADb^=OZm18+T^`A_x^J5GJ+XAwnM_(oI#wmkom6R Lf7V3Ig~ zmP^)#GWgo@pqeR$89e{`e}5;^AbNL+F`w!IyqLjDI|gyeAG(Nd4dB)C?`H6QndK{k z*QHiJk~RCd<{;iCP=B1kJAG#%nu5lhq@gDy!enuAmmS6v#`k#4~{|7Jg z6{uHpc>7+&tM)xut(Kud)v+&bMWfoytMfkUNnVqWV}p7VP3m1 cJuDYF@$svr&nOH*s3s#8g!k_$PMW#JEynbC@f#v)@Y6z)ez=Bvsc2 zaft{V+%%l5p9toO+fjHaj1mIv6R51F?MMWwDjEMY%LEcjlN$d_YFt99Ph|L-_zq=o zy-&>%S`0ZDi5B9ZFg}WdEL92)$fE0gxGG>DaxfCu#X(_w6bD%X6daHnbYN73&th*r zMO7oPNgNc$M{!W)GpyhsOa}#uoG0vo$9Py7q)0m{5+fPngpA2f-N8RzUDybV_v-z4 z8V7Kk`pYEC892P;b>kckq7Nwo&%+;)#$Rv VJ& z>0XCkwVwJm99Mhsj56@7it`R_;e@jBym}2UkSZrtAN77-_%7omb(LP_*xVr31a&P> z0ZO0w6o`;ezr?Qy+6_E`d numUsers = new ArrayList (); - BufferedReader reader1 = new BufferedReader(new FileReader(new File("UserAccounts.txt"))); - String line1; - while ((line1 = reader1.readLine()) != null) { - String[] arr = line1.split("\\|"); - numUsers.add(new UserEntity(arr[0], arr[1])); - } - int j; - for (j = 0; j < numUsers.size(); ++j) { - } - System.out.println("Number of users register: " + j); - - ArrayList numStoreOwners = new ArrayList (); - BufferedReader reader2 = new BufferedReader(new FileReader(new File("StoreOwnerAccounts.txt"))); - String line2; - while ((line2 = reader2.readLine()) != null) { - String[] arr1 = line2.split("\\|"); - numStoreOwners.add(new UserEntity(arr1[0], arr1[1])); - } - int k; - for (k = 0; k < numStoreOwners.size(); ++k) { - } - System.out.println("Number of storeOwners register: " + k); - - ArrayList products = new ArrayList (); - BufferedReader reader3 = new BufferedReader(new FileReader(new File("Products.txt"))); - String line3; - while ((line3 = reader3.readLine()) != null) { - String[] arr = line3.split("\\|"); - products.add(new ProductEntity(arr[0], arr[1], arr[2], arr[3])); - } - int i; - for (i = 0; i < products.size(); ++i) { - } - System.out.println("Number of products: " + i); - System.out.println("Products & Offers ]::::"); - BufferedReader br1 = new BufferedReader(new FileReader(new File("Products.txt"))); - String line4 = br1.readLine(); - while (line4 != null) { - String[] arr = line4.split("\\|"); - System.out.println(arr[0] + " " + arr[3]); - line4 = br1.readLine(); - } - } + @SuppressWarnings("resource") +public void addproducttosystem()throws Exception { + Scanner userInput2 = new Scanner(System.in); + System.out.println("name of products is:"); + String Pname = userInput2.nextLine(); + System.out.println("category of products is:" ); + String Pcategory = userInput2.nextLine(); + System.out.println("price of products is:" ); + String Pprice = userInput2.nextLine(); + System.out.println("offer on products is:"); + String Poffer = userInput2.nextLine(); + new product().addproductinfo(Pname,Pcategory, Pprice,Poffer); + } + boolean check=true; + @SuppressWarnings("resource") +public boolean AcceptStore() { + System.out.println("Do you want to add this store to storeOwner enter 1 if no enter 2"); + Scanner request=new Scanner(System.in); + int what=request.nextInt(); + if(what==1) { + return check; + } + check=false; + return check; + } + @SuppressWarnings("resource") +public void addBrandtosystem()throws Exception { + Scanner userInput2 = new Scanner(System.in); + System.out.println("name of Brands is:"); + String name = userInput2.nextLine(); + System.out.println("category of Brands is:" ); + String category = userInput2.nextLine(); + new Brand().addBrandinfo(name,category); + } + + + @SuppressWarnings("resource") +public void addnewstatistics() throws IOException { + + ArrayList numUsers = new ArrayList (); + BufferedReader reader1 = new BufferedReader(new FileReader(new File("UserAccounts.txt"))); + String line1; + while((line1 = reader1.readLine()) != null) { + String[] arr = line1.split("\\|"); + numUsers.add(new UserEntity(arr[0], arr[1])); + } + int j; + for(j = 0; j < numUsers.size(); ++j) { + } + System.out.println("Number of users register: "+j); + + + + ArrayList numStoreOwners = new ArrayList (); + BufferedReader reader2 = new BufferedReader(new FileReader(new File("StoreOwnerAccounts.txt"))); + String line2; + while((line2 = reader2.readLine()) != null) { + String[] arr1 = line2.split("\\|"); + numStoreOwners.add(new UserEntity(arr1[0], arr1[1])); + } + int k; + for(k = 0; k < numStoreOwners.size(); ++k) { + } + System.out.println("Number of storeOwners register: "+k); + + + + ArrayList products = new ArrayList (); + BufferedReader reader3 = new BufferedReader(new FileReader(new File("Products.txt"))); + String line3; + while((line3 = reader3.readLine()) != null) { + String[] arr = line3.split("\\|"); + products.add(new ProductEntity(arr[0], arr[1], arr[2],arr[3])); + } + int i; + for(i = 0; i < products.size(); ++i) { + } + System.out.println("Number of products: "+i); + System.out.println(" Products & Offers :"); + BufferedReader br1 = new BufferedReader(new FileReader(new File("Products.txt"))); + String line4= br1.readLine(); + while(line4 != null) { + String[] arr = line4.split("\\|"); + System.out.println(arr[0]+" "+arr[3]); + line4=br1.readLine(); + } + } } diff --git a/src/Brand.java b/src/Brand.java index f2522bf..bdda3b8 100644 --- a/src/Brand.java +++ b/src/Brand.java @@ -1,7 +1,6 @@ import java.io.IOException; import java.util.ArrayList; public class Brand { - product p=new product(); @SuppressWarnings("unused") private String bname; diff --git a/src/BrandEntity.java b/src/BrandEntity.java index d7b89d0..5bed0ae 100644 --- a/src/BrandEntity.java +++ b/src/BrandEntity.java @@ -1,27 +1,25 @@ -public class BrandEntity { +public class BrandEntity { private String category; private String name; - public BrandEntity(String name, String category) { this.name = name; this.category = category; - + } - + public String getBrandName() { return name; } - public void setBrandName(String name) { this.name = name; } - public String getBrandCategory() { return category; } - public void setBrandCategory(String category) { this.category = category; } - + + + } diff --git a/src/BuyedProduct.java b/src/BuyedProduct.java index 23fe15d..bd4f70c 100644 --- a/src/BuyedProduct.java +++ b/src/BuyedProduct.java @@ -2,151 +2,140 @@ import sprint3.numberOfBoughtProducts; public class BuyedProduct { - private String username; - private String storeownername; - private String productname; - protected String amount; - private String bname; - private String pprice; - private String shippingaddress; - ArrayList BuyedProductDatabase = new ArrayList (); +private String username; +private String productname; +protected String amount; +protected String bname; +private String pprice; +protected String shippingaddress; - public BuyedProduct(String uname,String storeownername, String Pname, String bamount, String bname, String price, String address) - throws Exception { - this.username = uname; - this.storeownername=storeownername; - this.productname = Pname; - this.amount = bamount; - this.bname = bname; - this.pprice = price; - this.shippingaddress = address; + ArrayList BuyedProductDatabase = new ArrayList (); + +public BuyedProduct(String uname,String Pname,String bamount,String bname,String price,String address) throws Exception { + this.username = uname; + this.productname=Pname; + this.amount=bamount; + this.bname=bname; + this.pprice=price; + this.shippingaddress=address; + + BuyedProductDatabase=FileUsage.buyed_productReadFromFile(BuyedProductDatabase); +} +public BuyedProduct() throws Exception { + + BuyedProductDatabase=FileUsage.buyed_productReadFromFile(BuyedProductDatabase); +} - BuyedProductDatabase = FileUsage.buyed_productReadFromFile(BuyedProductDatabase); - } - - public BuyedProduct() throws Exception { +public void buyproduct(String uname, String pname, String bamount,String bname,String pprice,String shippingaddress) throws Exception { + boolean FoundinSystem2=false; + boolean FoundinSystem3=false; + boolean FoundinSystem4 = false; + boolean FoundinSystem5 = false; + boolean Found = false; + Integer num1=0; + Integer num2=0; - BuyedProductDatabase = FileUsage.buyed_productReadFromFile(BuyedProductDatabase); - } - - public void buyproduct(String uname, String storeownername ,String pname, String bamount, String bname, String pprice, - String shippingaddress) throws Exception { - boolean FoundinSystem2 = false; - boolean FoundinSystem3 = false; - boolean FoundinSystem4 = false; - boolean FoundinSystem5 = false; - boolean Found = false; - Integer num1 = 0; - Integer num2 = 0; - Integer num3 = 0; - String remain; - for (int i = 0; i < new ProductOfStoreowner().ProductOfStoreownerDatabase.size(); i++) { - num1 = Integer.valueOf(bamount); - num2 = Integer.valueOf(new ProductOfStoreowner().ProductOfStoreownerDatabase.get(i).getProductQuantity()); - // p.price=String.valueOf(new - // ProductOfStoreowner().ProductOfStoreownerDatabase.get(i).getPrice()); - if (num1 <= num2) { - FoundinSystem3 = true; - } + for(int i=0;i storeReadFromFile(ArrayList st String line; while((line = reader.readLine()) != null) { String[] arr = line.split("\\|"); - store.add(new StoreEntity(arr[0], arr[1], arr[2],arr[3])); + store.add(new StoreEntity(arr[0], arr[1], arr[2])); } return store; } @SuppressWarnings("resource") public static ArrayList buyed_productReadFromFile(ArrayList buyedProduct) throws Exception{ - BufferedReader reader = new BufferedReader(new FileReader(new File("BuyedProduct.txt"))); - String line; - while ((line = reader.readLine()) != null) { - String[] arr = line.split("\\|"); - buyedProduct.add(new BuyedProductEntity(arr[0], arr[1], arr[2], arr[3], arr[4], arr[5],arr[6])); - } - return buyedProduct; - } - + BufferedReader reader = new BufferedReader(new FileReader(new File("BuyedProduct.txt"))); + String line; + while((line = reader.readLine()) != null) { + String[] arr = line.split("\\|"); + buyedProduct.add(new BuyedProductEntity(arr[0], arr[1], arr[2], arr[3],arr[4],arr[5])); + } + return buyedProduct; + } } \ No newline at end of file diff --git a/src/Main.java b/src/Main.java index 4fea18f..967e717 100644 --- a/src/Main.java +++ b/src/Main.java @@ -4,131 +4,138 @@ public class Main { - @SuppressWarnings({ "unused", "resource" }) - public static void main(String[] args) throws Exception { - User u = new User(); - StoreOwner s = new StoreOwner(); - Adminstrator a = new Adminstrator(); - Collaborator c = new Collaborator(); - product p = new product(); - boolean storewant = false; - Scanner userInput = new Scanner(System.in); - while (true) { - System.out.println("For register enter 1: "); - System.out.println("For login enter 2: "); - int want = userInput.nextInt(); - if (want == 1) { - System.out.println("To return to home page Enter 0: "); - System.out.println("For register as a new user enter 1: "); - System.out.println("For register as a new store owner enter 2: "); - System.out.println("For register as a new Adminstrator enter 3: "); - int want1 = userInput.nextInt(); - if (want1 == 0) { - System.out.println(" To Home Pgae "); - } - if (want1 == 1) { - u.register(1); - } - if (want1 == 2) { - s.register(2); - } - if (want1 == 3) { - a.register(3); - } - } else if (want == 2) { - System.out.println("To return to home page Enter 0: "); - System.out.println("For login as a User enter 1: "); - System.out.println("For login as a Store owner enter 2: "); - System.out.println("For login as an Adminstrator enter 3: "); - System.out.println("For login as a Collaborator enter 4: "); - int want2 = userInput.nextInt(); - if (want2 == 0) { - System.out.println(" To the Home Page "); - } - if (want2 == 1) { - u.login(1); - System.out.println("To return to home page Enter 0: "); - System.out.println("To view products Enter 1: "); - System.out.println("To buy a product Enter 2: "); - int userwant = userInput.nextInt(); - if (userwant == 0) { - System.out.println(" To the Home Page "); - } - if (userwant == 1) { - new UserWantsViewProduct().wantstoviewproduct(); - } - if (userwant == 2) { - u.userbuyproduct(); - } - - } else if (want2 == 2) { - s.login(2); - if (storewant == true) { - if (a.check == true) { - System.out.println("Adminstrator accepts to add new store"); - s.addnewstore(); - } else if (a.check == false) { - System.out.println("Adminstrator refuses to add new store"); - } - } - - System.out.println("To return to home page Enter 0: "); - System.out.println("To Add new store Enter 1: "); - System.out.println("To Add new product to store Enter 2: "); - System.out.println("To view statistics Enter 3: "); - System.out.println("To Add new Collaborator Enter 4:"); - System.out.println("To buy a product Enter 5:"); - int want3 = userInput.nextInt(); - if (want3 == 0) { - System.out.println(" To the Home Page "); - } - if (want3 == 1) { - storewant = true; - s.wantaddstore(); - } - if (want3 == 2) { - s.addproducttostoreowner(); - } - if (want3 == 3) { - new StatisticsStoreOwner().usersstatistics(); - } - if (want3 == 4) { - s.wantToAddCollaborator(); - } - if (want3 == 5) { - s.storeownerbuyproduct(); - } - - } else if (want2 == 3) { - a.login(3); - if (storewant) { - a.AcceptStore(); - } - System.out.println("To return to home page Enter 0: "); - System.out.println("To Add new product Enter 1: "); - System.out.println("To Add new brand Enter 2: "); - System.out.println("To see new statistics Enter 3:"); - int want4 = userInput.nextInt(); - if (want4 == 0) { - System.out.println(" To the Home Page "); - } - if (want4 == 1) { - a.addproducttosystem(); - } - if (want4 == 2) { - a.addBrandtosystem(); - - } - if (want4 == 3) { - a.addnewstatistics(); - } - - } else if (want2 == 4) { - c.CollaboratoerLogin(); - c.useAsStoreOwner(); - - } - } + @SuppressWarnings({ "unused", "resource" }) + public static void main(String[] args) throws Exception{ + User u=new User(); + StoreOwner s=new StoreOwner(); + Adminstrator a=new Adminstrator(); + Collaborator c= new Collaborator(); + product p = new product(); + boolean storewant=false; + Scanner userInput = new Scanner(System.in); + while(true) { + System.out.println("For register enter 1: "); + System.out.println("For login enter 2: "); + int want=userInput.nextInt(); + if (want==1){ + System.out.println("To return to home page Enter 0: "); + System.out.println("For register as a new user enter 1: "); + System.out.println("For register as a new store owner enter 2: "); + System.out.println("For register as a new Adminstrator enter 3: "); + int want1=userInput.nextInt(); + if(want1==0) { + System.out.println(" To Home Pgae "); + } + if(want1==1){ + u.register(1); + } + if(want1==2){ + s.register(2); + } + if(want1==3){ + a.register(3); + } + } + else if(want==2) + { + System.out.println("To return to home page Enter 0: "); + System.out.println("For login as a User enter 1: "); + System.out.println("For login as a Store owner enter 2: "); + System.out.println("For login as an Adminstrator enter 3: "); + System.out.println("For login as a Collaborator enter 4: "); + int want2=userInput.nextInt(); + if(want2==0) { + System.out.println(" To the Home Page "); + } + if(want2==1){ + u.login(1); + System.out.println("To return to home page Enter 0: "); + System.out.println("To view products Enter 1: "); + System.out.println("To buy a product Enter 2: "); + int userwant=userInput.nextInt(); + if(userwant==0) { + System.out.println(" To the Home Page "); + } + if(userwant==1) { + new UserWantsViewProduct().wantstoviewproduct(); + } + if(userwant==2) { + u.userbuyproduct(); + } + + } + else if(want2==2){ + s.login(2); + if(storewant==true) { + if(a.check==true) { + System.out.println("Adminstrator accepts to add new store"); + s.addnewstore(); + } + else if(a.check==false) { + System.out.println("Adminstrator refuses to add new store"); + } + } + + System.out.println("To return to home page Enter 0: "); + System.out.println("To Add new store Enter 1: "); + System.out.println("To Add new product to store Enter 2: "); + System.out.println("To view statistics Enter 3: "); + System.out.println("To buy a product Enter 4: "); + System.out.println("To Add new Collaborator Enter 5:"); + int want3=userInput.nextInt(); + if(want3==0) { + System.out.println(" To the Home Page "); + } + if(want3==1) { + storewant=true; + s.wantaddstore(); + } + if(want3==2) { + s.addproducttostoreowner(); + } + if(want3==3) { + new StatisticsStoreOwner().usersstatistics(); + } + if(want3==4) { + s.storeownerbuyproduct(); + } + if(want3==5) { + s.wantToAddCollaborator(); + } + + } + else if(want2==3){ + a.login(3); + if(storewant) { + a.AcceptStore(); + } + System.out.println("To return to home page Enter 0: "); + System.out.println("To Add new product Enter 1: "); + System.out.println("To Add new brand Enter 2: "); + System.out.println("To see new statistics Enter 3:"); + int want4=userInput.nextInt(); + if(want4==0) { + System.out.println(" To the Home Page "); + } + if(want4==1) { + a.addproducttosystem(); + } + if(want4==2) { + a.addBrandtosystem(); + + } + if(want4==3) { + a.addnewstatistics(); + } + + + + } + else if(want2==4){ + c.CollaboratoerLogin(); + c.useAsStoreOwner(); + } + } + } } - } -} \ No newline at end of file +} diff --git a/src/ProductOfStoreowner.java b/src/ProductOfStoreowner.java index b8eafa8..901f50a 100644 --- a/src/ProductOfStoreowner.java +++ b/src/ProductOfStoreowner.java @@ -1,72 +1,69 @@ import java.util.ArrayList; - @SuppressWarnings("unused") public class ProductOfStoreowner { - private String storeOwnerName; - private String name; - private String category; - private String price; - private String productquantity; - private String brandname; - private String brandcategory; - - ArrayList ProductOfStoreownerDatabase = new ArrayList (); - - public ProductOfStoreowner(String storeOwnerName, String Pname, String Pcategory, String Pprice, String bname, - String bcategory, String productquantity) throws Exception { +private String storeOwnerName; +private String name; +private String category; +private String price; +private String productquantity; +private String brandname; +private String brandcategory; - this.storeOwnerName = storeOwnerName; - this.name = Pname; - this.category = Pcategory; - this.price = Pprice; - this.productquantity = productquantity; - this.brandname = bname; - this.brandcategory = bcategory; - - ProductOfStoreownerDatabase = FileUsage.product_sOwnerReadFromFile(ProductOfStoreownerDatabase); - } + ArrayList ProductOfStoreownerDatabase = new ArrayList (); + +public ProductOfStoreowner(String storeOwnerName,String Pname,String Pcategory,String Pprice,String bname,String bcategory, String productquantity) throws Exception { + + this.storeOwnerName=storeOwnerName; + this.name=Pname; + this.category=Pcategory; + this.price=Pprice; + this.productquantity=productquantity; + this.brandname=bname; + this.brandcategory=bcategory; + + ProductOfStoreownerDatabase = FileUsage.product_sOwnerReadFromFile(ProductOfStoreownerDatabase); +} +public ProductOfStoreowner() throws Exception { + + ProductOfStoreownerDatabase = FileUsage.product_sOwnerReadFromFile(ProductOfStoreownerDatabase); +} - public ProductOfStoreowner() throws Exception { - ProductOfStoreownerDatabase = FileUsage.product_sOwnerReadFromFile(ProductOfStoreownerDatabase); +public void addstoreproductinfo( String storeOwnerName,String pname, String pcategory,String pprice,String bname,String bcategory,String pproductquantity) throws Exception { + + boolean FoundinSystem1=false; + boolean FoundinSystem2=false; + for(int i = 0; i < new product().prodctDatabase.size() ; ++i) { + if((pname.equals(new product().prodctDatabase.get(i).getName())) && + (pcategory.equals(new product().prodctDatabase.get(i).getCategory())) && + (pprice.equals(new product().prodctDatabase.get(i).getPrice()))) + { + FoundinSystem1=true; + + } } - - public void addstoreproductinfo(String storeOwnerName, String pname, String pcategory, String pprice, String bname, - String bcategory, String pproductquantity) throws Exception { - - boolean FoundinSystem1 = false; - boolean FoundinSystem2 = false; - for (int i = 0; i < new product().prodctDatabase.size(); ++i) { - if ((pname.equals(new product().prodctDatabase.get(i).getName())) - && (pcategory.equals(new product().prodctDatabase.get(i).getCategory())) - && (pprice.equals(new product().prodctDatabase.get(i).getPrice()))) { - FoundinSystem1 = true; - - } - } - for (int j = 0; j < new Brand().BrandDatabase.size(); j++) { - if ((bname.equals(new Brand().BrandDatabase.get(j).getBrandName())) - && (bcategory.equals(new Brand().BrandDatabase.get(j).getBrandCategory()))) { - FoundinSystem2 = true; - - } - } - if (FoundinSystem1 == false || FoundinSystem2 == false) { - System.out.println("The Product or Brand is not found in system"); - return; - } - if (FoundinSystem1 == true & FoundinSystem2 == true) { - for (int i = 0; i < ProductOfStoreownerDatabase.size(); ++i) { - if (ProductOfStoreownerDatabase.get(i).getName().equals(pname) - & ProductOfStoreownerDatabase.get(i).getBrandName().equals(bname) & bcategory == pcategory) { - System.out.print("this product is already added with this brand \n"); - return; - } - } - FileUsage.usingBufferedWritter(storeOwnerName + "|" + pname + "|" + pcategory + "|" + pprice + "|" + bname - + "|" + bcategory + "|" + pproductquantity, "ProductsOfStoreowner.txt"); - System.out.println("Product is added to store with a brand"); - } + for(int j = 0; j < new Brand().BrandDatabase.size() ; j++) { + if((bname.equals(new Brand().BrandDatabase.get(j).getBrandName())) && + (bcategory.equals(new Brand().BrandDatabase.get(j).getBrandCategory()))) + { + FoundinSystem2=true; + + } } + if(FoundinSystem1==false || FoundinSystem2==false ) { + System.out.println("The Product or Brand is not found in system"); + return; + } + if(FoundinSystem1==true & FoundinSystem2==true) { + for(int i = 0; i < ProductOfStoreownerDatabase.size() ; ++i) { + if(ProductOfStoreownerDatabase.get(i).getName().equals(pname) & ProductOfStoreownerDatabase.get(i).getBrandName().equals(bname) & bcategory==pcategory) { + System.out.print("this product is already added with this brand \n"); + return; + } + } + FileUsage.usingBufferedWritter(storeOwnerName + "|" +pname + "|" + pcategory + "|" + pprice + "|" + bname + "|" + bcategory + "|" + pproductquantity,"ProductsOfStoreowner.txt"); + System.out.println("Product is added to store with a brand"); + } + } } \ No newline at end of file diff --git a/src/Store.java b/src/Store.java index 6581d5f..3aaacb6 100644 --- a/src/Store.java +++ b/src/Store.java @@ -1,50 +1,34 @@ import java.io.IOException; import java.util.ArrayList; - public class Store { + + + public String storelocation; + public String storetype; + public String storename; + + ArrayList StoreDatabase=new ArrayList (); + public Store(String storename ,String storetype, String storelocation) throws Exception { + this.storename=storename; + this.storetype=storetype; + this.storelocation=storelocation; + + StoreDatabase=FileUsage.storeReadFromFile(StoreDatabase); + } + public Store() throws Exception{ + StoreDatabase=FileUsage.storeReadFromFile(StoreDatabase); + } - public String storelocation; - public String storetype; - public String storename; - public String storeowneraccount; - ArrayList StoreDatabase = new ArrayList (); - - public Store(String storename, String storeowneraccount, String storetype, String storelocation) throws Exception { - this.storename = storename; - this.storeowneraccount = storeowneraccount; - this.storetype = storetype; - this.storelocation = storelocation; - - StoreDatabase = FileUsage.storeReadFromFile(StoreDatabase); - } - - public Store() throws Exception { - StoreDatabase = FileUsage.storeReadFromFile(StoreDatabase); - } - - public void addstoreinfo(String storename, String storeowneraccount, String storetype, String storelocation) - throws Exception { - boolean FoundinSystem1 = false; - boolean FoundinSystem2 = false; - for (int i = 0; i < new systemUser().StoreODatabase.size(); ++i) { - if (storeowneraccount.equals(new systemUser().StoreODatabase.get(i).getUsername())) { - FoundinSystem1 = true; - } - } - for (int i = 0; i < StoreDatabase.size(); ++i) { - if (StoreDatabase.get(i).getname().equals(storename)) { - System.out.print("this store is already found "); - FoundinSystem2 = true; - return; - } - } - if (FoundinSystem1 == false) { - System.out.println("This storeowner is not found"); - } - if (FoundinSystem2 == false && FoundinSystem1 == true) { - FileUsage.usingBufferedWritter(storename + "|" + storeowneraccount + "|" + storetype + "|" + storelocation, - "Store.txt"); - System.out.println("Store is added"); - } - } + public void addstoreinfo( String storename, String storetype,String storelocation) throws IOException { + for(int i = 0; i < StoreDatabase.size(); ++i) { + if(StoreDatabase.get(i).getname().equals(storename)) { + System.out.print("this product is found"); + return; + } + } + + FileUsage.usingBufferedWritter(storename + "|" + storetype + "|" + storelocation ,"Store.txt"); + System.out.println("Store is added"); +} } + diff --git a/src/StoreEntity.java b/src/StoreEntity.java index 10842e0..10cc387 100644 --- a/src/StoreEntity.java +++ b/src/StoreEntity.java @@ -1,27 +1,19 @@ -public class StoreEntity { - public StoreEntity(String name,String account, String type , String location) { +public class StoreEntity { + public StoreEntity(String name, String type , String location) { this.location = location; this.type = type; this.name = name; - this.accountname=account; } private String location; private String type; private String name; - private String accountname; public String getname() { return name; } public void setname(String name) { this.name = name; } - public String getAccountname() { - return accountname; - } - public void setAccountname(String accountname) { - this.accountname = accountname; - } public String getType() { return type; } diff --git a/src/StoreOwner.java b/src/StoreOwner.java index 2f436ae..fabd331 100644 --- a/src/StoreOwner.java +++ b/src/StoreOwner.java @@ -1,95 +1,101 @@ import java.util.Scanner; -public class StoreOwner extends systemUser implements StoreOwnerAddColloborators ,StoreOwnerAddProducts,StoreOwnerAddStores,StoreOwnerBuyProducts { +public class StoreOwner extends systemUser implements StoreOwnerAddStores,StoreOwnerAddProducts,StoreOwnerBuyProducts,StoreOwnerAddColloborators { systemUser s = new systemUser(); - public StoreOwner() throws Exception { super(); // TODO Auto-generated constructor stub } - - @SuppressWarnings({ "resource", "unused" }) - public void wantaddstore() throws Exception { - - Scanner userInput2 = new Scanner(System.in); - System.out.println("Name of store is:"); - String sname = userInput2.nextLine(); - System.out.println("Type of store is:" ); - String stype = userInput2.nextLine(); - System.out.println("location of store is:" ); - String slocation = userInput2.nextLine(); - System.out.println("Wait for the admin to accept this may take time"); + +@SuppressWarnings({ "resource", "unused" }) +public void wantaddstore() throws Exception { + //Adminstrator admin=new Adminstrator(); + Scanner userInput2 = new Scanner(System.in); + System.out.println("Name of store is:"); + String sname = userInput2.nextLine(); + System.out.println("Type of store is:"); + String stype = userInput2.nextLine(); + System.out.println("location of store is:"); + String slocation = userInput2.nextLine(); + System.out.println("Wait for the admin to accept this may take time"); } - @SuppressWarnings({ "resource" }) public void addnewstore() throws Exception { - Scanner userInput2 = new Scanner(System.in); - System.out.println("Name of store is:"); - String sname = userInput2.nextLine(); - System.out.println("Your account name is:"); - String saccount = userInput2.nextLine(); - System.out.println("Type of store is:"); - String stype = userInput2.nextLine(); - System.out.println("location of store is:"); - String slocation = userInput2.nextLine(); - new Store().addstoreinfo(sname, saccount, stype, slocation); + Scanner userInput2 = new Scanner(System.in); + System.out.println("Name of store is:"); + String sname = userInput2.nextLine(); + System.out.println("Type of store is:"); + String stype = userInput2.nextLine(); + System.out.println("location of store is:"); + String slocation = userInput2.nextLine(); + new Store().addstoreinfo(sname, stype, slocation); } - @SuppressWarnings({ "resource" }) public void addproducttostoreowner() throws Exception { - Scanner userInput3 = new Scanner(System.in); - - System.out.println("Name of Store owner is:"); - String storeOwnerName = userInput3.nextLine(); - System.out.println("Name of products is:"); - String Pname = userInput3.nextLine(); - System.out.println("Category of products is:"); - String Pcategory = userInput3.nextLine(); - System.out.println("Price of products is:"); - String Pprice = userInput3.nextLine(); - System.out.println("Name of brand is:"); - String Brandname = userInput3.nextLine(); - System.out.println("Category of brand is:"); - String Brandcategory = userInput3.nextLine(); - System.out.println("Quantity of products is:"); - String Pproductquantity = userInput3.nextLine(); - new ProductOfStoreowner().addstoreproductinfo(storeOwnerName, Pname, Pcategory, Pprice, Brandname, - Brandcategory, Pproductquantity); + Scanner userInput3 = new Scanner(System.in); + System.out.println("name of Storeowner is:"); + String StoreOwnerName = userInput3.nextLine(); + System.out.println("name of products is:"); + String Pname = userInput3.nextLine(); + System.out.println("category of products is:"); + String Pcategory = userInput3.nextLine(); + System.out.println("price of products is:"); + String Pprice = userInput3.nextLine(); + System.out.println("name of brand is:"); + String Brandname = userInput3.nextLine(); + System.out.println("category of brand is:"); + String Brandcategory = userInput3.nextLine(); + System.out.println("Quantity of products is:"); + String Pproductquantity = userInput3.nextLine(); + new ProductOfStoreowner().addstoreproductinfo(StoreOwnerName,Pname, Pcategory, Pprice, Brandname, Brandcategory, + Pproductquantity); } + public void storeownerbuyproduct() throws Exception { + Scanner userInput3 = new Scanner(System.in); + System.out.println("Account name is:"); + String Uname = userInput3.nextLine(); + System.out.println("name of products is:"); + String Pname = userInput3.nextLine(); + System.out.println("amount of products is:"); + String bamount = userInput3.nextLine(); + System.out.println("name of brand is:"); + String bname = userInput3.nextLine(); + System.out.println("price of product is:"); + String pprice = userInput3.nextLine(); + System.out.println("Shipping address is:"); + String shippingaddress = userInput3.nextLine(); + new BuyedProduct().buyproduct(Uname,Pname, bamount, bname,pprice,shippingaddress); + + } public void wantToAddCollaborator() throws Exception { Scanner input = new Scanner(System.in); - System.out.println("What is your Username? "); - System.out.println("StoreOwner username: "); - String storeOwnerName = input.nextLine(); System.out.println("Enter the information of your Collaborator "); System.out.println("UserName: "); - String collaboratorName = input.nextLine(); + String collaboratorName=input.nextLine(); System.out.println("Password: "); - String password = input.nextLine(); + String password=input.nextLine(); System.out.println("Your Collaborator account is added succesfully!"); - FileUsage.usingBufferedWritter(storeOwnerName + "|" + collaboratorName, "storeOwnerCollaborator.txt"); - FileUsage.usingBufferedWritter(storeOwnerName + "|" + collaboratorName + "|" + password, "Collaborator.txt"); + FileUsage.usingBufferedWritter(collaboratorName + "|" + password , "Collaborator.txt"); } - public void storeownerbuyproduct() throws Exception { - Scanner userInput3 = new Scanner(System.in); - System.out.println("Your username is:"); - String Uname = userInput3.nextLine(); - System.out.println("Store owner account's name is:"); - String Sname = userInput3.nextLine(); - System.out.println("name of product is:"); - String Pname = userInput3.nextLine(); - System.out.println("amount of products is:"); - String bamount = userInput3.nextLine(); - System.out.println("name of brand is:"); - String bname = userInput3.nextLine(); - System.out.println("price of product is:"); - String pprice = userInput3.nextLine(); - System.out.println("Shipping address is:"); - String shippingaddress = userInput3.nextLine(); - new BuyedProduct().buyproduct(Uname, Sname, Pname, bamount, bname, pprice, shippingaddress); - - } } + + + + + + + + + + + + + + + + + + diff --git a/src/StoreOwnerAddColloborators.java b/src/StoreOwnerAddColloborators.java index 93e1620..6054a19 100644 --- a/src/StoreOwnerAddColloborators.java +++ b/src/StoreOwnerAddColloborators.java @@ -1,3 +1,4 @@ + public interface StoreOwnerAddColloborators { public void wantToAddCollaborator() throws Exception; } diff --git a/src/StoreOwnerAddProducts.java b/src/StoreOwnerAddProducts.java index 15b1ffd..f1f9db9 100644 --- a/src/StoreOwnerAddProducts.java +++ b/src/StoreOwnerAddProducts.java @@ -1,3 +1,4 @@ + public interface StoreOwnerAddProducts { public void addproducttostoreowner() throws Exception; } diff --git a/src/StoreOwnerAddStores.java b/src/StoreOwnerAddStores.java index 895bd60..3ecddb4 100644 --- a/src/StoreOwnerAddStores.java +++ b/src/StoreOwnerAddStores.java @@ -1,5 +1,5 @@ + public interface StoreOwnerAddStores { public void wantaddstore() throws Exception; - public void addnewstore() throws Exception; } diff --git a/src/StoreOwnerBuyProducts.java b/src/StoreOwnerBuyProducts.java index 8842394..3c862b6 100644 --- a/src/StoreOwnerBuyProducts.java +++ b/src/StoreOwnerBuyProducts.java @@ -1,3 +1,4 @@ + public interface StoreOwnerBuyProducts { public void storeownerbuyproduct() throws Exception; } diff --git a/src/User.java b/src/User.java index bb5d1c5..c2c4121 100644 --- a/src/User.java +++ b/src/User.java @@ -9,11 +9,9 @@ public User() throws Exception { @SuppressWarnings("resource") public void userbuyproduct() throws Exception{ Scanner userInput3 = new Scanner(System.in); - System.out.println("Your username is:"); + System.out.println("Account name is:"); String Uname = userInput3.nextLine(); - System.out.println("Store owner account's name is:"); - String Sname = userInput3.nextLine(); - System.out.println("name of product is:"); + System.out.println("name of products is:"); String Pname = userInput3.nextLine(); System.out.println("amount of products is:" ); String bamount = userInput3.nextLine(); @@ -23,7 +21,10 @@ public void userbuyproduct() throws Exception{ String pprice = userInput3.nextLine(); System.out.println("Shipping address is:" ); String shippingaddress = userInput3.nextLine(); - new BuyedProduct().buyproduct(Uname,Sname,Pname, bamount, bname, pprice,shippingaddress); + new BuyedProduct().buyproduct(Uname,Pname, bamount, bname, pprice,shippingaddress); } + + + } + -} \ No newline at end of file diff --git a/src/product.java b/src/product.java index 2228ca7..1c57fea 100644 --- a/src/product.java +++ b/src/product.java @@ -1,39 +1,37 @@ import java.io.IOException; import java.util.ArrayList; -public class product { - protected String name; - String category; - String price; - String offer; - - ArrayList prodctDatabase = new ArrayList (); - - public product(String Pname, String Pcategory, String Pprice, String Poffer) throws Exception { - this.name = Pname; - this.category = Pcategory; - this.price = Pprice; - this.offer = Poffer; - - prodctDatabase = FileUsage.productReadFromFile(prodctDatabase); - } - - public product() throws Exception { - prodctDatabase = FileUsage.productReadFromFile(prodctDatabase); - } - - int id = 0; - - public void addproductinfo(String pname, String pcategory, String pprice, String poffer) throws IOException { - for (int i = 0; i < prodctDatabase.size(); ++i) { - if (prodctDatabase.get(i).getName().equals(pname)) { - System.out.print("this product is found \n"); - return; - } - - } - - FileUsage.usingBufferedWritter(pname + "|" + pcategory + "|" + pprice + "|" + poffer, "Products.txt"); - System.out.println("Product is added to system"); - } +public class product { +protected + String name; + String category; + String price; + String offer; + ArrayList prodctDatabase = new ArrayList (); + + public product(String Pname,String Pcategory,String Pprice,String Poffer) throws Exception { + this.name=Pname; + this.category=Pcategory; + this.price=Pprice; + this.offer=Poffer; + + prodctDatabase = FileUsage.productReadFromFile(prodctDatabase); + } + public product() throws Exception { + prodctDatabase = FileUsage.productReadFromFile(prodctDatabase); + } + + int id=0; + public void addproductinfo( String pname, String pcategory,String pprice, String poffer) throws IOException { + for(int i = 0; i < prodctDatabase.size(); ++i) { + if(prodctDatabase.get(i).getName().equals(pname)) { + System.out.print("this product is found"); + return; + } + + } + + FileUsage.usingBufferedWritter(pname + "|" + pcategory + "|" + pprice + "|" + poffer,"Products.txt"); + System.out.println("Product is added to system"); +} } diff --git a/src/sprint4/NumberOfAddedAccounts.java b/src/sprint4/NumberOfAddedAccounts.java index 722190d..e61ff03 100644 --- a/src/sprint4/NumberOfAddedAccounts.java +++ b/src/sprint4/NumberOfAddedAccounts.java @@ -1,4 +1,4 @@ -package sprint3; +package sprint4; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; diff --git a/src/sprint4/StatisticsStoreOwner.java b/src/sprint4/StatisticsStoreOwner.java index b996ec7..85062a8 100644 --- a/src/sprint4/StatisticsStoreOwner.java +++ b/src/sprint4/StatisticsStoreOwner.java @@ -1,4 +1,4 @@ -package sprint3; +package sprint4; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; diff --git a/src/sprint4/UserWantsViewProduct.java b/src/sprint4/UserWantsViewProduct.java index 56214e6..bd81ee0 100644 --- a/src/sprint4/UserWantsViewProduct.java +++ b/src/sprint4/UserWantsViewProduct.java @@ -1,4 +1,4 @@ -package sprint3; +package sprint4; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; diff --git a/src/sprint4/numberOfBoughtProducts.java b/src/sprint4/numberOfBoughtProducts.java index 9d28ea6..7523780 100644 --- a/src/sprint4/numberOfBoughtProducts.java +++ b/src/sprint4/numberOfBoughtProducts.java @@ -1,4 +1,4 @@ -package sprint3; +package sprint4; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; diff --git a/storeOwnerCollaborator.txt b/storeOwnerCollaborator.txt index 9b3dab5..f548168 100644 --- a/storeOwnerCollaborator.txt +++ b/storeOwnerCollaborator.txt @@ -1,7 +1,4 @@ nesma_thabet|noran - noran_1|NesmaHatem - merret1|merret - salmaa1|laila \ No newline at end of file