Full download Object Oriented Programming_hard_man_v1.pdf Amany Fawzy Elgamal file pdf all chapter on 2024

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 54

Object Oriented

Programming_hard_man_v1.pdf Amany
Fawzy Elgamal
Visit to download the full and correct content document:
https://ebookmass.com/product/object-oriented-programming_hard_man_v1-pdf-ama
ny-fawzy-elgamal/
More products digital (pdf, epub, mobi) instant
download maybe you interests ...

Design patterns: elements of reusable object-oriented


software Gamma

https://ebookmass.com/product/design-patterns-elements-of-
reusable-object-oriented-software-gamma/

C++ Programming: An Object-Oriented Approach, 1e ISE


1st Edition Behrouz A. Forouzan

https://ebookmass.com/product/c-programming-an-object-oriented-
approach-1e-ise-1st-edition-behrouz-a-forouzan/

Clinically Oriented Anatomy Eighth North American


Edition – Ebook PDF Version

https://ebookmass.com/product/clinically-oriented-anatomy-eighth-
north-american-edition-ebook-pdf-version/

Organizational Change: An Action-Oriented Toolkit Third


Edition – Ebook PDF Version

https://ebookmass.com/product/organizational-change-an-action-
oriented-toolkit-third-edition-ebook-pdf-version/
Vessels: The Object as Container Claudia Brittenham

https://ebookmass.com/product/vessels-the-object-as-container-
claudia-brittenham/

Ethnography: A Theoretically Oriented Practice Vincenzo


Matera

https://ebookmass.com/product/ethnography-a-theoretically-
oriented-practice-vincenzo-matera/

Pseudo-Noun Incorporation and Differential Object


Marking Imke Driemel

https://ebookmass.com/product/pseudo-noun-incorporation-and-
differential-object-marking-imke-driemel/

Landscape, Materiality and Heritage: An Object


Biography Tim Edensor

https://ebookmass.com/product/landscape-materiality-and-heritage-
an-object-biography-tim-edensor/

Pseudo-Noun Incorporation and Differential Object


Marking Imke Driemel

https://ebookmass.com/product/pseudo-noun-incorporation-and-
differential-object-marking-imke-driemel-2/
Object-Oriented
Programming
Object-Oriented
Programming
By

Amany Fawzy Elgamal

Cambridge
Scholars
Publishing
Object-Oriented Programming

By Amany Fawzy Elgamal

This book first published 2024

Cambridge Scholars Publishing

Lady Stephenson Library, Newcastle upon Tyne, NE6 2PA, UK

British Library Cataloguing in Publication Data


A catalogue record for this book is available from the British Library

Copyright © 2024 by Amany Fawzy Elgamal

All rights for this book reserved. No part of this book may be reproduced,
stored in a retrieval system, or transmitted, in any form or by any means,
electronic, mechanical, photocopying, recording or otherwise, without
the prior permission of the copyright owner.

ISBN (10): 1-5275-6425-8


ISBN (13): 978-1-5275-6425-1
Table of Contents

Chapter On e............................................................................................ 1
Introduction

Chapter Tw o 6
UML

Chapter Th ree 43
Object-Oriented Programming Concepts

Chapter Fo ur 92
Inheritance

Chapter Fi ve 109
Encapsulation

Chapter Si x 124
Polymorphism

Bibliography 150
Chapter One

Introduction

In Structured Programming, a program is comprised of a set of


instructions. Small programs are generally easy to understand, but larger
ones, containing hundreds of statements, can be difficult to comprehend
unless they are divided into smaller parts. Consequently, functions and
procedures are utilized to make these programs easier to read and
understand.

The standard approach to designing software systems involves identifying


the problem, and then developing a set of functions that can accomplish
the required tasks. If these functions are too complex, they are further
broken down until they become simple enough to understand. This process
is known as functional decomposition.

Data is usually stored in a database of some sort, or it might be held in


memory as global variables.

Consider a simple example: a training center system that stores data about
students and teachers, and can record information about available courses.
This system also tracks each student and the courses in which they are
enrolled. A potential functional design for this system would involve
writing the following functions:

add_student

enter_for_exam

check_exam_marks

issue_certificate

expel_student
2 Chapter One

Furthermore, a data model is needed to store information about students,


trainers, exams, and courses, requiring the design of a database schema to
hold this data, as shown in Figure 1.1.

Figure 1.1: A database schema for a training center system

These functions depend on this data. For instance, the “add_student”


function will modify the “students” data, and the “issue_certificate”
function needs to access the student's data to know the details of the
student who needs the certificate, as well as the exam data. Figure 1.2
illustrates this data and the functions associated with it, showing the
dependency lines.

Figure 1.2: Dependency lines between functions and data.


Introduction 3

Problems arise when things become more complex, as the difficulty of


maintaining the system increases.

For example, if we find that storing a student’s date of birth as a two-digit


number to represent the year was a bad idea, the simple solution is to
change the birthdate field in the Students’ table from two to four digits for
the year number. However, this change may cause unforeseen side effects.
The data for exams, courses, and tutors all depend on the data in the
Students’ table, so we may inadvertently disable the add_student,
enter_for_exams, issue_certificate, and expel_student functions. The
"add_student" function will certainly not work as it expects the year of
birth in the form of a two-digit number.

To solve problems facing programmers, such as the one mentioned above,


the concept of Object-Oriented Programming (OOP) is adopted. Two
related issues are the absence of any restrictions on functions accessing
global data in the program, and the lack of a complete connection between
the functions and data, which is at odds with practical reality.

Consider a store management program. One piece of global data is the


variable used to store the set of items in the store. Different functions in
the program access this variable to insert a new item, display existing
items, or modify an item. In a procedural program, there are usually two
basic types of data or variables: local and global. Local data is specific to
each function, accessible and used solely within its function, making it
hidden inside this function.

In the store program, for example, the Display() function uses local data
that is completely linked to its function and cannot be modified through
any other function. If two or more functions share the same data, then this
data must be global, where any function within the program can access it.

Managing many functions and much public data (variables) can lead to an
increase in errors resulting from accessing those variables, where one of
the functions may accidentally modify one of the global variables.

Another issue is the difficulty of understanding the overall structure of the


program, as well as the challenge of modifying the program. Any change
in a global variable may require modifying all functions that use this
variable. In the store program, for example, if we want to change the
product code from a 5-digit to a 12-digit number, which requires changing
the data type from short to long, we must modify all functions that use this
4 Chapter One

variable to handle data of type long instead of short. Thus, separating data
from functions is problematic, which is inconsistent with practical reality.

In our daily life, we deal with objects such as people, cars, and so on,
which are not merely functions or data, but entities that contain attributes
and behaviors.

Attributes are the various elements associated with an object that uniquely
define it. For example, in the case of people, eye color, height, and job,
and in the case of cars, horsepower, and the number of doors, are all
attributes equivalent to data within the program.

Behavior refers to the operations that an entity performs in real life in


response to certain events. This behavior is equivalent to the function
inside the program.

Neither data alone nor functions alone are sufficient to represent objects in
real life as efficiently as desired. The fundamental idea of OOP languages
is to group the data and functions into a single unit called an object. This
way, we can effectively model real-world objects in our programs. An
object-oriented design for the training center system mentioned earlier
might involve objects for Students, Courses, and Exams, each with its own
data and functions. The Student object would have data like name and
birthdate and functions like enroll_in_course(). This encapsulation of data
and functions into objects leads to more intuitive, maintainable, and
flexible programs.

In the context of our previous store management program example, each


item in the store could be represented as an object, with attributes such as
name, price, and quantity, and methods such as restock() or sell(). The
item’s code could be changed from a 5-digit to a 12-digit number simply
by modifying the Item class, without the need to change every function
that uses this item code.

Thus, in OOP, the data and the operations that can be performed on it are
combined into a single entity, making it easier to understand how a
program works. Additionally, OOP provides several benefits such as
encapsulation, inheritance, and polymorphism that make it easier to
design, implement, and manage software systems.

