In this example, we will discuss in detail about Method Handles in Java, a feature introduced in Java 1.7. We will talk about the Java Reflection API and its performance issues, method handles, why were they introduced, and how to create and use them. 1. The Java Reflection API The old school Java Reflection API (introduced in Java 1.1) is ...
Read More »Home » Archives for Anmol Deep »
Java Naming Conventions
In this example, we will be discussing naming code conventions for the Java Programming Language. We will talk about different identifier types and the best practices to follow while naming them in your program. 1. Introduction As a team member of a codebase of any size (small, medium, or large), it is the responsibility of the programmer or the developer ...
Read More »Java Parse String Example
In this example, we shall learn about the different techniques to parse a String in Java. We will be demonstrating the StringTokenizer class, the String.split() method, and live code examples to leverage these utilities. 1. Introduction The definition of “parse java” in Wiktionary is: “To split a file or other input into pieces of data that can be easily stored ...
Read More »Singly Linked List Java Example
In this example, we shall discuss how to create a Singly Linked List in Java. We will also go through some live code demonstrating different operations on a Singly Linked List. You can also check this tutorial in the following video: Java LinkedList Tutorial – video 1. What is a Linked List? A Linked List is a linear data structure ...
Read More »Copy Constructor Java Example
In this tutorial, we shall discuss the Copy Constructor in Java. In the world of object-oriented programming, a copy constructor is a special type of constructor that takes an object of the same class as an argument and returns a duplicate or a copied instance of the input object initialized with the values of the member variables of the passed ...
Read More »Java Import Keyword Example
In this example, we will learn about the Java Import keyword. We will talk about Java packages and their types and what problems an import keyword solves when programming in Java. TipYou may skip the packages section and jump directly to the Import keyword section below. 1. Packages A java package is used to group related types(classes, interfaces, enumerations, and ...
Read More »