网站建设
  简约型网页设计套餐998
  实惠型网站建设套餐2580
  综合型网站制作套餐4980
  网站改版与网站维护
  行业网站建设方案
  大型网站建设解决方案
  企业网站建设流程
  帝网科技网站设计与网站制作
建站FAQ
·网站空间问题解答
·企业邮箱问题解答
 
酷站欣赏
·房产酷站(379)
·综合门户(8 9)
·建筑装饰(603)
·手机通讯(354)
·生活购物(376)
·医疗保健(199)
·文化摄影(602)
·休闲体育(399)
>>更多酷站欣赏
网站优化
·Google(谷歌)优化   ·百度(BaiDu)优化
·雅虎(Yahoo)优化    ·Alexa排名优化   
·Google AdSense   ·DMOZ目录提交  
建站知识
·网站建设知识·网站名词解释·网站运营知识
·网络营销知识·搜索引擎知识·实用技术文摘
网站推广
百度网站推广 google网站推广
搜狐网站推广 网易网站推广
新浪网站推广   雅虎网站推广
  您当前位置: 当前位置:帝网科技 >> web开发 >> JSP专栏 >> 浏览文章
 
 
JSP用bean获取各种参数
作者:佚名 来源:帝网科技 日期:2009年10月26日 点击数:


  1.包:

  package beanpackage;

  /**

  *

  * @author lucifer

  */

  public class SystemProperties {

  public String getRuntimeEnvironmentVersion(){

  return System.getProperty("java.version");

  }

  public String getRuntimeEnvironmentVendor(){

  return System.getProperty("java.vendor");

  }

  public String getVmVersion(){

  return System.getProperty("java.vm.version");

  }

  public String getVmVendor(){

  return System.getProperty("java.vm.vendor");

  }

  public String getVmName(){

  return System.getProperty("java.vm.name");

  }

  public String getVmSpecVersion(){

  return System.getProperty("java.vm.specification.version");

  }

  public String getVmSpecVendor(){

  return System.getProperty("java.vm.specification.vendor");

  }

  public String getVmSpecName(){

  return System.getProperty("java.vm.specification.name");

  }

  public String getRteSpecName(){

  return System.getProperty("java.specification.name");

  }

  public String getRteSpecVersion(){

  return System.getProperty("java.specification.version");

  }

  public String getRteSpecVendor(){

  return System.getProperty("java.specification.vendor");

  }

  public String getOperatingSystemName(){

  return System.getProperty("os.name");

  }

  public String getOperatingSystemVersion(){

  return System.getProperty("os.version");

  }

  public String getOperatingSystemArchitecture(){

  return System.getProperty("os.arch");

  }

  }

  2.JSP代码:

  <%--

  Document : usebean

  Created on : 2009-10-3, 13:06:24

  Author : lucifer

  --%>

  <%@page contentType="text/html" pageEncoding="UTF-8"%>

  

  "http://www.w3.org/TR/html4/loose.dtd">

  

  

  

  

  JSP Page

  

  

  Operating System Name:

  

  

  Operating System Version:

  

  

  Operating System Architecture:

  

  

  

  Runtime Environment Version(JDK version):

  

  

  Runtime Environment Vendor(JDK vendor):

  

  

  

  VM Version:

  

  

  VM Vendor:

  

  

  VM Name:

  

  

  

  RTE Specification Version:

  

  

  RTE Specification Vendor:

  

  

  RTE Specification Name:

  

  

  

  VM Specification Name:

  

  

  VM Specification Version:

  

  

  VM Specification Vendor:

  

  

  

  3.输出:

  Operating System Name: Windows Vista

  Operating System Version: 6.0

  Operating System Architecture: x86

  Runtime Environment Version(JDK version): 1.6.0_16

  Runtime Environment Vendor(JDK vendor): Sun Microsystems Inc.

  VM Version: 14.2-b01

  VM Vendor: Sun Microsystems Inc.

  VM Name: Java HotSpot(TM) Client VM

  RTE Specification Version: 1.6

  RTE Specification Vendor: Sun Microsystems Inc.

  RTE Specification Name: Java Platform API Specification

  VM Specification Name: Java Virtual Machine Specification

  VM Specification Version: 1.0

  VM Specification Vendor: Sun Microsystems Inc.

  相关文章
 
·如何建立JSP操作以提高数据库访问效率
·servlet 生成静态HTML的方法
·使用JSP实现简易的SQL报表
·浅析Servlet和Jsp中的多国语言显示
·JSP/Servlet/JSF:自定义标签的另类体
·使用JSP+javascript打造二级级联下
·实例:JSP结合XML+XSLT将输出转换HTML
·JSP教程:JSP页面跳转的实战规则
·关于JSP中的offsetparent
·JSP中errorPage设置方法
·JSP用bean获取各种参数
·JSP基础知识教程
·在Eclipse中部署Tomcat,并运行JSP
·jsp教程:深入浅出URL编码
·JSP技术优缺点深入分析(2)
·Jsp环境下ajax乱码问题的解决方法
·JSP技术优缺点深入分析(1)
·jsp上传组件smartupload介绍
·JSP中文字符乱码处理的2种方法
·jsp入门:Jsp运行原理
 
 

公司环境 | 合作伙伴 | 人才招聘 | 付款方式 | 关于我们

地址:广州市天河区中山大道中120号D805 电话:020-82529556 传真:020-82529556
广州帝网网络科技有限公司 版权所有 粤ICP备08119341号