是否可以在单独的 war 文件中创建可动态插入的 GWT 小部件/portlet? [英] Is it possible to create dynamically pluggable GWT widgets/portlets in separate war files?

查看:31
本文介绍了是否可以在单独的 war 文件中创建可动态插入的 GWT 小部件/portlet?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在 GWT 中创建可以动态加载并添加到 GWT Web 应用程序的小部件/portlet,以及 GWT 小部件可以驻留在单独的 war 文件中的位置?

Is it possible to create widgets / portlets in GWT that can be dynamically loaded and added to a GWT web application, and where the GWT widgets can reside in a separate war files?

为了澄清我的问题:符合 JSR168/JSR286 的门户可以在单独的项目(war 文件)中创建 portlet 并将它们动态加载到门户页面中.假设您想在 GWT 应用程序中做类似的事情.因此,假设我们为 GUI 创建了一个仅使用 GWT(没有 JSP 等)的门户,并且我们想要动态添加一个用纯 GWT 编写的portlet".这可能吗?

To clarify my question: JSR168/JSR286 compliant portals make it possible to create portlets in separate projects (war files) and to dynamically load these into a portal page. Suppose you want to do something similar in a GWT application. So suppose we made a portal using only GWT for the GUI (no JSP or alike) and we want to dynamically add a "portlet" written in pure GWT. Would that be possible?

我可以想象它可以使用 IFrame 来完成,但如果这样的 GWT 小部件/portlet 完全成为 GWT 主机门户"应用程序的一部分并共享它的样式表和其他资源,那就更好了.

I can imagine that it could be done using an IFrame, but it would be nicer if such a GWT widget/portlet would be fully part of the GWT host "portal" application and share it's style sheets and other resources.

推荐答案

我认为GWT portlet"只不过是您自己编写的一个小部件(并且可能实现了一个通用接口).

I'd imagine that a "GWT portlet" is nothing more than a widget that you write yourself (and perhaps implements a common interface).

困难的部分是动态地允许预编译的 gwt 应用程序包含另一个 gwt 组件(在本例中为 portlet),而无需再次使用源代码进行编译(这似乎是问题所暗示的).

The hard part is to dynamically allow a precompiled gwt app to include another gwt component (the portlet in this case) without compiling again with the source (which is what the question seems to imply).

这篇关于是否可以在单独的 war 文件中创建可动态插入的 GWT 小部件/portlet?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