Skip to main content

Instructor-led training

Practical Java Language Topics Training in Omaha, Nebraska

The Java platform has many powerful capabilities to help developers in the day to day tasks of creating good software systems.

What you'll learn

The Java platform has many powerful capabilities to help developers in the day to day tasks of creating good software systems. Some of this are built into the language, and some are separate tools that have become widely adopted because of their usefulness. This one day course looks at the following three tools that can be of enormous help to programmers that are writing Java systems:

Private Training for Teams

This course is offered as private, instructor-led training for organizations, onsite in Omaha, Nebraska or live online. Dates, delivery format, and course content are arranged around your team's requirements.

This course is not currently scheduled as a public class for individual enrollment.

Request Group Training

Prerequisites

Programmers with experience in working with Java and Object - Oriented (OO) programming.

Course Outline

 
ant: Basics
ant Overview
Installing and Running ant
Buildfiles, Projects, Targets and Tasks
Properties
Creating Build Files
Paths(e.g. CLASSPATH, PATH)
Resource Collections - FileSets, DirSets, Files, PatternSets
Other Resource Collections and Selectors
LABS: 
 
Running ant
Creating and Using Buildfiles
Using Basic ant Tasks
Working with Paths
Using Resource Collections
ant: Tasks
Overview of ant Tasks
The <javac> Task in Depth
The <java> Task in Depth
Creating Java Archives - <jar>, <war>, <ear>
File Related Tasks
Other Useful Tasks
LABS: 
 
Working with <javac> and <java>
Creating Archives
Working With File Tasks
ant: Modularity
Properties Files
The <ant> Task and SubProjects
The <import> Task For Importing Buildfiles
LABS: 
 
Working With Properties Files
Creating Modular Buildfiles
JUnit: Basics
JUnit Overview, Test Driven Development
Tests and Assertions
Running Tests
Working With Exceptions
LABS:
 
Writing Tests
Running Tests
Testing Exceptions
JUnit: Organizing Tests
Writing Fixtures - @Before, @After
Test Suites
Other Capabilities
The ant <junit> Task
LABS:
 
Using Fixtures
Using Suites
Logging: Basics
Logging Overview
log4j Overview
Loggers, Appenders, Layouts
Configuring log4j
Using log4j
LABS:
 
Setting Up log4j
Using Basic log4j Logging
Logging: More On log4j
Logger Heirarchy
Logging Levels
Working With Appenders
Using PatternLayout
LABS:
 
Working With Loggers
Working With Appenders
Using Layouts
Logging: Other Logging Frameworks
Java Logging
Apache Commons Logging

What makes build, test and logging tools hard to master

The Java syntax in this course is easy for an experienced developer. The harder part is that all three topics are configuration-driven. Ant buildfiles are declarative XML, JUnit finds and runs your tests by convention, and log4j behavior is decided mostly by configuration rather than by the calling code. Mistakes tend to show up as a wrong classpath, a test that never runs, or log lines that go nowhere.

The syllabus builds in layers:

  • Ant fundamentals. Projects, targets, tasks and properties come first, then paths (CLASSPATH, PATH) and resource collections: FileSets, DirSets, PatternSets and selectors. Most buildfile problems come from not being clear about which files a collection actually matches.
  • Ant tasks and modularity. <javac> and <java> are covered in depth, followed by <jar>, <war> and <ear> and the file tasks. Properties files, the <ant> task with subprojects, and <import> then split a large build into pieces. A common misconception is that a buildfile is a script that runs top to bottom, when it is really a set of targets and properties. Another is that properties behave like variables you can reassign.
  • JUnit. The course covers tests and assertions, running tests, and testing for expected exceptions. It then moves to organization: @Before/@After fixtures, suites, and running tests from the Ant <junit> task. The usual traps are tests that depend on each other and assertions that only repeat the implementation.
  • Logging. The course covers loggers, appenders and layouts, the logger hierarchy, levels and PatternLayout. It closes with Java Logging and Apache Commons Logging. The hard concept is that a message's fate depends on the logger's position in the hierarchy, its level, and the appenders attached, not on the log call itself.

