Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Demos, Demos, Demos

A list of the demo projects I created for various posts and videos - they include the snippets shown therein and then some. Now they wait for you to try them out.

A fair share of my posts demonstrate how to use Java language features, how to get the most out of APIs, how to implement a pattern in modern Java, and so forth. For most of them I created dedicated demo projects and here's a list of them.

So if you're the kind of person who prefers to learn from code rather than blog posts or videos, why not check them out and play with the code yourself?

Java X Demo

A project showcasing all important Java 9-16 features

Here's a list of the posts that reference it:

Image with slug implementing-gatherers
Implementing New Java Stream Operations#video#streams
Implementing a bunch of Gatherers to better understand the proposed addition to the stream API
Image with slug java-13-guide
Definitive Guide To Java 13#post#java‑13
A detailed guide to Java 13: text blocks, switch expressions with yield, ZGC, dynamic AppCDS archives
Image with slug java-12-experiments
Java 12 Experiments (Live Stream)#video#java‑12
In my first live stream ever (yay!), we explored Java 12's API improvements
Image with slug talk-java-var
Fun With var#talk#anonymous‑classes #default‑methods #generics #lambda #java‑10 #var
A live-coding talk where I show off all you need to know about var in Java. And then some.
Image with slug java-12-switch-expression
First Contact with Switch Expressions in Java 12#video#java‑12 #switch
With Java 12, switch is no longer just a statement, but becomes an expression. Let's take a look!
Image with slug var-java-10
First contact with var in Java 10#video#java‑10 #var
How to use var, where it works and where it doesn't (and why), and how it might impact readability
Image with slug java-9-stream
Java 9 Additions To Stream#post#java‑9 #streams
Java 9 is coming! One of the many changes are new Stream methods: takeWhile, dropWhile, and ofNullable. For more fun with streams!

Modern Java in Action

A GitHub Crawler with everything Java (21) has to offer

Here's a list of the posts that reference it:

Image with slug talk-java-action
Modern Java in Action#talk#java‑21 #virtual‑threads #pattern‑matching #records
Let's write a GitHub Crawler and let's throw in everything Java (23) has to offer

Loom Lab

Experiments with Project Loom's virtual threads and structured concurrency

Here's a list of the posts that reference it:

Module System Woes

Common problems that pop up in modularized projects and their solutions or workarounds

Here's a list of the posts that reference it:

Image with slug talk-java-modules-irl
Java Modules in Real Life#talk#j_ms #migration
Advice on why, when, when not, and how to use Java modules in real life for your projects

J_MS Monitor

An example project making full use of the Java module system and all its features

Here's a list of the posts that reference it:

Image with slug build-modules
Java Modules Cheat Sheet#post#j_ms #java‑9 #java‑11
A cheat sheet for building and running Java modules from the command line with javac, jar, and java

Java After Eight

A real-life code base, initially on Java 8, that invites an update to Java 15 and to the many new language features, additional and improved APIs, and JVM capabilities

Here's a list of the posts that reference it:

Effective Java

A code base with examples, tests, and benchmarks for my YouTube series on Effective Java, Third Edition

Here's a list of the posts that reference it:

Image with slug effective-java-builders
Use Builders... Cautiously - Effective Java, Item 2#video#book‑club #patterns
Why and how to avoid the builder pattern and how to make best use of it if you can't
Image with slug effective-java-static-factory-methods
Static Factory Methods - Effective Java, Item 1#video#book‑club #patterns
How to use static factory methods to overcome three shortcomings of constructors
Image with slug effective-java-kickoff
Kicking off a series on Effective Java, Third Edition#video#book‑club
Kick-off to
a YouTube series on Effective Java, Third Edition - let's find some angles Josh didn't cover

Java 9/11 Migration

A Java 8 code base that causes some migration challenges when updated to Java 9/11

Here's a list of the posts that reference it:

JUnit 5 Demo

A demo showing off all essential and many advanced JUnit 5 features

Here's a list of the posts that reference it:

Image with slug junit-5-parameterized-tests-nighthacking
Parameterized Tests in JUnit 5#video#junit‑5
At JavaLand 2017, I spent 15 minutes exploring JUnit 5's (then) brand-new parameterized test feature in a NightHacking session

Maven Java 9+

Different ways to build projects on Java 9 and later with Maven

Here's a list of the posts that reference it:

JSR 305 on Java 9+

An exploration into various ways of getting JSR 305 to work on Java 9

Here's a list of the posts that reference it:

Jigsaw vs Reflection

An experiment with Project Jigsaw's encapsulation and reflection

Here's a list of the posts that reference it:

JUnit Lambda Lab

An experiment with the JUnit Lambda prototype

Here's a list of the posts that reference it:

Benchmark Lab

A collection of various JMH-based Java benchmarks

Here's a list of the posts that reference it:

Image with slug java-stream-performance-your-ideas
Stream Performance - Your Ideas#post#java‑8 #performance #streams
Another post about stream performance - this one implements your ideas about how else to approach the topic.
Image with slug java-stream-performance
Stream Performance#post#java‑8 #performance #streams
A close look at stream performance. How do they compare to for and for-each loops oder arrays and lists. And what role plays boxing?

Pirate-Elvis Operator

A small project containing the Pirate-Elvis operation and some example uses

Here's a list of the posts that reference it:

Javadoc 8 Tags

A demo showing @apiNote, @implSpec, and @implNote in action, including the necessary additions to Maven's pom.xml and the generated javadoc

Here's a list of the posts that reference it:

Instances of Non-Capturing Lambdas

An exploration into the JVM's reuse of non-capturing lambda expression instances

Here's a list of the posts that reference it:

Serialize Optional

A demo showing how to use the serialization proxy pattern to serialize Optional instances

Here's a list of the posts that reference it:

Image with slug serialize-java-optional
Serialize Optional#post#java‑8 #optional #serialization
A summary of why you can't serialize Optional and what can be done to deal with that limitation if necessary.

Serialization Proxy Pattern

A demo of the serialization proxy pattern

Here's a list of the posts that reference it:

Decorator Pattern With Java 8

A demo of how to better use the decorator pattern with Java 8 features

Here's a list of the posts that reference it: