|
May
18 |
|
comment |
Not getting any output after calling C executable file from Java code C executables are no different from other executables, at least from the point of view of process execution. As @JunedAhsan points out, the problem is that you have to read the executable's output yourself (and either show it or do something with it). |
|
May
17 |
|
comment |
Best practice for returning multiple values in Java? You can avoid typos and self-document if using an Enum for the key values. |
|
May
17 |
|
answered | Best practice for returning multiple values in Java? |
|
May
17 |
|
comment |
store object during a 10 minute window Surprisingly elegant - congrats. |
|
May
17 |
|
comment |
store object during a 10 minute window @SubSevn but you need to insert everything into the treemap or the deletes will not be consistent (insert 10 equally-max values, remove 9: one is still left; vs remove the 10: have to search for previous). No real savings from storing max separately - either the tree is up to date, or it is not useful. |
|
May
17 |
|
revised |
store object during a 10 minute window incorporated assylias' comment |
|
May
17 |
|
comment |
store object during a 10 minute window good call, @assylias |
|
May
17 |
|
comment |
store object during a 10 minute window the scheduler is overkill; it is better to do cleanup only as new entries arrive (or the 'max' is actually requested). |
|
May
17 |
|
answered | store object during a 10 minute window |
|
May
17 |
|
comment |
deep copy for a graph using hashmap does not work question - why does a vertex map to a pair of map<v,e>? I can understand vertices = Map<V, Map<V,E>> (although it would be simpler to have a Map<V, Set<E>>), but why the extra pair? |
|
May
17 |
|
answered | Java regular Expression to replace System.out.println patterns |
|
May
17 |
|
comment |
Security concerns and architecture in PHP using per-user, random, large salts is at least as important as the hashing algorithm itself. Don't forget your salt! No salt = asking for collisions (as in two users using the same password) and rainbow-tables. |
|
May
17 |
|
comment |
Check for filenames with version fields larger than those of a given filename Edited to try to make the question stand out more. Please comment if over-edited. |
|
May
17 |
|
revised |
Check for filenames with version fields larger than those of a given filename clarified question, made the actual question stand out, simplified title |
|
May
17 |
|
answered | Check for filenames with version fields larger than those of a given filename |
|
May
17 |
|
comment |
How to delete duplicates? AFAIK, no - keeping a linked list around should have additional costs. Also, this is not faster than sorting + removing neighboring duplicates (unless the number of duplicates is truly large) |
|
May
17 |
|
answered | How to delete duplicates? |
|
May
14 |
|
comment |
a free solution to package java web application with tomcat to an exe @david99world Fully agree; my point is that obfuscation may not be perfect, but it is as perfect as it gets. More security can only be bought at the cost of an always-online requirement and part of the code running on a (vendor-controlled) server. |
|
May
14 |
|
answered | a free solution to package java web application with tomcat to an exe |
|
May
14 |
|
comment |
a free solution to package java web application with tomcat to an exe There is no way to make a self-contained exe that does not contain the code (in binary, as a compiled exe). Therefore, obfuscation is all you can hope for. If obfuscation is not a solution, then no solution exists. |