增加 BuildPanel.java 的注释

This commit is contained in:
许轲 2023-10-11 02:08:34 +08:00
parent 70dc245d1e
commit 9c3473a166

View File

@ -7,15 +7,27 @@ import org.jcnc.jnotepad.component.module.vbox.components.DebugBox;
import org.jcnc.jnotepad.component.module.vbox.components.RunBox;
/**
* 底部Run,Debug,Cmd面板
* 底部运行调试和命令终端面板
*
* <p>这个类实现了一个包含运行信息调试信息和命令终端的底部面板它是TabPane的子类用于将这三个组件以选项卡的形式显示在底部面板上</p>
*
* <p>可以通过调用getInstance方法获取单例实例</p>
*
* @see CmdTerminalBox
* @see RunBox
* @see DebugBox
* @see TabPane
* @author cccqyu
*/
public class BuildPanel extends TabPane {
private static BuildPanel instance = null;
/**
* 获取BuildPanel的单例实例
*
* @return BuildPanel的单例实例
*/
public static BuildPanel getInstance() {
if (instance == null) {
@ -36,23 +48,38 @@ public class BuildPanel extends TabPane {
Tab runTab = new Tab("运行", runBox);
runTab.setClosable(false);
Tab buildTab = new Tab("构建", debugBox);
Tab buildTab = new Tab("调试", debugBox);
buildTab.setClosable(false);
Tab cmdTab = new Tab("终端",cmdTerminalBox);
Tab cmdTab = new Tab("命令终端", cmdTerminalBox);
cmdTab.setClosable(false);
this.getTabs().addAll(runTab, buildTab, cmdTab);
}
/**
* 获取命令终端组件
*
* @return CmdTerminalBox对象
*/
public CmdTerminalBox getCmdTerminalBox() {
return cmdTerminalBox;
}
/**
* 获取运行信息组件
*
* @return RunBox对象
*/
public RunBox getRunBox() {
return runBox;
}
public DebugBox getBuildBox() {
/**
* 获取调试信息组件
*
* @return DebugBox对象
*/
public DebugBox getDebugBox() {
return debugBox;
}
}