The Decorator of Wards
Dynamically add arcane wards and logging to matrix operations.
✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Decorator
ARCANUM SCHOOL: Transmutation // Warding
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// MATLAB PATTERN //
classdef WardDecorator < SpellInterface
properties
WrappedSpell
end
methods
function obj = WardDecorator(spell)
obj.WrappedSpell = spell;
end
function cast(obj, target)
disp('Applying protective ward...');
obj.WrappedSpell.cast(target);
disp('Ward dissipating...');
end
end
end
Decorator
Wrap your fragile matrix inversions in robust wards of protection.
Runic Tags:
#decorator
#wards
#spells