了解 Java Web 应用程序框架

发布于 2024-12-27 06:43:00 字数 1065 浏览 1 评论 0原文

有人可以帮助我理解 java web 应用程序框架中的一些基本概念吗?

我对 Web 应用程序框架的理解 - 它提供了很多基础设施来构建我的 Web 应用程序,例如处理 http 客户端请求、将任务委托给不同的控制器、作用于模型、识别下一页的方法等。基本上我不需要担心如何处理客户端请求,我只需要编写控制器类、前端页面并将它们放在适当的位置,其余的由框架处理。

当我使用spring框架时确实如此。

但当我开始使用其他 Web 应用程序框架时,我遇到了很多问题。

  1. 我听说GWT可以用来快速开发丰富的前端页面。但我没有看到任何与后端 servlet/业务层交互的 Web 层框架解释。不提供任何Web层框架,还能称为Web应用框架吗?
  2. 如果我使用 GWT 进行前端页面开发,我可以使用 Spring 或任何其他 MVC 框架作为中间层。如果是这样我怎样才能实现这个目标?
  3. 我又问了关于谷歌新框架的问题 - GUICE?它被称为网络应用程序框架。但我不明白提供的文档如何使用这个框架设计一个具有三个主要层的 Web 应用程序?与 Spring 不同的是,Spring 提供了一个简洁的 MVC 结构来配置页面、控制器等,但它没有足够的文档来解释这些设计问题。 我不明白在我的 Web 应用程序中使用 Guice 框架的好处,其他框架解释了如何在这些情况下使用它们?
  4. 总而言之,我们可以用 GWT 前端、GUICE Web 应用程序框架设计一个 Web 应用程序吗?如果可以,在这种情况下,如何在 guice 内部设计中间层?基本上,我想知道这个框架如何处理不同的客户端请求以及它如何在内部将业务委托给不同的组件......等等。

另外,当 GUICE 这样的新框架出现时,我们通常会寻找 MVC 类型的结构来使用,这是现在想到的一个普遍问题。如果框架中没有MVC,我们应该如何决定和设计Web应用程序。例如,Guice 没有任何 MVC 解释,也没有建议任何设计此类 Web 应用程序的方法。

除此之外,我想了解移动 Web 应用程序的一般生命周期。与一般的 Web 应用程序相比,它有何不同? 如果我想设计一个可以通过浏览器中的互联网以及移动访问进行访问的 Web 应用程序,那么设计限制是什么?

请有人帮助我理解上述内容。

Can somebody help me to understand a few basic concepts in java web applications framework?

My understanding of a web application framework - It provides lot of infrastructure to build my web application like handling http client requests, delegating the tasks to different controllers, acting on the model, a way to identify the next page..etc. Basically I dont need to worry about how I should handle client requets, i just need to write the controller classes, front end pages and place them in appropriate place and the rest is handled by framework.

It is very true when I use spring framework.

But I got lot of questions when I started to use other Web application frameworks .

  1. I have heard that GWT can be used to rapidly develop rich front end pages. But I did not see any web-tier framework explanation to interact with the back end servlet/business layers. Without any web-tier framework provided, can it be called a web application framework?
  2. If I use GWT for my front end page development, can I use Spring or any other MVC framework as a Middle tier. If so how can I achieve this?
  3. Again my question on google's new framework - GUICE? Its called a web application framework. But i did not understand with the documentation provided how can I design a web application with three main tiers using this framework? Unlike spring where it provides a neat MVC structure to configure the pages, controllers..etc, it does not have enough document explaining these design issues.
    I dont understand the benefit of using Guice framework in my web application, where as other framework explain how they can be used in these cases?
  4. To summarize, can we design a web application with GWT front end, GUICE web app framework - If so, how the middle tier can be designed in this case inside guice? Basically, i want to know how this framework handles different client requests and how it delegates the business to different components internally..etc.

Also, one general question which comes to mind now when a new framework comes like GUICE, we generally look for MVC kind of structure to work with. How should we decide and design web appl if MVC is not available in framework. Like example, Guice does not have any MVC explained, also it does not suggest any approach to design such web appl.

Apart from this, I wanted to understand the general life cycle of a mobile web application. How it is different in contrast to general web application?
If i want to design a web application which can be accessed over internet in browsers along with Mobile access, what are the design constraints?

Please somebody help me to understand the above items.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文