void (StringBuilder sb, DisplayMode mode) { sb.append("mode: ").append(mode.getWidth()).append("x").append(mode.getHeight()); sb.append("; bit depth=").append(mode.getBitDepth()); sb.append("; refresh rate=").append(mode.getRefreshRate()); sb.append("\n"); }