JPlag
JPlag copied to clipboard
Add Java-CPG language module
This Draft PR contains the new "Java Code Property Graph" module. It uses a CPG library and graph transformations to normalise substructures of the code prior to tokenization, which should lead to a higher resilience against refactoring attacks.
It also serves to fix SonarCloud errors before a proper PR is opened.
For this commit, some SonarCloud checks are going to fail because of code that was not part of my frontend and that I did not intend to touch in the first place. The issue is that a rule deems wildcard type arguments highly critical in return types, but that makes working with nested generic types very hard, like the method List<LanguageOption<?>> getOptionsAsList()
in LanguageOptions
. I wonder if there is a way for you to review/accept this commit even if these checks fail.
Edit: Well, what do you know, it did pass 😊
Please also add the language to the report viewer here: https://github.com/jplag/JPlag/blob/develop/report-viewer/src/model/Language.ts
Also set a language for highlighting here: https://github.com/jplag/JPlag/blob/develop/report-viewer/src/utils/CodeHighlighter.ts
I think I got rid of all unwanted changes to base code. I'm still fixing some bugs with new test submission files that I got, but the overall structure and basic workflow of the frontend should be stable now. @tsaglam, I think the reviewers can start.
Quality Gate passed for 'JPlag Plagiarism Detector'
Issues
0 New issues
1 Accepted issue
Measures
0 Security Hotspots
No data about Coverage
No data about Duplication