业务委托处理异常
我对有关业务代表的一行内容感到困惑:
业务委托句柄&抽象的 任何远程异常
这里的“抽象”一词是什么意思?是否只是提供细节而不是如何实施?
I'm confused in one of the line about Business delegate that says:
Business delegate handle & abstract
any remote exception
What do they mean with the word "abstract" here? Is it just providing a details not how to implement them?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您检查过 Sun 文档吗?
http://java.sun.com/blueprints/patterns/BusinessDelegate.html
如果将客户端直接绑定到业务服务接口,则每次业务服务更改时,该客户端可能都必须更改。在只有一种类型的客户端使用服务的情况下,这没什么大不了的,但是当你有一堆可能不同的客户端都想要使用相同的服务时,这就变得更成问题了。最重要的是,所有想要使用该服务的客户端可能都希望以类似的方式查找服务并处理服务中的异常。
为了缓解这种情况,您将异常处理和分布式查找的所有详细信息从各个客户端中提取出来(“抽象”出来),并将其提取到业务委托对象中。现在,您的所有客户端都可以使用业务委托以统一的方式访问业务服务,并且当业务服务发生更改时,只有您的业务委托对象需要更改,而不是所有单独的客户端。
这就是我对这个场景的理解。希望这能为您解决问题。
Have you checked out the Sun documentation yet?
http://java.sun.com/blueprints/patterns/BusinessDelegate.html
If you tie a client directly to a business service interface, that client may potentially have to change every time the business service changes. In the scenario where you have one type of client using a service, that's not a big deal, but when you have a bunch of potentially different clients that all want to use the same service, it becomes more of a problem. On top of that, all of your clients that want to use the service probably want to handle looking up the service and handling exceptions from the service in a similar fashion.
In order to mitigate this scenario, you pull all the details of exception handling and distributed lookup out of the individual clients ("abstract" it out) and pull it into a business delegate object. All your clients can now use a business delegate to access the business service in a uniform way and when the business service changes, only your business delegate object has to change rather than all your individual clients.
That's kind of my understanding of the scenario. Hopefully that clears things up for you.