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

- 7 submitted: last submission 10 Dec 2015

The latest update on the code in this book can be found in the author's GitHub page at
https://github.com/peterpilgrim/javaee7-developer-handbook

Page : 45 | Errata type: Technical

The following line in the last paragraph of the Basic injection section:
For now, we will assume that the lifetime of the bean typed live for the duration of the application.

should be
For now, we will assume that these bean types exist for the lifetime of the application's deployment.

Page : 29 and 31 | Errata type: Technical

ProjectTasksService should be ProjectTaskService

Page : 50 | Errata type: Grammar

The last sentence of the page:


With CDI, we use special custom annotation for this.

should be
With CDI, we use a special custom annotation for this.

Page : 151 | Errata type: Technical

The line above the second code snippet is


The file, which is specific only to the GlassFish application server, and is
named src/test/resources-glassfish-embedded/glassfish-resources.xml is
as follows:

It should be
The file, which is specific only to the GlassFish application server, and is
named src/test/resources-glassfish-embedded/logging.properties is
as follows:

Page : 19 | Errata type: Technical

The third point of the page is


JSON-P 1.0: This is a brand new framework for the Java application
read-and-write JavaScript Schema Object Notation (JSON) documents

It should be
JSON-P 1.0: This is a brand new framework for the Java application
read-and-write JavaScript Object Notation (JSON) documents

Chapter number 4 is titled as Essential Java Persistence API 3.2


It should be Essential Java Persistence

Page : 129 | Errata type: Technical


The third paragraph of the page starts with
The Java Persistence API (JPA), JSR 338, Version 3.2 is the specification that mandates how persistence can be
applied...

It should be
The Java Persistence API (JPA), JSR 338, Version 2.1 is the specification that mandates how persistence
can be applied...

On page 209
The second code example is identical to the one on page 208.

Before the call to em.persist(employee); the bidirectional relation should


be setup by adding a call to address.setEmployee(employee);

Page: 215
The correct code ispublic boolean addPhone( Phone phone) {

if ( ! phones.contains( phone) ) {
Employee oldEmployee = phone.getEmployee();
if ( oldEmployee != null ) {
removePhone( phone )
}
phones.add( phone );
return true;
}
else { return false; }
}

public boolean removePhone( Phone phone ) {


if ( phones.contains( phone) ) {
phones.remove(phone);
phone.setEmployee(null);
return true;
}
else {
return false;
}
}

You might also like