Test 1 Flashcards
comes into play as the standard notation used in industry for software documentation.
The Unified Modeling Language (UML)
These days, new software is usually:
object- oriented
the software is written using an abstraction called an:
object
Programming using binary numbers:
Machine code
Programming using alphanumeric symbols, or mnemonics, as short hand for machine code:
Assembly language
Assembly language is translated into machine code by a program called an:
assembler
Programming using languages (such as Fortran and COBOL) that have high- level constructs such as types, functions, loops and branches:
High-level languages
High-level languages ( and later generations of programming languages) are translated into machine code using a program called a:
compiler
Programming using cleaner high- level languages (such as Pascal Modula and Ada) that are characterized by fewer pitfalls for the programmer and more discipline in the way a program is broken down into sub-tasks and sub- systems:
Structured programming
Programming using independent modules of data and functions that correspond to concepts in the problem domain, such as Customer or ScrollBar. This modularity leads to even fewer pitfalls for the programmer and encourages the reuse of code across separate programs:
Object-oriented programming
is a description of the steps a development team should go through in order to produce a high-quality system. Also describes what should be produced ( documents diagrams, code, etc.) and what form the products should take (for example, content, icons, coding style)
methodology
Better suited to an object oriented programming style. Included Booch method:
Leading market of methodologies. Owned by IBM
So called ‘agile’ methodology, which means responsive to changes in software requirements or changes in our understanding of the problem
Object oriented methodologies
Rational unified process
Extreme programming
The methodology used in this book, __________ is a simplified one based on widely accepted theory and practice. As a result, you won’t have to learn the complexities of a full industrial methodology. Nor will you be told exactly what to do at each stagewhich will allow you to be more creative as you learn
Ripple
The notation used for illustrations , wherever possible, is the. This has become the accepted standard for software diagrams. presentation conventions mean that some lines are thicker than others and that some characters are in bold or italics. Some of these conventions are difficult to accomplish when drawing by hand:
Unified Modeling Language (UML)
What are some justifications typically given for object orientation?
Objects are easier for people to understand
Specialist can communicate better
Data and processes are not artificially separated
Code can be reused more easily
Object orientation is mature and well proven
Typically, the first rung is fixing faults ( bugs) in the code written by others:
The second rung is writing the code itself:
The third is deciding what code needs to be written:
Finally comes the role of talking to customers to discover what they need and then writing down a specification of what the finished system must be able to do.
programmer
senior programmer
designer
analyst
What is an object?
An object is a thing, an entity, a noun, something you can pick up or kick, anything you can imagine that has its own identity. Some objects are living and some aren’t
All objects have attributes: for example:
Objects also have behavior: for example:
a car has a manufacturer, a model number, a color and a pricea dog has a breed, an age, a color and a favorite toy.
a car can move from one place to another and a dog can bark
each object has certain knowledge , in the form of attributes, and it knows how to perform certain ____________ for the benefit of the rest of the program.
operations
the assignment of human characteristics to inanimate objects or animals. It’s common in object- oriented development , imagining software objects as little people.
anthropomorphism
Before we go any further, it’s important to note that we’re not trying to __________ the real world, that would be far too difficult we’re simply trying to make sure that our software is influenced by real-world concepts, so that it is easier to produce and easier to change.
simulate
is a representation of a problem domain or a proposed solution that allows us to talk, or reason, about the real thing . This allows us to increase our understanding and avoid potential pitfalls:
model
______________ refers to an object hiding its attributes behind its operations (it seals the attributes in a capsule, with operations on the edge)Hidden attributes are said to be _________.
Encapsulation
private
What are some differences between association and aggregation?
Association is a weak form of connection
Aggregation means putting objects together to make bigger objects
Aggregation form a ______________ hierarchy?
Part-whole
Decide which is association or aggregation?
Friends:
Books on a bookshelf:
Windows in an office block:
association
association
aggregation
The connections that you’ve seen on object diagrams until now are called _______. If we want to show that one object knows where the other one is, we can add an arrowhead.
Links
A ________ is a staple value in programming that comprises a sequence of characters
string
Each link can be thought of as an attribute: the label, or _______, indicates the attribute’s name.
role
The arrowhead indicates _______________, knowing where the other object is. Because there’s no arrowhead on the customer end, the implication is that String doesn’t know that it’s associated with aCustomer.
navigability
Navigable links often end up as _____________ in object-oriented programs. (is the address of an object in memory, so that we can find it when we need too)
pointers
Once objects are connected, they can ______________ , to perform more complex tasks than they could on their own.
collaborate
Objects collaborate by sending ____________ to each other
messages
look rather like object diagrams, except that the links have no direction and the object names are not underlined. Officially, there is no way to show replies, so a long-standing convention , the tadpole, has been used instead. Ideally, we would also show sequence numbers, but they’ve been omitted here, because the UML numbering scheme is rather involved
UML communication diagram
Sometimes, we can’t allow things to failwe would be rather disappointed if a fly-by-wire plane crashed because of a software fault. Ensuring success under such circumstances is a specialist area, _____________. Just to give you an idea, here’s one strategy for this is to install three computers on the plane and get them to vote on what to do nextif one computer says fly to the left, but the other two say fly to the right, the plane flies to the right
software reliability
An object-oriented program works by creating objects, connecting them together and getting them to collaborate by sending messages to each other. But who gets the ball rolling? Who creates the first object and who sends the first message? To solve this problem, all object oriented programs have an:
entry point
bad programming practice to allow more and more objects to be created by our program without taking steps to clean them up at the end of their useful life. Traditionally programmers have had to decide for themselves when the last connection to an object was about to be removed so that they could explicitly_______ or ______ the object’s memory
delete
free
( Structured languages don’t have objects , but they do have _______ , _______ and _______ that might need to be freed .) Keeping track of object lifetimes is complicated . It’s very easy for a programmer to forget about some of their unused objects, causing the program to keep growing a fault called a _______________
records
structures
arrays
memory leak