<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Qding</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Qding"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Qding"/>
	<updated>2026-06-12T08:50:50Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9716</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9716"/>
		<updated>2007-11-20T02:31:40Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This Wiki webpage is edited by Qinyi Ding and Ying Liao&lt;br /&gt;
= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP Pattern==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for ''General Responsibility Assignment Software Patterns''. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9715</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9715"/>
		<updated>2007-11-20T02:31:02Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Example of Creator Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP Pattern==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for ''General Responsibility Assignment Software Patterns''. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9714</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9714"/>
		<updated>2007-11-20T02:30:46Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Example of Creator Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP Pattern==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for ''General Responsibility Assignment Software Patterns''. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
&amp;lt;pre&amp;gt;Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9713</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9713"/>
		<updated>2007-11-20T02:30:13Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP Pattern==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for ''General Responsibility Assignment Software Patterns''. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9712</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9712"/>
		<updated>2007-11-20T02:30:00Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for ''General Responsibility Assignment Software Patterns''. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9710</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9710"/>
		<updated>2007-11-20T02:28:53Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;br&amp;gt;&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9705</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9705"/>
		<updated>2007-11-20T02:27:45Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Calculate something &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;They might change some data &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;If they don’t, what do they do? &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9704</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9704"/>
		<updated>2007-11-20T02:27:08Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;raquo;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9703</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9703"/>
		<updated>2007-11-20T02:26:11Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;&amp;lt;pre&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9700</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9700"/>
		<updated>2007-11-20T02:21:32Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;    Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9698</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9698"/>
		<updated>2007-11-20T02:20:58Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;*Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9697</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9697"/>
		<updated>2007-11-20T02:18:22Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;40%&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9695</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9695"/>
		<updated>2007-11-20T02:17:37Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9693</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9693"/>
		<updated>2007-11-20T02:17:05Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9692</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9692"/>
		<updated>2007-11-20T02:16:37Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot;&amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th align = &amp;quot;left&amp;quot;&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9690</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9690"/>
		<updated>2007-11-20T02:16:05Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table width = &amp;quot;80%&amp;quot; align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;1. Understand member data&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;2. Initiate actions in other objects&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;3. Understand related objects&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9689</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9689"/>
		<updated>2007-11-20T02:12:57Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;center&amp;quot; valign = &amp;quot;top&amp;quot; rowspan = 3&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9688</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9688"/>
		<updated>2007-11-20T02:12:09Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;center&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9687</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9687"/>
		<updated>2007-11-20T02:11:48Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9685</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9685"/>
		<updated>2007-11-20T02:11:02Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9684</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9684"/>
		<updated>2007-11-20T02:10:26Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;100%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9683</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9683"/>
		<updated>2007-11-20T02:10:00Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;left&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9682</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9682"/>
		<updated>2007-11-20T02:09:36Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table align = &amp;quot;center&amp;quot; valign = &amp;quot;top&amp;quot; width = &amp;quot;80%&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9681</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9681"/>
		<updated>2007-11-20T02:06:10Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9679</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9679"/>
		<updated>2007-11-20T02:05:24Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Knowing and Doing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&amp;lt;table&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;1. Understand member data&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;1. Perform a directly useful action &amp;lt;br&amp;gt;Change some data (Assign, calculate, create an object,…)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;2. Understand what you (an object) can do yourself &amp;lt;br&amp;gt;Calculate something &amp;lt;br&amp;gt;Create other objects&amp;lt;/td&amp;gt;&amp;gt;&amp;lt;td&amp;gt;2. Initiate actions in other objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;3. Understand related objects&amp;lt;/td&amp;gt;&amp;gt;&amp;lt;td&amp;gt;3. Control/coordinate other objects &amp;lt;br&amp;gt;They might change some data &amp;lt;br&amp;gt;If they don’t, what do they do? &amp;lt;br&amp;gt;Analogy: top brass, middle brass, and everyone else&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9677</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9677"/>
		<updated>2007-11-20T02:01:55Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP Concept */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept =&lt;br /&gt;
== Meaning of the Name ==&lt;br /&gt;
'''G'''eneral '''R'''esponsibility '''A'''ssignment '''S'''oftware '''P'''atterns&lt;br /&gt;
*General = Abstract; widely applicable&lt;br /&gt;
*Responsibility = Obligations, duties&lt;br /&gt;
*Assignment = Giving a responsibility to a module&lt;br /&gt;
*Software = Computer code&lt;br /&gt;
*Patterns = Regularities, templates, abstraction&lt;br /&gt;
&lt;br /&gt;
== Knowing and Doing ==&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9673</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9673"/>
		<updated>2007-11-20T01:59:28Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= GRASP Concept = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9672</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9672"/>
		<updated>2007-11-20T01:56:48Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;br /&gt;
