开发者

Detecting input redirection file

How can we detect/fetch the name of a file that's fed as an input redirection to a java program from the command line开发者_如何学运维?


Without OS-specific hacks (such as running ps -ef) you can't.

Why do you need this information, and why can't you restructure your program to simply take the file as a command-line argument?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