blob: 82d75431b696d5ce6696dcfec5fde3f1cb4086e8 [file] [log] [blame]
from pywayang.platform import Platform
class Plugin:
"""
A plugin contributes the following components to a :class:`Context`
- mappings
- channels
- configurations
In turn, it may require several :clas:`Platform`s for its operation.
"""
platforms = []
def __init__(self, *platform:Platform):
self.platforms = list(platform)
def __str__(self):
return "Platforms: {}".format(str(self.platforms))
def __repr__(self):
return self.__str__()
# define the basic plugins that can be used
java = Plugin(Platform('java'))
spark = Plugin(Platform('spark'))
flink = Plugin(Platform('flink'))