当前位置: 技术问答>java相关
JAVA中没有宏,那编程和调试起来不是很麻烦吗?有没有一些折中办法?
来源: 互联网 发布时间:2015-07-10
本文导语: (空) | use assert in 1.4 wrap up the System.out as another class like Debug. such as: class Debug{ public final debug(String msg){System.out.println(msg);} } when publishing, comment out the System.out.println in the ...
(空)
|
use assert in 1.4
wrap up the System.out as another class like Debug.
such as:
class Debug{
public final debug(String msg){System.out.println(msg);}
}
when publishing, comment out the System.out.println in the debug() method.
Theoretically, static final variable does not have to use memory.
Even though Java does, Java does not care that little memory overhead at all.
wrap up the System.out as another class like Debug.
such as:
class Debug{
public final debug(String msg){System.out.println(msg);}
}
when publishing, comment out the System.out.println in the debug() method.
Theoretically, static final variable does not have to use memory.
Even though Java does, Java does not care that little memory overhead at all.
|
宏是什么东西啊,呵,现在都什么年代了,谁还用宏啊,java里面有输出测试语句,在jbuilder里面也有debug。
|
用JBUILDER7。