Originally posted by Marco Tedone:
Hi, which patterns are we required to know for the SCJD (apart from MVC, and
Singleton)?
Marco
Hi,
Names of Design Patterns Not Strictly Required
----------------------------------------------
There is no requirement that you know the names of any design patterns for this
project. However, if parts of your submittal conform to some of the known
design patterns, this probably will make your software easier to understand,
make your software easier to modify in the future, and so forth.
So, in a sense, while knowledge of design patterns is never explicitly stated
as a requirement, and while you are not required to mention design patterns
in any of your documentation, if you final project is to be easy to understand,
easy to modify, and has been refactored, then even if you are not a design
patterns expert, your code probably had "re-invented" one or two design patterns.
I am not sure whether I will talk about design patterns in my choices.txt file.
One reason for this is that there is always the possibility, given that I am not
a design patterns expert, that I might mis-use a design pattern term, and thus
confuse the reader, who might use the same term but in a different context. For
instance, at Amazon.com, I have read some design pattern book reviews, where
some readers state that the author gave bad examples about some design pattern
or another.
Having said the above, however, does not mean that
you should not familiarize
yourself with design patterns; in fact, there are design pattern links given
either directly or indirectly if you look at the links given at the top of this
forum.
Motivations
-----------
In Martin Fowler's book, Refactoring: Improving the Design of Existing Code,
Chapter 3 is entitled: Bad Smells in Code.
This chapter has the following subsections, which, if the particular names have
fallen into standard usage, may have definitions on the internet: Duplicated
Code; Long Method; Large Class; Long Parameter List; Divergent Change;
Shotgun Surgery; Feature Envy; Data Clumps; Primitive Obsession; Switch
Statements; Parallel Inheritance Hierarchies; Lazy Class; Speculative
Generality; Temporary Field; Message Chains; Middle Man; Inappropriate
Intimacy; Alternative Classes with Different Interfaces; Incomplete Library
Class; Data Class; Refused Bequest; Comments.
Now, if you accept the above as bad smells in your program, and you refactor
to lessen these smells, then probably, somewhere, wittingly or unwittingly,
you have applied a design pattern; but, even if you did not, your code has
been restructured with the appropriate motivation, and I would think that your
code would do fine with respect to its design.
Pattern-Related Postings
------------------------
Here are some pattern-related postings. I am not saying, however, that these
links are the most relevant. You may do better using this forum's search
facility.
Topic: Object adapter design pattern
https://coderanch.com/t/185161/java-developer-SCJD/certification/Object-adapter-design-pattern General Pattern Links
http://www.c2.com/cgi/wiki?CategoryPattern http://www.ipd.uka.de/~tichy/patterns/overview.html http://hillside.net/patterns/links.htm http://www.c2.com/cgi/wiki?WelcomeVisitors http://umbc7.umbc.edu/~tarr http://umbc7.umbc.edu/~tarr/dp/dp.html RMI Pattern Link
http://www.javaworld.com/javaworld/jw-05-1999/jw-05-networked_p.html Topic: NX: Identify pattterns used in my design
https://coderanch.com/t/184864/java-developer-SCJD/certification/NX-Identify-pattterns-used-design Topic: NX: What is the point of multiple instances? (Actually Design Choices)
https://coderanch.com/t/184807/java-developer-SCJD/certification/NX-point-multiple-instances Topic: operating mode--share code
https://coderanch.com/t/184794/java-developer-SCJD/certification/operating-mode-share-code Topic: NX: Prepare for the Essay exam (Model-View-Controller, also see Sun link when I find it)
https://coderanch.com/t/184772/java-developer-SCJD/certification/NX-Prepare-Essay-exam Topic: ValueObject patern
https://coderanch.com/t/184727/java-developer-SCJD/certification/ValueObject-patern Sun's Value Object Pattern
http://developer.java.sun.com/developer/restricted/patterns/ValueObject.html Sun's Transfer Object
http://java.sun.com/blueprints/patterns/TransferObject.html Fowler's Data Transfer Object
http://www.martinfowler.com/eaaCatalog/dataTransferObject.html Topic: Is
String[ ] Serializabel? (2-Tier verse 3-Tier)
https://coderanch.com/t/184690/java-developer-SCJD/certification/String-Serializabel Topic: Should lock methods be callable by the client (2-Tier verse 3-Tier)
https://coderanch.com/t/184224/java-developer-SCJD/certification/Should-lock-methods-callable-client Topic: NX:What is Factory Pattern? (Links to pattern discussions on web)
https://coderanch.com/t/184697/java-developer-SCJD/certification/NX-Factory-Pattern Topic: Question about DesignPattern
https://coderanch.com/t/184643/java-developer-SCJD/certification/DesignPattern Topic: How long should a GUI client wait for a locked record? (3-Tier Solution to the Rescue)
https://coderanch.com/t/184640/java-developer-SCJD/certification/long-should-GUI-client-wait Topic: NX: Exposing different interface to client (than the one provided) (2-Tier verse 3-Tier)
https://coderanch.com/t/184642/java-developer-SCJD/certification/NX-Exposing-different-interface-client Topic: how to maintain a application?
https://coderanch.com/t/184601/java-developer-SCJD/certification/maintain-application Topic: FBN: Which classes in which package?
https://coderanch.com/t/184982/java-developer-SCJD/certification/FBN-Which-classes-which-package Topic: NX: Singleton in Ken's design.
https://coderanch.com/t/185005/java-developer-SCJD/certification/NX-Singleton-Ken-design Topic: Fantastic!! My RMI surprised me!!!

(Deals with one reference
type on client & single or multiple instances of Data)
https://coderanch.com/t/184466/java-developer-SCJD/certification/Fantastic-RMI-surprised-me-confused Thanks,
Javini Javono
[ March 07, 2004: Message edited by: Javini Javono ]
[ March 07, 2004: Message edited by: Javini Javono ]