Interfaces in Golang

  • 10 April 2020
  • ADM

Interfaces are collections of method signatures. A interface type can hold any value that implements those methods. The empty interface is an interface type that specifies zero methods. A type assertion provides access to an interface underlying concrete value. Two interfaces are equal if they have equal concrete values and identical dynamic types, or if both are nil.


All keywords in Java

  • 09 March 2020
  • ADM

Keywords are special words in the programing language which have reserved use in the language. Keywords may not be used as identifiers in Java; for example you cannot declare a field whose name is a keyword.


How to generate a random int in Golang

  • 27 September 2019
  • ADM

In Golang there a are two libraries for generating random integers, one is a pseudo-random number generator (package math/rand) and the second one is cryptographically secure random number generator (package crypto/rand)


How to split a string into slice in Golang

  • 15 May 2019
  • ADM

How to split a string into slice using Golang. For a simple split by a singular character you can use Split() method from strings package. For more complex rules the regexp.Split() method can be used.


Java Custom Annotations Example

  • 26 July 2018
  • ADM

How to create Java Custom Annotation. A simple example of creating Annotations in Java and usage by calling the Reflection API.


How to generate UUID / GUID in Java

  • 19 June 2018
  • ADM

How to generate UUID / GUID in Java using java.util.UUID class, UUID.randomUUID() method.