Third for [java] and second for [concurrency]

First to get the silver [jvm] badge, second to gold [performance] badge.

3h
comment Overriding equals for CopyOnWriteArraySet.add and remove
equals must be associative as documented in Object.equals() i.e. a.equals(b) == b.equals(a) otherwise you will get confusion.
3h
comment Dynamically create methods in java
BTW, You will want to use a HashMap instead of a Hashtable, unless you really have to.
4h
revised How to dynamically load a Java class without using a class loader?
added 286 characters in body
4h
answered How to dynamically load a Java class without using a class loader?
4h
comment Does java support pointers?
While Java doesn't support pointers, you can access memory by address. using Unsafe on some JVM, though it is discouraged, or not allowed by the SecurityManager.
4h
comment Does java support pointers?
A reference to an Object can be null.
4h
comment Does java support pointers?
Internally the null reference is actually 0. At least it is on OpenHFT/Hotspot though it is not defined in the JLS. You can see the actual addresses used via sun.misc.Unsafe.
4h
comment Simpe UDP optimisation
@Dexter The packet loss is likely to vary on a range of factors including the network between the server and the device itself. You may find you need to adapt what you do based on the client. i.e. you should get feedback from the device as to what the miss rate is. You might have to send each packet twice, say half a second apart to ensure you get almost every packet at least once.
1d
comment Where to find the source code of how Java create's an array
The code which does this is in the JVM. You can look at the source in OpenJDK but it will be in C rather than Java.
1d
comment Reading from multiple sockets in java
You need to read() from the Socket's InputStream in three threads at once. Am I missing something?
1d
comment My Java interface and abstract method nightmare ... (now with code)
d1.subDays(n) should just call d1.addDays(-n)
1d
comment How to improve performance of charAt with BigIntegers?
@user1613360 The trick to remember is that most of these sort of puzzles are mathematical in nature rather than plan programming tasks. Find a mathematical transformation which is cheaper and you will be dramatically faster.
1d
revised How to improve performance of charAt with BigIntegers?
added 114 characters in body
1d
comment How to improve performance of charAt with BigIntegers?
@DavidConrad Thank you, however I suspect the OP want the product of some numbers. I guess you meant to include 625.
1d
revised How to improve performance of charAt with BigIntegers?
added 114 characters in body
1d
answered How to improve performance of charAt with BigIntegers?
1d
comment How convert file. a to .c or other extension? I need read file .a
This doesn't appear to have anything to do with [java]
1d
revised How convert file. a to .c or other extension? I need read file .a
edited tags
1d
comment Store Long[] and Integer[] in the same HashMap using Generics
@BenBeri it would if you had defined T somewhere.
1d
comment Do default constructors for private inner classes have a formal parameter?
@yshavit BTW The JVM doesn't support private or protected classes. Marking the class private or protected changes the modifier for the default constructor. Also the JVM doesn't support calling a private constructor from another class. Thus a synthetic constructor is added to the "private class" so it can be constructed from another class.
1 2 3 4 5