This commit is contained in:
Jered Ye 2024-01-13 20:47:53 +08:00
commit 7b29344426
58 changed files with 140 additions and 50 deletions

BIN
Common/dist/Common.jar vendored

Binary file not shown.

View File

@ -3,5 +3,5 @@ do.depend=false
do.jar=true
javac.debug=true
javadoc.preview=true
project.Judger=K:\\OJ\\Judger
project.Judger=D:\\SchoolStudy\\ojrepull\\DHUOJ\\Judger
user.properties.file=C:\\Users\\tange\\AppData\\Roaming\\NetBeans\\8.0.2\\build.properties

BIN
Judger/dist/Judger.jar vendored

Binary file not shown.

View File

@ -1,10 +1,10 @@
#Sat, 13 Jan 2024 19:28:41 +0800
#Sat, 13 Jan 2024 20:25:29 +0800
K\:\\OJ\\client=
D\:\\SchoolStudy\\ojrepull\\DHUOJ\\client=
K\:\\OJ\\Common=
D\:\\SchoolStudy\\ojrepull\\DHUOJ\\Common=
K\:\\OJ\\Judger=
D\:\\SchoolStudy\\ojrepull\\DHUOJ\\Judger=
K\:\\OJ\\clientUpdater=
D\:\\SchoolStudy\\ojrepull\\DHUOJ\\clientUpdater=

View File

@ -1,14 +1,14 @@
#update Config.properties
#Sat Jan 13 19:28:55 CST 2024
#update config/config.properties
#Sat Jan 13 20:25:41 CST 2024
isCppRelative=true
isJavaRelative=true
Username=felix
MinGWDir=C\:\\Program Files (x86)\\CodeBlocks\\MinGW\\bin
MinGWDir=D\:\\SchoolStudy\\OJ_netbeans\\OJ\\client\\MinGW\\bin
URLip=106.15.36.190
relativeCCompilerDir=\\MinGW\\bin
JavaRelative=-1
JavaCompileDir=
Debug=1
MinGWRelative=2
MinGWRelative=1
relativeCppCompilerDir=\\MinGW\\bin
URLport=80

View File

@ -1,3 +0,0 @@
20:59:06 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
20:59:06 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
20:59:06 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null

View File

@ -1,3 +1,24 @@
19:28:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
19:28:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
19:28:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
01:52:18 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
01:52:18 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
01:52:18 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:08:36 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:08:36 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:08:36 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:17:42 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:17:42 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:17:42 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:23:13 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:23:13 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
02:23:13 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
08:59:46 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
08:59:46 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
08:59:46 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:26:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:26:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:26:53 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:47:54 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:47:54 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
09:47:54 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
20:25:39 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
20:25:39 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null
20:25:39 class java.io.FileNotFoundExceptionhttp://106.15.36.190:80/oj/SoftwareVersionMAction!DownLoad.action?versionId=null

View File

@ -3,4 +3,4 @@ do.depend=false
do.jar=true
javac.debug=true
javadoc.preview=true
user.properties.file=C:\\Users\\tange\\AppData\\Roaming\\NetBeans\\8.0.2\\build.properties
user.properties.file=C:\\Users\\dell\\AppData\\Roaming\\NetBeans\\8.0.2\\build.properties

View File

@ -3,10 +3,6 @@
<editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
<open-files xmlns="http://www.netbeans.org/ns/projectui-open-files/2">
<group name="最新版本代码"/>
<group>
<file>file:/K:/OJ/client/src/client/service/web/Webservice.java</file>
<file>file:/K:/OJ/client/src/client/test/Test1.java</file>
<file>file:/K:/OJ/client/nbproject/jaxws-build.xml</file>
</group>
<group/>
</open-files>
</project-private>

View File

