size.java
来自「LazyJ是一个快速Web应用程序开发框架。它包括: *.一个非常快的模板引擎」· Java 代码 · 共 37 行
JAVA
37 行
/** * */package lazyj.page.tags;import lazyj.Format;import lazyj.page.StringFormat;/** * <i>size</i> takes the integer value and returns the size (in bytes) indicated by the value. * * @author costing * @since 2006-10-13 * @see DDot * @see Dot */public final class Size implements StringFormat { /** * Use this to display file sizes. You should provide the file size in bytes as the value to this tag. * * @param sTag tag name, ignored * @param sOption always "size" * @param s string to format, the file size in bytes * @return human-friendly size * @see Format#size(long) */ public String format(final String sTag, final String sOption, final String s) { try { return Format.size(Long.parseLong(s)); } catch (NumberFormatException e) { return null; } }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?