Category Archives

Stuff to learn about Java

Spring Boot – IntelliJ IDEA Not Reloading Static Content

Seems the latest version as of November 20, 2015 of IntelliJ IDEA does not come equipped to reload Spring Boot static content on the fly such as HTML and Javascript files.  After much digging around and some help from a buddy of mine,…

Open eml files in compose mode

Before you get too excited, this solution only appears to work in Outlook and not Thunderbird.  I’ll explain a workaround for Thunderbird, but let’s first get Outlook work and the gist of what this post is about. So I had a situation where…

Java XML Parsing – Preserve XML as is during parsing

I had a unique situation where I needed to parse an XML document using Java, and I needed to preserve some of the XML in the document.  I am so used to parsing XML documents using Node and Element names etc, I could…

Splitting – Parsing a CSV String in Java

I found this to be very useful when I wanted to parse CSV strings into a Java List: Arrays.asList(someCsvString,split(“\\s*,\\s*”)); The nice part with this solution is the regex includes any spaces around the CSV.

Custom JARs in Maven

I had a situation where I have been learning Maven more and more every day and with the new application I was writing, I was splitting the code into separate maven modules/JARs.  When I was first setting up my projects, I soon came…

Comparing Values using BigDecimals in Java

Being a JDK 1.4 programmer for probably far too many years, I was never able to learn the correct ways to use some of the latest JDK 1.5+ features.  Thanks to a colleague that I work with, he was able to give me…

Iterating through HashMaps

In my JDK 1.4 world, I had a very common way of iterating through lists and maps.  Switching to JDK 1.7 had me learning so many new ways of doing things in so many areas.  One of them was iterating over HashMaps, so…

Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom

So you’ve spent countless hours trying to figure out why your pom.xml file generates the following error: Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom I spent a great deal of time looking for proxy issues etc and finally found out that the reason I was having…

Formatting Numbers in Java

I found it a bit confusing figuring out how to format numbers and currency etc in Java, so I thought I would write a quick blog about it.  Lets consider a big number such as: 123,123,123,123.99 There are a number of things we…

Initializing a Web Service in Java

Hopefully you’ve been able to read some articles on my blog related to using Web Services in Java/Websphere and they’ve provided you some assistance.  In relation to that topic, this article simple illustrates how you you can invoke a web service using both…

Categories