@ -63,7 +63,7 @@ public class Config {
public static void save(){
try {
FileOutputStream fos = new FileOutputStream(common.FileFinder.findFile("config/config.properties"));
prop.store(fos, "update Config.properties");
prop.store(fos, "update config/config.properties");
fos.close();
} catch (FileNotFoundException ex) {
Logger.getLogger(Config.class.getName()).log(Level.SEVERE, null, ex);

View File

@ -31,6 +31,7 @@ import java.util.List;
import javax.xml.namespace.QName;
import org.apache.cxf.endpoint.Client;
import org.apache.cxf.service.factory.ServiceConstructionException;
/**
*
* @author ytxlo

View File

@ -86,9 +86,9 @@ public class MainFrame extends JFrame implements ColorChange {
private JPanel NorthPanel;
private JLabel jl_south;
private JMenu JM_CompileInfo;
private JMenuItem cCPlus_CompileInfo;
private JMenuItem java_CompileInfo;
// private JMenu JM_CompileInfo;
// private JMenuItem cCPlus_CompileInfo;
// private JMenuItem java_CompileInfo;
private JMenuItem JM_return;
private JMenuItem JM_UpdateProblem;
private JMenuItem JM_UpdateStatus;
@ -150,8 +150,10 @@ public class MainFrame extends JFrame implements ColorChange {
this.TP_Main = new JTabbedPane();
this.JPT_Result = new JPanel();
this.JPT_Submit = new JPanel();
this.cCPlus_CompileInfo = new JMenuItem("C/C++编译器");
this.java_CompileInfo = new JMenuItem("Java编译器");
// this.cCPlus_CompileInfo = new JMenuItem("C/C++编译器");
// this.java_CompileInfo = new JMenuItem("Java编译器");
this.JB_return = new JButton();
//this.JCB_Model = new JComboBox();
this.UpdateProblem = new JButton();
@ -172,7 +174,7 @@ public class MainFrame extends JFrame implements ColorChange {
this.freshMenu = new JMenu("同步");
this.systemMenu = new JMenu("系统");
this.JM_CompileInfo = new JMenu("编译器设置");
// this.JM_CompileInfo = new JMenu("编译器设置");
this.JM_return = new JMenuItem("返回考试列表");
this.JM_UpdateProblem = new JMenuItem("下载全部题目");
@ -203,27 +205,29 @@ public class MainFrame extends JFrame implements ColorChange {
this.NorthPanel.add(this.TP_time, BorderLayout.EAST);
this.NorthPanel.add(this.jl_south, BorderLayout.WEST);
JM_CompileInfo.add(cCPlus_CompileInfo);
cCPlus_CompileInfo.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
NewCompileSetting config = new NewCompileSetting("c", MainFrame.this, true);
config.setVisible(true);
}
});
JM_CompileInfo.add(java_CompileInfo);
java_CompileInfo.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
NewCompileSetting config = new NewCompileSetting("java", MainFrame.this, true);
config.setVisible(true);
}
});
// JM_CompileInfo.add(cCPlus_CompileInfo);
// cCPlus_CompileInfo.addActionListener(new ActionListener() {
// @Override
// public void actionPerformed(ActionEvent e) {
// NewCompileSetting config = new NewCompileSetting("c", MainFrame.this, true);
// config.setVisible(true);
// }
// });
// JM_CompileInfo.add(java_CompileInfo);
// java_CompileInfo.addActionListener(new ActionListener() {
// @Override
// public void actionPerformed(ActionEvent e) {
// NewCompileSetting config = new NewCompileSetting("java", MainFrame.this, true);
// config.setVisible(true);
// }
// });
freshMenu.add(JM_UpdateProblem);
freshMenu.add(JM_UpdateStatus);
freshMenu.add(JM_UpdateExam);
//freshMenu.add(JM_return);
systemMenu.add(JM_CompileInfo);
// systemMenu.add(JM_CompileInfo);
systemMenu.add(JM_Exit);
menubar.setLayout(new FlowLayout(FlowLayout.LEFT));
MenuPanel.add(this.menubar, BorderLayout.WEST);
@ -316,6 +320,7 @@ public class MainFrame extends JFrame implements ColorChange {
// // config.setVisible(true);
// }
// });
this.JB_return.setText("返回考试列表");
this.JB_return.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent evt) {

View File

@ -178,7 +178,6 @@ public class CodePanel extends JPanel implements ActionListener {
this.jLabel5 = new JLabel("学生测试输出");
this.jLabel6 = new JLabel("运行结果:");
this.jLabel7 = new JLabel("编程语言:");
//this.jLabel7 = new JLabel("");
this.jpanel1 = new JPanel();
this.jpanel2 = new JPanel();
this.jpanel3 = new JPanel();
@ -201,12 +200,12 @@ public class CodePanel extends JPanel implements ActionListener {
JEP_Code.setCodeFoldingEnabled(true);
JEP_Code.setFont(new Font("YaHei Consolas Hybrid", Font.PLAIN, fontsize));
RTextScrollPane codePanel = new RTextScrollPane(JEP_Code);
//codePanel.setBorder(BorderFactory.createEmptyBorder());
this.Top_code.setLayout(new BorderLayout());
this.jSplitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
//this.jSplitPane.setDividerLocation(0.7);
this.jSplitPane.setResizeWeight(0.8);
this.jSplitPane.setDividerSize(7);
this.jSplitPane.setOneTouchExpandable(true);
@ -456,6 +455,8 @@ public class CodePanel extends JPanel implements ActionListener {
} else if ("C++".equals(lan)) {
language = "C++";
JEP_Code.setSyntaxEditingStyle(SyntaxConstants.SYNTAX_STYLE_CPLUSPLUS);
} else if ("python".equals(lan)){
JEP_Code.setSyntaxEditingStyle(SyntaxConstants.SYNTAX_STYLE_PYTHON);
}
}
@ -1099,6 +1100,22 @@ public class CodePanel extends JPanel implements ActionListener {
return false;
}
}
if (language.toLowerCase().equals("python")) {
tmp = Config.getCompilerDir("python");
if (tmp == null || "".equals(tmp) || !FileFinder.isExistFile(tmp + File.separator + "javac.exe")) {
//弹窗设置保存
Object t = this.getParent();
while (!(t instanceof MainFrame)) {
t = ((Component) t).getParent();
}
JOptionPane.showMessageDialog(this, "请先配置编译器");
NewCompileSetting window = new NewCompileSetting(language, (MainFrame) t, true);
window.setVisible(true);
return false;
}
}
return true;
}

View File

@ -0,0 +1,18 @@
#include <stdio.h>
int main()
{
double a,b,c;
while(scanf("%lf%lf", &a, &b) != EOF)
{
if (b!=0)
{
c=a/b;
printf("%.2f\n", c);
}
else
printf("error\n");
}
return 0;
}

BIN
client/test/output/Main.o Normal file

Binary file not shown.

View File

@ -23,7 +23,7 @@ int main()
</sourceCode>
<id>992628</id>
<time>2024-01-11 14:04:25</time>
<time>2024-01-13 01:52:26</time>
<status>AC</status>
<correctCaseIds>3020,3021,3022,3023,</correctCaseIds>
<wrongCaseIds/>

View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="GB2312" standalone="no"?>
<code>
<finished>true</finished>
<submit>
<sourceCode>#include &lt;stdio.h&gt;
int main()
{
double a = 0.01,b=0.01,c=0.01;
while(scanf("%lf%lf", &amp;a, &amp;b) != EOF)
{
if (b!=0)
{
c=a/b;
printf("%.2f\n", c);
}
else
printf("error\n");
}
printf("\n");
return 0;
}
</sourceCode>
<id>836152</id>
<time>2024-01-13 09:48:18</time>
<status>AC</status>
<correctCaseIds>3024,3025,3026,3027,</correctCaseIds>
<wrongCaseIds/>
<score>49.0</score>
<remark>AC£ºÔËÐнá¹ûÕýÈ·</remark>
<similarity/>
<submits>51</submits>
</submit>
</code>

Binary file not shown.

Binary file not shown.

Binary file not shown.