• Menu
  • Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

JavaBeat

Java Tutorial Blog

  • Java
    • Java 7
    • Java 8
    • Java EE
    • Servlets
  • Spring Framework
    • Spring Tutorials
    • Spring 4 Tutorials
    • Spring Boot
  • JSF Tutorials
  • Most Popular
    • Binary Search Tree Traversal
    • Spring Batch Tutorial
    • AngularJS + Spring MVC
    • Spring Data JPA Tutorial
    • Packaging and Deploying Node.js
  • About Us
  • Java
    • Java 7
    • Java 8
    • Java EE
    • Servlets
  • Spring Framework
    • Spring Tutorials
    • Spring 4 Tutorials
    • Spring Boot
  • JSF Tutorials
  • Most Popular
    • Binary Search Tree Traversal
    • Spring Batch Tutorial
    • AngularJS + Spring MVC
    • Spring Data JPA Tutorial
    • Packaging and Deploying Node.js
  • About Us

Anees Asghar

How to Format a String With printf() in Java

March 8, 2024 //  by Anees Asghar

To format a string with printf() in Java, execute the “System.out.printf()” statement with the “%s” or “%S” format specifier.

Category: Java

How to Sort a Map by Value in Java

March 8, 2024 //  by Anees Asghar

In Java, you can sort a map by value using three methods: “Collections.sort()”, “Stream().sorted()”, and “Custom Comparators”.

Category: Java

How to Use StringUtils Class in Java

February 29, 2024 //  by Anees Asghar

To Use the StringUtils class in Java, add its corresponding Apache Commons dependency in a “pom.xml” file of your maven project.

Category: Java

How to Use String.replaceAll() Method in Java

February 29, 2024 //  by Anees Asghar

The “String.replaceAll()” method is used to replace all occurrences of a specific character, word, or substring, with a new character, word, or substring.

Category: Java

How to Use String substring() Method in Java

February 29, 2024 //  by Anees Asghar

To use the String substring() method in Java, follow the syntax “inputString.substring(int startIndex);” or “inputStr.substring(int startIndex, int endIndex);”.

Category: Java

How to Use Set contains() Method in Java

February 29, 2024 //  by Anees Asghar

In Java, the set contains() method accepts the target element as a parameter and is used with a dot syntax: “setName.contains(Object targetElement);”.

Category: Java

How to Get the Current Working Directory in Java

February 29, 2024 //  by Anees Asghar

To get the current directory in Java, you can use the classes like “System”, “Paths”, “File”, “FileSystems” and “SystemUtils”.

Category: Java

How to Use Increment ++ Operator in Java

February 22, 2024 //  by Anees Asghar

Increment “++” is one of the unary operators in Java that increments the variable value by one. It is used either as a pre-increment “++i” or post-increment “i++”.

Category: Java

  • « Go to Previous Page
  • Page 1
  • Page 2
  • Page 3
  • Page 4
  • Page 5
  • Page 6
  • Interim pages omitted …
  • Page 8
  • Go to Next Page »

Primary Sidebar

Follow Us

  • Facebook
  • Pinterest

FEATURED TUTORIALS

How to Initialize an Array in Java

Introduction to Java Server Faces (JSF)

Introduction to Java 6.0 New Features, Part–1

Java 6.0 Features Part – 2 : Pluggable Annotation Processing API

Introduction to Java Server Faces(JSF) HTML Tags

JavaBeat

Copyright © by JavaBeat · All rights reserved
Privacy Policy | Contact