Nothing new, but because I needed a neat list of what kind of lambda I can pass as a parameter for a method, here it is: Class to useinput paramsreturn valuenoteRunnablerun()()Supplierget()xCallablecall()x throws exceptionConsumeraccept(x)()BiConsumeraccept(x,y)()Functionapply(x)yinput/return types can be differentBiFunctionapply(x,y)zinput/return types can be differentPredicatetest(x)booleanUnaryOperatorapply(x1)x2input/return types are the sameBinaryOperatorapply(x1,x2)x3input/return types are the same Code example: public void someMethod(Function<String, Integer>… Continue reading Using Java lambdas as method parameters
This is the follow-up of Learn dApp coding by writing a Blockchain Trading Bot - Part 1. If you haven't, you should read it first. Now that we know how to connect to our wallet, we are going to trade tokens. Tokens are instances of cryptocurrencies. Smart Contracts A blockchain allows you to record transactions.… Continue reading Learn dApp coding by writing a Blockchain Trading Bot – Part 2 : Trade cryptocurrencies.
Here's a challenge for you, Java developers. You'd like to write some open source code, but you don't know where to start? You'd like to work on a small and fun coding project, that you can do in a couple of days? You want to take on an interesting challenge, trying to write some nice… Continue reading Single File Java Challenge
The Terracotta Server Array (TSA) provides the platform for Terracotta products and the backbone for Terracotta clusters. It allows, for instance, to use Ehcache in a clustered mode, and benefit of a distributed in-memory cache. It is available as open source, and you may want to contribute to it, or even just build it yourself… Continue reading Terracotta OSS dev starter
BigMemory is the java solution that allows you to store terabytes of data in distributed memory across multiple servers without performance hits from the Java garbage collector, thus improving the speed of your application, as your data can be accessed directly from memory. With the release of 4.1, a number of improvements and new features… Continue reading BigMemory 4.1 technical overview
I wrote a little utility class to get the OS details in Java. As you may know, you can get the name, version and architecure of your OS in java by using System properties. But this information is limited. For instance, on Mac Os, you will get the version but can not know what is… Continue reading Get your OS distribution details in Java
Ceci est un petit article afin de partager mon expérience, et donner quelques conseils, pour ceux qui désirent partir travailler aux Etats-Unis. Mon expérience est celle d'un développeur, mais la plupart des informations sont applicables pour la plupart des expatriés du tertiaire. Je travaille depuis un peu plus de trois ans en tant que développeur… Continue reading But alors you are french?
The Terracotta Toolkit is an API that provides you many functionalities in a clustered manner. E.g., you can get a Clustered ReadWrite Lock, so you can do synchronization between different applications running on different machines/JVMs. In 3.7, you get the Toolkit like this: ClusteringToolkit toolkit = new TerracottaClient("localhost:9510").getToolkit(); In 4.0, you get the Toolkit like… Continue reading Terracotta toolkit