¡@

Home 

java Programming Glossary: dosomethingelse

Purpose of ThreadLocal?

http://stackoverflow.com/questions/1490919/purpose-of-threadlocal

resp User user getLoggedInUser req doSomething doSomethingElse renderResponse resp Now what happens if the doSomething methods.. resp User user getLoggedInUser req doSomething user doSomethingElse user renderResponse resp user A more elegant solution is to.. req StaticClass.getThreadLocal .set user try doSomething doSomethingElse renderResponse resp finally StaticClass.getThreadLocal .remove..

Dynamically find the class that represents a primitive Java type

http://stackoverflow.com/questions/180097/dynamically-find-the-class-that-represents-a-primitive-java-type

names with lists of parameter types doSomething int double doSomethingElse java.lang.String boolean If the input was something like java.lang.String..

Why do we need break after case statements?

http://stackoverflow.com/questions/2710300/why-do-we-need-break-after-case-statements

'A' case 'B' case 'C' doSomething break case 'D' case 'E' doSomethingElse break etc. Just an example. In my experience usually it is bad..

How expensive are Exceptions [duplicate]

http://stackoverflow.com/questions/567579/how-expensive-are-exceptions

piece of code in our software private void doSomething try doSomethingElse catch DidNotWorkException e log A Message goOn private void.. DidNotWorkException e log A Message goOn private void doSomethingElse if isSoAndSo throw new DidNotWorkException goOnAgain How is.. performance of this compared to private void doSomething doSomethingElse goOn private void doSomethingElse if isSoAndSo log A Message..

What is the Java ?: operator called and what does it do?

http://stackoverflow.com/questions/798545/what-is-the-java-operator-called-and-what-does-it-do

. So you cannot compress this if someBool doSomething else doSomethingElse into this someBool doSomething doSomethingElse share improve..

Does setting Java objects to null do anything anymore?

http://stackoverflow.com/questions/850878/does-setting-java-objects-to-null-do-anything-anymore

... doSomethingWith obj obj null explicitly set to null doSomethingElse The rationale here was that because obj is still in scope then.. it does not become garbage collectable until after the doSomethingElse method completes. And this is the advice that probably no longer..

Switch without break

http://stackoverflow.com/questions/8563970/switch-without-break

So for instance switch foo case 0 doSomething case 1 doSomethingElse default doSomeOtherThing This is perfectly valid Java but it.. If foo is 0 all three of the functions doSomething doSomethingElse and doSomeOtherThing run in that order . If foo is 1 only doSomethingElse.. and doSomeOtherThing run in that order . If foo is 1 only doSomethingElse and doSomeOtherThing run. If foo is any other value only doSomeOtherThing..