Created
February 13, 2025 02:24
-
-
Save ancyrweb/e6209a67f8a392eaeab6390cad7aeea1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Command { | |
execute() {} | |
} | |
class Transactional { | |
constructor(command) { | |
this.command = command; | |
} | |
execute() { | |
console.log('Begin transaction'); | |
this.command.execute(); | |
console.log('End transaction'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment