Answer To: MITS4002 OBJECT-ORIENTED SOFTWARE DEVELOPMENT Research Study (5%) 50% deduction for Late Submission...
Sonu answered on May 13 2021
Shopping Cart/1. Research.docx
Design patterns described in Smith (2015) and Gamma et al (1999)
1. The formalisation relates to approaches that propose a specification of and specify design patterns (or parts thereof) and verify their implementations. Such approaches include specification languages and tools for the selection and introduction of design patterns in systems. They prevent implementations inconsistent with the intents of the patterns, which would void the benefits of these patterns. Despite their importance, few specification languages are reported in the literature. LePUS is a full-fledged logic language with a well-defined semantics. It has a compact vocabulary and can represent regularities and relations among classes, functions, and inheritance hierarchies. Similarly, Hedin rahena presents an approach based on attribute grammars for formalising design patterns, which provides attributes extensions describing conventions by declarative semantic rules. Smith et al. also proposed a formalisation of design patterns based on the ς-calculus and implemented in the SPQR tool to model and identify regularities in systems designs. However, these specification languages are seldom used in research and practice and no tooling in popular integrated development environments supports these languages.
2. Alexander introduced such architectural patterns in architecture in 1974 and, 20 years later, they made their way in software engineering thanks to the work of Gamma et al.
Design patterns introduced by Gamma et al, describe and name common design problems and their solutions in object-oriented programming.
• Meta-patterns defined by Pree [75] are reusable object-oriented designs using a domain-independent terminology and notation.
• JNI idioms [76] capture common interactions between Java and C/C++ code.
• Exception-handling idioms [77] report good practices in handling exception, in particular in Java.
• File editing patterns [80] capture developers’ file edits during source-code changes.
• Programming languages features are a form of pattern, idioms really, that solve particular programming problems, e.g., the try-with-resources idiom.
• Patterns of API usages [81] put together and make explicit systematically sets of method invocations and their parameters values for given APIs.
Finally, studying the principles of patterns could also provide evidence for or against certain practices being “patterns”. As suggested by Alexander and taken by Gamma et al. a problem and its solution must have been encountered in three different contexts, at least, before being afforded the name of “pattern”. Thus, some current practices called patterns are not “real” patterns. Conversely, solutions to common problems, even if recurring in different contexts, are not “patterns” per se. For example, the programming idiom of iterating with an Iterator through a list is common in many programming languages and, as such, is a quintessential part of the languages rather than a pattern. Moreover, some patterns exist only to overcome limitations in programming languages, e.g., the try with-resources feature in Java vs. destructors.
Shopping Cart/Checkout/.classpath
Shopping Cart/Checkout/.project
Checkout
org.eclipse.jdt.core.javabuilder
org.eclipse.jdt.core.javanature
Shopping Cart/Checkout/.settings/org.eclipse.jdt.core.prefs
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=1.8
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.8
Shopping Cart/Checkout/bin/com/checkout/CheckoutController.class
package com.checkout;
public synchronized class CheckoutController {
public void CheckoutController();
}
Shopping Cart/Checkout/bin/com/checkout/LocalPriceComputer.class
package com.checkout;
public synchronized class LocalPriceComputer {
public void LocalPriceComputer();
...