Tag archives for Java - Page 2
Learn to create a Snake game in Java 2D
Snake is a classic video game in which a player controls a Snake that must eat apples and avoid walls. Each time, you eat an apple, the Snake grows. The Snake's goal is to eat the maximum of apples. It's a game of kind infinite. Snake is also an ideal game to create when you want to learn to create 2D…
Discover Java 9 Top 5 Features
After some delays, Java 9 should be released in March 2017 with a lot a various new features. In this article, we let you to discover the Top 5 of new features expected with Java 9. 1. Java comes modular with Jigsaw Expected since Java 7, the project Jigsaw should become a reality with Java 9. Main goal of Jigsaw…
Create your first JNI Application on Android with the NDK
Like you must know, Java is the default programming language to make applications on Android. However, Java is not always the best solution for making fast apps, especially if you want to make games. A lot of games’ engines are made directly with C/C++. To let developers to make optimized part of codes in C/C++, Google offers the Android Native…
Create your first JavaFX 8 Application with Eclipse
Directly integrated in the JDK of Java 8, JavaFX is the new recommended way to create and deliver desktop applications and rich internet applications (RIA) in Java. JavaFX must replace Swing as the standard GUI library for Java SE. However, both technologies will continue to be integrated in the JDK. You can have a preview of the JavaFX Architecture in…
Calculate shortest paths in Java by implementing Dijkstra’s Algorithm
Conceived by Edsger W. Dijsktra in 1956 and published three years later, Dijkstra’s algorithm is a one of the most known algorithms for finding the shortest paths between nodes in a graph. This algorithm is applied in a lot of domains. For example, once you have represented road networks in a graph, it becomes easy to calculate shortest paths inside…
Jury rules in Google’s favor over Oracle : Android makes “fair use” of Java APIs
At the end of a two-week trial, a federal jury concluded that Android, the Google’s Mobile Operating System, makes "fair use" of Java APIs. Android doesn’t infringe Oracle-owned copyrights. Indeed, the Google’s re-implementation of 37 Java APIs is protected by "fair use" doctrine. After three days of deliberations, the jury unanimously answered "yes" in Google’s favor to the following question…
Learn to make a MVC application with Swing and Java 8
The Model-View-Controller is a well known software architectural pattern ideal to implement user interfaces on computers by dividing an application intro three interconnected parts. Main goal of Model-View-Controller, also known as MVC, is to separate internal representations of an application from the ways information are presented to the user. Initially, MVC was designed for desktop GUI applications but it’s quickly…
Implement the Adapter Design Pattern in Java
In software engineering, a design pattern is a general reusable solution to a commonly occurring problem with a given context in software design. In that new serie of articles, you're going to discover how to implement some of the most known design patterns in Java. To start the serie, you're going to study the Adapter Design Pattern. The Adapter Design…
Use your Java classes in the browser with JavaPoly.js
Java has always been usable in the browser since its creation. However, the browser needed the specific Java plugin to execute Java applications that was packaged inside applets. Then, a more flexible solution was created with Java Web Start but finally, it was always based on the applet technology. With the end announced of plugins support in browsers like Chrome…
Discover OkHttp, a powerful HTTP & HTTP/2 client for Android applications
Created by Square, OkHttp is an open source project designed to be an efficient HTTP and HTTP/2 client. It lets you to make fast requests and save bandwith. It offers some great features out of the box like to share a socket for all HTTP/2 requests to the same host, a connection pooling mechanism when HTTP/2 is not available, transparent…