Flyweight pattern is not a pattern that you will come across very often in web applications. Most web applications are just serving incoming HTTP requests, a task that lasts just a few milliseconds. So, memory usage is not really a consideration for their developers. However, there is one area where you can see this pattern…
Tag: patterns
Design Patterns in Action: Decorator and SPL Iterators in AWS S3
My purpose here is to talk about the decorator pattern in SPL iterators. But since many people are not aware of how much the iterators are really used, I would also like to point out one of their use cases in real life. So, my starting point will be AWS Simple Storage Service (S3). For…
Design patterns in action: Builder and Symfony Finder
The Symfony Finder ( Symfony\Component\Finder ) is a component that, according to its documentation, can be used to “build rules to find files and directories”. This functionality includes a numder of optional parameters that can be used to construct the Finder object based on what files or directories we are looking for. The Finder uses…