🐎 PONY WARD DIFFICULTY: Apprentice Structural

The Adapter Ward

Harmonizing disparate arcane interfaces.

✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Adapter
ARCANUM SCHOOL: Transmutation // Interface Shifting
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// PONY PATTERN //
class val LightningAdapter is EnergySource
  let _crystal: ManaCrystal val
  new create(c: ManaCrystal val) => _crystal = c
  fun draw_energy(): U32 => _crystal.extract_mana() * 2

The Adapter Ward

Adapters transmute incompatible method calls. Wrappers can safely embed val or iso capabilities to bridge the gaps between disparate magical subsystems.

Runic Tags: #pony #adapter