design-patterns/structural/bridge/implementations.py
Ruidy 11b03fee22
Bridge (#8)
* bridge example

* edit gitignore
2020-09-17 17:45:18 +02:00

15 lines
536 B
Python

"""
Each Concrete Implementation corresponds to a specific platform and implements
the Implementation interface using that platform's API.
"""
from IImplementation import Implementation
class ConcreteImplementationA(Implementation):
def operation_implementation(self) -> str:
return "ConcreteImplementationA: Here's the result on the platform A."
class ConcreteImplementationB(Implementation):
def operation_implementation(self) -> str:
return "ConcreteImplementationB: Here's the result on the platform B."