A program written in the OOP style differs from a program written in a


structured style in two ways.
Introduction 5

1- Program building unit:

The program written in the structural style has a main programming unit
and a group of sub-units. The sub-units are called from the main unit. As
for the program written in the OOP style, the program unit becomes the
class, which is a template for defining objects.

2- Dealing with data:

Where in the structural program, the programmer's effort is focused on the


program code, that is, the lines of the program that handle the flow of
operations, while the view of the data is a secondary view. OOP considers
the data an important part of the program. Thus, we have a library not only
of functions, but a library of classes that contain data and functions.

In summary, while structured programming is a powerful tool for creating


simple to moderately complex programs, object-oriented programming
offers a more flexible and intuitive approach for developing complex
software systems. However, the best approach depends on the specific
needs and constraints of the project at hand.

In the rest of this book, we will cover the details of OOP concepts.
Chapter Two

UML

Unified Modeling Language (UML) is a visual modeling language that


provides developers (working in the field of analysis and design of object-
oriented systems) with diagrams and methods to visualize, create, and
document software systems, and to model the organizations that use these
systems. Note that it is not a way to build or develop systems; it will not
direct them on what to do first and what to do next. It will not tell you how
to design the system but it will help you with modeling.

Several participants participate in the development of software systems,


each with a role, for example:

- Analysts
- Designers
- Programmers
- Testers

Each of them is interested in different aspects of the system, and needs a


different level of detail. For example, the programmer needs to understand
the design of the system in order to convert it into code. The system
analyst is concerned with the behavior of the system as a whole.

UML attempts to provide a highly expressive language so that participants


can take advantage of system diagrams. It has become the approved
language for modeling software operations after it has been widely
accepted by those interested in building software. This language provides
a simplified symbolic means to express various models of software
through which it is easy for analysts, designers, programmers, and clients
to communicate with each other and pass information in a concise, unified
format. This aspect is similar to building schemes in architecture or
electrical circuit diagrams that can be understood and dealt with among
workers in the field.

Between 1989 and 1994, there were a large number of software modeling
languages, each with its own symbols and rules, and each language had
UML 7

elements similar to the elements of other languages without an integrated


language that satisfies the software needs. Until the mid-nineties, three
methodologies appeared. Each methodology has its own strengths and
these methodologies are:

1. Booch’s methodology is characterized by quality in terms of design


and implementation. Grady Booch worked extensively on the Ada
language, and had a major role in the development of Object
Oriented techniques for the language. Despite the strength of
Booch’s methodology, the symbols in it were not well accepted.
2. Object Modeling Technique (OMT), which is the best technique in
analyzing information systems with big data.
3. OOSE (Object Oriented Software Engineering) methodology is a
powerful tool as a good way to understand the behavior of an entire
system.

In 1994, Jim Rumbaugh, founder of OMT, left General Electric and joined
Booch to work for Rational Corp. The purpose of the collaboration was to
integrate their ideas and pour them into a unified methodology. Then the
creator of OOSE, Ivar Jacobson, also joined Rational, and his ideas were
included in the unified methodology called the Unified Modeling Language.

The following table shows the different versions of the language:

Table 2.1
Version Date Description
1.1 11-1997 The OMG Object Management Group (OMG™)
adopts UML 1.1 proposal.
1.3 03-2000 Contains a number of changes to the UML
metamodeling, semantics, and notation, but
should be considered a minor upgrade to the
original proposal.
1.4 09-2001 Mostly “tuning” release but not completely
upward compatible with the UML 1.3. Addition
profiles as UML extensions grouped together.
Updated visibility of features. Stick
arrowhead in
Interaction diagrams now denote asynchronous
call. Model element may now have multiple
stereotypes. Clarified collaborations.
Refined definitions of components and related
concepts. Artifacts were added to represent
physical representations of components.
8 Chapter Two

1.5 03-2003 Added actions - executable actions and


procedures, including their run-time semantics,
defined the concept of a data flow to carry data
between actions, etc.
1.4.2 01-2005 This version was accepted as ISO specification
(standard) ISO/IEC International Organization
for Standardization (ISO) and the International
Electro technical Commission (IEC).
2.0 08-2005 New diagrams: object diagrams, package
diagrams, composite structure diagrams,
interaction overview diagrams, timing diagrams,
profile diagrams. Collaboration diagrams were
renamed to communication diagrams. Activity
diagrams and sequence diagrams were enhanced.
Activities were redesigned to use a Petri-like
semantics. Edges can now be contained in
partitions. Partitions can be hierarchical and
multidimensional. Explicitly modeled object
flows are new. Classes have been extended with
internal structures and ports (composite
structures). Information flows were added. New
notation for concurrency and branching using
combined fragments. Notation and/or semantics
were updated for components, realization,
deployments of artifacts. Components can no
longer be directly deployed to nodes. Artifacts
should be deployed instead. Implementation has
been replaced by «manifest». Artifacts can now
manifest any package able element (not just
components, as before). It is now possible to
deploy to nodes with an internal structure. New
meta classes were added: connector,
collaboration use, connector end, device,
deployment specification, execution
environment, accept event action, send object
action, structural feature action, value pin,
activity final, central buffer node, data stores,
flow final, interruptible regions, loop nodes,
parameter, port, behavior, behavioral classifier,
duration, interval, time constraint, combined
fragment, creation event, destruction event,
execution event, interaction fragment,
interaction use, receive signal event, send signal
event, extension, etc. Integration between
structural and behavioral models was improved
with better support for executable models.
UML 9

2.1 04-2006 Minor revision to UML 2.0 - corrections and


consistency improvements.
2.1.1 02-2007 Minor revision to the UML 2.1
2.1.2 11-2007 Minor revision to the UML 2.1.1
2.2 02-2009 Fixed numerous minor consistency
problems and added clarifications to
UML 2.1.2
2.3 05-2010 Minor revision to the UML 2.2, clarified
associations and association classes, added final
classifier, updated component diagrams,
composite structures, actions, etc.
2.4.1 08-2011 The current version of UML, a minor revision to
UML 2.3, with a few fixes and updates to
classes; packages - added URI package attribute;
updated actions; removed creation event,
execution event, send and receive operation
events, send and receive signal events, renamed
destruction event to destruction occurrence
specification; profiles - changed stereotypes and
applied stereotypes to have upper-case first letter
- «Metaclass» and stereotype application.
2.5 FTF - Beta 11-2012 From the UML language perspective, 2.5 will be
1 a minor revision to UML 2.4.1, while they spent
many effort simplifying and reorganizing
specification documents. It seems that this time
"professors" took over researchers and industry
practitioners and instead of fixing actual UML
issues waiting to be resolved for several years,
they re-wrote UML specifications "to make
them easier to read". For example, they tried "to
reduce forward references as much as possible",
which is an obvious requirement for textbooks
but not for specifications. There will be no
separate UML 2.5 Infrastructure document, so
that the UML 2.5 specification will be a single
document. Package merge will no longer be used
within the specification itself. Four UML
compliance levels (L0, L1, L2, and L3) are to be
eliminated, as they were not useful in practice.
UML 2.5 tools will have to support complete
UML specifications. Information flows, models,
and templates will no longer be auxiliary UML
constructs.
10 Chapter Two

2.5 RTF - Beta 09-2013 Work in progress - some fixes, clarifications,


2 and explanations added to UML 2.5 FTF - Beta
1. Updated description for multiplicity and
multiplicity elements. Clarified definitions of
aggregation and composition. Finally fixed a
wrong «instantiate» dependency example for
Car Factory. Introduced notation for inherited
members with a caret "A" symbol. Clarified
feature redefinition and overloading. Moved and
rephrased definition of qualifiers. Few
clarifications and fixes for stereotypes, state
machines, activities. Protocol state machines are
now denoted using «protocol» instead of
{protocol}.
Use cases are no longer required to express some
needs of actors and to be initiated by an actor.
2.5 08-2015 UML was made simple than it was before. Rapid
functioning and the generation of more effective
models were introduced. Outdated features were
eliminated. Models, templates were eliminated
as auxiliary constructs.
2.5.1 12-2017 The current UML standards call for 13 different
types of diagrams: class, activity, object, use
case, sequence, package, state, component,
communication, composite structure, interaction
overview, timing, and deployment.

