xz-x / 2020se1-faq Goto Github PK
View Code? Open in Web Editor NEW南大软院2020级软工1大作业提问区
南大软院2020级软工1大作业提问区
Error:(23, 9) java: 找不到符号
符号: 类 ClassFile
位置: 类 edu.nju.ClassFileReaderTest
Error:(4, 38) java: 程序包seec.test.util.classfileparser不存在
Error:(23, 35) java: 找不到符号
符号: 类 ClassFile
位置: 类 edu.nju.ClassFileReaderTest
大作业3运行test时会报如图错误:
找到一个解决方法是https://blog.csdn.net/weixin_42356358/article/details/88547718
但是看到pom.xml中已有
然后尝试执行mvn compile
没有报错,执行mvn dependency:tree
会报如图错误
暂时没有找到更多解决方法,请问有人知道该怎么做吗?
请问这个变量是直接从测试文档里获取的吗?
问题:zipEntry.getName() 返回的是 "java/lang/Object.class",分隔符为正斜杠'/'
文件路径并不是用File.seperator 即 '' 分隔
但是非zip的文件路径调用File.seperator依然是''
因此不能直接将zipEntry的name与classname进行比较
寻找原因:
https://docs.microsoft.com/zh-cn/dotnet/framework/migration-guide/mitigation-ziparchiveentry-fullname-path-separator
问:大家是否有类似问题?还是我自己并不需要纠结此问题就可以解决?
无法通过reimport下载依赖
如图所示,本地使用了94ms通过所有测试,况且这边根据对比线上线下并没有发现OJ中的privateTest,也就是说所有的本地用例应该均已运行通过,但是push到OJ上之后全部运行超时,暂时原因不明,希望助教能为我指点迷津。下面是本地环境配置情况。
OJ运行结果为AC
OJ上运行提示因运行超时获得0分。OJ上我可见的控制台输出如下:
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=utf-8
Picked up _JAVA_OPTIONS: -Djdk.net.URLClassPath.disableClassPathURLCheck=true
Running edu.nju.ClassFileReaderTest
Cancelling nested steps due to timeout
Sending interrupt signal to process
Terminated
script returned exit code 143
Timeout has been exceeded
1.所谓的必选参数和用户参数能否给一个准确的定义,在写题目的时候就特别不清晰,而百度的时候相关资料几乎找不到。
是否可以理解为 -* 后面紧跟的第一个就是必选参数, 再后面就是用户参数?
如测试用例中的testHelp内部的 -h -s arg0 -p hello
这里是否可以理解为 arg0 是-s的必选参数 ,hello是-p的必选参数,还是理解为其他类型
2.对于getArgs()方法和getOptionValue()方法,是否可以理解为,前者获取用户参数,后者获取全部参数?
3.用户参数的存在意义是什么?
如测试用例中的testSideEffect中的 -s arg0 既然-s就是修改sideEffect属性,又何必添加一个用户参数?
再比如用例testPirnt中的 -p hello arg0 既然-p是打印hello,那又何必带上arg0这一用户参数?
局部变量表Vars在invokeinterface时,Vars此类已经有setObjectref方法了,也有setSlot方法,为什么在Vars索引值0的地方存储Objectref时先存入槽slot中进而使用setSlot而非直接用setObjectref方法来存放呢?求解
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.