Java course

Java Level 10: Reflection & Language Infrastructure

Reflection & Language Infrastructure is level 10 of 16 of the LoWisa Java course. It has 3 lessons and 9 ideas. Below is every lesson and what it teaches, in one line each.

Updated 2026-11-16

Annotations

  • What annotations are. An annotation attaches metadata to code: @Override for the compiler, @Test for tools reading later.
  • Retention. Retention decides how long an annotation survives: source, class file, or visible at runtime.
  • Writing your own. Custom annotations plus a processor let you declare intent once and generate the boilerplate.

Reflection

  • Reflection basics. Reflection inspects classes at runtime: fields, methods and annotations discovered from Class objects.
  • Dynamic invocation. Reflection can invoke methods found by name: the machinery under dependency injection and test runners.
  • The cost. Reflection trades safety and speed for flexibility: application code should rarely reach for it directly.

Dynamic Language Features and Trade-Offs

  • Proxies. A dynamic proxy implements an interface at runtime, wrapping calls: how frameworks add behaviour invisibly.
  • Class loading. Classes load lazily through classloaders: plugins and containers isolate code by loader.
  • Magic budget. Every reflective trick spends the team’s debuggability: frameworks may, application code mostly should not.

Before and after this level

In the app each of these ideas is taught and then asked back, and the level ends with a checkpoint and flashcards. See Checkpoints and flashcards.

Frequently asked questions

What does Java Level 10: Reflection & Language Infrastructure cover?

Annotations, Reflection, Dynamic Language Features and Trade-Offs: 3 lessons and 9 ideas.

What should I know before this level?

The level before it, Level 9: JVM & Memory, which covers Heap, Stack and Object Allocation, Garbage Collection, JVM Runtime Behaviour.

Learn Java on your phone

The first level is free. LoWisa is on Google Play and the App Store.