The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

texture (13) [Avatar] Offline
#1
If the book can be more clear about where the snippets are then it could save me a lot time.

I suggest adding the names of the class + package as a reference.
mike.mccandless (221) [Avatar] Offline
#2
Re: Difficulty to find the correct source code to test
Yeah sorry about that. It may've been better to name the packages by chapter/appendix number too...

Most of the time it's pretty clear where the code example will live right?

We try hard not to include redundant info in the cost listings (eg imports are not listed as well for that reason).

Also, we can't really change this at this point -- the manuscript is now basically frozen except for small fixes.
texture (13) [Avatar] Offline
#3
Re: Difficulty to find the correct source code to test
Some of them were easy to find but when the snippets only show the name of the method then the problem starts.

Nevertheless the book is an excellent source to get indepth knowledge about Lucene and complementary tools.
texture (13) [Avatar] Offline
#4
Re: Difficulty to find the correct source code to test
How about just updating the source code? Adding the chapter, section and listing numbers to the package. Is it viable?
mike.mccandless (221) [Avatar] Offline
#5
Re: Difficulty to find the correct source code to test
Hmm I think that's a good idea! I'll do that. Thanks!
texture (13) [Avatar] Offline
#6
Re: Difficulty to find the correct source code to test
Thank you for accepting my suggestion.

Please also consider this one. I found assertion is a good tool to check the code but when using in a text book it renders sometimes hard to read. I explain why:

- The reader need to take into consideration the kind of assertion used: true, false, ...
- Sometimes the assertion compares the output with a number, but for the user it is hard to know what output was that.

So, I suggest removing the assertions and replace them with println .
mike.mccandless (221) [Avatar] Offline
#7
Re: Difficulty to find the correct source code to test
Thanks for the suggestion...

We actually do a mix in the book (sometimes print things, though not often); maybe we should do more prints.

But, the book is now done -- it's already done to press. So we can think about this for the next one!
yonofui (10) [Avatar] Offline
#8
Re: Difficulty to find the correct source code to test
When the source code will be updated, as promised in this thread?
mike.mccandless (221) [Avatar] Offline
#9
Re: Difficulty to find the correct source code to test
The source code was already updated to list the chapter number at the top of the sources (look for comments like // From Chapter 5).

But the other suggestions came too late -- the book has already shipped -- so I won't be updating the sources based on that. We can think about it for the next edition though smilie

Mike
yonofui (10) [Avatar] Offline
#10
Re: Difficulty to find the correct source code to test
I cannot find comments like // From Chapter 5 in the sources downloaded from http://www.manning.com/hatcher3
Do I miss something?
Are you sure you uploaded the updated sources?
yonofui (10) [Avatar] Offline
#11
Re: Difficulty to find the correct source code to test
Sorry, looked at the old version of the source code...
When the new version with the chapters was uploaded?
mike.mccandless (221) [Avatar] Offline
#12
Re: Difficulty to find the correct source code to test
OK glad you found them! I'm not sure when the last update was... I think shortly before going to press in July?

Mike