Het Proxy-patroon biedt een tijdelijke aanduiding of surrogaat voor een ander object om toegang tot het te controleren. De proxy heeft dezelfde interface als het echte object, maar voegt gedrag toe — zoals lazy loading, toegangscontrole, caching of logging — voordat het naar het object delegeert.
Wat het Proxy-patroon doet
PROXY → an object that STANDS IN for another, controlling access to it:
→ same interface as the real object (clients use it transparently)
→ adds behavior BEFORE/AROUND delegating to the real object
→ controls WHEN and HOW the real object is accessed
→ "a stand-in that adds control/behavior"
