我是个新手,在linux使用java编程时,出现这个情况。
我把要引的包放在classpath中,红色部分:
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$HADOOP_HOME/hadoop-1.0.4.core.jar:${CLASSPATH}
通过echo $CLASSPATH查看也能输出结果。
mport org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Job;
import org.apache.hadoop.mapreduce.Mapper;
import org.apache.hadoop.mapreduce.Reducer;
import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
public class wordcount {
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
{
private final static IntWritable one=new IntWritable(1);
private Text word=new Text();
public void map(Object key, Text value,Context context) throws IOException,InterruptedException{
String[] words=value.toString().split(" ");
for(String str : words)
{
word.set(str);
context.write(word,one);
}
}
}
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
{
int total =0;
for(IntWritable val1 : values)
{
total++;
}
context.write(key,new IntWritable(total));
}
}
public static void main(String[] args) throws Exception {
Configuration conf1=new Configuration();
Job job=new Job(conf1,"word count");
job.setJarByClass(wordcount.class);
job.setMapperClass(WordCountMapper.class);
job.setReducerClass(WordCountReducer.class);
job.setOutputKeyClass(Text.class);
job.setOutputValueClass(IntWritable.class);
FileInputFormat.addInputPath(job, new Path(args[0]));
FileOutputFormat.setOutputPath(job, new Path(args[1]));
System.exit(job.waitForCompletion(true ) ? 0:1);
}
}
使用javac wordcount.java 编译出现:
[解析开始时间 RegularFileObject[wordcount.java]]
[解析开始时间 RegularFileObject[wordcount.java]]
[解析已完成, 用时 24 毫秒]
[源文件的搜索路径: .,/usr/lib/jvm/jdk1.8.0_73/lib/dt.jar,/usr/lib/jvm/jdk1.8.0_73/lib/tools.jar]
[类文件的搜索路径: /usr/lib/jvm/jdk1.8.0_73/jre/lib/resources.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/rt.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/sunrsasign.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/jsse.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/jce.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/charsets.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/jfr.jar,/usr/lib/jvm/jdk1.8.0_73/jre/classes,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/jaccess.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/sunpkcs11.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/zipfs.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/dnsns.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/jfxrt.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/nashorn.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/sunec.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/localedata.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/cldrdata.jar,/usr/lib/jvm/jdk1.8.0_73/jre/lib/ext/sunjce_provider.jar,.,/usr/lib/jvm/jdk1.8.0_73/lib/dt.jar,/usr/lib/jvm/jdk1.8.0_73/lib/tools.jar/usr/local/Hadoop/hadoop-1.0.4.core.jar]
wordcount.java:2: 错误: 程序包org.apache.hadoop.conf不存在
import org.apache.hadoop.conf.Configuration;
^
wordcount.java:3: 错误: 程序包org.apache.hadoop.fs不存在
import org.apache.hadoop.fs.Path;
^
wordcount.java:4: 错误: 程序包org.apache.hadoop.io不存在
import org.apache.hadoop.io.IntWritable;
^
wordcount.java:5: 错误: 程序包org.apache.hadoop.io不存在
import org.apache.hadoop.io.Text;
^
wordcount.java:6: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Job;
^
wordcount.java:7: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Mapper;
^
wordcount.java:8: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Reducer;
^
wordcount.java:9: 错误: 程序包org.apache.hadoop.mapreduce.lib.input不存在
import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
^
wordcount.java:10: 错误: 程序包org.apache.hadoop.mapreduce.lib.output不存在
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
^
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Object.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/String.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Exception.class)]]
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Mapper
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:14: 错误: 找不到符号
private final static IntWritable one=new IntWritable(1);
^
符号: 类 IntWritable
位置: 类 WordCountMapper
wordcount.java:15: 错误: 找不到符号
private Text word=new Text();
^
符号: 类 Text
位置: 类 WordCountMapper
wordcount.java:16: 错误: 找不到符号
public void map(Object key, Text value,Context context) throws IOException,InterruptedException{
^
符号: 类 Text
位置: 类 WordCountMapper
wordcount.java:16: 错误: 找不到符号
public void map(Object key, Text value,Context context) throws IOException,InterruptedException{
^
符号: 类 Context
位置: 类 WordCountMapper
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/io/IOException.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/InterruptedException.class)]]
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Reducer
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 Text
位置: 类 WordCountReducer
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Iterable.class)]]
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 Context
位置: 类 WordCountReducer
[正在检查wordcount]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/io/Serializable.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/AutoCloseable.class)]]
wordcount.java:14: 错误: 找不到符号
private final static IntWritable one=new IntWritable(1);
^
符号: 类 IntWritable
位置: 类 WordCountMapper
wordcount.java:15: 错误: 找不到符号
private Text word=new Text();
^
符号: 类 Text
位置: 类 WordCountMapper
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Throwable.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Byte.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Character.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Short.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Long.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Float.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Integer.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Double.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Boolean.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Void.class)]]
wordcount.java:30: 错误: 找不到符号
for(IntWritable val1 : values)
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:34: 错误: 找不到符号
context.write(key,new IntWritable(total));
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:38: 错误: 找不到符号
Configuration conf1=new Configuration();
^
符号: 类 Configuration
位置: 类 wordcount
wordcount.java:38: 错误: 找不到符号
Configuration conf1=new Configuration();
^
符号: 类 Configuration
位置: 类 wordcount
wordcount.java:39: 错误: 找不到符号
Job job=new Job(conf1,"word count");
^
符号: 类 Job
位置: 类 wordcount
wordcount.java:39: 错误: 找不到符号
Job job=new Job(conf1,"word count");
^
符号: 类 Job
位置: 类 wordcount
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Class.class)]]
wordcount.java:43: 错误: 找不到符号
job.setOutputKeyClass(Text.class);
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:44: 错误: 找不到符号
job.setOutputValueClass(IntWritable.class);
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:45: 错误: 找不到符号
FileInputFormat.addInputPath(job, new Path(args[0]));
^
符号: 类 Path
位置: 类 wordcount
wordcount.java:45: 错误: 找不到符号
FileInputFormat.addInputPath(job, new Path(args[0]));
^
符号: 变量 FileInputFormat
位置: 类 wordcount
wordcount.java:46: 错误: 找不到符号
FileOutputFormat.setOutputPath(job, new Path(args[1]));
^
符号: 类 Path
位置: 类 wordcount
wordcount.java:46: 错误: 找不到符号
FileOutputFormat.setOutputPath(job, new Path(args[1]));
^
符号: 变量 FileOutputFormat
位置: 类 wordcount
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/System.class)]]
[共 363 毫秒]
39 个错误
wordcount.java:2: 错误: 程序包org.apache.hadoop.conf不存在
import org.apache.hadoop.conf.Configuration;
^
wordcount.java:3: 错误: 程序包org.apache.hadoop.fs不存在
import org.apache.hadoop.fs.Path;
^
wordcount.java:4: 错误: 程序包org.apache.hadoop.io不存在
import org.apache.hadoop.io.IntWritable;
^
wordcount.java:5: 错误: 程序包org.apache.hadoop.io不存在
import org.apache.hadoop.io.Text;
^
wordcount.java:6: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Job;
^
wordcount.java:7: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Mapper;
^
wordcount.java:8: 错误: 程序包org.apache.hadoop.mapreduce不存在
import org.apache.hadoop.mapreduce.Reducer;
^
wordcount.java:9: 错误: 程序包org.apache.hadoop.mapreduce.lib.input不存在
import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
^
wordcount.java:10: 错误: 程序包org.apache.hadoop.mapreduce.lib.output不存在
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
^
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Object.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/String.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Exception.class)]]
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Mapper
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:12: 错误: 找不到符号
public static class WordCountMapper extends Mapper<Object, Text,Text,IntWritable>
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:14: 错误: 找不到符号
private final static IntWritable one=new IntWritable(1);
^
符号: 类 IntWritable
位置: 类 WordCountMapper
wordcount.java:15: 错误: 找不到符号
private Text word=new Text();
^
符号: 类 Text
位置: 类 WordCountMapper
wordcount.java:16: 错误: 找不到符号
public void map(Object key, Text value,Context context) throws IOException,InterruptedException{
^
符号: 类 Text
位置: 类 WordCountMapper
wordcount.java:16: 错误: 找不到符号
public void map(Object key, Text value,Context context) throws IOException,InterruptedException{
^
符号: 类 Context
位置: 类 WordCountMapper
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/io/IOException.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/InterruptedException.class)]]
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Reducer
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:26: 错误: 找不到符号
public static class WordCountReducer extends Reducer<Text,IntWritable,Text,IntWritable>{
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 Text
位置: 类 WordCountReducer
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Iterable.class)]]
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:27: 错误: 找不到符号
public void reduce(Text key,Iterable<IntWritable> values,Context context) throws IOException,InterruptedException
^
符号: 类 Context
位置: 类 WordCountReducer
[正在检查wordcount]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/io/Serializable.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/AutoCloseable.class)]]
wordcount.java:14: 错误: 找不到符号
private final static IntWritable one=new IntWritable(1);
^
符号: 类 IntWritable
位置: 类 WordCountMapper
wordcount.java:15: 错误: 找不到符号
private Text word=new Text();
^
符号: 类 Text
位置: 类 WordCountMapper
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Throwable.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Byte.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Character.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Short.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Long.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Float.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Integer.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Double.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Boolean.class)]]
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Void.class)]]
wordcount.java:30: 错误: 找不到符号
for(IntWritable val1 : values)
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:34: 错误: 找不到符号
context.write(key,new IntWritable(total));
^
符号: 类 IntWritable
位置: 类 WordCountReducer
wordcount.java:38: 错误: 找不到符号
Configuration conf1=new Configuration();
^
符号: 类 Configuration
位置: 类 wordcount
wordcount.java:38: 错误: 找不到符号
Configuration conf1=new Configuration();
^
符号: 类 Configuration
位置: 类 wordcount
wordcount.java:39: 错误: 找不到符号
Job job=new Job(conf1,"word count");
^
符号: 类 Job
位置: 类 wordcount
wordcount.java:39: 错误: 找不到符号
Job job=new Job(conf1,"word count");
^
符号: 类 Job
位置: 类 wordcount
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Class.class)]]
wordcount.java:43: 错误: 找不到符号
job.setOutputKeyClass(Text.class);
^
符号: 类 Text
位置: 类 wordcount
wordcount.java:44: 错误: 找不到符号
job.setOutputValueClass(IntWritable.class);
^
符号: 类 IntWritable
位置: 类 wordcount
wordcount.java:45: 错误: 找不到符号
FileInputFormat.addInputPath(job, new Path(args[0]));
^
符号: 类 Path
位置: 类 wordcount
wordcount.java:45: 错误: 找不到符号
FileInputFormat.addInputPath(job, new Path(args[0]));
^
符号: 变量 FileInputFormat
位置: 类 wordcount
wordcount.java:46: 错误: 找不到符号
FileOutputFormat.setOutputPath(job, new Path(args[1]));
^
符号: 类 Path
位置: 类 wordcount
wordcount.java:46: 错误: 找不到符号
FileOutputFormat.setOutputPath(job, new Path(args[1]));
^
符号: 变量 FileOutputFormat
位置: 类 wordcount
[正在加载ZipFileIndexFileObject[/usr/lib/jvm/jdk1.8.0_73/lib/ct.sym(META-INF/sym/rt.jar/java/lang/System.class)]]
[共 363 毫秒]
39 个错误
,我想问下这个引用第三方的jar包,如何使用啊?急
windows下如下 最后一个;后面必须要用空格把这个类和lib包分开。LZ是在linux下,需要把;替换成:路径当然也要替换成linux格式的。
javac -cp c:\abc.jar;d:\efg.jar; f:\Test.java
java -cp c:\abc.jar;d:\efg.jar; f:\Test