You are here |
ryanharter.com | ||
| | | |
www.metaltoad.com
|
|
| | | | One of the biggest announcements for Androiddevelopers from Google IO 2018 was the announcement of | |
| | | |
blog.nuculabs.de
|
|
| | | | Hello, In this article we're going to explore the Method Injection and Property Injection design patterns. To demonstrate the patterns I'm going to add a new interface named Encoder to the printer.py file and a concrete implementation for two encoders: Rot13Encoder and NullEncoder. 1 2 3 4 5 6 7 8 9 10 11 12 13 class Encoder(metaclass=abc.ABCMeta): def encode(self, message: Message) -> Message: raise NotImplementedError("encode must be implemented!") class Rot13Encoder(metaclass=abc.ABCMeta): def encode(self, message: Message) -> Message: return Message(codecs.encode(str(message), 'rot_13')) class NullEncoder(metaclass=abc.ABCMeta): def encode(self, message: Message) -> Message: return message The Encoder will be used by the printer in order to encode the messages before printing them. | |
| | | |
vgaidarji.me
|
|
| | | | I'm a software developer with the main focus on Android platform. | |
| | | |
zacbrown.org
|
|
| | Zac Brown's Nonsense is the source for all of Zac Brown's nonsense. If it's Zac Brown related, then it's probably nonsense. And if it's nonsense, then it's probably here! |