Setting the Java Class Path
The class path is the path taht Java Runtime Environment(JRE) searches for classes and other resource files.
Synopsis:
The class serach path (classpath) can be set suing either the -classpath option when calling a JDK tool( the preferred method) or bby setting the CLASSPATH environment variable.
The -classpath option is preferred beacuse you can set it individually for each application without affecting other applications and without outher applications modifying its value.
sdkTool -classpath classpath1:classpath2...
set CLASSPATH=classpath1;classpath2...
sdkTool
A command-line tool, such as java, javac, javadoc, or apt.For a listing, see JDK Tools and Utilites at
http://docs.oracle.com/javase/8/docs/technotes/tools/index.html
classpaht1:classpath2
Classpaths to the JAR,zip or class files.Each class path should end with a file name or directory depending on what you are setting the class path to, as follows:
`For a JAR or zip file that contains class files, the class path ends with the name of the zip or JAR file.
`For class files in an unnamed package, thje class path ends with the direcotry that contains the class files.
`For class files in a named package, the class path ends with the directory that contains the root package, which is the first package in the full package name.
Multiple path entries are separated by semicolons with no spaces around the equals sigh (=) in windows.
The defalut class path is the current direcoty. Setting the CLASSPATH variable or using the -classpath command-line option overrides that default, so if you want to include the current direcoty in the search path,
then you must include a dot(.) in the new settings.
Class path entries that are neither directories nor archives (.zip or JAR files) nor the asterisk(*) wildcard character are ignored.
Setting the Java Class Path的更多相关文章
- The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path:
运行环境: Intellij idea 14 在改了项目名称. 运行时候出现了 The APR based Apache Tomcat Native library which allows opti ...
- The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path解决方案
0.环境: win7系统,Tomcat9配置无误. 1.错误: 项目中某一.jps页面忽然出现错误,鼠标点上去为:The superclass "javax.servlet.http.Htt ...
- The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path。问题
JSP页面顶端出现“红色”的报错信息:The superclass "javax.servlet.http.HttpServlet" was not found on the Ja ...
- java如何修改java.library.path并且不重启jvm也能生效
先说一下需求吧, 目前在用JCEF实现java程序桌面版包装,源码中需要加载编译好的几个dll文件,而这些文件的路径必然是根据程序安装的路径而变化的,这就需要在程序运行的时候,去动态修改java.li ...
- MyEclipse Java Build Path详解
转载自:http://blog.163.com/magicc_love/blog/static/185853662201111161580631/ 1.设置"source folder&qu ...
- 错误:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
我们在利用Eclipse进行Java web开发时,可能会出现这样的错误:The superclass javax.servlet.http.HttpServlet was not found on ...
- ubuntu下eclipse遇到The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
JSP页面顶端出现“红色”的报错信息:The superclass "javax.servlet.http.HttpServlet" was not found on the Ja ...
- 项目忽然出现 The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path 解决方法
0.环境: 新装win8.1系统,Tomcat配置无误. 1.错误: 项目中某一.jps页面忽然出现错误,鼠标点上去为:The superclass "javax.servlet.http. ...
- no leveldbjni64-1.8 in java.library.path
在抽取以太坊Java版本的Trie树部分时,遇到了一个问题: Exception in thread "main" java.lang.UnsatisfiedLinkError: ...
随机推荐
- 2018-2019-2 《网络对抗技术》Exp4 恶意代码分析20165211
目录 实践内容概述 实践目标 实践内容 实验问题回答 实践过程记录 系统运行监控 使用schtacks指令监控系统运行 使用sysmon工具监控系统运行 恶意软件分析 使用Virus Total分析恶 ...
- JAVA中拆箱和装箱
浅谈JAVA中拆箱与装箱 一. 什么是装箱?什么是拆箱? 在Java SE5之前,如果要生成一个数值为10的Integer对象,必须这样进行: Integer i = new Integer(10) ...
- and与or的用法
#1.判断下列语句的True和False # 1)1 > 1 or 3 < 4 or 4 > 5 and 2 > 1 and 9 > 8 or 7 < 6 结果为T ...
- Bootstrap3基础 img-responsive 响应式图片
内容 参数 OS Windows 10 x64 browser Firefox 65.0.2 framework Bootstrap 3.3.7 editor ...
- ng-model绑定的是ng-option中的什么?
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script sr ...
- Ajax详细剖析
概述 对于WEB应用程序:用户浏览器发送请求,服务器接收并处理请求,然后返回结果,往往返回就是字符串(HTML),浏览器将字符串(HTML)渲染并显示浏览器上. 传统的Web应用 一个简单操作需要重新 ...
- 【修改缓存路径】修改Gradle缓存路径的几种方式
起因 Android Studio的gradle在缓存处理上有时候会莫名其妙的出问题,必要时需要手动删除缓存,然后重新编译.有时也有出于其他考虑指定gradle缓存路径. 方法1:修改gradle文件 ...
- HDU 6191 Query on A Tree(可持久化Trie)
题意 \(n\) 个点的有根树,根为 \(1\) .每个点有点权,有 \(q\) 个询问,每次询问以 \(u\) 为根的子树的点的点权中异或 \(x\) 所得的最大值是多少. 思路 求出整棵树的 \( ...
- Shiro学习笔记(二)
首先还是先搭建工程运行环境 依旧搭建的是Maven工程,如果不是Maven 也可以去网上找jar包然后导入 (我使用Maven主要是找依赖配置文件就行,我自己导jar包的时候就是很容易报错) 还是先 ...
- Leetcode1 - A + B Problem - Easy
Write a function that add two numbers A and B. Example Example 1: Input: a = 1, b = 2 Output: 3 Expl ...