Software Documentation
Software Documentation
Documentation
Ian Sommerville
Lancaster University, UK
For large software projects, it is usually the case that documentation starts
being generated well before the development process begins. A proposal to
develop the system may be produced in response to a request for tenders by an
external client or in response to other business strategy documents. For some
types of system, a comprehensive requirements document may be produced
which defines the features required and expected behavior of the system. During
the development process itself, all sorts of different documents may be
produced – project plans, design specifications, test plans etc.
It is not possible to define a specific document set that is required – this
depends on the contract with the client for the system, the type of system
being developed and its expected lifetime, the culture and size of the company
developing the system and the development schedule that it expected.
However, we can generally say that the documentation produced falls into two
classes:
1. Process documentation These documents record the process of
development and maintenance. Plans, schedules, process quality
documents and organizational and project standards are process
documentation.
2. Product documentation This documentation describes the product
that is being developed. System documentation describes the product
from the point of view of the engineers developing and maintaining the
system; user documentation provides a product description that is
oriented towards system users.
Process documentation is produced so that the development of the system can
be managed. Product documentation is used after the system is operational but
is also essential for management of the system development. The creation of
a document, such as a system specification, may represent an important
milestone in the software development process.
Process documentation
Effective management requires the process being managed to be visible.
Because software is intangible and the software process involves apparently
similar cognitive tasks rather than obviously different physical tasks, the only
way this visibility can be achieved is through the use of process documentation.
Process documentation falls into a number of categories:
1. Plans, estimates and schedules These are documents produced by
managers which are used to predict and to control the software process.
2. Reports These are documents which report how resources were used
during the process of development.
3. Standards These are documents which set out how the process is to be
implemented. These may be developed from organizational, national or
international standards.
Product documentation
Product documentation is concerned with describing the delivered software
product. Unlike most process documentation, it has a relatively long life. It
must evolve in step with the product which it describes. Product documentation
includes user documentation which tells users how to use the software product
and system documentation which is principally intended for maintenance
engineers.
User Documentation
Users of a system are not all the same. The producer of documentation must
structure it to cater for different user tasks and different levels of expertise and
experience. It is particularly important to distinguish between end-users and
system administrators:
1. End-users use the software to assist with some task. This may be flying
an aircraft, managing insurance policies, writing a book, etc. They
want to know how the software can help them. They are not interested
in computer or administration details.
System Documentation
System documentation includes all of the documents describing the system
itself from the requirements specification to the final acceptance test plan.
Documents describing the design, implementation and testing of a system are
essential if the program is to be understood and maintained. Like user
documentation, it is important that system documentation is structured, with
overviews leading the reader into more formal and detailed descriptions of each
aspect of the system.
For large systems that are developed to a customer’s specification, the system
documentation should include:
1. The requirements document and an associated rationale.
2. A document describing the system architecture.
3. For each program in the system, a description of the architecture of
that program.
4. For each component in the system, a description of its functionality
and interfaces.
5. Program source code listings. These should be commented where the
comments should explain complex sections of code and provide a
rationale for the coding method used. If meaningful names are used and
a good, structured programming style is used, much of the code should
be self-documenting without the need for additional comments. This
information is now normally maintained electronically rather than on
paper with selected information printed on demand from readers.
6. Validation documents describing how each program is validated and how
the validation information relates to the requirements.
Document Quality
Document structure
The document structure is the way in which the material in the document is
organized into chapters and, within these chapters, into sections and sub-
sections. Document structure has a major impact on readability and usability
Submitted to CM:
CM Identifier:
Distribution: Project list
Confidentiality: Commercial
Documentation Standards
Documentation standards act as a basis for document quality assurance.
Documents produced according to appropriate standards have a consistent
appearance, structure and quality. I have already introduced the IEEE standard
for user documentation in the previous section and will discuss this standard in
more detail shortly. However, it is not only standards that focus on
documentation that are relevant. Other standards that may be used in the
documentation process are:
1. Process standards These standards define the process which should be
followed for high-quality document production.
2. Product standards These are standards which govern the documents
themselves.
3. Interchange standards It is increasingly important to exchange copies
of documents via electronic mail and to store documents in databases.
Interchange standards ensure that all electronic copies of documents are
compatible.
Standards are, by their nature, designed to cover all cases and, consequently, can
sometimes seem unnecessarily restrictive. It is therefore important that, for
each project, the appropriate standards are chosen and modified to suit that
particular project. Small projects developing systems with a relatively short
expected lifetime need different standards from large software projects where
the software may have to be maintained for 10 or more years.
Product standards
Product standards apply to all documents produced in the course of the
software development. Documents should have a consistent appearance and,
documents of the same class should have a consistent structure. Document
standards are project-specific but should be based on more general
organizational standards.
Examples of product standards which should be developed are:
1. Document identification standards As large projects typically produce
thousands of documents, each document must be uniquely identified.
For formal documents, this identifier may be the formal identifier
defined by the configuration manager. For informal documents, the
style of the document identifier should be defined by the project
manager.
2. Document structure standards As discussed in the previous section,
there is an appropriate structure for each class of document produced
during a software project. Structure standards should define this
organization. They should also specify the conventions used for page
numbering, page header and footer information, and section and sub-
section numbering.
3. Document presentation standards Document presentation standards
define a ‘house style’ for documents and they contribute significantly
to document consistency. They include the definition of fonts and
styles used in the document, the use of logos and company names, the
use of color to highlight document structure, etc.
4. Document update standards As a document is changed to reflect
changes in the system, a consistent way of indicating these changes
should be used. These might include the use of different colors of cover
to indicate a new document version and the use of change bars to
indicate modified or deleted paragraphs.
Interchange standards
Document interchange standards are important as more and more documents
are produced in electronic format as well as or instead of on paper. For
documentation that is delivered with a software system, the Adobe Portable
Document Format (PDF) is now very commonly used. However, when
documents are exchanged by the development team and drafts are circulated
within an organization these are often in the format of whatever word
processor is used (often Microsoft Word).
Assuming that the use of a standard word processor and graphical editing
system is mandated in the process standards, interchange standards define the
conventions for using these tools. The use of interchange standards, allows
documents to be transferred electronically and re-created in their original form.
Interchange standards are more than simply an agreement to use a common
version of a system for document production. Examples of interchange
standards include the use of an agreed standard macro set if a text formatting
system is used for document production or the use of a standard style sheet for
a word processor. Interchange standards may also limit the fonts and text styles
used because of differing printer and display capabilities.
Writing style
Standards and quality assessment are essential if good documentation is to be
produced but document quality is fundamentally dependent on the writer’s
ability to construct clear and concise technical prose. In short, good
documentation requires good writing.
Writing documents well is neither easy nor is it a single stage process. Written
work must be written, read, criticized and then rewritten until a satisfactory
document is produced. Technical writing is a craft rather than a science but
some broad guide-lines about how to write well are:
1. Use active rather than passive tenses It is better to say ‘You should
see a flashing cursor at the top left of the screen’ rather than ‘A
flashing cursor should appear at the top left of the screen’.
2. Use grammatically correct constructs and correct spelling To boldly
go on splitting infinitives (like this) and to misspell words (like mispell)
irritates many readers and reduces the credibility of the writer in their
eyes. Unfortunately, English spelling is not standardized and both
British and American readers are sometimes irrational in their dislike of
alternative spellings.
3. Do not use long sentences which present several different facts It is
better to use a number of shorter sentences. Each sentence can then be
assimilated on its own. The reader does not need to maintain several
pieces of information at one time to understand the complete sentence.
4. Keep paragraphs short As a general rule, no paragraph should be made
up of more than seven sentences. Our capacity for holding immediate
information is limited. In short paragraphs, all of the concepts in the
paragraph can be maintained in our short-term memory which can hold
about 7 chunks of information.
5. Don’t be verbose If you can say something in a few words do so. A
lengthy description is not necessarily more profound. Quality is more
important then quantity.
On-line documentation
It is now normal to provide some on-line documentation with delivered
software systems. This can range from simple ‘read me’ files that provide very
limited information about the software through interactive hypertext-based
help systems to a complete on-line suite of system documentation. Most
commonly, however, hypertext-based help systems are provided. These may be
based on a specialized hypertext system or may be HTML-based and rely on
web browsers for access.
The main advantage with on-line documentation is, of course, its accessibility.
It is not necessary for users to find manuals, there is no possibility of picking
up out-of-date documentation and built-in search facilities can be used to locate
information quickly.
Document Preparation
Stage 1: Creation
Approved document
Stage 3: Production
Text
Finished
document
Text + formatting
commands
Text
Text editor formatter
Document
indexes
Document
Document database
entry
Submitted system
document
document make mistakes because they are not working from the current
version of a document.
Each document should have a unique record and this can be used as a key in a
document database record. However, retrieval by other fields such as the title
and author should also be supported.
The basic problem with managing documents using a file system to store the
documents and a database management system to maintain document
information is that users have to be disciplined in the way they use they
system. They must ensure that they check out a copy of the document from
the system each time they need it rather than use a local copy on their
computer or the copy that they have printed. In practice, achieving this level
of discipline is difficult and errors are always likely to arise.
In very large projects, specialized document management systems may be used
that integrate the storage of the documents and the maintenance of document
information (Figure 5). Document management software allows related
documents to be linked, maintains records of who has checked out documents,
may support the compression and de-compression of document text and
provides indexing and information retrieval facilities so that documents can be
found. Document management systems may also include version management
facilities so that different document versions may be maintained.
References
Dix, A., Finley, J., Abowd, G. and Beale, R. 1998. Human-Computer
Interaction, 2nd ed. London: Prentice-Hall.
Garg, P. K. and Scacchi, W. 1990. ‘A hypertext system to maintain software
life-cycle document’. IEEE Software, 7 (3), 90–8.
IEEE, 1987. IEEE Standard for Software User Documentation, IEEE-Std1063-
1987. New York: Institute of Electrical and Electronics Engineers.
Further reading
The Art of Technical Documentation 2nd ed. 1998. K. Haramundanis, Woburn-
MA: Butterworth-Heinemann.
This book is primarily aimed at technical writers and prospective technical
writers and is not specific to software documentation. However, it includes
good general advice on document presentation and style.
Writing for Science and Engineering: Papers, Presentations and Reports. 2000.
H. Silyn-Roberts. Woburn-MA: Butterworth-Heinemann.
Again, this is a general book on documentation. It is more detailed than
Haramundanis’s book and includes very specific advice and checklists on
structure and style.
A Style Guide for the Computer Industry. 1996, Mountain View, CA: Sun
Microsystems.
This book includes specific information and advice on writing style for
software and hardware documents. Includes information on writing for
international audiences. It was originally developed for people involved in
writing documentation for Sun software and hardware systems.
Designing and Writing Online Documentation. 2nd ed. W. Horton, New York:
Wiley Publishers Inc.
This is based on a hypermedia model of on-line documentation as discussed in
this paper. It includes good general advice but it is rather outdated as it predates
the general use of the WWW so does not mention HTML-based systems.
Acknowledgements
This paper is a revised version of Chapter 30 from my book Software
Engineering, 4th edition, published by Addison Wesley in 1992. Thanks to the
publishers (now Pearson Education Ltd) for permission to re-publish this
material.