Browse by Topic

Popular

Latest

Latest Java Posts

Diagram showing Java stream map transforming a collection of elements into a new collection.
Java

Java Stream map: Transforming Elements with Examples

Learn how to use Java Stream map to transform elements, with syntax, examples, and performance considerations for real-world code.

Java StreamsFunctional ProgrammingStream.mapJava 8
A Java stream pipeline with a filter operation selecting elements that match a predicate.
Java

Java Stream filter(): Usage, Predicates, and Performance

Learn how to use Java Stream filter() with Predicate, combine conditions, avoid common mistakes, and understand important performance tradeoffs.

Java StreamsStream APIPredicateFunctional Programming
Illustration of the Java Stream.of factory method converting individual values into a sequential stream pipeline.
Java

Java Stream.of: Creating Streams from Fixed Values

Learn how to use Java Stream.of to create streams from fixed values, avoid the primitive array trap, and choose the right stream factory method.

Stream APIStream.ofJava collectionsFunctional programming
Diagram showing an array being transformed into a stream pipeline with filter and map operations
Java

Java Arrays Stream: Convert and Process Arrays

Learn to convert Java arrays to streams, apply functional operations, and handle primitive arrays with practical examples and performance notes.

JavaStreamsArraysFunctional Programming
Illustration of a Java collection being transformed into a stream pipeline with filter and map operations
Java

Java Collection Stream: Filter, Map, and Collect

java collection stream: Learn how to convert collections to streams, apply filter, map, and collect operations, and understand performance and thread-safety tradeoffs.

Java StreamsCollection OperationsFunctional ProgrammingStream API
Diagram showing different sources feeding into a Java Stream pipeline.
Java

Java Stream Creation: From Collections, Arrays, and Generators

Learn how to create Java streams from collections, arrays, generators, and files, with practical examples and performance tradeoffs.

Stream APIJava CollectionsFunctional ProgrammingJava I/O
Illustration showing a data pipeline of Java stream operations transforming collection elements through filter, map, and collect stages into a structured result.
Java

Java Stream API: Practical Patterns and Pitfalls

Understand the Java Stream API through practical examples covering lazy evaluation, collectors, parallel streams, performance, and common pitfalls.

Java StreamsFunctional ProgrammingJava CollectionsStream Performance
A Java developer choosing between a method reference and a lambda expression for a stream operation, with a split visual showing the two syntax forms.
Java

Java Method Reference vs Lambda: When to Use Each

Compare Java method references and lambda expressions: learn the syntax differences, compile-time behavior, readability tradeoffs, and when to use each form.

JavaLambda ExpressionsMethod ReferencesFunctional Interfaces
Diagram showing a constructor reference pointing from a functional interface to a Java class constructor
Java

Java Constructor Reference: Syntax and Use

Understand Java constructor references, how they match functional interfaces, and when to use them in modern Java code.

JavaConstructor ReferencesMethod ReferencesFunctional Interfaces
Diagram showing a method reference from a class to an instance method invoked on an arbitrary object in a stream pipeline.
Java

Java Arbitrary Object Method Reference

Learn how arbitrary object method references work in Java, how they differ from bound references, and when to use them in stream pipelines.

method referenceslambda expressionsfunctional interfacesstreams