Each module has hands-on labs, so the concepts are practiced against real buildfiles, tests and configuration files.

Who it suits and where it fits

This is a one-day course for programmers who already work in Java and understand object-oriented programming. It suits teams that maintain or inherit Ant-based builds, want a consistent way to write and run unit tests, or need to replace ad hoc console output with configurable logging. It is a tools course, not a language course, so it assumes you can read and write Java without help.

Illustrative scenarios

The scenarios below are illustrations of how the course material can be applied. They are not descriptions of specific organizations or of the course's lab exercises.

  • Untangling a large buildfile. A team might maintain one long buildfile that compiles, packages and deploys several components. Using properties files, <import> and the <ant> task with subprojects, they could split it into shared and per-module buildfiles. FileSets and PatternSets would then control exactly which classes go into each <jar> or <war>.
  • Adding tests to existing code. For example, a group with untested utility classes could write JUnit tests with assertions and expected-exception checks, share setup through @Before/@After fixtures, group them into suites, and run them from the Ant <junit> task as part of the build.
  • Making diagnostics controllable. A team that relies on console printing might move to log4j. Loggers named by package, different levels per area, and separate appenders would let support staff raise detail for one subsystem without redeploying. A PatternLayout could standardize the format, and the Commons Logging and Java Logging material would help in choosing how libraries log.

AI coding assistants with these topics

AI coding assistants are useful for the repetitive parts. They can draft a first buildfile skeleton, generate JUnit test methods for a class, or produce a starting logging configuration. They are weaker where details are tool-specific:

  • Ant: an assistant may invent task attributes or borrow habits from other build tools. It can also write FileSet patterns that match too many or too few files, or miss how paths and properties resolve across imported buildfiles.
  • JUnit: generated tests often just restate the implementation, skip exception cases, or share state between tests that fixtures should isolate. They may also use annotations or APIs that do not match the project's JUnit and Java versions.
  • Logging: configuration syntax and class names differ between logging frameworks and between versions of the same framework. A suggested configuration may be silently ignored, or may send messages to the wrong appender or at the wrong level.

To verify, run Ant with verbose output and list the files each resource collection selects, and inspect the contents of the generated archives. Deliberately break the code to confirm that the tests fail. Check the logger hierarchy and levels by emitting a message at each level from several classes and seeing where it lands. Always compare suggestions with the versions your project actually uses.

Frequently asked questions

What level is this course and what should I know first?

It is a one-day, general-level course for programmers who already have experience with Java and object-oriented programming. No prior Ant, JUnit or log4j experience is listed as a prerequisite.

What does the course cover?

Three areas: Ant (buildfiles, properties, paths, resource collections, core tasks such as javac, java, jar, war and ear, and modular builds), JUnit (tests, assertions, exceptions, fixtures, suites and the Ant junit task), and logging (log4j loggers, appenders, layouts, levels and configuration, plus Java Logging and Apache Commons Logging). Each module includes labs.

Can the course be delivered privately for our team?

Yes. HSG delivers private training for organizations, either onsite at your location or live online.

Can the content be customized?

Private training can be tailored, including to the technology versions your organization uses. To discuss your tooling and goals, request a training proposal.

Training locations

Practical Java Language Topics training across the U.S. and beyond.

We provide private Practical Java Language Topics training for organizations, onsite at your location or live online, throughout the United States and internationally.

View all Practical Java Language Topics training locations

Train your team with HSG

Private, instructor-led training customized for your organization.

  • Onsite or live online delivery
  • Customized curriculum
  • For a single employee or an entire team
  • Flexible scheduling
  • Experienced instructors
Request Group Training

Questions? Call us at 303.377.6176
or email info@hartmannsoftware.com

Ready to train your team?

Let's customize this training for your organization.

Tell us about your employees, your goals, and your preferred schedule. We'll prepare a training proposal covering scope, delivery format, and pricing.