How to get local computer name and IP in Java

  • 05 March 2018
  • ADM

How to get local computer name and IP in Java. Simple snippet using InetAddress.getLocalHost() method.


HTTP URLConnection with proxy in Java

  • 08 February 2018
  • ADM

How to create an HTTP URLConnection with proxy in Java. Simple example including proxy authentication.


How to Check Alexa Rank in Java

  • 16 November 2017
  • ADM

How to Check Alexa Rank in Java using the undocumented API: http://data.alexa.com/data?cli=10&url=domainName. The code contains also the possibility of adding proxy settings


How to sort TreeMap in descending order in Java

  • 15 June 2017
  • ADM

How to sort TreeMap in descending order in Java. A simple example using a string as keys.


SWT Button Selection Event

  • 05 June 2017
  • ADM

SWT Button Selection Event. A simple example using SelectionListener interface to add an event to a button.


SWT update UI from another thread

  • 05 June 2017
  • ADM

SWT update UI from another thread. Used for long running operations and to avoid the UI being frozen during the operation.