Skip to content

Commit fe73b32

Browse files
committed
configure images to preview properly on GitHub
- set imagesdir per document - remove hardcoded path to images in image macros - override imagesdir in convert script - use proper inline image syntax - update convert script to accept list of formats - set doctype to book in document
1 parent 619d583 commit fe73b32

18 files changed

+213
-148
lines changed

docs/chapters/acks.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
== Acknowledgements
24

35
The following Java EE community members graciously reviewed and contributed to this hands-on lab:

docs/chapters/appendix.adoc

Lines changed: 86 additions & 84 deletions
Large diffs are not rendered by default.

docs/chapters/batch.adoc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
[[batch]]
24
== Ticket Sales (Batch Applications for the Java Platform)
35

@@ -13,7 +15,7 @@ Applications for the Java Platform (JSR 352) will define a programming
1315
model for batch applications and a runtime for scheduling and executing
1416
jobs.
1517

16-
image::images/5.0-batch-intro.png[title="Introduction to Batch"]
18+
image::5.0-batch-intro.png[title="Introduction to Batch"]
1719

1820
The core concepts of Batch Processing are:
1921

@@ -303,7 +305,7 @@ the bean to be injectable in an EL expression.
303305
+
304306
Resolve the imports.
305307
+
306-
image::images/5.10-imports.png[title="RequestScoped import"]
308+
image::5.10-imports.png[title="RequestScoped import"]
307309
+
308310
. Inject `EntityManagerFactory` in the class as:
309311
+
@@ -392,13 +394,13 @@ needs to be repeated for `f:` prefix.
392394
+
393395
. Run the project to see the output as shown.
394396
+
395-
image::images/5.14-sales.png[title="Sales link on main page"]
397+
image::5.14-sales.png[title="Sales link on main page"]
396398
+
397399
Notice, a new `Sales' entry is displayed in the left navigation bar.
398400
+
399401
. Click on `Sales' to see the output as shown.
400402
+
401-
image::images/5.15-sales.png[title="Movie Sales page"]
403+
image::5.15-sales.png[title="Movie Sales page"]
402404
+
403405
The empty table indicates that there is no sales data in the database.
404406
+
@@ -407,7 +409,7 @@ file. Look for `Waiting for localhost' in the browser status bar,
407409
wait for a couple of seconds for the processing to finish, and then
408410
click on `Refresh' button to see the updated output as shown.
409411
+
410-
image::images/5.16-sales-output.png[title="Movie Sales output page"]
412+
image::5.16-sales-output.png[title="Movie Sales output page"]
411413
+
412414
Now the table is populated with the sales data.
413415
+

docs/chapters/conclusion.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
== Conclusion
24

35
This hands-on lab built a trivial 3-tier web application using Java EE 7

docs/chapters/introduction.adoc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
== Introduction
24

35
The Java EE 7 platform continues the ease of development push that
@@ -49,7 +51,7 @@ http://netbeans.org/downloads/[http://netbeans.org/downloads/]. A
4951
snapshot of the downloads page is shown and highlights the exact
5052
`Download' button to be clicked.
5153
+
52-
image::images/1.1-netbeans-download.png[title="NetBeans download"]
54+
image::1.1-netbeans-download.png[title="NetBeans download"]
5355
endif::ide-netbeans[]
5456
+
5557
ifdef::server-glassfish[]

docs/chapters/jaxrs.adoc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
[[jaxrs]]
24
== View and Delete Movie (Java API for RESTful Web Services)
35

@@ -38,7 +40,7 @@ Resolve the imports.
3840
+
3941
WARNING: Make sure to pick `javax.enterprise.context.RequestScoped` class.
4042
+
41-
image::images/6.2-imports.png[title="RequestScoped import"]
43+
image::6.2-imports.png[title="RequestScoped import"]
4244
+
4345
. Add the following code to the class:
4446
+
@@ -139,7 +141,7 @@ Click on the yellow bulb in the left bar to resolve the namespace
139141
prefix-to-URI resolution. This needs to be completed for `h:`, `c:`,
140142
and `f:` prefixes.
141143
+
142-
image::images/6.6-imports.png[title="Namespace prefix imports"]
144+
image::6.6-imports.png[title="Namespace prefix imports"]
143145
+
144146
. Right-click on `org.javaee7.movieplex7.client' package, select
145147
`New', `Java Class', specify the value as `MovieBackingBean' and click
@@ -174,7 +176,7 @@ WARNING: Make sure to import `javax.enterprise.context.SessionScoped`.
174176
Running the project (Fn + F6 shortcut on Mac) and clicking on `Movies'
175177
in the left navigation bar shows the output as shown.
176178
+
177-
image::images/6.8-output.png[title="List of movies output page"]
179+
image::6.8-output.png[title="List of movies output page"]
178180
+
179181
The list of all the movies with a radio button next to them is
180182
displayed.
@@ -252,7 +254,7 @@ using the `id`, `name`, and `actors` property values.
252254
select a radio button next to any movie, and click on details to see the
253255
output as shown.
254256
+
255-
image::images/6.12-output.png[title="Movie Details page"]
257+
image::6.12-output.png[title="Movie Details page"]
256258
+
257259
Click on the `Back' button to select another movie.
258260
+
@@ -293,7 +295,7 @@ Make sure to resolve the imports.
293295
+
294296
Running the project shows the output shown.
295297
+
296-
image::images/6.14-output.png[title="Delete button"]
298+
image::6.14-output.png[title="Delete button"]
297299
+
298300
Select a movie and click on Delete button. This deletes the movie from
299301
the database and refreshes list on the page. Note that a redeploy of the

