JDK 1.4 Tutorial, eDoc 5 : Inspecting and Creating Stack Traces Buy on Amazon
Facebook LinkedIn

JDK 1.4 Tutorial, eDoc 5 : Inspecting and Creating Stack Traces

9.95 USD

Available for download now

Book Details
Author(s) Gregory Travis
ISBN / ASIN B00006928S
ISBN-13 978B000069283
Availability Available for download now
Sales Rank #11,516,661
Marketplace United States 🇺🇸
Ratings & Reviews No reviews yet — be the first!

No reviews yet.

Description

JDK 1.4 provides a couple of powerful new Exceptions features -- chained exceptions and StackTraceElements.

Chained exceptions formalize the idea that one exception can trigger another. In this e-doc, you'll learn how they work, what they replace, and how to traverse a chain of exceptions.

StackTraceElements provide programmatic interface to stack traces, which are generated as part of an exception. This is a good deal more convenient than generating a stack trace dump and parsing the output. In this e-doc, you'll learn how to access and use StackTraceElements. You'll also learn how to create a StackTraceElement, and you'll learn when this is appropriate to do.

This e-doc will show you how to:

  • Interpret chained exceptions
  • Traverse an exception chain
  • Create an exception chain
  • Access and view StackTraceElements
  • Synthesize StackTraceElements

Sample programs included in this chapter:

  • A custom stack-trace dumper that shows the source code context for each line of the exception
  • A task system which executes tasks in a thread pool and synthesizes correct exceptions for exceptions within the pool
Donate to EbookNetworking
No Prev
No Next