Tutorials
Step-by-step lessons for people who are new to Java. Each one explains the ideas, then shows a small program you can run, with its real output and screenshots.
How to use the tutorials#
Every tutorial has a program in the folder samples/UsingJava/tutorials. Read the explanation, run the program, change it, and try the exercises at the end. The programs are tested together with the rest of the package, so the output you see here is the output you will get.
cd samples/UsingJava/tutorials
ring ch01_first_look.ring # a console tutorial
ring ch16_window.ring # a windowA window stays open until you close it. To close it automatically after a time, set RINGJAVA_AUTOCLOSE to a number of milliseconds first.
The lessons about databases, JSON and HTML (12 to 14) download a package from Maven Central the first time; after that they run from the cache in ~/.ringjava/maven. Lesson 15 compiles a Java class, so it needs a JDK.
The lessons#
| Part | Lessons |
|---|---|
| The basics | A first look, Text, Numbers, Collections and streams, Dates and times, Files and folders, When things go wrong |
| Java calls Ring | Ring code that Java runs, Threads |
| Services | HTTP, Hashing and encryption, A database |
| Packages | JSON with Jackson, HTML with jsoup, Your own Java class |
| Windows | A first window, Controls, Layouts, Menus and dialogs, Drawing and images, Animation |
| Helpers | Queries, Window builders, JavaDatabase, A web server, A CSV report, Images, A JSON API |
After the tutorials, Applications shows forty-seven complete programs.