我正在尝试在源启动时运行具有内置 gui 的服务器。我可以弄清楚如何取出它,但无论如何我都想尝试解决它;这是我的错误
Exception in thread "main" java.lang.ExceptionInInitializerError
Caused by: java.awt.HeadlessException:
No X11 DISPLAY variable was set, but this program performed an operation which requires it.
at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:207)
at java.awt.Window.<init>(Window.java:535)
at java.awt.Frame.<init>(Frame.java:420)
at java.awt.Frame.<init>(Frame.java:385)
at javax.swing.JFrame.<init>(JFrame.java:180)
at server.model.controlpanel.ControlPanel.<init>(ControlPanel.java:20)
at server.Server.<clinit>(Server.java:69)