debug.java
来自「卡内基梅隆大学软件工程课件,很全面」· Java 代码 · 共 38 行
JAVA
38 行
/* * * Copyright 2001 Sun Microsystems, Inc. All Rights Reserved. * * This software is the proprietary information of Sun Microsystems, Inc. * Use is subject to license terms. * *//** * This class makes it easier to print out debug statements. * The Debug.print statements are printed to System.err * if debuggingOn = true. */package util;public final class Debug { public static final boolean debuggingOn = true; public static final void print(String msg) { if (debuggingOn) { System.err.println("Debug: " + msg); } } public static final void print(String msg, Object object) { if (debuggingOn) { System.err.println("Debug: " + msg); System.err.println(" " + object.getClass().getName()); } }} // Debug
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?