Scriptsmount a free web scripts directory provides website scripts, webmaster scripts, web directory scripts, directory scripts, php scripts, perl scripts, cgi scripts, html scripts, database scripts, asp.net scripts, form scripts, guestbook scripts for webmasters
Web Scripts :: Java :: Java Tips and Tutorials :: Development
21.
Diagnosing Java Code : The Orphaned Thread bug pattern
|
|
In multithreaded code, it is often common to use a single, master thread that drives the actions the other threads take. This master thread may send messages, often by placing them on a queue, that are then processed by the other threads. But if the master thread throws an exception, the remaining threads may continue to run, awaiting more input to the queue, causing the program to freeze. This article discusses detecting, fixing, and avoiding this bug pattern.
Hits: 40 Rating: 0.00 Votes: 0
[Detail]
[Send URL]
Category: Java :: Java Tips and Tutorials :: Development
|
22.
Diagnosing Java Code: The Impostor Type bug pattern
|
|
When special tags in fields are used to distinguish between types of objects, errors are possible in which a tag mislabels the associated data -- a bug pattern known as the Impostor Type. This article examines the symptoms and causes of this bug, defines ways to prevent this error from occurring, and discusses a tempting hybrid implementation that does not use impostor types but, in the end, turns out to have many of the same weaknesses. Article includes code snipets.
Hits: 37 Rating: 0.00 Votes: 0
[Detail]
[Send URL]
Category: Java :: Java Tips and Tutorials :: Development
|
23.
Improve the performance of your Java code
|
|
Many algorithms are expressed most concisely as tail-recursive methods. Compilers can automatically transform such methods into loops and thereby improve program performance, but this transformation is not required by the Java language specification, so not all JVMs will perform it. This means that tail-recursive methods in the Java language can result in unexpectedly large memory usage. This article demonstrates that dynamic compilation maintains the language's semantics while static compilation often doesn't. Learn why this matters and get a bit of code to help you determine whether your just-in-time (JIT) compiler can transform tail recursion on code while preserving semantics.
Hits: 34 Rating: 0.00 Votes: 0
[Detail]
[Send URL]
Category: Java :: Java Tips and Tutorials :: Development
|
24.
How to lock down your Java code
|
|
You inevitably spend some part of your week crunching code that you didn't write, and for which you may not have the source. This beginner's guide to opening up and locking down Java code walks you through the essentials of disassembling, decompiling, and obfuscating Java code, using examples from popular tools such as Mocha, HoseMocha, jmangle, and JODE.
Hits: 27 Rating: 0.00 Votes: 0
[Detail]
[Send URL]
Category: Java :: Java Tips and Tutorials :: Development
|
|
|
|
|