-
Notifications
You must be signed in to change notification settings - Fork 1
/
empty_bundle.py
29 lines (27 loc) · 864 Bytes
/
empty_bundle.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
from hal_configurator.lib.command_base import OperationBase, ArgumentDescriptor
EMPTY_BUNDLE = 'InForLoop'
OperationBase.register_bundle(EMPTY_BUNDLE)
class EmptyBundle(OperationBase):
def __init__(self,*args, **kwargs):
super(EmptyBundle, self).__init__(*args, **kwargs)
self.result = ''
@classmethod
def get_arg_descriptors(cls):
return [
ArgumentDescriptor("Bundle", "Operations Bundle", "OperationsBundle"),
]
@classmethod
def get_empty_dict(cls):
return{
"Code":cls.get_code(),
"Type":cls.get_name(),
"Arguments":{
"Bundle":{
"Name": EMPTY_BUNDLE,
"Operations": []
}
}
}
def run(self):
self.executor.execute_bundle_within_current_scope(self.kwargs["Bundle"])
__plugin__ = EmptyBundle