0 1 0 0

!"#$"%&'()*%+'"#%'# - PowerPoint PPT Presentation

!"#$"%&'()*%+'"#%'# ,'-%./&0#!&*1+%0*%)&0 !"#$%&'"()"*&+&,"(-&./"0&1&23 Radical Normal Radical composition Normal components Architectural Styles Normal


  1. !"#$"%&'()*%+'"#%'# ,'-%./&0#!&*1+%0*%)&0 !"#$%&'"()"*&+&,"(-&./"0&1&23

  2. Radical Normal

  3. Radical composition Normal components

  4. Architectural Styles ⊆ Normal Modes of Composition

  5. Architectural Style "#$%&'($')#( ! !"#$"%&%' *+#(,#(-(.'-+$/0,)'1'&/. ! !"%%&!'"() *+21$&3&'1'(-+$/0,/.(.'+$/00).&$1'&/. "#$%&'($')#13+4'53(67/.2&8)#1'&/. ! 1#$%&'($')#(+9+:$/0,/.(.'-;+$/..($'/#-;+$/.-'#1&.'-< =&-)13&>1'&/.+ ! 8#1,%+#(,#(-(.'1'&/. !

  6. Architectural Styles @&,(-+1.A+2&3'(#- B1'1+1C-'#1$'&/. D0,3&$&'+&.E/$1'&/. F15(#(A+-5-'(0- G(,/-&'/#&(- ?

  7. Pipes & Filters IE(#E&(J ! "#$%&'($')#13+,1''(#.+2/#+-'#(10+ 23 ,#/$(--&.8 (/%/#-8'. ! "+2&3'(#+A(2&.(-+1+ 24 ,#/$(--&.86$/0,)'1'&/.+-'(, ! B1'1+23/J-+'%#/)8%+1+ 25 -(K)(.'&13+$%1&.+/2+2&3'(#- ! "+2&3'(#+$%1&.+#(,#(-(.'-+1+-5-'(0 2'67'"0"% 2'""0*%'& H

  8. Pipes & Filters 7/0,/.(.'-+MN&3'(#-O ! 4('+/2+&.,)'-+1.A+/)',)'- 93 ! D.,)'+P+/)',)'+-'#(10- (/%/#-8'. ! F/$13+'#1.-2/#01'&/. 94 " &.$#(0(.'13+/)',)' ! Q./J.+1-+2&3'(#- 9" 7/..($'/#-+M@&,(-O ! N1$&3&'1'(+A1'1+23/J -+8%0&: 7+70: ! Q./J.+1-+,&,(- L

  9. Pipes & Filters D.E1#&1.'- Like what kind of Prog. Langs.? ! D.A(,(.A(.'+(.'&'&(- " A/+./'+-%1#(+-'1'( " %1E(+./+S./J3(A8(+/2+/'%(#+2&3'(#- ! T#1.-2/#01'&/. " &.$#(0(.'13+ " ./'+A(,(.A(.'+/.+/#A(#+&.+'%(+$%1&. X Y Can filter X influence filter Y? Can filter Y influence filter X? R

  10. Pipes & Filters 4,($&13&>1'&/. ! *+$&,+%&) *+#(-'#&$'(A+'/+3&.(1#+'/,/3/85 ! -".%/&/0$+$&) *+#(-'#&$'-+'%(+10/).'+/2+A1'1+/.+1+,&,( ! 12$&/0$+$&) *+A1'1+/.+1+,&,(+'/+C(+/2+1.+1$$(,'1C3(+'5,( V)(-'&/. ! 71.+1+2&3'(#+,#/$(--+133+/2+&'-+&.,)'+A1'1+1-+1+-&.83(+(.'&'5W U

  11. Pipes & Filters Z[10,3(- ! \.&[+-%(33+,#/8#10-+ " ,&,(3&.(- " $1'+2&3(X+]+-/#'+]+8#(,+S(5J/#A ! ^ZZ+4(#E3('+N&3'(#+M_1E1[`-(#E3('`N&3'(#O " '5,(A+,&,(- :0&@0& :0&@80% :0&@0& -3 -4 -" :0&@80% &0;)0:% <==>?0;)0:% &0:7'":0 <==>?0:7'":0 XY

  12. Pipes & Filters Z[10,3(- ! 7/0,&3(#- " a/#(+/2+1+-(K)(.'&13+C1'$%+1#$%&'($')#( 80A :B" :06 '7% *'(0 :')&*0#*'(0 6/*1+"0#*'(0 XX

  13. Pipes & Filters "AE1.'18(- ! 4&0,3(+$/0,/-&'&/. ! G()-( " 1.5+'J/+2&3'(#-+$1.+C(+$/0C&.(A+'/8('%(# ! 1-+3/.8+1-+'%(5+-,(1S+'%(+-10(+A1'1+31.8)18( ! @#/'/'5,&.8 " %/J+01.5+-$#&,'-+01S(+)-(+/2+8#(,;+1JS;+-(A+('$` ! Z1-5+8#/J'%+P+(E/3)'&/. " "#$%&'($')#13+(E13)1'&/.+2/#+,(#2/#01.$(+P+C/''3(.($S- ! 7/.$)##(.$5+P+,1#133(3&-0 Xb

  14. Pipes & Filters B&-1AE1.'18(- ! @//#+,(#2/#01.$( " (1$%+2&3'(#+%1-+'/+,1#-(+A1'1 " -%1#&.8+83/C13+A1'1+&-+A&22&$)3' ! d/'+1,,#/,#&1'(+2/#+&.'(#1$'&/.+ ! F/J+21)3'+'/3(#1.$(+'%#(-%/3A " e%1'+%1,,(.-+&2+1+2&3'(#+$#1-%(- ! B1'1+'#1.-2/#01'&/.+ " '/+F7B+'/+1$$/00/A1'(+2&3'(#-+ ! D.$#(1-(-+$/0,3([&'5+P+$/0,)'1'&/. Xc

  15. Pipe-and-Filter vs. Batch Sequential • Both decompose the task into a fixed sequence of computations (components) interacting only through data passed from one to another Batch Sequential Pipe-and-Filter • course grained • fine grained • high latency • results starts processing • external access to input • localized input • no concurrency • concurrency possible • non-interactive • interactive awkward but possible 32

  16. Data Abstraction IC_($'+I#&(.'(A+I#81.&>1'&/.+MIIIO ! Z.$1,-)31'&/.+MA1'1+P+/,(#1'&/.-O 7/0,/.(.'- ! IC_($'-;+0/A)3(- 7/..($'/#- ! #(,#(-(.'+&.'(#f/C_($'+$/00).&$1'&/. " -5.$%#/./)-+/#+1-5.$%#/./)-+ X!

  17. Data Abstraction Q(5+1-,($'- ! IC_($'-+,#(-(#E(+'%(&#+&.'(8#&'5+ ! ./+A&#($'+1$$(-- ! IC_($'+#(,#(-(.'1'&/.+&-+1+,#&E1'(+1221&# "AE1.'18(- ! D0,3(0(.'1'&/.+$%1.8(-+J&'%+0&.&013+83/C13+&0,1$' ! B($/0,/-&'&/. " 31#8(+-5-'(0+&.'/+1+-('+/2+&.'(#1$'&.8+/C_($'- " (1-5+'/+01.18(+P+(E/3E( X?

  18. Data Abstraction B&-1AE1.'18(- ! D.'(#1$'&/.+&._($'-+$/),3&.8 " /C_($'-+&.'(#1$'+E&1+,)C3&$+$/.'#1$' " J%1'+%1,,(.-+J%(.+'%(+$/.'#1$'+$%1.8(-W " &.A&#($'+$/),3&.8*+"+)-(-+g;+7+)-(-+g;+'%(.+$%1.8(-+01A(+C5+7+ /.+g+1#(+).([,($'(A+'/+" XH

  19. Data Abstraction 4/0(+'%/)8%'- ! B(-&8.+C5+$/.'#1$'+h+&.'(#21$(- " A($/),3(-+&.'(#f/C_($'+A(,(.A(.$&(- ! 45.$%#/.&>1'&/. e%1'+J/)3A+%1,,(.+&2+1.+/C_($'+J(#(+'/+21&3+A)#&.8+ 1.+/,(#1'&/.W XL

  20. Implicit invocation ZE(.'fC1-(A ! 7/0,/.(.'-+A/+./'+A&#($'35+&.E/S(+/'%(#+$/0,/.(.'- ! 4&0&31#+'/+ "3)&(4&(0567890/&)+:%0$;''&(% " &0,3&$&'+&.E/$1'&/.+1#$%&'($')#13+-'53(+%1-+C#/1A(#+-$/,( 7/0,/.(.'- ! a/A)3(-+i(E(.';+$133C1$S+]+,#/$(A)#(j+ " /C_($'-;+,#/$(--(-;+A&-'#&C)'(A+1,,3&$1'&/.- 7/..($'/#- ! T#1A&'&/.13+0('%/A+$133 ! g#/1A$1-'+/2+(E(.'- XR

  21. Implicit invocation @)C3&-%+P+4)C-$#&C( ! 7/0,/.(.'-+#(8&-'(#+2/#+(E(.'- ! ZE(.'-+1#(+8(.(#1'(A+,)C3&-%(A+ " C5+A&22(#(.'+-/)#$(- " '/+1+$(.'#13&>(A+-5-'(0 ! ZE(.'-+1#(+C#/1A$1-' " E&1+$133C1$S+/#+,#/$(A)#( XU

  22. Implicit invocation D.E1#&1.'- ! ZE(.'+8(.(#1'/#-+A/+./'+S./J+ " 1C/)'+(E(.'+$/.-)0(#- " 2).$'&/.13+&0,1$'+/.+A&22(#(.'+$/0,/.(.'- ! g#/1A$1-'+/#A(#&.8 " $/0,/.(.'-+$1../'+01S(+1--)0,'&/.-+1C/)'+/#A(#(A+A(3&E(#5 bY

  23. Implicit invocation Z[10,3(- ! d(J-;+2&#(+131#0-+('$` ! a=7 ! DBZ- ! B1'1C1-(+-5-'(0-+'/ " (.-)#(+$/.-&-'(.$5+$/.-'#1&.'- " ([($)'(+-'/#(A+,#/$(A)#(- ! \-(#+&.'(#21$( " 4(,1#1'&/.+/2+A1'1+,#(-(.'1'&/.+2#/0+A1'1+01.18(0(.' ! Z.'(#,#&-(+1,,3&$1'&/.+&.'(#1$'&/. bX

  24. Model-View-Controller 47

  25. Model-View-Controller • A decomposition of an interactive system into three components: – A model containing the core functionality and data, – One or more views displaying information to the user, and – One or more controllers that handle user input. • A change-propagation mechanism (i.e., observer) ensures consistency between user interface and model, e.g., – If the user changes the model through the controller of one view, the other views will be updated automatically • Sometimes the need for the controller to operate in the context of a given view may mandate combining the view and the controller into one component • The division into the MVC components improves maintainability 48

  26. Implicit invocation "AE1.'18(- ! a&.&013+A(,(.A(.$5+1.A+3//-(+$/),3&.8 " 7/0,/.(.'-+A/+./'+A&#($'35+&.'(#1$'+J&'%+(1$%+/'%(# " 7/0,/.(.'-+$1.+C(+1AA(A+/#+#(0/E(A ! k&8%35+#()-1C3( " 7/0,/.(.'-+$1.+C(+#(,31$(A+J&'%+.(J(#+$/0,/.(.'- ! J&'%/)'+$%1.8&.8+'%(&#+&.'(#21$(- ! 4$131C3( " d(J+$/0,/.(.'-+$1.+-&0,35+#(8&-'(#+'%(0-(3E(- bb

  27. Implicit invocation B&-1AE1.'18(- ! F/--+/2+([($)'&/.+$/.'#/3 " e%/;+J%(.;+J%1' ! B1'1+([$%1.8( " &.2/#01'&/.+%1-+'/+C(+(.$1,-)31'(A+J&'%&.+1.+(E(.' " -%1#(A+#(,/-&'/#5 " &0,1$'+/.+ ! 83/C13+-5-'(0+,(#2/#01.$(+P+#(-/)#$(+01.18(0(.' ! ZE(.'+$/.'([' " ).,#(A&$'1C3(+-&A(+(22($'- " %/J+'/+A(C)8+-)$%+1+,#/C3(0W bc

  28. Layered Systems I#81.&>(A+%&(#1#$%5 ! Z1$%+315(#+ " ,#/E&A(-+1+-(#E&$(+'/+'%(+315(#+1C/E( " 1$'-+1-+1+$3&(.'+'/+'%(+315(#+C(3/J 7/0,/.(.'-+ ! F15(#-*+$/0,/-(A+/2+8#/),-+/2+-)C'1-S- ! "@D*+4('+/2+$31--(-+([,/-&.8+1.+"@D+315(# 7/..($'/#- ! 7/00).&$1'&/.+,#/'/$/3-6&.'(#21$(- " A(2&.(+'%(+&.'(#f315(#+&.'(#1$'&/. b!

  29. Layered Systems /778+*/%+'": C/:+*#)%+8+%+0: *'&0 D"+'"#:E+"#6'(08 b?

  30. Layered Systems =&00#6'(08 bH

  31. Layered Systems /773 /774 C):+"0::#-)"*%+'": 70&:+:%0"*0 =+0&0(#6'(08 bL

  32. Example: FTP on top of TCP/IP FTP Protocol FTP FTP TCP Protocol TCP TCP IP Protocol IP IP Ethernet Protocol Ethernet Ethernet Physical Connect 71

  33. The Unix Layered Architecture 72

  34. Layered Systems D.E1#&1.'- ! F&0&'+315(#+&.'(#1$'&/.-+'/+1A_1$(.'+315(#-+/.35 " 71.+C(+E&/31'(A+1-+2/33/J-* ! "+315(#+015+)-(+1.5+315(#+C(3/J+2/#+-(#E&$( ! a)$%+#&$%(#+&.'(#1$'&/.+J%(.+$/0,1#(A+'/+,&,(3&.( " 'J/+J15+$/00).&$1'&/. ! F15(#-+0)-'+-),,/#'+'%(+,#/'/$/3-+/2+&'-+),,(#+1.A+3/J(#+ C/).A1#&(- bR

  35. Layered Systems "AE1.'18(- ! D.$#(1-&.8+3(E(3-+/2+1C-'#1$'&/. ! F/J+$/),3&.8 " (1-5+'/+01&.'1&. " 1+315(#+/.35+&.'(#1$'-+J&'%+1+315(#+1C/E(+1.A+1+315(#+C(3/J ! a/A)31#+#()-( " 1+315(#+$1.+C(+#(,31$(A+C5+1./'%(#+1-+3/.8+1-+'%(+&.'(#21$(+&-+ ./'+E&/31'(A bU

Recommend


More recommend