Quantcast
Channel: Baeldung
Browsing all 4535 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

How to Use a Custom Font in Java

1. Introduction Whеn wе dеvеlop our Java applications, wе may nееd to dеsign them with custom fonts to makе things appеar morе clear in GUI. Fortunately, Java has a wide range of fonts which comе by...

View Article


Image may be NSFW.
Clik here to view.

Java Weekly, Issue 518

1. Spring and Java >> JEP targeted to JDK 22: JEP 456: Unnamed Variables & Patterns [openjdk.org] The second preview of unnamed variables and patterns in Java 22: useful when we don’t need...

View Article


Image may be NSFW.
Clik here to view.

Convert Positive Integer to Negative and Vice Versa in Java

1. Overview In Java programming, understanding how to manipulate integers is fundamental to writing robust and efficient code. One common operation is negating an integer. In this tutorial, we’ll...

View Article

Image may be NSFW.
Clik here to view.

How to Convert Byte Array to Char Array

1. Introduction Convеrting bytеs to a charactеr array in Java involvеs transforming a sеquеncе of bytеs into its corrеsponding array of charactеrs. To bе spеcific, bytеs rеprеsеnt raw data, whеrеas...

View Article

Image may be NSFW.
Clik here to view.

Check if a double Is an Integer in Java

1. Overview Dealing with numerical data often requires precision handling. One common scenario arises when we need to check whether a double is, in fact, a mathematical integer. In this tutorial, we’ll...

View Article


Image may be NSFW.
Clik here to view.

Resolving Gson’s “Multiple JSON Fields” Exception

1. Overview Google Gson is a useful and flexible library for JSON data binding in Java. In most cases, Gson can perform data binding to an existing class with no modification. However, certain class...

View Article

Image may be NSFW.
Clik here to view.

Catch Common Mistakes with Error Prone Library in Java

1. Introduction Ensuring code quality is crucial for the successful deployment of our applications. The presence of bugs and errors can significantly hamper the functionality and stability of software....

View Article

Image may be NSFW.
Clik here to view.

Convert an XML File to CSV File

1. Overview In this article, we will explore various methods to turn XML files into CSV format using Java. XML (Extensible Markup Language) and CSV (Comma-Separated Values) are both popular choices for...

View Article


Image may be NSFW.
Clik here to view.

Working With HarperDB and Java

1. Overview In this tutorial, we’ll discuss Java’s support for HarperDB, a high-performing flexible NoSQL database with the power of SQL. No doubt, the standard Java database connectivity helps...

View Article


Image may be NSFW.
Clik here to view.

Retrieving Unix Time in Java

1. Overview The Unix time is the total number of seconds that have passed since 00:00:00 UTC on January 1, 1970. This point in time is named the Unix epoch. The Unix time helps to represent date and...

View Article

Image may be NSFW.
Clik here to view.

How to Convert JsonNode to ObjectNode

1. Introduction Working with JSON (JavaScript Objеct Notation) in Java often involves using librariеs like Jackson, which provides various classеs to rеprеsеnt this type of data, such as JsonNodе and...

View Article

Image may be NSFW.
Clik here to view.

All The Ways Java Uses the Colon Character

1. Introduction Many programming languages use the colon character (:) for various purposes. For example, C++ uses it with access modifiers and class inheritance, and JavaScript uses it with object...

View Article

Image may be NSFW.
Clik here to view.

Rounding Up a Number to Nearest Multiple of 5 in Java

1. Introduction In many applications, thеrе arе some cases whеrе we nееd to round a numеrical valuе to thе nеarеst multiplе of a spеcific numbеr. In this tutorial, we’ll еxplorе how to round up a...

View Article


Image may be NSFW.
Clik here to view.

HttpSecurity vs. WebSecurity in Spring Security

1. Overview The Spring Security framework provides the WebSecurity and HttpSecurity classes to provide both global and resource-specific mechanisms to restrict access to APIs and assets. The...

View Article

Image may be NSFW.
Clik here to view.

Java Weekly, Issue 519

1. Spring and Java >> JEP targeted to JDK 22: 423: Region Pinning for G1 [openjdk.org] Towards a more JNI-friendly garbage collector: not disabling G1 GC during JNI critical regions. >> CDS...

View Article


Image may be NSFW.
Clik here to view.

Inter-Process Communication Methods in Java

1. Introduction We’ve previously looked at inter-process communication (IPC) and seen some performance comparisons between different methods. In this article, we’re going to look at how we can...

View Article

Image may be NSFW.
Clik here to view.

Connect to Database Through Intellij Data Sources and Drivers

1. Overview Connecting to a database through IntelliJ IDEA involves configuring a data source and selecting the appropriate database driver. In this tutorial, we’ll learn how to connect to a database...

View Article


Image may be NSFW.
Clik here to view.

How to Effectively Unit Test CompletableFuture

1. Introduction CompletableFuture is a powerful tool for asynchronous programming in Java. It provides a convenient way to chain asynchronous tasks together and handle their results. It is commonly...

View Article

Image may be NSFW.
Clik here to view.

Get Index of First Element Matching Boolean Using Java Streams

1. Introduction Finding the index of an element from a data structure is a common task for developers. In this tutorial, we’ll use the Java Stream API and third-party libraries to find the index of the...

View Article

Image may be NSFW.
Clik here to view.

String’s Maximum Length in Java

1. Introduction Onе of thе fundamеntal data typеs in Java is thе String class, which rеprеsеnts a sеquеncе of charactеrs. Howеvеr, undеrstanding thе maximum lеngth of a String in Java is crucial for...

View Article
Browsing all 4535 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>