softw a re design problems you f ind a g a in a nd a g a in in re a l-world a pplic a tion development. • P a tterns a re a bout reusable designs a nd inter a ctions between objects. • The 23 G a ng of Four (GoF) patterns a re gener a lly considered the found a tion for a ll other p a tterns (G a mm a , Helm, Johnson, a nd Vlissides). 9
a cher running in its own execution thre a d, forever gr a ding—recording gr a des a s a collection of numeric a l v a lues. • A p a nel (PrinterP a nel) would like to show the gr a des a s they a re gener a ted. • Another p a nel (St a tistic a lP a nel) would like to show re a l-time st a tistics a bout the gr a des (how m a ny p a ss a nd how m a ny f a il). 37
C c1 = new C(); } public void method(X x) { x.m() B b = new B(); b.sleep(); } } public class Y { X x = new X(); B b = new B(); } public class A extends B { C c1, c2; public A() { c1 = new C(); } public void method() { D d = new D(); d.working(); } } public class X { B var = new A(); public void m() { double x – Math.sqrt(5); } }
Spring 2025 Copyright. These slides can only be used as study material for the class CSC307 at Cal Poly. They cannot be distributed or used for another purpose.