㈠ 如何简单描述java web技术使用实例
public class AddDeviceServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
doPost(request, response);
}
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
String licensePlate = request.getParameter("licensePlate"); //获取车牌号
String tel = request.getParameter("tel"); //获取手机号
MyDevice device = new MyDevice(licensePlate, tel); //将请求参数封装成一个对象
save(device); //保存数据
response.getWriter().print(true); //向客户端返回一个成功标识
response.setContentType("text/html;charset=utf-8");
response.setCharacterEncoding("utf-8");
response.getWriter().println("你的车牌号: " + licensePlate); //向客户端返回一个成功标识
response.getWriter().println("你的手机号: " + tel); //向客户端返回一个成功标识
}
㈡ 启动tomcat时报错: Illegal access: this web application instance has been stopped already
异常信息:Illegal access: this web application instance has been stopped already.Could not load java.net.BindException.The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
非法访问:此Web应用程序实例已停止了。无法加载java.net.BindException。最终是由下面的堆栈跟踪调试目的,以及试图终止线程从而导致非法访问抛出一个错误造成的,并没有功能的影响。
原因:这个是在关闭应用服务器或重新部署装载项目失败会发生。当应用程序卸载时,并不会关闭所有的线程。当tomcat已经关闭了其类加载器后,一些线程依然会继续运行,这样就导致出错,这些错误就会被到日志文件里。
解决方法是:修改tomcat目录下conf文件夹下的server.xml,在<Host>标签添加子元素找到<Context>标签,把reloadble的属性值设为:reloadable="false"。
㈢ 设那么是手机WEB应用可否举个例子
用手机上网络,不安装程序,你接触到的就是web应用。相对程序来说就是很方便,只要是有浏览器就都可以用,不用在商店下载程序
㈣ 急求!!web service 的应用实例 ,wed service !!!
wed
service
项目
为什么还要在项目名称后面加一个service呢
才能显示出里面的方法来呢???高手指点下!!
㈤ Web 有哪些 Erlang 语言应用的例子
Mochiweb
一句话介绍: MochiWeb is an Erlang library for building lightweight HTTP servers.
Mochiweb在Erlang项目中被当做一个Web组件被广泛使用(比如RabbitMQ的plug-in),它的设计相当收敛,除了基础的Web请求处理没有提供特别复杂的功能集(后面会提到其它Web Server).目前我已经在两个项目中使用了Mochiweb,得心应手.
Mochiweb项目代码有很多值得学习的地方,比如 mochiglobal [ 链接 ],Parameterized mole [链接]今年夏天我把Mochiweb代码打印了一份,看得很是过瘾.这里有一篇实战风格的入门文章:A practical introction to MochiWeb - Alex Marandon[链接]
使用Rebar很容易编译运行,里面自带一个简单的Echo demo,你可以使用Rebar快速建立起来自己的站点框架,动手试试吧
项目地址:mochi/mochiweb · GitHub
Cowboy
一句话介绍: Cowboy is a small, fast and molar HTTP server written in Erlang.
使用Cowboy需要通过编写Handler来定制如何处理Web请求.这是它设计上的一大特色.项目源码自带了N种版本的hello_world,也是可以非常快上手.编译运行依然是rebar搞定,这个项目现在保持更新,每天都能收到github推送的代码变更邮件.
项目地址:extend/cowboy 路 GitHub
YAWS
一句话介绍:Yaws is a HTTP high perfomance 1.1 webserver particularly well suited for dynamic-content web applications.
这个略显怪异的名字是Yet another Webserver的缩写.其提供的已经不是简单的脚手架了,而是支持动态内容输出,REST,文件上传SOAP等等.在其官网上有丰富的文档和样例代码.O'Reilly在2012年6月出版的 Building Web Applications with Erlang 一书中使用的就是YAWS.这本不足150页的小册子是很好的YAWS入门教程.估计国内出版社不会引进这样一本冷冷的书,自己找电子版读吧,很容易找到.
项目地址:Yaws
Misultin [停止更新]
一句话介绍: Misultin development has been discontinued.
是的,这个项目已经不再继续更新了;停止更新的原因是作者认为各个Web server项目有"too much plication of efforts".作者在项目介绍中倒是简单评价了Mochiweb和Cowboy:
Mochiweb has been around the block for a while and it's proven solid in proction, I can only recommend it for all basic webserver needs you might have. Cowboy has a very interesting approach since it allows to use multiple TCP and UDP protocols on top of a common acceptor pool. It is a very modern approach, is very actively maintained and many projects are starting to be built around it.
项目地址:ostinelli/misultin ¡ GitHub
看过Misultin作者的一番评论,其实可以回答不少人关于"用Mochiweb做Web项目很痛苦"的问题:如果你要做一个丰富多彩的Web站点,在Mochiweb提供的脚手架上,你要完成很多工作,显然你需要其它选择,呃,或许你需要选择一个Web Framework了.对于大多数框架来说,其设计的总要目标就是开发效率和常见应用场景的支持.我们看看有哪些Erlang Web Framework可用吧!
Elrang Web Frameworks
除了http://Asp.net MVC,RoR之外,其实还有很多Web Framework可用,看看Erlang世界里面的解决方案吧:
ChicagoBoss
一句话介绍:Chicago Boss is a server framework inspired by Rails and written in Erlang.
ChicagoBoss是现在非常活跃的Erlang Web Framework,在各种细节上都为新手准备的相当周到比如60秒快速上手教程什么的.甚至它说自己区别于其它Erlang Web Framework的就是" it is easy to set up and use."它之间Web Server是选择的Misultin现在已经迁移到Cowboy.前端MVC架构,内置消息队列BOSSMQ,数据存储方面选择性也比较多:Mnesia MongoDB Mysql PostgreSQL Riak ,Tokyo Tyrant;模板方案依然是使用ErlyDTL.
另外,我觉得ChicagoBoss的文案是这些项目里面写的最棒的,直接命中你最想知道的两个问题:
"Chicago Boss is a server framework inspired by Rails and written in Erlang. It offers all the conveniences of modern web development, including Comet. What sets Chicago Boss apart from other non-Erlang frameworks is that it can handle large amounts of traffic without any drop in performance. What sets Chicago Boss apart from other Erlang frameworks is that it is easy to set up and use."
项目地址:ChicagoBoss/ChicagoBoss 路 GitHub
入门PDF: http://www.evanmiller.org/chicago-boss-tutorial.pdf
Nitrogen
一句话介绍:Nitrogen Web Framework is the fastest way to develop interactive web applications in full-stack Erlang.
看群里面讨论,采用Nitrogen的项目也不在少数,这个项目动态模板方案不是采用ErlyDTL,而是自己有一套解决方案Nitrogen records [链接].网站上的例程和Step by Step教程足够详细,入门应该比较快.
项目地址:Nitrogen - Nitrogen Web Framework for Erlang
Zotontic
一句话介绍:Zotonic is the open source, high speed, real-time web framework and content management system, built with Erlang.
应该说Zotontic和其它框架的差异更多是在业务定位上了,提供了很多CMS直接可用的功能,查看其features列表能够看到详细介绍,注意:"Typically 10 times (and much more) faster than PHP content management systems." [链接]
Zotontic构建在Mochiweb和PostgreSQL之上.
项目地址:http://zotonic.com/
BeepBeep
一句话介绍: BeepBeep is a simple web application framework for Mochiweb inspired by Rails and Merb
BeepBeep 构建在 MochiWeb 和 ErlyDTL (后面会介绍) 基础之上. 沿袭了mochiweb的优良传统一键建站,基于ErlyDTL提供Django 模板的视图展现.
这个项目已经09年之后就没有实质性的更新,最近一次更新是2010年更新了一下README,慎重选择吧.
还有一个项目ErlyWeb同样是
㈥ 求C#.net开发的web应用实例
www.51aspx.com下载源码,你要什么样的就下什么样的。
㈦ 什么是web服务器,举个例子
用来储存网页文件的服务器,举例那就只能说,你看到的网页都是由网页服务器支援的
㈧ 举几个web2.0网络的例子
Web2.0包含了我们经常使用到的服务,例如博客、播客、维基、P2P下载、社区、分享服务等等.