≡ Menu

@Useful

I had no idea that there was a @NonNull annotation in Java.  Well, it is kinda in Java.  Close enough.

https://blogs.oracle.com/java-platform-group/entry/java_8_s_new_type

@Tainted and @Untainted look useful too.  Given the annotation processing features and IDE/checker support, annotations could become indispensable in solid Java coding.

How to Learn IntelliJ Keyboard Shortcuts

Two ways I know of:

1) Use the Key Promoter plugin.  This will show you the keyboard shortcut when you perform a command using the mouse.  I have similar extensions in other programs and find them very useful.

2) CMD-SHIFT-A.  You can then type a command name and in addition to allowing you to perform the command, it will show you the shortcut you could use.

Oh, and if you want some pointers, here are two:

1) https://www.jetbrains.com/idea/help/keyboard-shortcuts-you-cannot-miss.html

2) http://www.jetbrains.com/idea/docs/IntelliJIDEA_ReferenceCard_Mac.pdf

Continuous Testing Within the IDE

Stumbled upon a plugin to IntelliJ and Eclipse today that continuously runs unit tests for you.  It analyzes the code to know which unit tests will be affected by source changes.

http://infinitest.github.io/

I like the idea a lot, but find the execution lacking.  For example, the icon is red even when there are no errors**.  I would expect green.  Also, when it does find errors, it doesn’t allow you to double click on an issue to go straight to the culprit.

I hope it is updated to add those and other features to make this a truly useful tool.

** Well, actually that isn’t true.  I had a problem in my project where IntelliJ was confused.  The icon in fact goes green when the unit tests pass, which is nice.  You still cannot double click on errors though.

It is quite amazing how easy it is to do micro-benchmarking incorrectly.  Here’s some information if you don’t believe me:

https://wiki.openjdk.java.net/display/HotSpot/MicroBenchmarks

https://wiki.openjdk.java.net/display/HotSpot/PerformanceTechniques

https://julien.ponge.org/blog/avoiding-benchmarking-pitfalls-on-the-jvm/

http://stackoverflow.com/questions/11227809/why-is-processing-a-sorted-array-faster-than-an-unsorted-array

Groovy News

In other news, Groovy could be at a crossroads with Pivotal pulling out of funding Groovy development.

http://www.theregister.co.uk/2015/01/22/open_source_java_grails_and_groovy_as_pivotal_pulls_out/

Maybe if Oracle were smart they would fund it and pull in the developers to merge Groovy and Java?

Move fast and break things

Erik sure gets passionate about eradicating agile:

http://www.theregister.co.uk/2015/01/08/erik_meijer_agile_is_a_cancer_we_have_to_eliminate_from_the_industry/

Samsung Note 4 Things To Do

If you are wondering what the first 13 things are you should do with your new Note 4 phone, then look no further.

http://phandroid.com/2014/10/17/galaxy-note-4-first-13-things/

It’s a great list especially if you are unfamiliar with Android because you are moving away from iPhone.

Functional Refactoring with Java 8 Video

Watched this video recently which goes over some of the new features of Java 8.  Definitely worth watching:

via: http://virtualjug.com/pragmatic-functional-refactoring-with-java-8

Faaasssttttt!

Java is high performance. By high performance we mean adequate. By adequate we mean slow.

– http://www.mrbunny.com/

A Cup of Ceylon

Just read a recent article about the JVM targeted language Ceylon.  As with most JVM languages, it has some interesting features and solves some of the irksome aspects of Java.  However, I don’t see that the advantages currently outweigh the pain.  Moving to a new language with its own issues is a big step.  Sometimes the devil you know is the better option.  How then does the new pretender supplant the bloated incumbent?

http://www.dzone.com/articles/java-scala-ceylon-evolution