Esempio n. 1
0
    def _make_session_endpoint(self, id_string, module, endpoint_id):
        stack = Stack()
        frame = PushFrame()
        stack.add_frame(frame)
        frame.add_command(XPath.string(id_string))
        arguments = []
        helper = WorkflowHelper(self.suite, self.app, self.modules)
        for child in helper.get_frame_children(id_string, module):
            if isinstance(child, WorkflowDatumMeta):
                arguments.append(Argument(id=child.id))
                frame.add_datum(StackDatum(id=child.id, value=f"${child.id}"))

        return SessionEndpoint(
            id=endpoint_id,
            arguments=arguments,
            stack=stack,
        )
Esempio n. 2
0
 def get_frame_children(self, module, form):
     helper = WorkflowHelper(self.suite, self.app, self.app.get_modules())
     frame_children = helper.get_frame_children(module, form)
     if module.root_module_id:
         frame_children = prepend_parent_frame_children(helper, frame_children, module.root_module)
     return frame_children