Design Issue - Which Language?
CSC 205
There are a few cases where language choice was a factor in getting a project
out the door, but they are unusual. A system can be hacked together
in almost any language. Where language choice does make a difference
is in maintenance, portability, and reuse issues.
Unlike most design issues that are technical tradeoffs, the language
choice issue is often influenced by tradition, politics and power.
As software engineers, our primary considerations are cost, schedule, and
quality. We would like to make an objective determination
based on reason and empirical evidence.
Language Categories
A common grouping for 3rd generation programming languages is:
-
Imperative Languages (Cobol, Pascal, Fortran)
-
Object-oriented Languages (Smalltalk, Eiffel, Java, Ada95,
C++, Component Pascal)
-
Functional Languages (Lisp, ML)
-
Logic Languages (Prolog)
There are 4th generation languages available on every platform. Their fundamental
characteristic is specialization; they are designed for special purposes.
A few examples:
-
Database Queries (SQL)
-
Database Applications (Access, Powerbuilder, Delphi, Focus)
-
Prototyping (Tcl, Visual Basic)
-
Windows applications (Visual Basic, Delphi)
-
WWW (html, javascript)
-
UNIX scripting (Perl)
-
Internet applications (Java, InterDev)
Selection Criteria
-
Customer Requirement - The customer may mandate the language to be used.
Often this is because they want to be able to maintain the code.
-
Programmer skill level - It may be more cost-effective to select a language
with which the programming staff is already fluent. However, an experienced
programmer should be able to learn a new language easily, and no doubt
will have to several times during his or her career.
-
Application domain - Choose a language that best suits the characteristics
of your application. For example, Cobol suits the business domain because
(why?). Fortran suits the scientific domain because (why?). Ada suits the
embedded system domain because (why?). Powerbuilder suits the database
domain because (why?).
-
Design methodology - Choose a language that matches your design methodology.
-
Quality attributes in your requirements - portability, maintainability,
reliability, reusability. Languages have a major effect on your project's
quality requirements. For example, it's quite difficult to write a portable
C program. Note: if you chose Java because you
think it's the only language that runs on multiple platforms, you need to read this
list of languages for the JVM.
-
Availability of supporting tools: Compiler (obviously), IDEs, debuggers,
linkers, editors, libraries, test coverage tools, GUI builder, etc.
-
Other factors - Standards, training, books and support are important to
many people, especially in large organizations.
Imperative Language Characteristics
-
Data structures with assignable values
-
Compile-time binding
-
Explicit storage allocation
Functional Language Characteristics
-
Computing is done with expressions
-
Programmer doesn't think about data structures nor storage issues
Object Oriented Language Characteristics
-
Abstract data types, encapsulation, data hiding
-
Inheritance
-
Polymorphism, run-time binding
Logic Languages
-
Fact and rule driven
-
Relations instead of functions