Explain Codes LogoExplain Codes Logo

Java

@requestparam vs @PathVariable

java
requestparam
pathvariable
url-encoding

Convert String to double in Java

java
input-sanitization
bigdecimal
error-handling

How to for each the hashmap?

java
hashmap
lambda
iterator

What is the equivalent of Java static final fields in Kotlin?

java
kotlin
constants
javainteroperability

Scanning Java annotations at runtime

java
reflection
spring
classgraph

Compare two objects in Java with possible null values

java
null-safety
equals
comparator

How to avoid "ConcurrentModificationException" while removing elements from `ArrayList` while iterating it?

java
concurrent-modification
arraylist
multithreading

How do I trim a file extension from a String in Java?

java
file-extension
edge-cases
unit-testing

When should I use the "strictfp" keyword in Java?

java
strictfp
performance
best-practices

Get file name from URL

java
file-handling
commons-io
regex

How can I pad a String in Java?

java
padding
string-formatting
guava

Should I use Java's String.format() if performance is important?

java
stringbuilder
performance
readability

Get java.nio.file.Path object from java.io.File

java
path
file-operations
exception-handling

Jsp tricks to make templating easier?

java
templating
tag-files
jstl

How do I get the current index/key in a "for each" loop

java
for-each
index-tracking
java-8

Converting double to string

java
string-formatting
decimalformat
error-handling

How to get a thread and heap dump of a Java process on Windows that's not running in a console

java
heap-dump
thread-dump
visualvm

Split string to equal length substrings in Java

java
string-splitting
regex
guava

Create `ArrayList` from array

java
arrays
guava
streams

How do I determine whether an array contains a particular value in Java?

java
arrays
streams
performance