docs/chapters/jms.adoc

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
[[jms]]
24
== Movie Points (Java Message Service)
35

@@ -37,7 +39,7 @@ passivated with the request.
3739
+
3840
Resolve the imports.
3941
+
40-
image::images/8.2-imports.png[title="RequestScoped import"]
42+
image::8.2-imports.png[title="RequestScoped import"]
4143
+
4244
. A message to a JMS Queue is sent after the customer has bought the
4345
tickets. Another bean will then retrieve this message and update the
@@ -266,41 +268,41 @@ message is displayed on the screen.
266268
+
267269
. Run the project. The update page looks like as shown:
268270
+
269-
image::images/8.10-output.png[title="Points link on main page"]
271+
image::8.10-output.png[title="Points link on main page"]
270272
+
271273
Click on `Points' to see the output as:
272274
+
273-
image::images/8.10-output2.png[title="Points output page"]
275+
image::8.10-output2.png[title="Points output page"]
274276
+
275277
The output shows that the queue has 0 messages. Enter a message `1212'
276278
in the text box and click on `Send Message' to see the output as shown.
277279
+
278-
image::images/8.10-output3.png[title="Validation message on Points page"]
280+
image::8.10-output3.png[title="Validation message on Points page"]
279281
+
280282
This message is not meeting the validation criteria and so the error
281283
message is displayed.
282284
+
283285
Enter a message as `12,12' in the text box and click on `Send Message'
284286
button to see the output as:
285287
+
286-
image::images/8.10-output4.png[title="Correct input for Points page - Send Message (queue size=1)"]
288+
image::8.10-output4.png[title="Correct input for Points page - Send Message (queue size=1)"]
287289
+
288290
The updated count now shows that there is 1 message in the queue. Click
289291
on `Receive Message' button to see output as:
290292
+
291-
image::images/8.10-output5.png[title="Correct input for Points page - Receive Message (queue size=0)"]
293+
image::8.10-output5.png[title="Correct input for Points page - Receive Message (queue size=0)"]
292294
+
293295
The updated count now shows that the message has been consumed and the
294296
queue has 0 messages.
295297
+
296298
Click on `Send Message' 4 times to see the output as:
297299
+
298-
image::images/8.10-output6.png[title="Correct input for Points page - Send Message (queue size=4)"]
300+
image::8.10-output6.png[title="Correct input for Points page - Send Message (queue size=4)"]
299301
+
300302
The updated count now shows that the queue has 4 messages. Click on
301303
`Receive Message' 2 times to see the output as:
302304
+
303-
image::images/8.10-output7.png[title="Correct input for Points page - Receive Message (queue size=2)"]
305+
image::8.10-output7.png[title="Correct input for Points page - Receive Message (queue size=2)"]
304306
+
305307
The count is once again updated to reflect the 2 consumed and 2
306308
remaining messages in the queue.

docs/chapters/jsf.adoc

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
[[jsf]]
24
== Show Booking (JavaServer Faces)
35

@@ -76,7 +78,7 @@ commandButton refers to the next view in the flow, i.e.
7678
Click on the yellow bulb as shown and click on the suggestion to
7779
add namespace prefix/URI mapping for `h:`. Repeat the same for `f:` prefix as well.
7880
+
79-
image::images/9.3-imports.png[title="Namespace prefix mapping imports"]
81+
image::9.3-imports.png[title="Namespace prefix mapping imports"]
8082
+
8183
. Right-click on `Source Packages', select `New', `Java Class'.
8284
Specify the class name as `Booking' and the package name as
@@ -368,24 +370,24 @@ which defines the flow of the pages.
368370
. Run the project by right clicking on the project and selecting
369371
`Run'. The browser shows the updated output.
370372
+
371-
image::images/9.11-output.png[title="Book a movie link on main page"]
373+
image::9.11-output.png[title="Book a movie link on main page"]
372374
+
373375
Click on `Book a movie' to see the page as shown.
374376
+
375-
image::images/9.11-output2.png[title="Book a movie page"]
377+
image::9.11-output2.png[title="Book a movie page"]
376378
+
377379
Select a movie, say `The Shiningr and click on `Pick a time' to see the
378380
page output as shown.
379381
+
380-
image::images/9.11-output3.png[title="Show Timings page"]
382+
image::9.11-output3.png[title="Show Timings page"]
381383
+
382384
Pick a time slot, say `04:00', click on `Confirm' to see the output as shown.
383385
+
384-
image::images/9.11-output4.png[title="Confirm? page"]
386+
image::9.11-output4.png[title="Confirm? page"]
385387
+
386388
Click on `Book' to confirm and see the output as:
387389
+
388-
image::images/9.11-output5.png[title="Reservation Confirmed page"]
390+
image::9.11-output5.png[title="Reservation Confirmed page"]
389391
+
390392
Feel free to enter other combinations, go back and forth in the flow and
391393
notice how the values in the bean are preserved.

docs/chapters/json.adoc

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
[[json]]
24
== Add Movie (Java API for JSON Processing)
35

@@ -50,11 +52,11 @@ this implementation will consume a JSON representation of the resource.
5052
+
5153
Make sure to resolve imports from the appropriate package as shown.
5254
+
53-
image::images/7.2-imports.png[title="Provider import"]
55+
image::7.2-imports.png[title="Provider import"]
5456
+
5557
. Make the class implements `MessageBodyReader<Movie>`.
5658
+
57-
image::images/7.3-implements.png[title="Implement abstract methods for MessageBodyReader"]
59+
image::7.3-implements.png[title="Implement abstract methods for MessageBodyReader"]
5860
+
5961
Click on the hint (shown as yellow bulb) on the class definition and
6062
select `Implement all abstract methods'.
@@ -132,7 +134,7 @@ this implementation will produce a JSON representation of the resource.
132134
+
133135
Resolve the imports as shown.
134136
+
135-
image::images/7.6-imports.png[title="Provider import"]
137+
image::7.6-imports.png[title="Provider import"]
136138
+
137139
. Make this class implement `MessageBodyWriter` interface by adding the following code:
138140
[source, java]
@@ -142,7 +144,7 @@ Resolve the imports.
142144
+
143145
The IDE provide a hint to implement abstract methods as:
144146
+
145-
image::images/7.7-implements.png[title="Implement abstract methods for MessageBodyWriter"]
147+
image::7.7-implements.png[title="Implement abstract methods for MessageBodyWriter"]
146148
+
147149
Click on the hint (show as yellow bulb) on the class definition and
148150
select `Implement all abstract methods'.
@@ -230,7 +232,7 @@ then renders `movies.xhtml'.
230232
Click on the hint (show as yellow bulb) to resolve the namespace
231233
prefix/URI mapping as shown.
232234
+
233-
image::images/7.11-imports.png[title="Namespace prefix mapping imports"]
235+
image::7.11-imports.png[title="Namespace prefix mapping imports"]
234236
+
235237
. Add `movieName` and `actors` field to `MovieBackingBean` as:
236238
+
@@ -273,17 +275,17 @@ the POJO to JSON. Media type of `application/json` is specified using `MediaType
273275
+
274276
Resolve the imports as shown
275277
+
276-
image::images/7.14-imports.png[title="Entity import"]
278+
image::7.14-imports.png[title="Entity import"]
277279
+
278280
. Run the project to see the updated main page as:
279281
+
280-
image::images/7.15-output.png[title="New Movie button"]
282+
image::7.15-output.png[title="New Movie button"]
281283
+
282284
A new movie can be added by clicking on `New Movie' button.
283285
+
284286
. Enter the details as shown:
285287
+
286-
image::images/7.16-output.png[title="Add a New Movie page"]
288+
image::7.16-output.png[title="Add a New Movie page"]
287289
+
288290
Click on `Add' button. The `Movie Id' value has to be greater than 20
289291
otherwise the primary key constraint will be violated. The table
@@ -292,6 +294,6 @@ sequence; however this is not done in the application.
292294
+
293295
The updated page looks like as shown
294296
+
295-
image::images/7.16-output2.png[title="Newly added movie"]
297+
image::7.16-output2.png[title="Newly added movie"]
296298
+
297299
Note that the newly added movie is now displayed.

docs/chapters/revision.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:imagesdir: ../images
2+
13
== Revision History
24

35
. Added IntelliJ IDEA specific instructions. (Jan 22, 2014)

0 commit comments

Comments
 (0)