gpt4 book ai didi

java - 什么决定了 System.out.println(args) 命令打印到哪里?

转载 作者:行者123 更新时间:2023-11-29 03:32:23 25 4
gpt4 key购买 nike

这可能是一个愚蠢的问题,但我在网上找不到任何答案。什么(如果有的话)决定了 System.out.println(args) 命令的参数将显示在哪里?我一直在使用由我的讲师创建的 IO 类,它创建了自己的 GUI 并默认写入特定区域,但现在我正在制作自己的程序,我正在努力让文本/图像/任何东西显示在我的位置想要它。

最佳答案

来自 the Javadocs for System.out :

The "standard" output stream. This stream is already open and ready to accept output data. Typically this stream corresponds to display output or another output destination specified by the host environment or user.

在大多数计算环境中,有三个 standard streams与进程相关联。

但是请注意,System.out 可以在 Java 中通过使用 System.setOut() 重新分配。 .

关于java - 什么决定了 System.out.println(args) 命令打印到哪里?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17539751/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com