*[http://class.ee.iastate.edu/berleant/home/Courses/SoftwareEngineering/CprE486fall2005/moreGRASP.pdf moreGRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9666</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9666"/>
		<updated>2007-11-20T01:51:30Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9664</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9664"/>
		<updated>2007-11-20T01:50:49Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;br /&gt;
*[http://www.ibm.com/developerworks/rational/library/may06/krebs/ Patterns in Action]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9642</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9642"/>
		<updated>2007-11-20T01:21:30Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;br /&gt;
*[http://www.mindspring.com/~mgrand/pattern_synopses2.htm Preview of Patterns in Java Volume 2]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9641</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9641"/>
		<updated>2007-11-20T01:20:56Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://books.google.com/books?id=r8i-4En_aa4C&amp;amp;printsec=frontcover Applying UML and Patterns: An Introduction to Object-Oriented Analysis and Design and the Unified Process]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;br /&gt;
*[http://www.csci.csusb.edu/dick/cs375/patterns.html Patterns and Principles]&lt;br /&gt;
*[http://www.kantega.no/kurs/kursliste/kursinfo.asp?thisId=1051865134 Design Patterns]&lt;br /&gt;
*[http://www.apwebco.com/index.html A&amp;amp;P Web Consulting]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9633</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9633"/>
		<updated>2007-11-20T01:14:37Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Comparison with Factory Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern =&lt;br /&gt;
When creation requires significant complexity, such as using recycled instances for performance reasons, conditionally creating an instance from one of a family of similar classes based upon some external property value, and so forth, you may not want to use the Creator pattern. You might want to delegate the creation to a class that is specifically designed for such a purpose. Consider the Factory pattern.&lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9628</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9628"/>
		<updated>2007-11-20T01:12:38Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Example of Creator Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
You will raise the question as who should be responsible for creating a SalesLineItem instance? Since the Sale object contains the SalesLineItem, the Sale is a good candidate for this responsibility. The sequence diagram showing this is:&lt;br /&gt;
&lt;br /&gt;
[[Image:Creator_2.jpg]]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9627</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9627"/>
		<updated>2007-11-20T01:11:18Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Example of Creator Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
[image Creator_1.jpg]&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Creator_2.jpg&amp;diff=9625</id>
		<title>File:Creator 2.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Creator_2.jpg&amp;diff=9625"/>
		<updated>2007-11-20T01:10:26Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Creator_1.jpg&amp;diff=9624</id>
		<title>File:Creator 1.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Creator_1.jpg&amp;diff=9624"/>
		<updated>2007-11-20T01:10:07Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9623</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9623"/>
		<updated>2007-11-20T01:08:58Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Example of Creator Pattern */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern =&lt;br /&gt;
Consider a simple part of a POS system as shown in the following class diagram:&lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9612</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9612"/>
		<updated>2007-11-20T01:05:51Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the GRASP pattern. The purpose of this pattern is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9564</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9564"/>
		<updated>2007-11-19T23:40:47Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern. The purpose of the process patterns is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
&lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
== Creator Pattern ==&lt;br /&gt;
The Creator pattern solves the problem: Who should be responsible for creating a new instance of some class? There are several cases to consider. Let A and B be objects. Larman offers the following.&lt;br /&gt;
&lt;br /&gt;
* B aggregates A objects. That is, there is a whole-part relationship between B and A. A objects are considered to be a part of B objects.&lt;br /&gt;
* B contains A objects. This is a stronger whole-part relationship, also called composition. With composition, the A objects have no existence outside of their relationship with B objects.&lt;br /&gt;
* B records instances of A objects.&lt;br /&gt;
* B closely uses A objects.&lt;br /&gt;
* B has the initializing data that will be pass to A when it is created (thus B is an Expert with respect to creating A).&lt;br /&gt;
&lt;br /&gt;
In these cases, B is a creator of A objects. If more than one option applies, prefer a class B which aggregates or contains class A.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9563</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9563"/>
		<updated>2007-11-19T23:38:29Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern. The purpose of the process patterns is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
*[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
*[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
*[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9562</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9562"/>
		<updated>2007-11-19T23:38:11Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern. The purpose of the process patterns is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
*Information Expert&lt;br /&gt;
*Creator&lt;br /&gt;
*Controller&lt;br /&gt;
*Low Coupling&lt;br /&gt;
*High Cohesion&lt;br /&gt;
*Polymorphism&lt;br /&gt;
*Pure Fabrication&lt;br /&gt;
*Indirection&lt;br /&gt;
*Protected Variations&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
#[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
#[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
#[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9561</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9561"/>
		<updated>2007-11-19T23:37:46Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* GRASP */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern. The purpose of the process patterns is to describe a proper way to perform tasks.&lt;br /&gt;
&lt;br /&gt;
The [http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP] pattern was first described by Craig Larman in his book: Applying UML and Patterns, 3ed. GRASP stands for General Responsibility Assignment Software Patterns. He mentioned that &amp;quot;The critical design tool for software development is a mind well educated in design principles. It is not the UML or any other technology&amp;quot;. Hence GRASP is more like a toolset to aid programmers in designing object-oriented programs.&lt;br /&gt;
&lt;br /&gt;
Examples of different patterns/principles used in GRASP are: &lt;br /&gt;
#Information Expert&lt;br /&gt;
#Creator&lt;br /&gt;
#Controller&lt;br /&gt;
#Low Coupling&lt;br /&gt;
#High Cohesion&lt;br /&gt;
#Polymorphism&lt;br /&gt;
#Pure Fabrication&lt;br /&gt;
#Indirection&lt;br /&gt;
#Protected Variations&lt;br /&gt;
All these patterns answer some software problem, and in almost every case these problems are common to most every software development project, thus they don't exist to facilitate new information but to better document and standardize old, tried-and-true programming principles in object oriented design.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
#[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
#[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
#[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9558</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9558"/>
		<updated>2007-11-19T23:30:46Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
#[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP Wikipedia]&lt;br /&gt;
#[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
#[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9557</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9557"/>
		<updated>2007-11-19T23:30:31Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;br /&gt;
#[http://en.wikipedia.org/wiki/GRASP_(Object_Oriented_Design) GRASP]&lt;br /&gt;
#[http://davidhayden.com/blog/dave/archive/2004/12/06/667.aspx Applying GRASP to Object Design]&lt;br /&gt;
#[http://web.cs.wpi.edu/~gpollice/cs4233-a05/CourseNotes/maps/class4/index.html Patterns - GRASP]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9556</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9556"/>
		<updated>2007-11-19T23:27:27Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Introduction */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
== GRASP ==&lt;br /&gt;
Most design patterns are used by programmers to better the code structure and facilitate their coding and maintenance. However, Creator Pattern belongs to a different kind of design pattern: the process pattern.&lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9555</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9555"/>
		<updated>2007-11-19T23:20:48Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Topic */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;br /&gt;
&lt;br /&gt;
= Introduction = &lt;br /&gt;
&lt;br /&gt;
= Pros and Cons = &lt;br /&gt;
&lt;br /&gt;
= Example of Creator Pattern = &lt;br /&gt;
&lt;br /&gt;
= Comparison with Factory Pattern = &lt;br /&gt;
&lt;br /&gt;
= Examples for Both Creator and Factory = &lt;br /&gt;
&lt;br /&gt;
= Reference =&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9554</id>
		<title>CSC/ECE 517 Fall 2007/wiki3 5 ld</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki3_5_ld&amp;diff=9554"/>
		<updated>2007-11-19T23:18:12Z</updated>

		<summary type="html">&lt;p&gt;Qding: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Topic =&lt;br /&gt;
''Take the Creator pattern and catalog the information on it available on the Web. Explain how it is different from the Factory pattern. Find good descriptions and good, concise, understandable examples. Tell which you consider the best to present to a class.''&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki2_5_kq&amp;diff=8193</id>
		<title>CSC/ECE 517 Fall 2007/wiki2 5 kq</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki2_5_kq&amp;diff=8193"/>
		<updated>2007-10-30T03:17:33Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
=Topic=&lt;br /&gt;
''CRC cards. Hundreds of Web pages cover CRC cards. Which explain them best? Which explain them in the context of specific languages, e.g., Ruby and Java? Which exercises can be used to teach them best, (i) interactively over the Web, (ii) to a class of students, via in-class exercises, (iii) for self-study?''&lt;br /&gt;
&lt;br /&gt;
=Definition=&lt;br /&gt;
A Class Responsibility Collaborator (CRC) model ([http://c2.com/doc/oopsla89/paper.html#cards Beck &amp;amp; Cunningham] 1989; Wilkinson 1995; [http://www.ambysoft.com/books/theObjectPrimer.html Ambler] 1995) is a collection of standard [http://en.wikipedia.org/wiki/Index_card index cards] that are used when first determining which [http://en.wikipedia.org/wiki/Class_%28computer_science%29 classes] are needed and how they will interact. &lt;br /&gt;
A CRC card always contain these sections:&lt;br /&gt;
* The class name: represents a collection of similar objects&lt;br /&gt;
* Its Super and Sub classes (if applicable)&lt;br /&gt;
* The responsibilities of the class: represents something a class knows or does&lt;br /&gt;
* The collaborator: The names of other classes with which the class will collaborate to fulfill its responsibilities. &lt;br /&gt;
* Author&lt;br /&gt;
&lt;br /&gt;
An example of CRC card is shown in figure 1.&lt;br /&gt;
&lt;br /&gt;
Figure 1:&lt;br /&gt;
&lt;br /&gt;
[[Image:CRCCard.gif]]&lt;br /&gt;
&lt;br /&gt;
=Advantages of CRC Card=&lt;br /&gt;
Using a small card keeps the complexity of the design at a minimum. It focuses the designer on the essentials of the class and prevents him from getting into its details and inner workings at a time when such detail is probably counter-productive. It also forces the designer to refrain from giving the class too many responsibilities. Because the cards are portable, they can easily be laid out on a table and re-arranged while discussing a design with other people.&lt;br /&gt;
&lt;br /&gt;
=Best Page Related to CRC ---- Example of ATM Machine=&lt;br /&gt;
[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html CRC Cards for ATM Example] is a very good page for a CRC card instantiation. We have browsed through hundreds of websites regarding to CRC card, and this page offers a clearest and most complete example using CRC card and Java implementation.&lt;br /&gt;
&lt;br /&gt;
The example the page provides is how to design an [http://en.wikipedia.org/wiki/Automated_teller_machine ATM machine]. It is absolutely not an easy task since an ATM machine has to interact with the bank and the user, and a transaction is also related to reading card and printing receipt. Moreover, the login system is essential to ensure security. In order to deal with the relationship of so many distinct classes of objects, we need the help of CRC card. &lt;br /&gt;
&lt;br /&gt;
The description on the CRC card of each class makes it clear of the responsibility and collaborate class of the specific class, and facilitate the designer to design interfaces more easily.&lt;br /&gt;
&lt;br /&gt;
Below is a complete list of the class used in an ATM machine design. You can click the link to access to the corresponding CRC card.&lt;br /&gt;
*[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#ATM Class ATM]&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;table width = 60%&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;Boundary/entity objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Controller objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Entity objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CardReader Class CardReader]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Session Class Session]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Balances Class Balances]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CashDispenser Class CashDispenser]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Transaction Class Transaction]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Card Class Card]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CustomerConsole Class CustomerConsole]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Withdrawal Class Withdrawal]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Message Class Message]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#EnvelopeAcceptor Class EnvelopeAcceptor]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Deposit Class Deposit]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Receipt Class Receipt]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Log Class Log]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Transfer Class Transfer]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Status Class Status]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#NetworkToBank Class NetworkToBank]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Inquiry Class Inquiry]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#OperatorPanel Class OperatorPanel]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#ReceiptPrinter Class ReceiptPrinter]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There are many other websites which introduce the concept and examples of CRC card. Please refer to the [http://pg.ece.ncsu.edu/mediawiki/index.php/CSC/ECE_517_Fall_2007/wiki2_5_kq#Reference Reference] of this page if you are interested.&lt;br /&gt;
&lt;br /&gt;
=Examples of CRC=&lt;br /&gt;
Since CRC card is a kind of conceptual description of classes, it uses more natual language than programming language like Java and Ruby. There are few websites which introduce the implementation of CRC card using Java, and fewer using Ruby. &lt;br /&gt;
&lt;br /&gt;
==An Example Using Java==&lt;br /&gt;
Let's take a look at a brief example from our best CRC page.&lt;br /&gt;
&lt;br /&gt;
A card reader is important to an ATM machine. The card reader is the interface to connect ATM and the card. It should tell ATM when a card is inserted, and should be able to read the information in the card. To eject card and retain card are also key functions of a card reader. &lt;br /&gt;
Therefore, the CRC card of a card reader could look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:CRCCardReader.JPG]]&lt;br /&gt;
&lt;br /&gt;
The UML diagram of the class is:&lt;br /&gt;
&lt;br /&gt;
[[Image:CardReader.JPG]]&lt;br /&gt;
&lt;br /&gt;
Hence the card reader class should have:&lt;br /&gt;
*Variables:&lt;br /&gt;
atm: The ATM to which this card reader belongs &lt;br /&gt;
 &lt;br /&gt;
*Constructor:&lt;br /&gt;
CardReader(ATM): Constructor &lt;br /&gt;
 &lt;br /&gt;
*Methods:&lt;br /&gt;
ejectCard() : Eject the card that is currently inside the reader. &lt;br /&gt;
readCard()  : Read a card that has been partially inserted into the reader &lt;br /&gt;
retainCard(): Retain the card that is currently inside the reader for action by the bank.&lt;br /&gt;
----&lt;br /&gt;
From the design above, we can easily code the class as:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/*&lt;br /&gt;
 * ATM Example system - file CardReader.java&lt;br /&gt;
 *&lt;br /&gt;
 * copyright (c) 2001 - Russell C. Bjork&lt;br /&gt;
 *&lt;br /&gt;
 */&lt;br /&gt;
 &lt;br /&gt;
package atm.physical;&lt;br /&gt;
import atm.ATM;&lt;br /&gt;
import banking.Card;&lt;br /&gt;
import simulation.Simulation;&lt;br /&gt;
&lt;br /&gt;
/** Manager for the ATM's card reader.  In a real ATM, this would &lt;br /&gt;
 *  manage a physical device; in this simulation, it uses classes &lt;br /&gt;
 *  in package simulation to simulate the device.  &lt;br /&gt;
 */&lt;br /&gt;
 &lt;br /&gt;
public class CardReader&lt;br /&gt;
{&lt;br /&gt;
    /** Constructor&lt;br /&gt;
     *&lt;br /&gt;
     *  @param atm the ATM that owns this card reader&lt;br /&gt;
     */&lt;br /&gt;
    public CardReader(ATM atm)&lt;br /&gt;
    {&lt;br /&gt;
        this.atm = atm;&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    // In a real ATM, code would be needed to sense insertion of a card into the&lt;br /&gt;
    // slot and notify the ATM - simulated in this case by a button in the GUI&lt;br /&gt;
    &lt;br /&gt;
    /** Read a card that has been partially inserted into the reader&lt;br /&gt;
     *&lt;br /&gt;
     *  @return Card object representing information on the card if read&lt;br /&gt;
     *          successfully, null if not read successfully&lt;br /&gt;
     */&lt;br /&gt;
    public Card readCard()&lt;br /&gt;
    {&lt;br /&gt;
        return Simulation.getInstance().readCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** Eject the card that is currently inside the reader.  &lt;br /&gt;
     */&lt;br /&gt;
    public void ejectCard()&lt;br /&gt;
    {&lt;br /&gt;
        Simulation.getInstance().ejectCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** Retain the card that is currently inside the reader for action by the&lt;br /&gt;
     *  bank.&lt;br /&gt;
     */&lt;br /&gt;
    public void retainCard()&lt;br /&gt;
    {&lt;br /&gt;
        Simulation.getInstance().retainCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** The ATM to which this card reader belongs&lt;br /&gt;
     */&lt;br /&gt;
    private ATM atm;    &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Teaching Exercises for CRC=&lt;br /&gt;
We read many webpages and we selected the ones below as the most suitable examples for different teaching purposes.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Teaching Interactively over the Web==&lt;br /&gt;
Of course the ATM machine example mentioned above is a very good case to study and to teach interactively over the web, since the content is detailed and each class in it is a good exercise to practice using CRC card. Besides the ATM website, another website [http://www.csc.calpoly.edu/~dbutler/tutorials/winter96/crc_b/ Object Oriented Analysis and Design using CRC Cards] is also very instructive and worth reading.&lt;br /&gt;
&lt;br /&gt;
This website is an online tutorial for how to use CRC card. The tutorial contains two stages: CRC card for analysis and CRC card for design. In the analysis stage there are two activities. The first one is to design an operation system for a technical library for an R&amp;amp;D organization. The author provides a list of possible classes for readers to choose and analyze. The second activity is to stabilize the system by consider more possible flaws of the system. The author summarize the strength of CRC card for analysis are:&lt;br /&gt;
&lt;br /&gt;
*Common Project Vocabulary&lt;br /&gt;
*Spread Domain Knowledge &lt;br /&gt;
*Making the Paradigm Shift &lt;br /&gt;
*Live Prototyping &lt;br /&gt;
*Identifying Holes in Requirements&lt;br /&gt;
&lt;br /&gt;
In the design stage the author lists some major elements for CRC design and some additional information to be added to cards in this stage: subresponsibilities, collaborating responsibilities and the data passed. There is the third activity to redo the scenarios in the analysis stage, with consideration of all design heuristics discussed. The author summarize the strength of CRC card for design are:&lt;br /&gt;
&lt;br /&gt;
*Spreading Objet-Oriented Design Expertise &lt;br /&gt;
*Design Reviews &lt;br /&gt;
*Framework for Implementation &lt;br /&gt;
*Informal Notation&lt;br /&gt;
&lt;br /&gt;
All in all, the material in this tutorial is in detail, and is suitable to be used for teaching interactively over web. The teacher could add more features and more detailed thinkings to the activites and the students could practice based on the tutorial.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Teaching in a Class==&lt;br /&gt;
&lt;br /&gt;
There is an example of how to use role playing to teach OO design through CRC cards by [http://www.cs.umu.se/~jubo/Papers/CRC_CeTUSS07.pdf Jürgen Börstler] Umeå University, Sweden. It not only works well at teaching CRC cards in class but also a good activity in class. Divide class into groups. Each member in the group presents an object (a CRC card). They can only think of their role. Their responsibilities and how they collaborate with others. Via this way, students can know how to define each CRC card by naming each role; to list what each role can do is to understand how to list responsibilities; to interact with other roles helps to figure out the collaborator of CRC cards.&lt;br /&gt;
It takes a small library system as example. There are four roles:&lt;br /&gt;
*Book: the information about the book, include title, author, register code...etc. &lt;br /&gt;
*Librarian: the role who manage books.&lt;br /&gt;
*Borrower: the one borrow books include their contact. &lt;br /&gt;
*Date: to record which day the book been borrow and return.&lt;br /&gt;
[[Image:Library diagram.JPG]]&lt;br /&gt;
&lt;br /&gt;
Each student play a role to discuss with others.&lt;br /&gt;
&lt;br /&gt;
[[Image:roles.JPG]]&lt;br /&gt;
&lt;br /&gt;
To let the activities approach, this paper has some suggestions. &lt;br /&gt;
*Carefully distinguish between classes and objects.&lt;br /&gt;
*Make scenarios as specif as possible.&lt;br /&gt;
*Start with the simplest possible meaningful scenario.&lt;br /&gt;
*Initialize the role-play properly.&lt;br /&gt;
*Be careful with object names.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Self-study==&lt;br /&gt;
Here is a good web page (http://www.agilemodeling.com/artifacts/crcModel.htm) for CRC cards self-study. It simple describes CRC cards at first and using an easy example to teach the rest. The example has only three main roles, student, seminar and professor. Because it’s an example relate to the student experience so it’s easy to understand. &lt;br /&gt;
Here's the example of one of the CRC card look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:crcCardStudent.jpg]]&lt;br /&gt;
&lt;br /&gt;
How to create CRC model? just follow these steps:&lt;br /&gt;
&lt;br /&gt;
*First, find the classes and how to name the classes. &lt;br /&gt;
*Second, find the responsibility. &lt;br /&gt;
*Third, define the collaborators to find out how each role interactive with others. &lt;br /&gt;
*Forth, move the cards around to more clearly figure out the relation of each class.&lt;br /&gt;
and then with the small increment you are able to do more practices to learn more about CRC cards. You can create a single requirement  such as user story,  business rule, or  system use case, instead of the entire collection of requirements for your system.&lt;br /&gt;
&lt;br /&gt;
I think this is an easy example for student to self-study. This the example here is related to student experience. Compare to other examples, some are hard for student to understand and some are too complicated. This one with simple case and short description will help student to learn the general idea of CRC cards.&lt;br /&gt;
&lt;br /&gt;
=Reference=&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Class-Responsibility-Collaboration_card Class Responsibility Collaboration Card]&lt;br /&gt;
* [http://www.possibility.com/epowiki/Wiki.jsp?page=CrcCards Epowiki about CRC Card]&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Class Responsibility Collaborator (CRC) Models]&lt;br /&gt;
* [http://www.csc.calpoly.edu/~dbutler/tutorials/winter96/crc_b/ CRC Cards Tutorial]&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html#cards Paper of Beck &amp;amp; Cunningham 1989]&lt;br /&gt;
* [http://www.ambysoft.com/books/theObjectPrimer.html Book of Ambler 1995]&lt;br /&gt;
* [http://www.c2.com/cgi/wiki?CrcCard CRC Card]&lt;br /&gt;
* [http://courses.knox.edu/cs292/ATMExample/index.html An Example of Object-Oriented Design: An ATM Simulation]&lt;br /&gt;
* [http://www.cs.umu.se/~jubo/Papers/CRC_CeTUSS07.pdf CRC-Cards and Roleplay Diagrams Informal Tools to Teach OO Thinking]&lt;br /&gt;
* [http://www.softstar-inc.com/Download/Intro%20to%20CRC.pdf Introduction to CRC Cards]&lt;br /&gt;
* [http://www.visual-paradigm.com/product/vpuml/demos/requirements/crccard.jsp CRC Card Diagram]&lt;br /&gt;
* [http://www.d.umn.edu/~gshute/ood/accounts/home.html CRC Cards for Bank Accounts]&lt;br /&gt;
* [http://www.cc.gatech.edu/ectropic/papers/extending_crc_cards_sept02.pdf Extending CRC Cards into a Complete Design Process]&lt;br /&gt;
* [http://coweb.cc.gatech.edu/cs2340/5583 How to Make Good CRC Cards and Scenarios]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki2_5_kq&amp;diff=8192</id>
		<title>CSC/ECE 517 Fall 2007/wiki2 5 kq</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2007/wiki2_5_kq&amp;diff=8192"/>
		<updated>2007-10-30T03:16:14Z</updated>

		<summary type="html">&lt;p&gt;Qding: /* Reference */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
=Topic=&lt;br /&gt;
''CRC cards. Hundreds of Web pages cover CRC cards. Which explain them best? Which explain them in the context of specific languages, e.g., Ruby and Java? Which exercises can be used to teach them best, (i) interactively over the Web, (ii) to a class of students, via in-class exercises, (iii) for self-study?''&lt;br /&gt;
&lt;br /&gt;
=Definition=&lt;br /&gt;
A Class Responsibility Collaborator (CRC) model ([http://c2.com/doc/oopsla89/paper.html#cards Beck &amp;amp; Cunningham] 1989; Wilkinson 1995; [http://www.ambysoft.com/books/theObjectPrimer.html Ambler] 1995) is a collection of standard [http://en.wikipedia.org/wiki/Index_card index cards] that are used when first determining which [http://en.wikipedia.org/wiki/Class_%28computer_science%29 classes] are needed and how they will interact. &lt;br /&gt;
A CRC card always contain these sections:&lt;br /&gt;
* The class name: represents a collection of similar objects&lt;br /&gt;
* Its Super and Sub classes (if applicable)&lt;br /&gt;
* The responsibilities of the class: represents something a class knows or does&lt;br /&gt;
* The collaborator: The names of other classes with which the class will collaborate to fulfill its responsibilities. &lt;br /&gt;
* Author&lt;br /&gt;
&lt;br /&gt;
An example of CRC card is shown in figure 1.&lt;br /&gt;
&lt;br /&gt;
Figure 1:&lt;br /&gt;
&lt;br /&gt;
[[Image:CRCCard.gif]]&lt;br /&gt;
&lt;br /&gt;
=Advantages of CRC Card=&lt;br /&gt;
Using a small card keeps the complexity of the design at a minimum. It focuses the designer on the essentials of the class and prevents him from getting into its details and inner workings at a time when such detail is probably counter-productive. It also forces the designer to refrain from giving the class too many responsibilities. Because the cards are portable, they can easily be laid out on a table and re-arranged while discussing a design with other people.&lt;br /&gt;
&lt;br /&gt;
=Best Page Related to CRC ---- Example of ATM Machine=&lt;br /&gt;
[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html CRC Cards for ATM Example] is a very good page for a CRC card instantiation. We have browsed through hundreds of websites regarding to CRC card, and this page offers a clearest and most complete example using CRC card and Java implementation.&lt;br /&gt;
&lt;br /&gt;
The example the page provides is how to design an [http://en.wikipedia.org/wiki/Automated_teller_machine ATM machine]. It is absolutely not an easy task since an ATM machine has to interact with the bank and the user, and a transaction is also related to reading card and printing receipt. Moreover, the login system is essential to ensure security. In order to deal with the relationship of so many distinct classes of objects, we need the help of CRC card. &lt;br /&gt;
&lt;br /&gt;
The description on the CRC card of each class makes it clear of the responsibility and collaborate class of the specific class, and facilitate the designer to design interfaces more easily.&lt;br /&gt;
&lt;br /&gt;
Below is a complete list of the class used in an ATM machine design. You can click the link to access to the corresponding CRC card.&lt;br /&gt;
*[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#ATM Class ATM]&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;table width = 60%&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;Boundary/entity objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Controller objects&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Entity objects&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CardReader Class CardReader]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Session Class Session]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Balances Class Balances]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CashDispenser Class CashDispenser]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Transaction Class Transaction]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Card Class Card]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#CustomerConsole Class CustomerConsole]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Withdrawal Class Withdrawal]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Message Class Message]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#EnvelopeAcceptor Class EnvelopeAcceptor]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Deposit Class Deposit]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Receipt Class Receipt]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Log Class Log]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Transfer Class Transfer]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Status Class Status]&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#NetworkToBank Class NetworkToBank]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#Inquiry Class Inquiry]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#OperatorPanel Class OperatorPanel]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[http://www.math-cs.gordon.edu/local/courses/cs211/ATMExample/CRCCards.html#ReceiptPrinter Class ReceiptPrinter]&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There are many other websites which introduce the concept and examples of CRC card. Please refer to the [http://pg.ece.ncsu.edu/mediawiki/index.php/CSC/ECE_517_Fall_2007/wiki2_5_kq#Reference Reference] of this page if you are interested.&lt;br /&gt;
&lt;br /&gt;
=Examples of CRC=&lt;br /&gt;
Since CRC card is a kind of conceptual description of classes, it uses more natual language than programming language like Java and Ruby. There are few websites which introduce the implementation of CRC card using Java, and fewer using Ruby. &lt;br /&gt;
&lt;br /&gt;
==An Example Using Java==&lt;br /&gt;
Let's take a look at a brief example from our best CRC page.&lt;br /&gt;
&lt;br /&gt;
A card reader is important to an ATM machine. The card reader is the interface to connect ATM and the card. It should tell ATM when a card is inserted, and should be able to read the information in the card. To eject card and retain card are also key functions of a card reader. &lt;br /&gt;
Therefore, the CRC card of a card reader could look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:CRCCardReader.JPG]]&lt;br /&gt;
&lt;br /&gt;
The UML diagram of the class is:&lt;br /&gt;
&lt;br /&gt;
[[Image:CardReader.JPG]]&lt;br /&gt;
&lt;br /&gt;
Hence the card reader class should have:&lt;br /&gt;
*Variables:&lt;br /&gt;
atm: The ATM to which this card reader belongs &lt;br /&gt;
 &lt;br /&gt;
*Constructor:&lt;br /&gt;
CardReader(ATM): Constructor &lt;br /&gt;
 &lt;br /&gt;
*Methods:&lt;br /&gt;
ejectCard() : Eject the card that is currently inside the reader. &lt;br /&gt;
readCard()  : Read a card that has been partially inserted into the reader &lt;br /&gt;
retainCard(): Retain the card that is currently inside the reader for action by the bank.&lt;br /&gt;
----&lt;br /&gt;
From the design above, we can easily code the class as:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/*&lt;br /&gt;
 * ATM Example system - file CardReader.java&lt;br /&gt;
 *&lt;br /&gt;
 * copyright (c) 2001 - Russell C. Bjork&lt;br /&gt;
 *&lt;br /&gt;
 */&lt;br /&gt;
 &lt;br /&gt;
package atm.physical;&lt;br /&gt;
import atm.ATM;&lt;br /&gt;
import banking.Card;&lt;br /&gt;
import simulation.Simulation;&lt;br /&gt;
&lt;br /&gt;
/** Manager for the ATM's card reader.  In a real ATM, this would &lt;br /&gt;
 *  manage a physical device; in this simulation, it uses classes &lt;br /&gt;
 *  in package simulation to simulate the device.  &lt;br /&gt;
 */&lt;br /&gt;
 &lt;br /&gt;
public class CardReader&lt;br /&gt;
{&lt;br /&gt;
    /** Constructor&lt;br /&gt;
     *&lt;br /&gt;
     *  @param atm the ATM that owns this card reader&lt;br /&gt;
     */&lt;br /&gt;
    public CardReader(ATM atm)&lt;br /&gt;
    {&lt;br /&gt;
        this.atm = atm;&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    // In a real ATM, code would be needed to sense insertion of a card into the&lt;br /&gt;
    // slot and notify the ATM - simulated in this case by a button in the GUI&lt;br /&gt;
    &lt;br /&gt;
    /** Read a card that has been partially inserted into the reader&lt;br /&gt;
     *&lt;br /&gt;
     *  @return Card object representing information on the card if read&lt;br /&gt;
     *          successfully, null if not read successfully&lt;br /&gt;
     */&lt;br /&gt;
    public Card readCard()&lt;br /&gt;
    {&lt;br /&gt;
        return Simulation.getInstance().readCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** Eject the card that is currently inside the reader.  &lt;br /&gt;
     */&lt;br /&gt;
    public void ejectCard()&lt;br /&gt;
    {&lt;br /&gt;
        Simulation.getInstance().ejectCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** Retain the card that is currently inside the reader for action by the&lt;br /&gt;
     *  bank.&lt;br /&gt;
     */&lt;br /&gt;
    public void retainCard()&lt;br /&gt;
    {&lt;br /&gt;
        Simulation.getInstance().retainCard();&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /** The ATM to which this card reader belongs&lt;br /&gt;
     */&lt;br /&gt;
    private ATM atm;    &lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Teaching Exercises for CRC=&lt;br /&gt;
We read many webpages and we selected the ones below as the most suitable examples for different teaching purposes.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Teaching Interactively over the Web==&lt;br /&gt;
Of course the ATM machine example mentioned above is a very good case to study and to teach interactively over the web, since the content is detailed and each class in it is a good exercise to practice using CRC card. Besides the ATM website, another website [http://www.csc.calpoly.edu/~dbutler/tutorials/winter96/crc_b/ Object Oriented Analysis and Design using CRC Cards] is also very instructive and worth reading.&lt;br /&gt;
&lt;br /&gt;
This website is an online tutorial for how to use CRC card. The tutorial contains two stages: CRC card for analysis and CRC card for design. In the analysis stage there are two activities. The first one is to design an operation system for a technical library for an R&amp;amp;D organization. The author provides a list of possible classes for readers to choose and analyze. The second activity is to stabilize the system by consider more possible flaws of the system. The author summarize the strength of CRC card for analysis are:&lt;br /&gt;
&lt;br /&gt;
*Common Project Vocabulary&lt;br /&gt;
*Spread Domain Knowledge &lt;br /&gt;
*Making the Paradigm Shift &lt;br /&gt;
*Live Prototyping &lt;br /&gt;
*Identifying Holes in Requirements&lt;br /&gt;
&lt;br /&gt;
In the design stage the author lists some major elements for CRC design and some additional information to be added to cards in this stage: subresponsibilities, collaborating responsibilities and the data passed. There is the third activity to redo the scenarios in the analysis stage, with consideration of all design heuristics discussed. The author summarize the strength of CRC card for design are:&lt;br /&gt;
&lt;br /&gt;
*Spreading Objet-Oriented Design Expertise &lt;br /&gt;
*Design Reviews &lt;br /&gt;
*Framework for Implementation &lt;br /&gt;
*Informal Notation&lt;br /&gt;
&lt;br /&gt;
All in all, the material in this tutorial is in detail, and is suitable to be used for teaching interactively over web. The teacher could add more features and more detailed thinkings to the activites and the students could practice based on the tutorial.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Teaching in a Class==&lt;br /&gt;
&lt;br /&gt;
There is an example of how to use role playing to teach OO design through CRC cards by [http://www.cs.umu.se/~jubo/Papers/CRC_CeTUSS07.pdf Jürgen Börstler] Umeå University, Sweden. It not only works well at teaching CRC cards in class but also a good activity in class. Divide class into groups. Each member in the group presents an object (a CRC card). They can only think of their role. Their responsibilities and how they collaborate with others. Via this way, students can know how to define each CRC card by naming each role; to list what each role can do is to understand how to list responsibilities; to interact with other roles helps to figure out the collaborator of CRC cards.&lt;br /&gt;
It takes a small library system as example. There are four roles:&lt;br /&gt;
*Book: the information about the book, include title, author, register code...etc. &lt;br /&gt;
*Librarian: the role who manage books.&lt;br /&gt;
*Borrower: the one borrow books include their contact. &lt;br /&gt;
*Date: to record which day the book been borrow and return.&lt;br /&gt;
[[Image:Library diagram.JPG]]&lt;br /&gt;
&lt;br /&gt;
Each student play a role to discuss with others.&lt;br /&gt;
&lt;br /&gt;
[[Image:roles.JPG]]&lt;br /&gt;
&lt;br /&gt;
To let the activities approach, this paper has some suggestions. &lt;br /&gt;
*Carefully distinguish between classes and objects.&lt;br /&gt;
*Make scenarios as specif as possible.&lt;br /&gt;
*Start with the simplest possible meaningful scenario.&lt;br /&gt;
*Initialize the role-play properly.&lt;br /&gt;
*Be careful with object names.&lt;br /&gt;
&lt;br /&gt;
==Exercise for Self-study==&lt;br /&gt;
Here is a good web page (http://www.agilemodeling.com/artifacts/crcModel.htm) for CRC cards self-study. It simple describes CRC cards at first and using an easy example to teach the rest. The example has only three main roles, student, seminar and professor. Because it’s an example relate to the student experience so it’s easy to understand. &lt;br /&gt;
Here's the example of one of the CRC card look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:crcCardStudent.jpg]]&lt;br /&gt;
&lt;br /&gt;
How to create CRC model? just follow these steps:&lt;br /&gt;
&lt;br /&gt;
*First, find the classes and how to name the classes. &lt;br /&gt;
*Second, find the responsibility. &lt;br /&gt;
*Third, define the collaborators to find out how each role interactive with others. &lt;br /&gt;
*Forth, move the cards around to more clearly figure out the relation of each class.&lt;br /&gt;
and then with the small increment you are able to do more practices to learn more about CRC cards. You can create a single requirement  such as user story,  business rule, or  system use case, instead of the entire collection of requirements for your system.&lt;br /&gt;
&lt;br /&gt;
I think this is an easy example for student to self-study. This the example here is related to student experience. Compare to other examples, some are hard for student to understand and some are too complicated. This one with simple case and short description will help student to learn the general idea of CRC cards.&lt;br /&gt;
&lt;br /&gt;
=Reference=&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Class-Responsibility-Collaboration_card Class Responsibility Collaboration Card]&lt;br /&gt;
* [http://www.possibility.com/epowiki/Wiki.jsp?page=CrcCards Epowiki about CRC Card]&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Class Responsibility Collaborator (CRC) Models]&lt;br /&gt;
* [http://www.csc.calpoly.edu/~dbutler/tutorials/winter96/crc_b/ CRC Cards Tutorial]&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html#cards Paper of Beck &amp;amp; Cunningham 1989]&lt;br /&gt;
* [http://www.ambysoft.com/books/theObjectPrimer.html Book of Ambler 1995]&lt;br /&gt;
* [http://www.c2.com/cgi/wiki?CrcCard CRC Card]&lt;br /&gt;
* [http://courses.knox.edu/cs292/ATMExample/index.html An Example of Object-Oriented Design: An ATM Simulation]&lt;br /&gt;
* [http://www.cs.umu.se/~jubo/Papers/CRC_CeTUSS07.pdf CRC-Cards and Roleplay Diagrams Informal Tools to Teach OO Thinking]&lt;br /&gt;
* [http://www.softstar-inc.com/Download/Intro%20to%20CRC.pdf Introduction to CRC Cards]&lt;br /&gt;
* [http://www.visual-paradigm.com/product/vpuml/demos/requirements/crccard.jsp CRC Card Diagram]&lt;br /&gt;
* [http://www.d.umn.edu/~gshute/ood/accounts/home.html CRC Cards for Bank Accounts]&lt;br /&gt;
* [http://www.cc.gatech.edu/ectropic/papers/extending_crc_cards_sept02.pdf Extending CRC Cards into a Complete Design Process]&lt;/div&gt;</summary>
		<author><name>Qding</name></author>
	</entry>
</feed>