java.awt.HeadlessException thrown from HeadlessGraphicsEnvironment.getDefaultScreenDevice

后端 未结 2 922
盖世英雄少女心
盖世英雄少女心 2021-01-20 05:01

I need to do some image processing on a java server (Debian with java version \"1.6.0_12\"), and I am receiving java.awt.HeadlessException from my code:

java         


        
2条回答
  •  一个人的身影
    2021-01-20 05:37

    Your code appears to be getting the default graphics device configuration on a machine that doesn't have a usable graphic device. This doesn't make much sense, and is never going to work.

    If you could explain why you are trying to do this (on a headless machine) we might be able to offer an alternative.

提交回复
热议问题