Learning Java Beginning programming with java for dummies First Edition John Bach
Learning Java Beginning programming with java for dummies First Edition John Bach
Learning Java Beginning programming with java for dummies First Edition John Bach
COM and NET Component Services 1st Edition Juval Löwykboqcyuw976
Photo chemistry Power Point Presentationmprpgcwa2024
Ad
Learning Java Beginning programming with java for dummies First Edition John Bach
1. Learning Java Beginning programming with java
for dummies First Edition John Bach download
https://textbookfull.com/product/learning-java-beginning-
programming-with-java-for-dummies-first-edition-john-bach/
Download full version ebook from https://textbookfull.com
2. We believe these products will be a great fit for you. Click
the link to download now, or visit textbookfull.com
to discover even more!
Learning Java An Introduction to Real World Programming
with Java Marc Loy
https://textbookfull.com/product/learning-java-an-introduction-
to-real-world-programming-with-java-marc-loy/
Beginning Programming with Python For Dummies 2nd
Edition John Paul Mueller
https://textbookfull.com/product/beginning-programming-with-
python-for-dummies-2nd-edition-john-paul-mueller/
Learning Java An Introduction to Real World Programming
with Java 5th Edition Marc Loy
https://textbookfull.com/product/learning-java-an-introduction-
to-real-world-programming-with-java-5th-edition-marc-loy/
Learning Network Programming with Java 1st Edition
Reese Richard M
https://textbookfull.com/product/learning-network-programming-
with-java-1st-edition-reese-richard-m/
3. Beginning Java with WebSphere Expert s Voice in Java
Janson Robert W
https://textbookfull.com/product/beginning-java-with-websphere-
expert-s-voice-in-java-janson-robert-w/
Java For Dummies 7th Edition Barry A. Burd
https://textbookfull.com/product/java-for-dummies-7th-edition-
barry-a-burd/
Learning Java Functional Programming 1st Edition Reese
Richard M
https://textbookfull.com/product/learning-java-functional-
programming-1st-edition-reese-richard-m/
Learning Java With Games Chong-Wei Xu
https://textbookfull.com/product/learning-java-with-games-chong-
wei-xu/
Computer Graphics Programming in OpenGL with Java
Gordon
https://textbookfull.com/product/computer-graphics-programming-
in-opengl-with-java-gordon/
5. Learning Java
B e g i n n i n g P r o g r a m m i n g w i t h J a v a
F o r D u m m i e s
By
John Bach
10. CONTENT
INTRODUCTION
Java Program Execution
BASIC STRUCTURES OF THE JAVA LANGUAGE
A simple program to lang 's ke Java
Comments
Data types and displaced n nye
Constants
Big numbers
Methods for working with large numbers
Operations
Converting numeric types
Cast
Strings
Union with t rock
Substrings
Editing a string
Checking strings for equalit y
Some methods of the String class
Controlling program execution
Block scope
11. Conditional statement if - else
Multivariate branching - switch statement
While and do - while loops
cycle for
Break statement
The continue statement
Arrays
Copying arrays
Sorting arrays
Arrays Class Methods
Multidimensional array s
Command line parameters
Cantilever th input-you in odes
OBJECTS AND CLASSES
Introduction to Object Oriented Programming
OOP terminology
Differences between OOP and Traditional Procedural Programming
Classes
New operation
An example of using existing classes
Constructors
Method overloading
The this keyword in constructors
A note about data encapsulation
Static fields and methods
Static fields
Static methods
Initialization blocks
Packages
Using packages
Adding a class to a package
Specifying the path to packages
Package scope
JAR files
Class design guidelines
12. INHERITANCE
Extending classes
Overriding (overriding) methods
Inheritance hierarchy
Polymorphism
Dynamic linking
Preventing Inheritance: Terminal Classes and Methods
Abstract classes
Protected Access ( protected, )
How to apply inheritance
Interfaces
Interface operator
Implements statement
Constants in interfaces
EXCEPTIONAL SITUATIONS
Classification of Exceptions
Declaring Method Exceptions
How to raise an exceptional situation
Creating Exception Classes
Catching exceptions ( t ry - catch block )
Catching multiple exceptions
Re-raising an exception
Finally section
How to use exceptions
I / O STREAMS
Reading and writing bytes
Complete family of threads
Stream filters
Data streams
Direct File Streams
Text streams
Writing text to the output stream
13. Reading text from an input stream
Working with files on the th system
LETTER T HURRAY
Introduction
The Java language was created in the early 90's as part of a
software development project for consumer electronic devices. The
original new object-oriented programming language was named Oak
(oak) . With the development of network Internet language Oak was
used to create Internet-applications ( eg, n and this language was
written Oak-browser " WebRunner " ) . In 1995, Sun Microsystems
decided to announce a new product, renaming it Java (the only
reasonable explanation for the name is the love of coffee
programmers) , and WebRunner was renamed HotJava .
The Java language is now increasingly used to create " middleware "
that maintains communication between clients and server resources
. In addition, the Java language has taken over the leadership in
embedded systems , becoming the de facto standard for portable
devices , on-board car computers, and so on .
One of the main advantages of the Java language is independence
from the platform on which programs are executed: the same code
can be run under Windows , Solaris , Linux , Macintosh , etc.
Operating systems . Another advantage is that the syntax of the
Java language is similar to the syntax language s C ++ and C . In
addition, Java is a completely object-oriented language, even more
so than C ++. All entities in the Java language are objects, with the
exception of a few primitive types , such as numbers.
In contrast to C ++ , it is easier to develop error-free programs in
Java . The Java language provides tools to eliminate the very
possibility of creating programs that would hide the most common
errors. To do this, the Java language has done the following :
14. The possibility of explicit allocation and freeing of memory
has been excluded. Java memory is automatically reclaimed
by garbage collection. The programmer is guaranteed
against errors related to misuse of memory ;
Introduced true arrays and disallowed pointer arithmetic.
Now programmers, in principle, cannot erase data from
memory due to improper use of pointers ;
Eliminated the possibility of confusing the assignment
operator with the equality comparison operator . Now you
can not even compile the expression of the if ( a = 3) { ... }
(this error - the source of most confusion in the languages C
and C ++).
Multiple inheritance is excluded. It has been replaced by
the concept of interface a , borrowed from Objective C. An
interface gives the programmer almost everything a
programmer can get from multiple inheritance, while
avoiding the complexity of managing class hierarchies .
Java Program Execution
A program written in a high-level language (called a source module )
cannot be executed immediately . From the beginning it must be
compiled, that is , translated into a sequence of machine instructions
- an object module. For boot th unit I of bektny module n uzhno
build the libraries used in the module and enable the cross-
references between the object module sections
The source module written in the language of the Java , could not
avoid these procedures, but here is shown the main feature of the
technology the Java - the program is compiled directly into machine
instructions, but does not command a particular processor, and in
the team's so-called in irtualn second machine s the Java ( JVM, Java
Virtual Machi ne ). The Java Virtual Machine is a collection of
commands along with their execution system. Note that the virtual
machine Java completely stack, and therefore does not require
complex th addressing of and memory cells and a large of quantity
and registers. By A team JVM short, most of which it has a length of
15. 1 byte, so the JVM command called a byte - code ( bytecodes ),
although there are teams of length 2 and 3 bytes. Full description of
the commands and the entire JVM architecture is contained in a
virtual machine specification the Java (the VMS, the Virtual Machine
specifica tion of ).
Another feature of Java is that all standard functions that are called
in a program are connected to it only at run time, and are not
included in the bytecode. In other words, there is dynamic linking (
dynamic binding ) , which significantly reduces the amount of the
compiled program.
Since a program written in Java is translated by the compiler into the
bytecode of the Java Virtual Machine , it is independent of the type
of processor and architecture of the computer being used .
Therefore, bytecode can be performed and be on any computer with
a system that implements the JVM. In this case, neither the type of
processor nor the architecture of the computer is important. T. e
language. The Java - machine-independent. (Obviously, the
implementation of the Java virtual machine is platform dependent.)
Bytecode interpretation and dynamic linking slow down program
execution significantly. It does not matter when the bytecode before
ae tsya on the network - network slower than any interpretation ;
however , other situations require a powerful and fast computer. To
increase the speed of interpretation p azrabotany JIT-compiler ( "
timely " compilers - the Just - with In - Time The compiler ),
memories have interpreted sections of code to machine CPU and
simply performing these areas when re-treatment, for example, in
cycles. Only a specialized processor can provide the highest speed of
bytecode execution . The company of SUN Microsystems released
the microprocessors picoJava , running on the system JVM
command, e nce and Java-processors of other companies. These
processors directly execute bytecode.
And nterpreta tori JVM commands in a specific processor instructions
designed for virtually all computing platforms. More and more
operating systems and database management systems include JVM
implementation in their core. A special JavaOS operating system has
16. also been created , which is used in electronic devices. Most
browsers have a built-in Java virtual machine to run applets.
The company of SUN Microsystems - the creator of technology Java
- distributes a set of software tools required for a full cycle of
software development on the language ie Java under the name of
the JDK ( Java Development Kit ). There are toolkits from other
companies .
The JDK suite of programs and classes contains:
javac - source to bytecode compiler;
java - the interpreter containing the JVM implementation;
appietviewer - browser-replacement applet viewer
jdt - debugger;
javap - disassembler;
jar - pro gram archiving and compression (using the
format zip -files);
the javadoc - prog Ranma to generate documentation
from comments ;
javah - generating program language header file C ;
javakey - a program for adding an electronic signature;
native2ascii - a program that converts binary files to text;
rmic and rmiregistry programs for working with remote
objects;
serialver - the program that determines the version
number of the class;
libraries and header files of " built-in " methods;
Library classes Java API (Application Programming
Interface) and others .
The first version of the JDK 1.0 was released in 1996 g ode . Starting
with the version the JDK 1.2, which came out in December 1998 g .,
Food technology Java Company and SUN became and nazyvat sya
Java 2 Platform of Standard Edition , abbreviated J 2 SE , a the JDK
was pereimenova n in Java 2 of Standard Edition the SDK ( Software
Development Kit ) , abbreviated as J 2 SDK . Also issue were Java 2
Enterprise Edition the SDK and Java 2 Micro Edition the SDK . (
However, the very company SUN until now has enjoyed , and the old
17. name - the JDK .) With the version the JDK 1.6 packages means
development began and nazyvat sya the Java Platform of Standard
Edition Development Kit ( the Java SE ) , the Java Platform
Enterprise Edition the SDK ( the Java EE ) and the Java Platform
Micro Edition SDK ( Java ME ). In addition , SUN separately
distributes a set of JRE ( Java Runtime Environment ) for working
with compiled Java programs .
Basic structures of the Java
language
A simple Java program
Consider a simple program that prints a message to the console
window :
public class FirstSample
{
public static void main (String [] args)
{
System.out.println ("Hello, World!");
}
}
The first and main point is that in the Java language , uppercase and
lowercase letters are strictly distinguished. If , for example, Dialed
amb word Main instead of main , the program will not be executed.
The keyword public is called the access modifier ( access modifier );
such modifiers control access to this code from other parts of the
program. The keyword class reminds us that all of the entities in the
language Java is inside a class , t. E. In Neki x container x , in which
the logic of the program concluded, defining the application. Classes
are the building blocks that make up all applications and applets
18. written in the Java language . All entities in Java programs must be
inside classes.
The class keyword is followed by the class name. The rules for
generating class names are not too strict. The name must start with
a letter, and the rest of it can be any combination of letters and
numbers. The length of the name is practically unlimited. Java
reserved words (for example, public or if ) cannot be used as a class
name .
Classes are usually called nouns starting with an uppercase letter.
The file containing the source code must be named the same as the
public class and have the extension . j ava .
Compiling the program :
java c FirstSample . java
The Java compiler will automatically name this file FirstSample .
class and will save it in the directory containing the source file.
To redirect error messages to a file ( when working on UNIX or
Windows NT / 2000 / XP platforms ) , just use the 2> operator:
javac FirstSample . java 2> errors . txt
For in the Run eniya byte code and using an interpreter Java n
uzhno dial command
java FirstSample
( no extension . class ) .
When to start from the compiled program, use the command java
ClassName , language interpreter Java always starts with the
implementation of the method main of the specified class.
Therefore, for the program to run at all, the class must contain a
main method .
In accordance with the specification of the language Java method
main must be declared public ( the public ) and static ( static ) .
19. With lovo void means that the method does not return any value.
The brackets in the source code of a program are used to mark parts
of the program (usually called blocks). In Java, the code of any
method must begin with an opening curly brace and end with a
closing curly brace ({…}) .
By azhdy operator must end with a semicolon. In particular, the end-
of-line character does not mean that the statement is terminated ,
so the statement can span as many lines as needed.
In this example, for a text string output using tsya object System .
out and cause t Xia its method println , in which the text string is
passed as a parameter. Note that period is used to call the method.
In the language of the Java , as well as in the language of s C / C
++ for the designation used strings double quotes.
Java methods can have one or more parameters , or none at all .
Even if the method has no parameters, you must leave empty
parentheses. For example, there is a parameterless version of the
println method that prints an empty string to the screen. Its call
looks like this: System.out.println () .
Comments
Comments in Java , as in most programming languages, are ignored
when compiling a program. Thus, you can add as many comments
to the program as required without fear of increasing its size.
The Java language has three ways to highlight comments in text.
The most common use of two forward slashes is //, whereby the
comment begins immediately after the // characters and continues
to the end of the line. In addition, the delimiters / * and * / can be
used .
T retya variety comments mozh is ispolzovat sya for automatic
generation of documentation. These comments begin with / ** and
end with * /. The javadoc utility is used to automatically generate
documentation . exe .
20. Data types and variables
The Java language is strongly typed. This means that the type of
each variable must be declared.
In the language of Java , there are eight basic types ( primitive types
) data. Four of them are integers, two - to the actual floating- point,
one is a character type char , used to represent characters in the
format of the Unicode , and the latter - a boolean type boolean - is
used for logical values.
There is no concept of unsigned numbers in Java .
Table 1 . Data types
A type Size in bytes Change interval
int 4 o t - 2147 483648 up to 2147483647
short 2 from -32768 up to 32767
l ong 8
o t -
9223372036854775808L
up to
922337203685477580
7 L
byte 1 o t - 12 8 up to 1 27
float 4
from - 3.4 02823 47 Е
38 F
up to 3.4 02823 47 E
+ 38 F
double 8
from - 1.7976931348623
1 57 E + 308
D o 1.79769313486231
57 E + 308
char 2 from 0 ( ' u0000 ' )
up to 65535 ( ' uFFFF
' )
Long integers have an L suffix ( for example, 4000000000L).
Hexadecimal numbers are prefixed with 0 x ( for example, 0 xCAFE
or 0 xcafe ). Octal numbers are prefixed with 0. For example, 010 is
8 10 .
Float numbers have an F suffix, for example 3.402F. Floating point
numbers having no suffix F ( e.g., 3.402), are always treated as the
number of type double ( with double precision ) . You can (but not
necessarily) use the D suffix to represent them, for example 3.402D.
21. All calculations performed on floating point numbers follow the IEEE
754 standard. In particular, the Java language has three special
floating point numbers:
positive infinity (constant Double . POSITIVE _ INFINITY )
;
negative infinity (constant Double . NEGATIVE _ INFINITY
) ;
NaN (not a number) ( constant Double. NaN ) .
They are used to indicate overflow and error. For example, dividing a
positive number by 0 equals positive infinity. Evaluating 0/0 or taking
the square root of a negative number is NaN.
For constants of type char , single quotes are used. For example, ' H
' is a character. It differs from "H" , which is a single character string.
In Java to represent the characters are encoded the Unicode , so the
value of the type as char coded 2-byte of vym code. Unicode is the
union of dozens of character encodings ; it includes Latin, Greek,
Arabic alphabets, Cyrillic and many other character sets.
Unicode character codes are usually expressed as hexadecimal
values
from ' u0000' to ' uFFFF' . The u prefix means that the
character is in Unicode format , followed by four hexadecimal digits
that identify the character. For example, ' u2122 ' is a trademark
(™) symbol .
With quantities of type char mozh but handled as integers . This
makes it possible to add two characters together, or to increment the
value of a character variable :
The Java language has a simple boolean type used to store boolean
values. Variables of this type can take only two values - true (true)
and false (false). Values of type boolean return as a result of all
comparison operators .
Note that the variable name must also begin with a letter and be a
combination of letters and numbers. The terms "letters" and
"numbers" in Java have a broader meaning than in most other
programming languages. Letters are considered Sim oxen ' A' - ' the
Z', 'a' - ' the z ', '_' and any symbol encoding the Unicode . Similarly,
22. both ordinary decimal digits '0' - ' 9 ' and any Unicode characters
used to denote a digit in any language are considered digits. The
use of other characters in identifiers is prohibited. All characters in
the variable name are important, and the case of the keyboard also
matters. Variable name length is not limited. You cannot use
reserved words as variable names.
In the language of Java size ad is, and determining the e variables
do not differ.
After declaring a variable, you must explicitly initialize it using the
assignment operator. For example :
int vacationDays ; // This is a declaration
vacationDays = 12; // This is an assignment operator
int index = 0 xffffffff ; // -1
long number = 25 L ;
float result = 2.5 F ;
double pi = 3.14159;
char c1 = 0x f132;
char c2 = 'a';
char c3 = ' n';
char c4 = ' u2122 ' ;
boolean done = false ;
The basic form of a variable declaration is as follows:
type identifier [= value] [, identifier [= value 2 ...];
Type - is either one of the built-in types so . e . byte , short , int ,
long , char , float , double , boolean , or the name of a class or
interface.
Constants
The Java language uses the final keyword to denote constants , for
example:
public class Constants
{
public static void main (String [] args)
23. {
final double CM_PER_INCH = 2.54 ;
double paperWidth = 8.5;
double PaperHeight = 11;
System . out . the println ( " The size of the page in
inches "
+ paperWidth * CM_PER_INCH + " on "
+ paper H eight * CM _ PER _ INCH );
}
}
The final keyword means that you can assign a value to a given
variable only once. It is not necessary to use only uppercase letters
in constant names .
In the Java language , you often need constants that are available to
multiple methods within the same class. They are usually called class
constants . Class constants are declared using the static final
keywords . Here's an example using a class constant :
public class Constants 2
{
public static final double CM_PER_INCH = 2.54;
public static void main (String [] args)
{
...
}
}
Note the fact that the class constant is defined outside the main
method . Thus, it can be used in other methods of the same class.
Moreover, if (as in this example) a constant is declared public ,
methods from other classes can also access it. In our example, this
can be done using the expression Constants 2. CM _ PER _ INCH .
24. Big numbers
If the precision of the built-in integer and floating point types is not
sufficient , you can refer to the two classes in the Java package .
math called Big I nteger and BigDecimal . These classes are
designed to manipulate numbers consisting of an arbitrary number
of digits. The Big I nteger and BigDecimal classes implement
arbitrary precision arithmetic on integers and real numbers,
respectively.
To convert an ordinary number to “ large ”, use the method
valueOf . Big I nteger a = Big I nteger.value O f (100);
The usual mathematical operators “ + ” and “ * ” cannot be applied
to large numbers . Instead, you need to use the add and multiply
methods from the classes to work with large numbers :
Big I nteger with = a . add ( b ); // c = a + b
BigI nteger d = c .multiply (b.add (BigInteger.valueOf (2)));
// d = c * ( b + 2)
Methods for working with large numbers
java.math.Big I nteger 1.1
Big I nteger add (Big I nteger other)
Big I nteger subtract (Big I nteger othe r)
Big I nteger multiply (Big I nteger other)
Big I nteger divide (Big I nteger other)
Big I nteger mod (Big I nteger other)
These functions return the sum, difference, product, quotient, and remainder
of a given large number by the value of other .
int compa reTo (Big I nteg e r other)
Returns 0 if the given large number is equal to the value of other, a negative
number if the given large number is less than the value of other, and positive
otherwise.
static Big I nteger valueOf (long x)
Returns a large number equal to the value of x.
25. java.mathBigDecimal 1.1
BigDecimal add (BigDecimal other)
BigDecimal subtract (BigDecimal other)
BigDecimal multiply (BigDecimal other)
BigDecimal divide (BigDecimal other, int roundingMod e)
Returns the sum, difference, product, and quotient of a large decimal number
by the value of other . To calculate the quotient, you need to support the
rounding mode. BigDecimal ROUND_HALF_UP means normal rounding (that is
, downward if the last digit is less than 5, and upward if it is greater than 5).
This is sufficient for ordinary calculations. Other rounding modes are described
in the API documentation.
int compareTo (BigDecimal other)
Returns 0 if this number is equal to the value type variable BigDecimal other , a
negative number if this number is less than the value of the variable other ,
and a positive number otherwise.
static BigDecimal valueOf (long x)
static BigDecimal valueOf (long x, int scale)
Returns a large decimal number equal to the value of x or x / 10 sc ale
.
Operations
Any language expression consists of operands (variables, constants,
etc.), connected by operation signs. An operation sign is a symbol or
group of symbols that tells the compiler to perform certain
arithmetic, logical, or other operations.
Operations are performed in a strict sequence. The value that
determines the preemptive right to perform a particular operation is
called priority. Table Figure 2 lists the various Java language
operations . Their priorities are the same for each group (the group
is located between two adjacent horizontal lines). The more
advantage the corresponding group of operations is, the higher it is
located in the table. The order of operations can be adjusted using
parentheses.
26. Table 2 .
Java Operations
Operation sign Purpose of operation
! Logical negation
~ Bitwise negation
, + Sign change
+ + Increase by one
Decrease by one
( type) Ex ivedenie type (e.g., ( float ) a )
* Multiplication
/ Division
% Determination of the remainder of
division
+ Addition
Subtraction
< < Shift left
>> Shift Right ( Arithmetic )
>>> Shift right ( boolean)
< Less than
< = Less or equal
> More than
> = More or equal
instanceof Checking object ( is there an object
an instance of this class )
= = Equally
! = Not equal
& Bitwise and logical " AND "
^ Bitwise and logical exclusive " OR "
| Bitwise and logical " OR "
27. && Logical " AND "
|| Logical " OR "
?: Conditional (ternary) operation
= Assignment
+ =, =, * =,
/ =, % = , <<
=, >> =, & = , |
=, ^ =
Binary operations (e.g. a * = b
(m. e. a = a * b) , etc.)
To avoid confusion in the concepts of "operation" and "operator",
note that the operator is the smallest executable unit of the
program. There are expression operators, the action of which is to
evaluate the given expressions (for example: a = b + c ; j ++;),
declaration operators, compound operators, empty operators, label
operators, loop operators, etc. The Java language uses a semicolon
to indicate the end of a statement .
Conversion e numeric types
Solid ones with arrows and in Fig. 1 denote transformations that are
performed without loss of information. The three dashed arrows
indicate transformations that may result in loss of precision. For
example, the number of digits in the large integer 123456 789
exceeds the number of digits that can be represented by the float
type . The number converted to float has the same meaning , but
with slightly lower precision.
int n = 123456789;
float f = n ; // Number n is equal to 1.234567892Е8
28. Figure: 1. Allowed conversions
If the two values are combined by a binary operator ( e.g., n + f ,
where n - an integer, a f - a floating point number), before
performing the operation, both operands are converted y are in
numbers having the same type .
If at least one of the operands is of type double ,
the second too Conversion from etsya in the number of
type double .
Otherwise, if either operand is float , the second
too Conversion from etsya in the number of type float .
Otherwise, if one operand is long , then the
second, too Conversion from etsya in the number of type
long .
Otherwise, both operands are converted to int
numbers .
Reduction type s
The language Java automatic conversion ( in the case of the numeric
types ) is possible only in the case where the accuracy of number
representation receiver variable enough for storing the initial value.
Such a conversion occurs, for example, when a character constant or
the value of a variable of type byte or short is entered into a variable
of type int . The size of the int type is sufficient to store numbers in
the range allowed for the byte type , so in such situations, an explicit
cast is not required. The converse in most cases is not true, however
29. for entering a value of type int variable type byte must use opera
tion actuation type ( type casting ) , to the variable int fits into a
variable desired type.
To cast a value to a specific type, you need to specify this type,
enclosed in parentheses, before it. The code snippet below
demonstrates casting from a source (variable of type int ) to the
type of destination (variable of type byte ). If, during such an
operation, the integer value went out of the range allowed for the
byte type , it would be reduced by dividing by modulo by the range
allowed for byte (the result of modulo by number is the remainder of
division by this number).
int a = 100;
byte b = (byte) a;
Automatic conversion type and in expressions can sometimes be the
cause of error messages the compiler. For example, the code below,
although it looks quite correct, results in an error message during
the translation phase. It stores the value 50 * 2 , which must fit into
the byte type (that is , into a byte variable ) . But due to the
automatic conversion of the result type to the int type (since the
number 2 is of the int type by default ), a translator error message is
generated - after all, when an integer is entered into a byte variable
, a loss of precision may occur.
byte b = 50;
b = b * 2;
Corrected text:
byte b = 50;
b = ( b yte ) ( b * 2);
which causes b to enter the correct value of 100.
Strings
Line - is a sequence of characters, such as " the Hello " , submitted
encoded the Unicode . In the language of Java is no built-in type for
strings. Instead, the Java standard library contains a built-in String
class . Each quoted string represents an instance of the String class .
30. String e = ""; // Empty string
String greeting = "Hello";
Strings are allocated in dynamic memory, the string identifier is, in
fact, a reference to the string.
Concatenating strings
The Java language , like most programming languages, allows you
to use the “ + ” operation to concatenate (concatenate) two strings.
String a = " Hello ,";
String b = " World ! ";
String message = a + b ;
The code above assigns the string " Hello , World ! " To the message
variable . When the string concatenation with a value that is not a
string, the value is converted from etsya string. For example the
code
int age = 1 8 ;
String rating = " PG " + age ;
assigns the string " PG 1 8 " to the rating variable .
This property is widely used in inference statements :
System.out.println ("The answer is " + answer);
Substrings
You can use the substring method of the String class to extract a
substring from a given string. For example the code
String a = " Hello ";
String s = a . substring (0, 4);
forms a string consisting of the characters " Hell " . In the Java
language , characters in a string are numbered from zero (as in the
C and C ++ languages ). For example, the character 'H' in the string
" Hello " is at position zero, and the character 'o' is at position four.
The second parameter of the substring method specifies the position
to which the copy is performed (that is , the elements at index 0, 1,
2, and 3 are copied) .
31. Editing a string
To determine the length of a string, use the length method , for
example:
String greeting = "Hello";
int n = greeting.length (); // String length is 5
A single character can be selected from a string . Calling greeting
.charAt (n) returns the Unicode character at position n , where n is
in the range 0 to greeting .length () - 1 , for example:
cha r last = greeting.charAt (4); // The fourth character , ie .
e . - ' o '
By Lass String do not have methods to change the character at a
given with Troc , about dnako variable of type String , you can
assign a new value (ie. E assign. Reference to the string " the Hello "
link on the next line ) :
String greeting = "Hello";
greeting = " Hello " + ", World ! ";
In this case , new cells are allocated in memory to store the string "
Hello , World !" and the variable greeting gets the address of this
timeline . The memory unit, which stores the value of " the Hello " ,
sooner or later, will be released by a mechanism and automatic
garbage collection.
If you want to change the string , you can use the class om the
StringBuffer .
Checking strings for equalit y
To check if two strings are the same, the equals method should be
used . The Calling up method
s . equals ( t ) ;
returns true if strings s and t are equal, otherwise it returns false .
Note that strings s and t can be both variables and constants. For
example, the expression
" Hello !" equals ( c ommand String );
32. quite acceptable . To check the identity of strings, ignoring the
distinction between uppercase and lowercase letters, use the equals
I gnoreCase method .
" Hello ". equalsIgnoreCase (" hello "); // Returns true
You cannot use the " ! = " Operation to test strings for equality . He
and checks only if both lines are stored in the same memory area.
Obviously , if both strings are stored in the same place, they must
match. However, it is quite possible that identical strings are stored
in different places.
Some methods of the String class
Class String in the language Java contains more than 50 methods.
Below are the most useful ones. Full list of methods can be found in
the documentation for the Java the API .
Java.lang.String 1.0
char char At (int index)
Returns the character at the specified position .
int compareTo ( String other )
It returns a negative value if the row line precedes other in lexicographic order,
a positive value - if a string other preceded this string in lexicographic order,
and 0 - f If the strings are identical .
boolean endsWith ( String suffix )
Returns true if the string ends with suffix substring .
boolean equals ( Object other )
Returns true if the string is equal to the string other .
boolean equalsIgnoreCase ( String other )
Returns true if the string is equal to the string other, disregarding the
difference between uppercase and lowercase letters.
int index (String str)
34. and filled with a spirit from “translunary” sources, required not the
critical minds of a later school of commentators to establish their
worth.14 Some passages are still recognized as having “no parallel in
all the range of tragedy.”15 Thus it was that at this period he was
throned in a school where all his fellows were his servile imitators.
Among them were Nashe, Peele, and Lilly; but poor Greene, with
one more outburst against the “upstart crow,” with “his tygres
heart,”16 who could have been none else than the writer whom he
had attacked in 1587, had finished his unfortunate career. And his
career was the one being pursued by all these fiery and impatient
souls. It was Marlowe, especially, who had plunged into all the mad
excesses of an unbridled life,17 the temporary drift of a youth with
convictions unsettled by draughts from Greek philosophers, senses
inflamed by the voluptuousness of Ovid, and an existence checkered
by frequent shadows of poverty and flitting gleams of plenty. It was
the unsettled state of vigorous youth, augmented by the peculiar
social conditions then existing.
Upon the continent the civil wars of Henry IV. had approached their
close. In England the Starchamber held its secret sessions; the block
of the executioner was kept warm with the blood of the insecure
nobility; while the torch for the fires of heretics was never allowed to
smolder. Elizabeth had been on the throne 35 years; Francis Bacon,
with mind bent on pre-eminence as a philosophic writer, was her
counsel learned extraordinary, and William Shakespere, six years
previously arrived from the obscure village of Stratford-on-Avon, was
a member of Lord Pembroke’s Company of actors. There were no
theaters at that time within the walls of the city; histrionic
exhibitions being presented on the boards of the “gorgeous playing
houses erected in the fields.” The edict against strolling players was
rigorously enforced; freedom of expression in matters of religious
belief was the subject of penal laws, and any animadversions
concerning the policy of the government were declared treasonable.
As an evidence of the barbarity of the times, the Southwark end of
the London bridge was decorated with the heads of thirty traitors, all
35. of which had fallen beneath the axe of the executioner after the
hanging and disemboweling of the bodies. The tower held many
martyrs of religion; and Fleet Street prison, with its foul quarters,
was the abiding place of hopeless prisoners for debt. If the pinch of
poverty of itself was spur enough to have produced the poems of
Goldsmith, the wonder at the immortal dramas and poems of the
Elizabethan era must vanish upon consideration of what poverty and
debt then meant, and the insecurity of the beggar who gave
expression to his coin-producing thoughts.
It was during a time, thus out of joint, that Hamlet and Richard the
III. walked, as embodied entities, from the brain of their author.
Besides the barbarity of the period, the intolerant spirit, and the
harsh laws, did any other factor add its motive power toward these
productions? Had some crisis been reached in the life of the author
greater than that evolved through poverty and the prospect of
imprisonment alone?
36. A CHANCE TO SERVE THE CHURCH.
Now will I show myself
To have more of the serpent then the dove;
That is more knave than fool.
—The Jew of Malta, ii, 3.
And thus I clothe my naked villainy
With odd old ends stolen forth of holy writ,
And seem a saint when most I play the devil.
—King Richard III, i, 3.
Under the newly-cast sign of an iron dolphin suspended before the
ale-house of that name, the two horsemen, who had ridden abreast
from Finbury Fields, dismounted for hasty refreshment. While
Tabbard was securing the horses near the end of the long stone
trough, at the front of the building, his waiting companion was idly
surveying the suroundings.
Directly across the unpaved highway, he could see the bulky steeple
of the parish church of Saint Botolph lifting itself into the misty air,
and just beyond the brick walls of the structure, the miserable
churchyard of Petty France. The few straggling headstones of the
graves of a multitude of buried foreigners could be faintly discerned
under scrubby trees inclosed with a fence of crumbling masonry. Its
southern edge was bordered by the town ditch, once broad enough
for the defense of the city, but now showing only a narrow black
mouth under the shadow of the old Roman wall. The latter was near
enough to be visible, and, coming out of the fog from east and west,
37. terminated in stone bulwarks against which the ancient gates of
Bishopsgate were hung. These were swung back, revealing a black
expanse below which ran the unseen road into the metropolis.
The scene was desolate in the extreme, but the spirits of the silent
observer had reached too high a pitch of exaltation to be affected by
any aspect of Nature. The news brought him by the present
henchman of the Duke of Sussex and past servant of the Golden
Hind, had lifted his mind above the plane where even thoughts of
approaching financial distress or fears of the plague could arise,
much less any sober-colored clouds be created by what passed
before the eye.
The bearer of the message, menial though he was, had rendered too
valuable a service to be treated in any other manner than as a good
fellow of equal rank with himself. Hence, he had thrown off the
superiority he generally assumed amid the common rabble, and after
listening affably to the remarks of Tabbard, had held him for a meal
at the Dolphin.
“How long will those gates be open?” asked Tabbard, looking in the
direction of the wall.
“Until ten o’clock, and even after that hour you can pass through if
you pound upon their fronts loudly enough to wake the keeper, who
sleeps within the little black house close to the wall on the southern
side. But in pounding, mind thee, Tabbard,” continued the speaker,
with a smile, “see to it that you do not mar the stone features of the
full length figure of King Richard the Second, which with broken
scepter in his hand, stands out from the northern front of one of the
rotting gates.”
“He must have his face now against the wall, for they are swung
outward,” remarked Tabbard.
“Yes, for the nonce, as closely hidden as the manner of his violent
death.”
38. “Ah,” said Tabbard, his mind crowded with the thoughts of the
existing religious persecutions, “did he espouse the cause of the
Papists?”
“Nay, my good fellow, that was two hundred years ago, when the
fury of the church, then in power, expended itself mainly in bulls of
excommunication. The violence of these days did not exist; but still
conflicting doctrines entertained by the clergy disturbed the serenity
of Rome, and the chief heretic was Wycliffe, whom the young king
protected. That priest sowed the most fruitful seeds of the
Reformation; but none of the Brownists or Puritans appear to
recognize, amid the tenets of their beliefs, the handwriting of that
master husbandman.”
“And I suppose that he was burnt, was he not?”
“After death.”
“In hell’s everlasting fire, eh?”
“Nay, I do not mean that. He died a natural death; but many years
after, his body was taken from its grave and publicly burned.”
“Little it disturbed him, I wot,” remarked Tabbard.
“So it seems that fanaticism rests not even with the death of the
person on whom it would wreak its fury, and it burns even in the
breasts of men as mild looking as yonder group of Puritans.”
He pointed to the middle of the road close before them where
several men were slowly walking toward Houndsditch. The plainness
of their dress, of the same color from head to foot, and of exactly
similar cut, was in striking contrast with the apparel of the two men
whom they were passing.
Their broad brimmed hats were high-crowned and flat at the top,
and pulled down so low that only four inches of face were visible
39. above the deep collars of their gray coats. The latter were hung with
heavy capes, and fronted with pin-head buttons to the lowest point
below their waists. Loose breeches disappeared at their knees into
rough looking high-boots with great rolling tops.
Their appearance excited Tabbard to laughter. Although still
regarded as objects of ridicule by the irreligious populace and the
body of the established church, the more thoughtful of those of
adverse belief were beginning to recognize in the Puritans’ open and
covert attacks upon the follies and vices of the times, the growth of
a moral and political power which likewise demanded forcible
suppression. Their railing libels against the clergy of the established
church had at length formed a pretext for Parliament to pass an act
that year making Puritanism an indictable offense. Their assembling
had already been prohibited by the Black Act of 1584.
Despite their persecution, the zeal of the dissenters continued in
their attacks upon what they considered crying evils. They stood
ready to apprehend all offenders against such ecclesiastical laws as
upheld the truth and sacredness of religion and the divinity of Christ.
So far as Romanism might be by them considered destructive of true
religion, they were ready to wield the sword forged by the
Episcopalian Parliament for the dismemberment of the Papists. Many
a non-conformist discovered in the person of the prosecuting witness
swearing against him a member of the sect of Brownists. But
particularly in the case of apostates and blasphemers the Puritans
and Brownists directed their efforts toward having meted out to the
offender the effective punishment provided by law.
As the two men turned and approached the door of the tavern, a
man with deep-set eyes, sunken nose and red-bearded face, and
dressed in the garb of a Puritan, hurriedly withdrew his face from a
window adjoining the entrance. The sinister expression of his face
had grown more pronounced during the last moment of his survey of
the newcomers; for it was at them that his gaze had been directed.
It was evident that their approach had disturbed him greatly; but the
40. disturbance was rather that of joy than of alarm. Still, whatever the
sight created or revived in the mind of Richard Bame, the fanatic, his
movements elicited the fact that he was either not desirous of the
impending meeting, or that he considered that his presence in
another quarter would be more to his advantage. He had seen the
gentleman in the black cloak before, but not to the knowledge of the
latter, so it was not the dread of an encounter that made Bame turn
and hasten toward the side-door of the dimly lighted tap-room. It
was the second step which he had taken in what he considered a
holy cause; of most evil effect it might be to the man approaching.
As the former passed the big chair in which the fat hostess of the
Dolphin sat knitting he muttered not too softly to be kept from ears
already aroused at the note of his departure:
“My chance to serve the church is ripe.”
He passed into the side alley leading to the high road when the two
men entered the room. The leader spoke without giving the woman
chance for words of greeting:
“Good hostess, a hasty snack is what we want.”
“Of what shall it be?” she asked.
“Sack, cheese, bread and two pieces of meat as big as your hand.
Drop yourself there, Tabbard?”
The speaker had tossed his cloak over the back of a chair as he
spoke and as hastily filled another. In impatience he drummed a
tattoo with one of his feet on the smooth oaken floor; and,
apparently without noting the freshness of the bare walls and the
chimney in which no fire had ever burned, his eyes roamed around
the room.
“Just built,” remarked Tabbard.
41. “Yes,” returned the hostess, setting the dishes called for before the
two strangers and smiling as though she felt flattered over the
knowledge that her house was the subject of observation and
comment.
“Where went the old building?” asked Tabbard.
The hostess turned her hand with thumb pointing upwards and said,
“In smoke.”
“Yes,” said Marlowe, whose scarlet doublet and silver-corded belt
had awakened the hostess’ admiration and almost hushed her into
respectful awe, “I saw its blaze from as far south as the Standard in
Cheap. The old tavern was twice as large as this, and being just
outside the wall was greatly frequented by travelers approaching
London late at night.”
“Do many stop here now?” inquired Tabbard.
“Not many at this season,” answered the hostess.
“The last one before you, kind sir,” she continued, now turning her
attention to Marlowe and bowing so that her eyes caught only the
sparkle of his rapier’s hilt, “left just as you entered. He acted
strangely as he caught sight of you.”
“So, who was he?”
“He gave me no name, but as he went out I heard him say: ‘My
chance to serve the church is ripe.’”
“How was he dressed?” asked Marlowe, suddenly setting down his
half-raised mug, and fixing his eyes upon the hostess.
“Like a Puritan,” she answered.
42. “And what business have honest Puritans hanging around the bars of
ordinaries and taverns?” exclaimed Marlowe, while Tabbard sneered
audibly, and asked:
“And of what appearance was this man who was lounging here for
the service of God?”
“His long red beard was all I noted,” she replied.
“I know him not,” said Marlowe, shaking his head, and then he
asked:
“Do you know his name?”
“Methinks that a man who was with him earlier called him Bame at
times, and again Richard.”
“Richard Bame!” exclaimed Marlowe, lifting his eyebrows and gazing
fixedly at the woman. “And he said that his chance to serve the
church was ripe?”
“True,” nodded the hostess, with her fists against her waist and
continuing to look at her interlocutor as though in expectation that
he would explain what interest he had in the man who had
departed.
“Draw us two more cups, Mistress Bunbay,” he said, noticing the
inquisitive expression on the woman’s face and desirous to get her
out of earshot.
As the woman went towards the bar, he whispered to Tabbard,
“Good fellow, for the turn thou hast done me in bringing news of the
lady at Deptford I would knight thee had I the power, or enrich thee
had I gold, but I have neither the one nor the other, except a brace
of angels of which one is thine. Here put it in thy pocket and when
occasion offers drink to the health of thy friend and to the confusion
43. of all such fellows as just left here. But now I would ask another
service of thee.”
“Speak, I am ready,” said Tabbard, picking up the ten-shilling piece,
and holding it as though he would have it grow into his palm.
“The man who left here,” continued the other, “is Richard Bame, who
has sworn to secure my arrest.”
“And for what?” exclaimed Tabbard. “Hast thou committed a crime?”
“Nay, listen. He is a whining, canting hypocrite, who has filed an
accusation against me for blasphemy. He hath no cause of
grievance, and his charges, if like what I have heard, are false. Word
of this was brought me but yesterday, and friendly warning given
that as soon as my whereabouts were known, my arrest would
follow. I said as we journeyed across the fields, a short time since,
that I hung behind the crowd to avoid my creditors, and that was
partly true; but besides, I was apprehensive of encountering a
constable with the writ issued upon the accusation. This Bame hath
been watching for me and is now going for the officer, if I mistake
not.”
“And what can I do for thee?” asked Tabbard, excitedly. “The sword
point is all too good for him. How is it that Barrowe was burnt, and
such as he live?”
“He is either carried away by religious fervor or is acting at the
instance of some writer whom I have grievously offended, but it
matters not what gives the spur to his actions,”18 continued Marlowe;
“I would not incite thee to do him violence. As soon as I reach the
County of Surrey, the writ issued by the justice will be inoperative;
but they may stay me before I cross London Bridge. Nothing must
prevent my reaching the Golden Hind, in Deptford, to-night.”
“And why not mount in haste and ride on now down Bishopsgate
Street to the Bridge?”
44. “The constable may be close at hand, and the pair even now
awaiting my departure. Then, again, I must stop at my quarters in
Coward Lane before I leave the city.”
“Well, well,” exclaimed Tabbard, “give me the word of action. I am
ready.”
“Mount horse at once, and press after him. Did you hear her
description of him? A red-bearded man with broad-brimmed hat and
long gray coat. If he encounters an officer and turns, haste thee
here before them with the warning. If he goes to his journey’s end,
you will find it at the office of the justice at the corner of the Old
Jewry and Poultry Street. It was there that the charge against me
was sworn to. Ride down Bishopsgate Street to Threadneedle and
then into Poultry. You will know the justice’s office by the red crown
in the stone wall above the doorway. Watch the actions of the man.
If a constable starts from the office upon Bame’s arrival, see to it
that such officer is interrupted by hook or crook, until thou hast
reason to believe that London Bridge lies between us.”
Tabbard had risen before the last word was spoken, and saying,
“You can trust me to keep your way clear,” he disappeared.
The man Bame paused not a moment on reaching the road, but
hastily crossed the bridge over the moat, passed through the wide
gate and strode on toward the south. Although he walked with
alacrity, a galloping rider coming in his wake had overtaken him
before he entered the street now known as Threadneedle. Crowds of
people were moving in all directions, but the broad-brimmed hat of
the man on foot and his long coat could be easily distinguished, and
the rider, slackening his horse’s pace, rode only fast enough to keep
this figure in view.
Contrary to the expectation of the rider, Bame, instead of going into
and through Poultry Street, turned northerly and passed into
Lothbury, by the residences of rich merchants, by the Lothbury
45. entrance of the Windmill tavern, which was once a Jewish
synagogue, by the low-built stone shops of coppersmiths and
founders of candlesticks, lamps and dishes, and around the corner of
the Old Jewry. Here before an arched entrance of the long stone
building, known as the Old or Prince’s Wardrobe, he encountered a
broad-shouldered man in leather doublet and jerkin, and, as the two
halted for a moment, Tabbard dismounted and tied his horse at the
corner of the parish church of St. Olave.
Tabbard could not overhear the conversation between the two men;
but as they moved, he followed to a building with quaint gables
projecting over the broad windows of two upper stories and a wide
stone entrance, above which was a great crown made of iron, set in
the grimy wall, and painted red. It was the house in which Thomas à
Becket first saw the light of day. Bame and his companion entered
this building, and Tabbard, leaning against a thick window frame
near the door, and on a level with his breast, looked through one of
the small squares of glass.
Several candles had already been lighted in the room, for the high
walls of the structures facing on the street, aided by the fog, made
the interior as obscure as the hold of a vessel with closed hatches.
He saw a man with periwig clapped on his gray head, beard trimmed
like an ace of spades with sharp end down, and a loose taffeta
gown, girt at his gross waist by a buff leather belt. He filled a chair
large enough for two men as slender as Tabbard, and had his eyes
been less confused by waking suddenly from a comfortable nap, or
wide open instead of blinking, he might have seen the curious
outsider.
Even Bame’s self-possession was disturbed in the presence of the
awakening conservator of the peace, and as noiseless as a drummer
in retreat from battle, he bowed most humbly.
“Well,” thundered the dazed justice, “who now, Gyves? Is this thy
last catch? And is it bail or the jail? What——”
46. “Nothing of that sort, your honor,” interrupted the constable, for
such he was.
“No,” began Bame, gaining confidence in himself from the
knowledge that the justice required some information which he
could advance, “I am Richard Bame, who swore to the accusation of
blasphemy against——”
“Tut, tut, I know thee,” exclaimed the justice, cutting him short and
reaching across the table for a folded paper, “here, Gyves, this is the
warrant,” he continued. “It hath lain here to await information of the
whereabouts of the rogue. And where is he?”
“At the Dolphin tavern, in Bishopsgate, without the wall,” answered
Bame.
“I know not the place. Is it within the ward?”
“’Tis next outside the gate.”
“Then the arrest can be made there by this constable.”
“True, your honor,” murmured the latter, “it is the new ale-house this
side of Fisher’s Folly where the bowling alleys are.”
“Get you off, rascal, and bring him in.”
“He is a young man and wears a black cloak, scarlet doublet, and
cap with white feather. His horse is gray and perchance you may
meet him on the road,” said Bame impressively and repeated the
description, while the constable kept nodding his head in token of
the reception and retention of the words.
As the constable came from the justice’s office into the street he ran
into Tabbard who had purposely placed himself in his way. The latter
gave utterance to a groan and limped as Gyves stammered an
apology for his apparent clumsiness.
47. “My leg,” whined Tabbard, “is badly knocked. You must help me to
the wine room of the Windmill across the way.”
“I can do that much for you,” returned the constable, taking his arm,
and across the uneven street, not yet lighted by the watchmen’s
lanterns, nor disturbed by the bellman’s drowsy tinkling, the
scheming Tabbard proceeded with his prospective comrade for an
evening’s carousal. Meanwhile the man left at the Dolphin tavern,
settled his bill, mounted his horse and was riding down Bishopsgate
Street toward London Bridge.
48. THE DRAWN SWORD.
Therefore sheath, your sword;
If you love me no quarrels in my house.
* * * * *
Here must no speeches pass, no swords be drawn.
—Jew of Malta, ii, 3.
Gentle Mercutio, put thy rapier up.
* * * * *
Beat down their weapons.—Gentlemen, for shame,
Forbear this outrage:
—Romeo and Juliet, iii, 1.
The plague, which thinned the population of London in 1593, was
not wholly confined to the city and its suburbs. Several of the
villages lying adjacent had been unable to bar its visitation. Travelers
on foot, on horse, or by boat upon the Thames, had aided in
spreading the germs. At the village of Deptford, situate three and a
half miles from London Bridge, cases had increased so that a
quarantine had, as early as June the first, been established against
all boats approaching the city side. It was not so easy to delay travel
along the public roads, and as yet the town lay open for another
visitation should the cases already within its limits be suppressed.
Two wayfarers had been struck down before the Golden Hind that
day. Dodsman, the landlord of this Deptford tavern, had allowed
them to be carried around to the stables, and left there to die, which
they did before night; and then, because of fear of infection, he had
49. discharged his two servants who had attended them. It was a duty
that he owed to the traveling public, so he asserted, and there
seemed weight in the assertion. It is to be supposed that any case
within the tavern walls would also have vitally affected his interests;
for he knew not whether the legal obligation to mark a red cross on
the outer door, with the text under it of “Lord have mercy upon us”
was strictly confined to the limits of London. As it was, this double
death-stroke had carried consternation into the crowd of refugees
who, fleeing this far, had complacently halted for the epidemic to die
out. If they did not depart on the morrow, it would be because they
trusted more to tavern walls than to the open road.
On this particular night, being the night of the day on which our
narrative begins, the tavern doors were closed. Only storms had
heretofore kept them from being open until midnight at least. There
was no reason to believe that death might not just as easily enter
through the keyholes as through open portals, and throttle one at
the fireside; but closed quarters seemed to assure safety. Dodsman,
at least, felt no fear when thus shut within his tap-room; and his
constant rule was to interpret other people’s feelings by the state of
his own when in like situations.
With his fat hands resting on the thick sill of a window, he stood
looking out into the uninviting night. The diamond-shaped panes of
variegated colors were not the clearest material to look through, but
they were transparent enough for him to see that the lantern
hanging from the arm of the high sign post at the tavern’s front was
lighted. The rays of this signal light had sufficient penetration to
reveal the wooden figure of a gilded deer, of life size, mounted upon
the sign post, and any belated traveler upon the fog-wrapped road
could by these rays alone have seen the red-painted facade of the
building, its bulging upper windows and the pedimented entrance.
The tavern had been erected early in the reign of Henry the Eighth,
so that the sunshine and tempests of eighty years had fallen upon it.
It was of two stories, the second with bay windows; and its rambling
50. front, plastered and painted red, rose close to the edge of the
highway. A few straggling dwellings of Deptford lay on the north and
west side of it, but the town proper lay so far to the south and east
that the tavern itself might almost be termed a wayside inn. There
was another house for travelers, at Redriffe, but this was much
meaner in pretensions, and interfered little, if at all, with the
business of the Golden Hind. The pretensions of the latter were
considerable, if from the gleams of art and the occasional display of
extravagance in the interior decorations, were to be drawn an
opinion in regard to want, or excess, of show.
There was stucco work in the ceiling of the tap-room, not plain, but
bearing raised arms, which better befitted the walls of the dining
room of some castle. In each corner, close to the ceiling, were
medallion figures of satyrs, while full-length images of these sylvan
demi-gods danced on raised panels in the center of each side of the
room, painted there with apparent reckless abandonment. One
smaller than the others was over the door, another was between two
square windows at the north, another repainted so that the original
lower goat legs and hoofs of the figure were surmounted by a like
body and head and horns, shone, in broken colors, from above the
bar, while the last of the four, recently retouched but not altered,
stood out on the wide chimney above the black fireplace.
This satyr was not the only decoration of the chimney-piece, for
above it a great bat extended its dusky wings, and under it hung a
long bow such as were even then used at the practice of archery in
Finbury Fields, and other commons in the vicinity of London.
There were other paintings in the rooms besides those in the panels.
From the cracked appearance of their canvas, and dingy hues, they
gave evidence of greater age than the cruder work of the former;
but of the collection of the portraits of two kings, one landlord and
an oxhead, not one would have been attributed to an Italian master.
Which were of the kings and which was of the ox could be still
distinguished upon careful observation.
51. The bar ranged on one side, and seemed of different growth from
the room, for there was nothing ornate about it except the decanters
and bottles on the shelf behind it. It appeared to have been dragged
in after some predecessor of Dodsman had planned to adapt the
room to uses other than those of dining, for which it had been
originally designed. Hence, tap-room it was, with its sanded floor,
round tables, uncomfortable wooden chairs, wherein the unrest of
occupants could only be drowned in sack or ale, despite the
inharmonious garnishments of walls and ceilings.
At the moment the landlord was staring through the window, the
short hand on the copper face of the old clock behind the bar was
pointing to the figure eight. Several candles in bronze holders at the
angles of the chimney, and at both ends of the bar, were blazing;
and above the room’s center, the immense brass chandelier hung
with every one of its big lamps lighted. Directly under it stood a
round table bearing on its top several silver mugs.
At the table were three men. They were all young in years, without
trace of past cares, and undisturbed with apprehensions of the
future. Two of the trio were attired in black doublets and hose, and
to judge by their dress or faces were little likely to attract attention
in any place. Their dark cloaks were hung against the wall at the
back of their chairs, and their hats were on the floor beside them.
The other member of the group was of more distinguished
appearance. His age was apparently thirty years. Although smooth-
shaven and of British cast of countenance there was something
about him that bespoke the foreign extraction of the man. It was not
in his speech, for his English accent was perfect; neither was it in his
dress, for that, although rich and elaborate, was clearly of the style
peculiar to the better class of London residents. His coat of buff
color, with loose sleeves, was edged with ruffles at collar and wrists,
and was the most striking feature of his dress. He appeared a
gentleman of quality, and as though he recognized his superiority
over his companions, he kept his head covered with a broad-
52. brimmed felt hat. It was thrown back on his head so that the long
black plumes touched his shoulder.
The two men first described were members of the Earl of Sussex’s
company of actors; their companion was one known as Francis
Frazer, nicknamed the Count by those who had heard of his asserted
claims to an estate on the continent, or had known him before his
imprisonment in the Tower, from which place he had issued under
his present name. He claimed to be a member of the scattered
family of La Marche, of royal lineage, but driven by the fury of the
civil wars of France to remain an exile from that country.
His recitals of the wrongs suffered by his father, and the obstacles
that impeded his own return to the land of his nativity, were
confused when, at times, he became communicative over his cups.
In sober moments a veil, impenetrable as steel, concealed from
chance companions even the events of the yesterday of the man;
and chance companions were all that he associated with. He had no
followers, no local habitation, and was looked upon as an
adventurer.
His constant disappearances from one haunt for months, and then
reappearances, without word of departure, notice of expected
return, or disclosure of the place and purpose of his absence,
naturally made him an object of suspicion. Once he had been thrown
into the Tower, and, after languishing for two years under a charge
that fell to pieces when the attention of the body in authority was
turned to it he was liberated, but not without a warning for him to
keep himself in retirement. It was because of this warning that he
had adopted the name of Frazer.
On this evening the two actors and Frazer had been thrown together
in the tap-room. One of the former and Frazer had met before, so
that, from their first calls for ale, there was enough of good-
fellowship between them to keep the cup circling. Besides the mugs
upon the table, was another article that seemed strangely out of
53. place. It was the naked sword of the so-called Count, with its basket
hilt close in front of the owner. It lay there glistening under the light
of the lamps like a menace to good cheer and humor. The handle of
the sword and the handle of the mug were constantly encountering
each other, as the owner, at intervals, reached for, quaffed from, and
reset the latter.
Its presence had raised no comment, until the red-headed tapster, in
placing a re-filled mug upon the table, spilt some of the contents
upon the glistening steel. In doing this he had reached across
Frazer’s knees and before he could withdraw his arm and fully
recover his balance, a strong hand caught him by the shoulder and
flung him backwards upon the floor.
Dodsman turned from the window, as he heard the fall, and the
clatter of an empty mug. He circled around the sprawling man and
approached the group, which was laughing boisterously at the
tapster’s mishap. Mine host, concealing his anger with the policy of
one who knew that the dents in his silverware could only be offset
by the fund which must follow from the carousal, simply said:
“How now, fellow? Curses upon thy clumsiness,” to his man, and
then looked inquiringly at the Count.
“He’s wet the blade which only blood should stain,” said its owner,
drawing it across his knee. Again they laughed.
“And why is it drawn except in defense of honor, or the Queen?”
asked Dodsman.
Frazer scowled, but the host with his white beard, red cheeks and
pleasant eyes was no mean appearing person, and the former felt
called upon to say:
“When death stalks so close to one as he has for the past two weeks
in London streets, it is well to have thy weapon drawn at all times.”
54. “A ready reply,” returned Dodsman, “but of no great weight.”
“Well,” said the other, “if straight answer you must have, I had
drawn it to exhibit it. It is seldom that a blade of this character falls
into the hands of any one save a peer of the realm. Look at it
closely, mine host,” he exclaimed, holding it aloft in the direction of
Dodsman, and wielding it with the ease and grace of one
accustomed to its use.
“Dost see its variegated watered appearance?” he continued, “like
those of Damascus make. Such it might be deemed to be, but here
it bears the stamp of Andrea de Ferrara. How many two-edged
blades of Toledo didst thou ever see drawn?”
“Few, good Count, but the less the better. This is a quiet house. I
aim for the entertainment of those, whom, whilst they here talk war
and duels, go elsewhere to engage in them.”
Several loud knocks at the outer door now resounded through the
room. The tapster, who meanwhile had raised himself from the floor,
shot back a bolt and drew in one wing of the two massy doors. The
darkness of the night could not conceal the mud-set stones of the
pavement, for the lights of the room streamed upon them. A man
stood there, with cloak wrapped close to his form and as high as his
eyes, apparently to keep from his face the increasing fog of the
night. He held the bridle of a horse in one hand and handing this to
the serving man, he strode into the room. As he swung back his
cloak, the face was disclosed of the man who had ridden with
Tabbard from Finbury Fields.
One of the two actors recognized him at once and cried out:
“Welcome, Kit. Thy tankard is ready.”
He turned from noticing that the time by the clock was only a few
minutes past eight, and with a remark to Dodsman to see to it that
55. his horse was properly fed and bedded, went over to the party of
three men.
“Already lodged near Sayes Court?” He spoke interrogatively.
“Yes,” rejoined one of the others. “You know the Count?”
“Most assuredly,” he answered.
Frazer nodded his head with the remark: “I remember the one
occasion.”
“In the tireing room at the Curtain, last winter, when between the
acts in Tamburlaine, you showed me the counter parades in quarte
and tierce. I have since put the lesson to good use, and have
brought the house down by its exhibition. Didst thou ever see him
fence, Bartol?” he inquired of the actor who was seated opposite
himself.
“Not I,” answered Bartol.
“It would do your heart good unless the encounter were in real
earnest and thyself an actor in it. And then thy life would not be
worth a tuppence. How ready lies thy blade for an occasion of that
kind,” he added, noticing the sword still laid across the table.
“Your praise is high,” said Frazer. “As for the sword, the hilt, when in
its place, interferes with my elbow when I drink.”
“Three reasons now for its drawing,” murmured the landlord to
himself, as, near at hand, he had been quietly listening to the
conversation. “The fourth reason will undoubtedly be the true one.”
“And when did you leave the city?” asked Bartol.
“Nearer seven than six by the clock in the tower at the Southwark
end of the London Bridge,” answered the late comer.
56. “Did you pass the morris-dancers?”
“Will Kemp and his company?”
“Yes, they left here late in the day. His taborer and two pretty
dancers were with him,” said Bartol.
“They were performing on the bridge as I rode across it. I reined in
my horse near the center of the bridge before the chapel of St.
Thomas. There they danced in the narrow way, with nearly every
inhabitant of the bridge either standing crowded in a circle around
them or looking out of the windows of their darksome shops. It
delayed me long.”
“But not against thy will, I am sure,” remarked Frazer, looking
searchingly at the speaker, over his raised cup.
“And why so?”
“Were the fair dancers no attraction? If they were not, there must
have been something pulling thee strongly in this direction. Perhaps
it is a fairer lady.”
He seemed to speak advisedly.
“True,” chuckled the landlord to himself, “and I wonder does he
know that she who was once the sweet maid of Canterbury lieth
here?”
“If so,” returned Marlowe with some irritation caused by the tones of
Frazer, “it is not a matter either for mention or discussion.”
“We will drink to her,” interrupted Bartol, “be she fair or plain, maid
or spouse, young or old. Here is to thy loadstone, Kit.”
“Not without mention of her name,” said Frazer, coldly.
57. “You will drink to her unknown or not at all,” responded Marlowe,
with considerable animation.
“Then not at all,” returned Frazer.
The two men stared at each other as though the breath of a coming
quarrel had touched their faces.
“Come,” exclaimed the actor, who thus far had remained silent. “This
is a raw gust that bloweth. If the gentleman knoweth a lady, I
warrant she is sweet enough for all glasses to be emptied in her
praise and honor. But he has not said that he knoweth any. And, on
the other hand, if the other gentleman hath some one in mind,
whom he would not pledge in reckless sort, is that not good reason
to let his lips go dry? Come, Dodsman, hast thou a box and dice?”
“Tug, the box,” said the landlord to the tapster.
“Is it to be at hazard?” asked Bartol.
“What you will,” answered the other.
“Set down thy mug,” he thundered to Marlowe, who seemed
wrapped in other thoughts.
“And Count,” said the landlord, “I will set thy sword here against the
wall.”
“Well, enough,” smoothly remarked the one addressed, who,
adventurer as he was, at mention of the dice let all his thoughts of
quarrel slip.
“You three play,” said Marlowe, “I will look on.”
“As usual——” began Bartol.
“With only the dregs of a once full bottle,” muttered Marlowe,
finishing his friend’s remark.
58. Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade
Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.
Let us accompany you on the journey of exploring knowledge and
personal growth!
textbookfull.com