2.1 UML Diagrams


UML consists of a set of diagrams representing the parts of a system.
These diagrams are divided into two main categories:

1- Structure Diagrams, which represent the architectural


components of the system such as objects, relationships and the
dependence of system elements on each other.

They include Class Diagram, Object Diagram, Component Diagram,


Composite Structure Diagram, Package Diagram, and Deployment Diagram.

Class Diagram: A diagram shows the classes within the system and the
relationships between them.

Package Diagram: It breaks the system down into smaller and easier-to-
understand parts, and this diagram allows us to model these parts.
UML 11

Component Diagrams: to encode how the system is separated or


partitioned and how each model depends on the other. It focuses on the
actual components of the program (files, link libraries, executables, and
packages) and not on the logical or intellectual separation as in the
Package Diagrams.

2- Behavior Diagrams, which represent the dynamics of the system


and the interaction between the system’s objects and the changes that
occur in the system. They include: Use Case diagrams, Activity diagrams,
State Machine, Communication diagrams, Sequence diagrams, Timing
diagrams, and Interaction Overview diagrams.

Use Case Diagram: A description of the behavior of the system from the
user’s point of view. It describes interaction with the outside world; it is
useful during the analysis and development stages, and helps in
understanding the requirements.

Collaborative diagrams: to describe how the objects we build collaborate


and use numbers to show the sequence of messages. Collaborative
diagrams are also referred to as Communication diagrams in UML.

Sequence Diagram: describes how objects in the system interact over


time. It displays the time sequence of the objects participating in the
interaction. It consists of a vertical dimension (time) and a horizontal
dimension (different object).

State Diagrams: to show the succession of transitions between different


states of an organism during its life cycle and the events which force it to
change its state. Activity Diagram: shows a special case where most of
the states are states and actions and most transitions are triggered by the
completion of the verbs of the source states. This diagram focuses on
internal processing-driven flows.

There are different programs to create, document and track these diagrams
and generate source code for files for several languages, which facilitates
the programming process, and these programs include: Edraw UML
Diagram, With Class2000, Rational Rose, Model Maker, and you can
draw the diagrams through several web sites. You can rely on these
diagrams in Object Oriented systems, but they are not suitable for some
applications, such as Networking Projects, Web applications, and database
design.
12 Chapter Two

2.2 System modeling


When modeling any Object Oriented system, we deal with three main
parts:

• Functional Model: It is a form that depends on the user's point of


view and includes use case diagrams.
• Object Model: It is the model that is concerned with the
architecture of the system and sub-systems using objects and
attributes, operations and associations. This model includes a class
diagram.
• Dynamic Model: It is the model that is concerned with the internal
behavior of a system and includes Sequence Diagrams, Activity
Diagram, and State Diagram.

2.3 Use Case Diagram


A powerful UML tool, it is a description of a set of interactions between a
user and a system. By building a set of use case diagrams, we can describe
the system clearly and concisely. The two main components of a use case
diagram are the use case and the actor. Use case describes the interaction
between the user and the system. Use cases are usually described using
combinations of (verb / noun) - e.g.: ‘pay bills’, ‘update salary’ or ‘create
an account’. The actor is the role that the user plays in the system, whether
that user is a human or even another system that the system being modeled
will interact with.

UML provides simple notation to represent the use case and the actors
as shown in figure 2.1.

Fig. 2.1 Actor and use case


UML 13

The player will activate or initiate a particular use case. For example, if we
are developing a banking system, and we have a use case called “withdraw
cash”, we need customers to be able to withdraw that cash as shown in
figure 2.2.

Fig. 2.2 withdraw cash use case

For most systems, a single actor can interact with a range of use cases, and
more than one different actor can activate a single use case. This brings us
to an integrated use case diagram. For example, a patient calls a doctor’s
office to book an appointment for an examination as shown in figure 2.3.

Fig. 2.3 Make appointment

Therefore, the person working in the inquiries searches the appointment


book to search for an empty appointment and set the appointment.

The full schema is shown in figure 2.4. It includes use cases for the
following:

- Dealing with the patient and making or canceling an appointment


with the doctor’s schedule organizer.
- Interaction between patient and doctor requesting treatment.
- Dealing with patient to pay the account.
14 Chapter Two

Fig. 2.4 Full Shema

System Boundaries: It is a square that represents the boundaries of the


interaction between actors and the system, as it groups all use cases
together in one place.

2.3.1 Relationships in Use Case


1. Generalization: means that one is a type of another. It is
represented as follows in figure 2.5:

Fig. 2.5 Generalization

2. Includes: means that one is an evocation of another. It is


represented as shown in figure 2.6:

Fig. 2.6 Include

3. Extend: means that one is a variation of another. It is represented


as shown in figure 2.7:
UML 15

Fig. 2.7 Extend

The following figure (2.8) shows the use case diagram including these
relationships.

Fig. 2.8 use case with relationships


16 Chapter Two

The following figure (2.9) represents the use case diagram for part of
an E Learning system:

Fig 2.9 Use case for E Learning system


UML 17

2.3.2 Purpose of use case


- Use cases can provide a structured way to describe user interactions
with the system, their effectiveness in achieving this goal depend
on how well they are written and how well they capture user needs.
- Use cases are a tool for describing the functionality of the system
from the perspective of its users, but they do not provide a
complete specification of the system. There may be other
requirements or constraints that are not captured in the use cases,
such as performance requirements, security requirements, or data
constraints.
- They enable communication between customers and developers (as
long as the scheme is that easy, everyone can understand it).
- Use cases guide members of development teams through the
development processes.
- Provide a methodology for planning, and allow us to estimate the
time needed to complete the work.
- Provide the basis for system design and test.
- Finally, use cases help in inform user documentation.

Use case diagrams are used in almost all projects, they help to clarify and
show requirements and project planning. In the preliminary stage of the
project, most use cases must be defined, and during the project's progress,
there may be a need to define other use cases.

Note that each use case is associated with at least one of the actors. The
actor may be a person, another computer system, or an event for whom or
what will use the system. The actor does not represent these things, but
represents their roles. This means that when these objects interact with the
system in multiple ways, one actor does not represent them. For example,
a person who works in a customer service center by telephone and receives
orders from the customer must be represented twice as a “Support Staff”
actor and a “Sales representative” actor.
18 Chapter Two

Figure 2.10 shows an example illustrating the use case diagrams for a
library system.

Fig. 2.10 Use cases for a library System

2.4 Class diagram


This diagram represents the classes included in the system and
their relationships. It is referred to as a static diagram because it describes
the classes with their properties, methods, and their static relationships
with each other, but it does not display the interactions between them.

Class representation in the Class Diagram

The classes are represented in this diagram as shown in figure 2.11.


UML 19

Class Name
Attribute 1
Attribute 2

Operationl()
Operation2()
Ope ration3 ()

Class
+ Httrl : int
+ attrS : string
+ operation! <p : pooi) : double
# operations^)

Fig. 2.11 Class diagram

A class is represented by a rectangle divided into three parts. The first part
displays the class name (use the singular form for the class name, which
expresses a general case such as a student or book). The class name
indicates the function it performs. The second part includes all the
attributes (or properties) that characterize our class. The last part contains
all the methods or operations of the class. Figure 2.12 represents examples
of class diagrams.

Fig. 2.12 Examples of class diagram


20 Chapter Two

Scope

The following symbols are used to define the scope of attributes or


methods. These symbols show us the accessibility of the attribute or
method within the class. They are known as modifiers:

- "+" stands for public.


- "#" stands for protected.
- "-" stands for private.

