
公共方法
aa1000777
这个作者很懒,什么都没留下…
展开
-
字体文件解析
public static Typeface getTypeFace(Context context, String type) { if ("bold".equals(type)) { return Typeface.createFromAsset(context.getAssets(), "Gotham-Rounded-Book_21018.ttf"); } else原创 2014-05-09 17:35:15 · 1184 阅读 · 0 评论 -
正则表达式大全
一、校验数字的表达式数字:^[0-9]*$n位的数字:^\d{n}$至少n位的数字:^\d{n,}$m-n位的数字:^\d{m,n}$零和非零开头的数字:^(0|[1-9][0-9]*)$非零开头的最多带两位小数的数字:^([1-9][0-9]*)+(.[0-9]{1,2})?$带1-2位小数的正数或负数:^(\-)?\d+(\.\d{1,2})?$正数、负数、和小数:^(\-|\+)?\转载 2014-05-29 09:06:24 · 943 阅读 · 0 评论