Google News
logo
Swift - Interview Questions
What are the Adapter and the Memento Pattern in Swift Programming Language?
Adapter : It converts the interface of a class into other interfaces as required by the client. It covers itself around the objects to reveal a standard interface to connect with that object.
 
Memento : It is used in iOS as a part of the state restoration. This externalized state of the code can be store without breaching encapsulation. Memento is especially used by Apple for archiving.
Advertisement