Public (+): Any element of the class or outside of the class can access this
member (attributes or operation). Private (-): The member can only be
accessed within the class itself. Protected access specifier (#): The
property can only be accessed within the class or from another class that
inherits this class.

The following example shows a class diagram for a class called 'Vehicle'
that includes an integer property for the number of vehicles, a string
property to hold the vehicle type, and two integer properties for the
vehicle's maximum and minimum speed. Operations or methods of this
class include a set of functions such as a process to create the vehicle,
another to destroy it, a process to increase its speed, and another to move
backwards as shown in Figure 2.13.

#NiimberOfVehicles: integer
description of attributes
#mark : string or member data
Sspeed maximal: integer
t Sspeed courante : integer

+ CreateVehicle () description of methods =


+ DestroyVehicle 0
associate code to data
+ Start 0
+ Accelerate(rate : integer)
+ Advance ()
+ MoveBack 0

Fig. 2.13 Vehicle class

The accurate description of classes within the system is one of the most
important skills in the development of Object-Oriented Systems (OOS).
To perform this task, you can use a technique called Noun Identification
UML 21

Technique (NIT). It uses the System Requirement Specification (SRS)


document and extracts the nouns and verbs (nouns represent classes and
verbs express operations or methods). We will introduce this in the
following example.

In the library system, we can use the following SRS document to define
the classes in the system.

Books and Journals

The library contains a number of books and journals. The library can
contain several copies of the same book. Some of the books are for short­
term loans only. All other books may be borrowed by any library member
for three weeks. Members of the library can normally borrow up to six
items at a time, but members of staff may borrow up to 12 items at one
time. Only members of staff may borrow journals. The borrowing system
must keep track of borrowing duration, enforcing the rules described
above.

To define the classes in the borrowing system, we can omit the word
“library” because it is outside the scope of the system’s classes. Also, a
“short term loan” where it represents an event not a class. The word
“week” is omitted because it represents a time measuring unit, also “item”
because it is ambiguous, as it represents a book or newspaper, also “time”
and “system” because they are outside the scope of the system, as well
as the word “rules”. Thus, the classes are:

- Book
- Journal
- Copy (of book)
- Library member
- Member of staff

2.4.1. Relationships between classes


Class diagrams represent classes and the relationships with each other. The
relationships between classes take one of four types, which are illustrated
in the following figure (2.14).
22 Chapter Two

Fig. 2.14 Type of relationship

The following figure (2.15) illustrates examples of these relationships.

Fig. 2.15 Examples of relationships

2.4.1.1 Generalization/ inheritance

This relationship is used when two classes are similar with some
differences. For example, when we have a general class such as employee
and another class is a special case of this class such as engineer, this
means that the class of engineer has all the characteristics and operations
of the employee class and acquires the properties and operations that
belong to it. In this case, the employee class is the base class, while the
engineer class is the derived class. This relationship is represented in the
diagram by an arrow with a triangle head indicating the inherited class and
its beginning from the inherited class, as shown in figure 2.16.
UML 23

Derived

Fig. 2.16 Generalization

Note: The derived class contains all the properties of the base class
except the private members.

The following figure (2.17) shows a diagram of a base (main) class


representing the employee, including two derived classes representing
managers and programmers. In addition, a manager class is a main class
from which two classes are derived, namely, the project manager and
department manager.

Fig. 2.17 Employee base class with two levels of inheritance

The following example shows a main class for graphic objects and then
deriving two classes for line and circle, as shown in figure 2.18.
24 Chapter Two

Fig. 2.18 graphical class with two sub classes

The following example represents a main class of vehicles, including


derived classes representing helicopters, wagons, and ships. Note writing
the name of the main class in italics as shown in figure 2.19, which
expresses that it is an abstract class, meaning that there are no physical
objects of this class.

Fig. 2.19 Vehicle class


UML 25

A derived class can inherit more properties and operations from more than
one parent class, which is called multiple inheritance, as shown in the
following two figures (2.20 A, 2.20 B).

Fig. 2.20 A

Fig. 2.20 B

2.4.2.2 Association

The second type is called association, and it is the most common


relationship in the class diagram. The association shows the relationship
between instances of classes (objects). It is a mechanism that shows how
to communicate between objects and can be uni- or bi- express how the
two objects participate in the relationship by sending messages to each
other.

In UML, a line connecting the two classes represents this association, and
the number of objects participating in this association from both ends
[min.max] is placed at the end of the line connecting the two objects.

For example, the order class is related to the customer class, and the
multiplicity of the association denotes the number of objects that can
participate in this relationship. For example, an order object can only be
26 Chapter Two

associated with one customer, but a consumer can be associated with many
orders.

Multiplicity between classes can take one of the following figures


(2.21).

Fig. 2.21 Multiplicity between classes

The link between the two classes has a significant name, such as “drives”
in the previous figure. The numbers at both ends of the link describe the
multiplicity. In this example, we are saying, “every manager drives one
company car”, and (in the opposite direction) “every company car is
driven by one manager”. Figure 2.22 represents multiplicity between
Manager class and Staff Member class.

Figure 2.22 multiplicity between Manager class and Staff Member class

In the previous figure, we find that “each Manager manages 1 or more


Staff Member”; and (opposite), “each Staff Member is managed by one
Another random document with
no related content on Scribd:
Her one motive in drawing up this gay programme is to give him
pleasure, to chase the hopelessness out of his gaunt face; and perhaps she
overdoes the content of her tone, for he stops in his walk to send the gimlet
of his suspicious eyes through her.
“It is not to please me that you are doing it,” he says with sharp
contrariety: “mind that! I would be shot before I would influence you a
hair-breadth one way or the other in such a matter. And between you and
me”—it is the phrase which usually precedes some unflattering observation
upon his son—“if I were a young woman, and Rupert were the last man in
the world——”
But what Sir George’s course as a young woman would be his niece is
determined for once not to hear.
“Stop!” she says, laying her firm hand in prohibition upon his arm, and
speaking with an authority that for the moment seems to reverse their
relative positions. “You must not run down my husband to me!”
CHAPTER V
The hall-door reveals an unwelcome sight, though no one can deny that it is
a showy one, nor that the February sunlight is snobbish enough to treble
itself against the brazen glories of the crests on blinker and harness and
panel of the Princes’ carriage. It is a fact of disagreeable familiarity to both
uncle and niece that Féodorovna Prince will never allow any of her
acquaintance to be “not at home;” and that to be pursued to study, toilet-
table, and bed is the penalty exacted from those upon whom she chooses to
inflict her friendship. The two exchange a look.
“Do not let her come near me,” says the man, in accents of peremptory
disgust, and so flings off to his den; while Lavinia, with the matter-of-fact
unselfishness of the well-broken human female, goes smiling into the
drawing-room.
After all, it is not Féodorovna, but her mother, who comes forward
alone, and with jet-clinking apology.
“You do not mind? It is not a thing that one has any right to do? But
Féodorovna would insist on getting out, so I got out too.”
At another moment this exegesis, pregnant in its unconscious brevity of
the relations between mother and daughter, would have made Lavinia
laugh; but at the present moment a horrible suspicion freezes all tendency to
mirth.
“Féodorovna!”—looking round in bewildered apprehension. “Why,
where is she?”
The visitor is so obviously in no hurry to answer, that Miss Carew’s
question repeats itself with an imperativeness that drags out the reluctant
and frightened response.
“Well, my dear, you must not scold me, as I see you are inclined; or, if
you do, it will be grossly unjust. You know what she is when she takes a
thing into her head, and I am bound to say she does feel, and has felt, very
keen sympathy for him in his trouble; indeed, we all have.”
She pauses, weakly hoping for some expression of thanks or
reassurance; but Lavinia only stares at her with confusing sternness in her
aghast blue eyes.
“And when she heard that the things had come back—poor Bill’s things
—I believe the news came through the servants—nothing would serve her
but that she must see Sir George, to tell him how much she felt for him. You
know that she has that curious personal feeling about the whole of our
Army in South Africa, as if it belonged to her in a way, and she always
rated Bill very highly.”
Again the mother pauses, with a hope—but a fainter one than its
predecessor—that this tribute to the dead may have a mollifying effect upon
her inconveniently silent and staring young hostess.
“And where is she now?” asks Lavinia, with an accent that makes Mrs.
Prince regret her silence.
“She said she would go to Sir George’s room to wait for him; that she
was sure he would prefer that there should be no witnesses to their meeting.
Oh, do not go after her!”—with a despairing clutch at Lavinia’s raiment as
the latter makes a precipitate movement doorwards. “It is too late now; and,
after all, Sir George, poor man, is very well able to take care of himself.
And if he gives her a real good snub, why, so much the better.”
Lavinia pauses, arrested by the something of sound sense that leavens
her companion’s flurried speech, and with a dawning pity in her relenting
eyes.
“And there is something I want so much to say to you,” goes on the poor
woman, hanging on to the skirt of her advantage, though wisely
relinquishing her material grasp. “You know that I always bring my troubles
to you, and I am in a fresh one now.”
“About her, of course?”
“Oh yes; about her, of course. I suppose that but for her things would
have gone almost too smoothly with Mr. Prince and me. I suppose that the
Almighty sees we need her to prevent us getting too—too uppish.”
The adjective is scarcely on the level of refinement held before her own
eyes by the poor lady, but the tear that moistens condones it.
“What is it now?” asks the girl, with a resolute banishing to the back of
her mind of the intense annoyance and apprehension caused by the odious
intrusion of Féodorovna, and sitting down beside her guest with resolute
and patient sympathy.
“I never look at her letters,” says Mrs. Prince, lowering her voice, which
has taken on a tone of eager relief. “You know I do not; but she had left it
with her others for the butler to stamp. He had it in his hand; it was at the
top. I could not help seeing the address.”
“Not again? She has not been writing to General —— again?”
The expression of tragic repulsion in her young companion’s face seems
to get upon Mrs. Prince’s nerves.
“How you do jump down one’s throat!” she cries peevishly. “No, of
course she has not!”
“It was stupid of me to suggest it! To whom, then?”
“I really could not help seeing,” continues the elder woman, mollified
and apologetic for her own action. “It was no case of prying, but I could not
help reading, ‘Surgeon-General Jameson, Army Medical Department,
Victoria Street, Westminster.’ ”
There is a pregnant pause.
“Surgeon-General Jameson!” repeats Lavinia. “He is Director-General of
the R.A.M.C., isn’t he?”
The plumed toque that crowns Mrs. Prince’s expensive toupet gives a
dejected dip of assent.
“Does she know him?”
“Not from Adam. But that would never stop her writing to any one; no,
nor speaking to them either!”
Another pause.
“She wants to go out to South Africa as a nurse, I suppose?”
Again the tall ostrich feathers wave acquiescence. This time a spoken
elucidation follows.
“That is it, as far as we—her father and I—can make out.”
Lavinia draws a little nearer, and lays her hand upon the arm of her
visitor’s chair, while her chin lifts itself, and then falls again in a movement
of hopeless pity.
“I am very sorry indeed for you both! How does Mr. Prince take it?
What does he say?”
“You can never get much out of Mr. Prince,” replies his wife, in a tone
whose complaint is streaked with admiration for a verbal continence of
which she feels herself quite incapable. “But he did say, in his dry way, that
he should be sorry to be one of Féo’s patients.”
Lavinia smiles, but cautiously; and then, illuminated by a sudden
suggestion of valid consolation, speaks.
“You may make your mind easy, they will never accept her! She has
none of the qualifications.”
A slightly soothed expression comes over the visitor’s perturbed
features.
“It seems an odd thing to say of one’s own child, but I must say that
there is no one that I would not rather have about me than Féo when I am at
all poorly; and Mr. Prince is just the same.”
“Then do not waste time in worrying!” says Lavinia, with bracing
cheerfulness; herself encouraged by the success of her mode of reassurance.
“She will infallibly get a polite No for her answer, and you will never hear
anything more about it.”
“You are wrong there,” replies Féodorovna’s mother with rueful
shrewdness. “She is sure to tell us about it. Féo has an odd way of boasting
about things that other people would be ashamed of!”
“It is impossible to contradict this assertion, and with a passing wonder
and pity for a love cursed with such good eyes,” Lavinia repeats, in despair
of finding anything better, her already-tried-and-found-wanting anodyne.
“Well, at all events, nothing will come of it.”
“And what will her next move be? I ask you that! What will her next
move be?” inquires Mrs. Prince, in dreary triumph.
The pride of having proposed an insoluble riddle kindles a funeral torch
in each eye. The question, as the too clear-sighted parent had expected,
stumps Miss Carew, nor can any of the hysterical indelicacies which pass
through her mind as likely to illustrate Féodorovna’s future course be
decently dressed enough to be presented as hypotheses to Féodorovna’s
mother.
It is the occasion of her dilemma who cuts it short by an entrance a good
deal less aspen-like and deliberate than is usual in her case. It is, of course,
an extravagant trick of fancy, but the impression is at once conveyed to at
least one of the occupants of the drawing-room that Féodorovna has been
kicked into the room. The pink umbrage in her silly face confirms the idea
of some propelling force behind her, as does the excessive civility of the
attendant Rupert. That the deferential empressement of his manner is the
cover for an inclination towards ungovernable, vexed laughter is suspected
only by Lavinia. That some catastrophe has attended the visit of the young
paraclete is obvious to the meanest observer; but it is not until after the
Princes’ carriage has crunched and flashed away with Féodorovna reclining
in swelling silence upon the cushion, and her mother casting glances of
frightened curiosity at her infuriated profile that the details of the disaster
reach Lavinia’s ears. Not immediately even then, since before she can
besiege her cousin with terrified questions, he is summoned to his father;
and it is fully half an hour before he rejoins her in the schoolroom. She has
to wait again even then; since at her first allusion to the subject, he is seized
with such fou rire that he has to roll on his face on the old sofa before he
can master the shoulder-shaking convulsions of his uncomfortable mirth.
“What happened?” cries the girl, standing over her fiancé’s prostrate
figure in a fever of apprehension. “Oh, do get up, and stop laughing! What
is there to laugh at? You are too stupid to live!”
“I shall not live much longer!” replies the young man, rearing himself up
into a sitting posture, and presenting a subdued but suddenly grave surface
to his censor; “not if we are often to have such treats as this. I do not know
why I laugh, for I never felt less hilarious in my life.”
“You are as hysterical as a woman!” says Lavinia, with a frown.
“It is not my fault, though it is my eternal regret that I am not one!” he
retorts.
It is lucky for him that the fever of her preoccupation prevents Lavinia
from hearing this monstrous aspiration.
“Did he do anything violent?” she asks in a voice made low by dread.
“He kept his hands off her, if you mean that!” replies Rupert, showing
symptoms of a tendency to relapse into his convulsion of laughter; “but
only just! If I had not appeared in the nick of time, I would not have
answered for her life!” Then, as Lavinia keeps looking at him in smileless
tragedy, he goes on, “I was hanging about, waiting for him, as you know he
had told me that he should have something to say to me—by-the-by, he has
just been saying it, but that is another story—when I heard raised voices, or
rather a raised voice. You know that long, dull roar of his that always makes
me call on the hills to cover me!”
“Well?”
“I felt that there was no time to be lost, so I hurried in—only just in
time! I saw in his eye that the next moment he would have her by the
shoulders, and be thrusting her through the door!”
“But he did not! you stopped him?”—breathlessly.
“Yes, thank the Lord!” He pauses, and his lips begin to twitch with
nervous mirth. “I know what you thought: she was shot into the dining-
room like a projectile; but it was not as bad as that. Only moral force
propelled her.”
Lavinia brings her hands together with a sort of clap, but relief mingles
with the indignant animosity of her tone.
“What had she said? What had she done?”
Rupert shrugs his shoulders. “What is our little Féo not capable of saying
and doing?” he asks sarcastically. “But you must remember I came in only
for the bouquet of the fireworks.” After a pause, in a key of real feeling,
with no tinge of satire, “Poor old fellow! I would have done a good deal to
save him from it. I think the last straw was when she began to finger the
things—Bill’s poor little possessions—and to imply, if she did not exactly
assert, that his death was quite as great a blow to her as to the old man.”
“And when we remember what Bill’s estimate of her was!” cries
Lavinia, reddening with indignation. “Oh, if we could but tell her of his
saying that he should have to put barbed wire round himself whenever he
went outside the gate to prevent her getting at him!”
They both laugh—the little rueful laugh with which the jests of the
departed are recalled.
“After they had gone,” pursues Rupert, “when he sent for me, I found
him still in a terrible state. I have never seen him in such an ungovernable
fury. Not with me—to me he was like a pet lamb.”
Again they both laugh a little grimly, conscious of the extreme audacity
of the comparison.
“You will not believe it,” says Rupert, half humorously, and yet with a
quiver of emotion on his sensitive face, “but he actually thanked me for
coming to his rescue! Me, if you please, moi qui vous parle!”
“ ‘It is an ill wind that blows nobody any good,’ ” replies Lavinia,
cheerfully, but with conscious effort, and with the feeling, often before
experienced, that a good deal of physical fatigue attends living over the
crater of Etna.”
“He calmed down after a while. I spent all the bad language I was master
of, and wished it had been more, upon the whole Prince clan; and that did
him good, so much so that he was able by-and-by to talk of something
else.”
“Of what else?” The question is an idle one, and Miss Carew is
conscious of it.
So is Rupert. “I expect that you know,” he answers quietly.
Never until to-day has Lavinia felt gêne in the presence of her lifelong
playfellow and comrade, and that she should do so now strikes her as so
monstrous an anomaly that it must be treated drastically.
“About our marriage, do you mean?” she inquires, taking the bull by the
horns, and looking him full in the face.
“Yes.”
“H’m!” Struggle as she may, her lips can produce nothing more
forthcoming than the monosyllable.
“He asked me whether the engagement still existed?”
“So he did me.”
“Whether we had any intention of fulfilling it?”
“Ditto!”
“Whether it was essential to our happiness?”
“Essential to our happiness,” repeats she, as if it were a dictation lesson.
“He said that we were all that he had left in the world.”
Lavinia nods, speech seeming difficult. Is Rupert going to recapitulate,
in his father’s unsparing Saxon, the reason for that father’s anxiety to see
them wed? She waits in rosy dread. It is a moment or two before relief
comes.
“He ended by adjuring me not to marry you in order to please him. I
think I was able to reassure him as to that not being my primary
inducement.”
They know each other far too well for her not to be instantly aware of an
alteration in his voice—not to have an instant’s flashed certainty that the
playmate, the comrade, the brother-cousin, is gone, and that the lover stands
full-fledged in their stead before her. Whether the conviction causes her
pain or pleasure, she could not tell you. She only feels as she has done in
the morning, but a thousandfold more so, that the situation is
overpoweringly odd.
“Well!” she says slowly, afraid to look away from him, lest she should
never again be able to lift her stupidly rebellious eyes to his.
“I suppose it was bound to come, some time or other?”
It is not an effusive mode of acquiescence.
“Have you nothing more to say about it?”
If she had had any doubt as to the final banishment out of her life of the
boy-comrade, the method of this question, and a certain reproachful
enterprise divined in the asker’s eye, would have banished it.
“What more is there to say?” she returns in troubled haste. “What more
than we have been saying all our lives, in a way?” Then, with a sudden
impulsive throwing herself on his judgment and mercy, “I suppose we do
feel all right, don’t we?”
CHAPTER VI

“I love nothing so well as you!


Is not that strange?”

Rupert is “all right.” Of that there can be no question. It turns out now
that he has been “all right” for as long as he can remember. The discovery
that it is only his delicacy and self-command that have hitherto hindered his
manifesting his “all-rightness” practically, fills Lavinia with such admiring
gratitude as makes her almost certain that she is “all right” too. She has no
female friend with whom to compare notes, nor would she do so if she had,
her one intimate, Mrs. Darcy, being very far from belonging to that not
innumerous band of matrons who enjoy revealing the secrets of their own
prison-house to a selected few. Lavinia has to work out her problem for
herself. Not betrothed only now, but going to be married, with a tray of
engagement-rings crawling down from London by the South-Eastern for
approval, with a disinterring by Sir George, from his dead wife’s presses, of
wedding laces——
Lavinia wishes that Rupert did not take quite so great an interest in the
latter, and did not know quite so much about Point de Venise, Point de
Flanders, and Point d’Angleterre—; with interesting and illumining
comparison of past feelings, and with a respectable modicum of kisses. If
the candour of her nature, and the knowledge of how perfectly useless it is
to lie to a person who knows her so through and throughly as Rupert,
compel her to acknowledge that these latter do not cause her any particular
elation, she is able truly to answer him that she does not dislike them so
much as to forbid a frugal repetition. Once or twice, touched and stung to
generosity by his unselfish refraining from even the dole of allowed
endearments, she takes the initiative; and at other times consoles him for
her want of fervour by assuring him, with emphatic words, and the crystal
clearness of her kind, cold eyes, that she is “not that sort.”
She is wondering to-day whether, when she left him five minutes ago at
the lych-gate, he did not look as if he were getting a little tired of the
explanation. It ought to be thoroughly satisfactory to him, for, after all, you
can’t give more than you have; but she has never been in the habit of
crossing or discontenting her men, and to be found not up to the expected
mark in the matter of endearment vexes her as much as to be convicted of
neglecting their buttons or slurring their dinner.
It is a week since Miss Carew has paid the visit, usually a daily or bi-
daily one, to the Rectory. The unwonted absence for three days from her
monopolizing husband and boisterous brood of Mrs. Darcy, partly accounts
for this omission; and not even to herself does Lavinia own that she is in a
less hurry than usual to greet her returned ally. Rupert is never in any great
hurry to see Susan, and has gracefully declined to accompany his fiancée on
her present errand of announcement.
“You shall tell me about it when you come back. I shall like to hear how
her face lights up when she hears the good news,” he says with a half-
sarcastic smile; then, seeing the girl wince a little at this hitting of a nail all
too soundly on the head, he laughs it off pleasantly. “Tell her, as you told
me, that it was ‘bound to come.’ ”
“Mine was certainly a very original way of accepting an offer,” replies
Lavinia, slightly flushing. Never since the decisive day has she felt quite at
her ease with Rupert, and so goes off laughing too; but the laugh disappears
as soon as she is out of sight.
The day is full of hard spring light, which shows up, among other
revelations, the emptiness of the Rectory drawing-room, with its usual
refined litter of needlework and open books, and the figures of the children
in the chicken-yard, whither a spirit of search and inquiry leads Lavinia’s
feet. From her friend’s young family she hears that their mother has gone up
the village to bandage a cut hand; but it is with difficulty that this
information is extracted from them, so vociferously preoccupied are they
with their own affairs. Gloriously happy, covered with mud, hatless,
dishevelled, blissful, speaking all at once, they reveal to her, in shouting
unison, the solid grounds for their elation—nurse gone off at a moment’s
notice, governess’s return indefinitely postponed, mother busy, father
absent!
“Oh, Lavy, we are having such a good time, particularly at tea! Serena
has tea with us.”
Serena’s age is two years, and detractors say that her Christian name
must have been bestowed with an ironical intention.
“And no doubt you spoil her very much?”
“No,” thoughtfully; “we do not spoil her. We only try to make her as
naughty as we can.”
Their visitor smiles at the nice distinction, and weakly shrinking from
pointing out the immorality of the course of conduct described, judiciously
changes the topic by asking why the flag on the henhouse is flying half-
mast high.
She is at once informed by grave voices that there has been a court-
martial, and that General Forestier Walker is to have his neck wrung for
breaking his eggs.
“General —— was the presiding judge,” says Phillida, pointing to a
peaceable-looking white Dorking matron, making the gravel fly behind her
with the backward sweep of her scratching feet. “He is Féo Prince’s
general. She told me, last time she was here, that she had asked him to
marry her.”
“As if he would be thinking of such tommy-rot as marriage now!” cries
Chris, more struck, apparently, by the ill-timing of the overture than its
indelicacy.
“Miss Brine was shocked,” says Phillida, thoughtfully. “She said that it
was putting the cart before the horse, and that Féo ought to have waited for
him to speak first.”
“But if he wouldn’t?” cries little Daphne, swinging Lavinia’s hand,
which she has annexed, to and fro, and staring up with the puzzled violet of
her round eyes.
They all laugh.
“That is unanswerable,” says Lavinia, blushing even before the children
at this new instance of Féodorovna’s monstrous candour; adding, in a not
particularly elate key, as her glance takes in a recherché object nearing their
little group across the white grass of the still wintry glebe, “Why, here is
Féo!”
“They told me your mother was out,” says the visitor, as if this were a
sufficient explanation for her appearance.
The children greet her with the hospitable warmth which nature and
training dictate towards any guest, qua guest, but without the exuberant,
confident joy with which they always receive Lavinia. However, they repeat
the tale of General Forestier Walker’s crime and fate, and add, as peculiarly
interesting to their hearer, the name of the presiding judge.
Féodorovna listens with an absence of mind and eye which she does not
attempt to disguise.
“I was coming on to you,” she says, addressing Lavinia, and turning
away with an expression of boredom from her polite little hosts. “I should
have asked you to give me luncheon, but since I find you here, it does as
well.”
Neither in voice nor manner is there any trace of the resentment that
Miss Carew is guiltily feeling. Féodorovna never resents. Too well with
herself often to perceive a slight, and too self-centred to remember it,
Lavinia realizes with relief that all recollection of the peril Miss Prince’s
shoulders had run at Sir George’s all-but ejecting hands has slidden from
that fair creature’s memory.
“I went to London yesterday,” she says, turning her back upon the cocks
and hens, and their young patrons, as unworthy to be her audience.
“We saw you drive past,” says Phillida, innocently; “you went by the
11.30 train. We were not looking out for you; we were watching Lavy and
Rupert. From mother’s bedroom we can see right into their garden.”
“Can you, indeed?” interposes the voice of Mrs. Darcy, who has come
upon the little group unperceived by the short cut from the village. “I am
glad you told me, as I shall try for the future to find some better
employment for your eyes.”
Her voice is quite quiet, and not in the least raised; but the children know
that she is annoyed, and so does Lavinia, who, with a flushed cheek and an
inward spasm of misgiving, is trying to reconstruct her own and her fiancé’s
reciprocal attitudes at eleven o’clock of yesterday’s forenoon. To them all
for once Féodorovna’s unconscious and preoccupied egotism brings relief.
“I was telling Lavinia that I went to London yesterday.”
“For the day? to buy chiffons? I suppose I shall have to reclothe this
ragged regiment soon,” looking round ruefully at her still somewhat
abashed offspring, and avoiding her friend’s eye.
“Chiffons! oh no!” a little contemptuously. “I went up to see the
Director-General of the Army Medical Department.”
“Indeed! Is he a friend of yours?”
“Oh dear no; I went on business.”
“To offer your services as a nurse, I suppose?” replies Mrs. Darcy, as if
suggesting an amusing absurdity, and unable to refrain from stealing a look
at Lavinia, while her own face sparkles with mischievous mirth.
“Exactly,” replies Féodorovna, with her baffling literalness. “I sent up
my name, and he saw me almost at once.” She pauses.
“And you made your proposal?”
“Yes.”
“He accepted it?”
Féodorovna’s pale eyes have been meeting those of her interlocutor.
They continue to do so, without any shade of confusion or mortification.
“No; he refused it point-blank.”
As any possible comment must take the form of an admiring ejaculation
addressed to the medical officer in question, Susan bites her lips to ensure
her own silence.
“He put me through a perfect catechism of questions,” continues Miss
Prince, with perfect equanimity. “Had I had any professional training?”
“You haven’t, have you?”
“I answered that I hadn’t, but that I could very easily acquire some.”
“And he?”
“Oh, he smiled, and asked me if I had any natural aptitude.”
“Yes?”
“I answered, ‘None, but that no doubt it would come.’ ”
The corners of Mrs. Darcy’s mouth have got so entirely beyond her
control that she can only turn one imploring appeal for help to Lavinia, who
advances to the rescue.
“And then?” she asks, with praiseworthy gravity.
“Oh, then he shrugged his shoulders and answered drily, ‘I have had
three thousand applications from ladies, from duchesses to washerwomen,
which I have been obliged to refuse. I am afraid that I must make yours the
three thousand and first;’ and so he bowed me out.”
She ends, her pink self-complacency unimpaired, and both the other
women look at her in a wonder not untouched with admiration. Neither of
them succeeds in making vocal any expression of regret.
“It is one more instance of the red tapeism that reigns in every
department of our military administration,” says Miss Prince, not missing
the lacking sympathy, and with an accent of melancholy superiority. “Next
time I shall know better than to ask for any official recognition.” After a
slight pause, “It is a bitter disappointment, of course; more acute to me
naturally than it could be to any one else.”
With this not obscure intimation of the end she had had in view in
tendering her services to the troops in South Africa, Féodorovna departs.
The two depositaries of her confidence look at each other with faces of
unbridled mirth as soon as her long back is turned; but there is more of
humorous geniality and less of impartial disgust in the matron’s than the
maid’s.
“Poor thing! I wonder what it feels like to be so great a fool as that!”
said Mrs. Darcy, with a sort of lenient curiosity. “I declare that I should like
to try for the hundredth part of a minute!”
“She meant to nurse him!” ejaculates Lavinia, with a pregnant smile.
“Poor man! If he knew what he had escaped!”
“And now, what next?” asks Susan, spreading out her delicate,
hardworking hands, and shaking her head.
“ ‘What next?’ as the tadpole said when his tail dropped off!” cries
Daphne, pertly—a remark which, calling their parent’s attention to the
edified and cock-eared interest of her innocents, leads to their instant
dispersal and flight over the place towards the pre-luncheon wash-pot,
which they hoped to have indefinitely postponed. When they are out of
sight and earshot.
“You came to tell me something?” Mrs. Darcy says, with an entire
change of tone. “Though I am not in the habit of watching Rupert and Lavy
from an upper chamber, like those graceless brats, I know what it is.”
“Then I may spare myself the trouble of telling you,” answers the girl, in
a key of constrained and artificial playfulness.
Her friend’s kind eyes, worn, yet with the look of a deep, serene
contentment underlying their surface fatigue, look at her with a
compassionate interrogation.
“Are you doing it to please yourself?” she asks in a low voice, yet not
hesitatingly.
“Whom else?”
“It is a motive that has so very seldom guided you,” replies the elder
woman, with an enveloping look of motherly solicitude. “And in this kind
of case it is the only one that is of the least value; it is the one occasion in
life in which it is one’s bounden duty to be absolutely selfish!”
“Were you absolutely selfish when you married Mr. Darcy?” asks
Lavinia, carrying the war into the enemy’s quarters, and with an apposite
recalling of all the sacrifices that her friend—once a very smart London girl
—is rumoured by the neighbourhood to have been called upon to make by
her choice.
“Absolutely,” replies Susan, with the stoutness of the most unmistakable
truth. “Everybody belonging to me cried, and said they could not see what I
saw in Richard; but I saw what I saw in him, and I knew that that was all
that mattered.”
“Perhaps I see what I see in Rupert,” replies Lavinia, plucking up her
spirit, and detecting a joint in her companion’s harness, though her own
voice is not assured.
“If you do, of course it is all right,” rejoins the other, unelastically.
Lavinia’s head would like to droop, so oppressive is the sense of the cold
doubt infiltrated into her own acquiescent serenity; but she forces it to hold
itself up against its will.
“He is quite aware that we have your disapproval,” she says with a
dignity that is native to her; “so much so that he advised me to tell you it
was ‘bound to come.’ ”
Mrs. Darcy looks at her sadly; but without either apology or
contradiction.
“That is just what I do not feel.”
“You have always done him scant justice!” cries the girl, stung into
hotter partisanship by the chill whisper of a traitor within her own camp.
“After all, it is I, not you, that am to marry him.”
“Yes, it is you;” in downcast assent.
“When you have praised him it has always been in some damning way,”
pursues Lavinia, breaking more and more into flame—“saying what a good
judge of lace he is, and how well he mended your Bow teapot!”
“So he did.”
“How would you like it, if, when some one asked my opinion of Mr.
Darcy as a parish priest, I answered that he did not make bad cabbage-
nets?”
Susan smiles reluctantly. “Do not let us quarrel,” she says. “As long as I
supply you with eggs, it would be inconvenient to you; and, as for me, why,
I might break another teapot!”
* * * * *
“Well, how did she take it?” asks Rupert, who has apparently been
waiting the whole time of his betrothed’s absence in contented smoking and
musing under the immemorial yews of the churchyard.
“She asked me whether I am marrying you to please myself?” replies
Lavinia, lifting eyes in which he notes a trouble that had not clouded them
when he parted from her, in an almost doglike wistfulness of appeal to his,
“Am I, Rupert?”
“Our friends ask us very indelicate questions,” he answers, turning away.
* * * * *
A day or two later Lavinia has a casual meeting with Mrs. Prince in the
road.
“Whom do you think she has been writing to now?” asks Féodorovna’s
parent, leaning over the side of the victoria, and whispering loudly. “The
Officer Commanding Cavalry Depôt, Canterbury! What can she have to say
to him?”
CHAPTER VII
Spring has come; even according to the Almanack, which is later in its
sober estimate of the seasons, and also truer than the sanguine poets. But as
to April 23 there can be no difference of opinion between prose and verse.
To the curious observer of the English spring it may seem every year harder
to decide whether the frank brutality of March, the crocodile tears of April,
or the infinite treacheries of May, are the more trying to the strained planks
of the British constitution? Through this course of tests, unescapable,
except by flight, the village of Campion is passing like its neighbours. But
in the Egypt of the east wind, there has been revealed, on this 23rd of April,
the existence of a Goshen.
“ ‘Don’t cast a clout till May is out!’ ” says Lavinia, taking off her jacket
and giving it to Rupert to carry. “It is impossible to act up to that axiom to-
day!”
The action, in its matter-of-factness, might be taken to prove that Lavinia
is still in that brief and tantalizing portion of a woman’s existence, when
tyrant man is a willing packhorse; though, in Rupert’s case, the indication is
worth nothing. In point of fact, they are still unwed. This is due to no
jibbing on the part of Miss Carew. The engagement-ring has not crawled
back to London by a South-Eastern express, the yellowed Mechlin has not
returned to its camphored privacy, the cousins are still “going to be
married.” The delay has come from the person whose feverish eagerness
had at first seemed to brook no moment of waiting.
“Of course, I can’t expect any one else to share the feeling,” Sir George
has said to the bridegroom-elect, when he has innocently alluded to the
marriage as an event in the near future; “but I cannot help thinking there is
some indecency in feasting and merry-making when the eldest son of the
house is scarcely cold in his grave!”
Rupert is used to the sharp turnings and breakneck hills of his father’s
utterances, but at this he cannot help looking a little blank.
“I thought it was your wish, sir,” he answers.
“If it is only because I wish it that you are marrying Lavinia, as I have
already told you, I think the whole thing had better be off!” retorts Sir
George, with another surprising caper of the temper; adding, in a voice of
wounded protest that thinks it is temperate and patient, “I ask for a decent
delay between an open grave and a carouse, and you fly off at once into a
passion!”
“Bid the Rectory light its bonfire—the bonfire it is getting ready against
the Relief of Mafeking!” says Rupert, returning to the drawing-room, where
Lavinia is sitting arduously working out a new patience—it is after dinner.
“Tell Susan to deck her countenance in its brightest smiles. The wedding is
indefinitely postponed!”
“Is it?” she answers, looking up from her cards. “You do not say so!”
Then, afraid that the colourless ejaculation is not quite up to the mark, she
adds, in a tone where his too-sharp ear detects rather the wish to cheer him
than any personal annoyance. “But it will be on again to-morrow. He is
quite as keen about it as you—or I.”
Once again that too officious ear tells him of the almost imperceptible
hiatus that parts the pronouns.
“Come and help me!” she adds, divining in him some little jarred
sensitiveness; and, resting the tranquil friendliness of her eyes upon him,
while her hand pulls him down to a seat beside her. “I can’t recollect
whether this is red upon black, or if one follows suit.”
That was weeks ago, and Lavinia’s prophecy is fulfilled. On this 23rd of
April she has the knowledge that only five weeks of maidenhood remain to
her. No sooner had Sir George paid his ill-tempered tribute to his dead son,
and frightened and snubbed the survivor into a hurt and passive silence
upon the subject nearest to both their hearts, than the increased irritability of
his temper and the misery of his look tells his two souffre-douleurs that he
has repented of that delay in carrying out his passionately desired project,
for which he has to thank himself.
“One more such evening, and I shall think that there is a good deal to be
said in praise of parricide!” says Rupert, in groaning relief after the strain of
an evening of more than ordinary gibing insult on the one side, and hardly
maintained self-restraint on the other. “Of course I know what it means.
Poor old chap! He would give the world to climb down; and he would die
sooner than do it!”
The young man’s face is pale, and the tears of intolerably wounded
feeling glisten in his eyes.
Lavinia listens in parted-lipped compassion, as so often before, for both
the sinner and the sinned against.
“I will be his ladder,” she says, in a key of quiet resolve, and so leaves
the room.
Half an hour later she returns. Her large eyelids are reddened, and her
mouth twitching, but she is determinedly composed.
“It is all right,” she says cheerfully. “We are to be married on May the
28th; and he cried and begged our pardon.”
Thus it comes to pass that on this 23rd of April Lavinia is pacing in
almost imminent bridehood—for what are five short weeks?—beside her
future husband along a rustic road. They are taking a sweethearts’ ramble,
like any other lad and lass. About them the charming garden of England
swells and dips in gentle hills and long valleys and seaward-stretching
plain. They have mounted the rise behind their house, and looked from the
plough-land at the top towards the distant Sussex range. The cherry
orchards still hold back their snowy secret, but the plum-blossom is
whitening the brown trees; and he would be over-greedy for colour whom
the dazzling grass and the generous larches and the sketchily greening
thicket did not satisfy.
Their path, leading down from the hill-crest, has brought them to an old-
world farm, where with its team of four strong horses, that to a London eye,
used to overloading and strain, would look so pleasantly up to their work, a
waggon stands by a stack, from whose top men are pitching straw into it.
On the grass in front of the house sheep crop and stare with their stupid
wide-apart eyes, and hen-coops stand—lambs and chickens in friendliest
relation. A lamb has two little yellow balls of fluff perched confidently, one
on its woolly back, one on its forehead.
Lavinia has seen it all a thousand times before; but to-day a new sense of
turtle-winged content and thankful acquiescence in her destiny seems
settling down upon her heart. The feeling translates itself into words.
“It is very nice to have you back.”
“It is very nice to be back,” replies her companion, with less than his
usual point.
Rupert has been in London, and returned only last night. His visits to the
metropolis have to be conducted with caution and veiled in mystery, despite
the innocency of his objects, owing to the profound contempt felt and—it

You might also like