gpt4 book ai didi

mule - 骡子如何调用组件?

转载 作者:行者123 更新时间:2023-12-02 22:05:25 26 4
gpt4 key购买 nike

在阅读了一些关于 Mule 的指南之后,我有一个关于组件的问题,正如 mule 文档中所说,

A simple POJO (Plain Old Java Object) component that will be invoked by Mule when a message is received. The class or object instance to be used can be specified using a child object factory element, or via the 'class' attribute. If the 'class' attribute is used, an object factory cannot be configured as well. Using the 'class' attribute is equivilant to using the propotype object factory ('prototype-object' child element).

文档中只是说Mule在接收到消息时会调用组件,但问题是Mule如何知道组件有多少方法,应该调用哪个方法?或者组件中必须有一个方法,而不管方法名称如何?还有 mule 如何处理方法的参数?

最佳答案

或者,您可以使用:

<invoke object-ref="..." method="..."  methodArguments="..." />

这比配置入口点解析器更方便。

关于mule - 骡子如何调用组件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16207597/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com