The Java compiler is able to pre-calculate certain values for us at compile time. This allows us to use some variables with expressions that must be constant, and leads to some runtime efficiencies.
Search Results for: constant declaration
Convert One Enum to Another Enum in Java
A quick and practical guide to convert one enum to another.
The Java final Keyword – Impact on Performance
Explore if there are any performance benefits from using the final keyword on a variable, method, and class
Mutable vs. Immutable Objects in Java
Learn more about the definitions, examples, advantages, and considerations of mutable and immutable objects in Java.
Static Final Variables in Java
In this tutorial, we learn how to declare and initialize constant variables.
Convert an XML File to CSV File
Learn how to quickly convert XML files to CSV using Java
Implementing toString() on enums in Java
Different ways of implementing toString for enums.
Using an Interface vs. Abstract Class in Java
Learn when to use an interface and when to use an abstract class in Java.
Java Class File Naming Conventions
Understand autogenerated class naming conventions in Java.
Using JNA to Access Native Dynamic Libraries
Learn how to use JNA to access native code easily when compared to JNI.
Casting int to Enum in Java
Learn how to cast an int to an Enum in Java
OCP Certification – Advanced Java Class Design
Learn some tips on common aspects of the OCP Certification exam.
Anonymous Classes in Java
Learn about Java anonymous classes.
Attaching Values to Java Enum
Explore features of the Java Enum implementation.
Java Interfaces
Explore the concept of Java interfaces and learn how Java uses them to implement polymorphism and multiple inheritance.
Introduction to Basic Syntax in Java
Explore the basics of Java syntax.
Implementing a Custom Lombok Annotation
Learn how to implement a custom annotation using Lombok handlers.
Basic IntelliJ Configuration
Learn about basic configuration and usage of the IntelliJ IDE
The “final” Keyword in Java
Learn what the final keyword in Java means when applied to classes, methods, and variables.
Overview of Java Built-in Annotations
Discover built-in annotations in Java.