上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 28 下一页
摘要: /** * 正则表达式过滤 标签 * @param str * @return */ public static String cutOutImgPrefix(String str){ String regex = "]*>"; return str.replaceAll(regex, ""); } 阅读全文
posted @ 2016-07-22 17:55 wikiki 阅读(4556) 评论(2) 推荐(1) 编辑
摘要: Camera camera = Camera.open(); Parameters parameters = camera.getParameters(); List supportedPreviewSizes = parameters .getSupportedPreviewSizes(); fo... 阅读全文
posted @ 2016-07-22 16:39 wikiki 阅读(677) 评论(0) 推荐(0) 编辑
摘要: package com.example.decript; import java.io.UnsupportedEncodingException; import java.security.InvalidKeyException; import java.security.MessageDigest; import java.security.NoSuchAlgorithmException;... 阅读全文
posted @ 2016-07-22 10:38 wikiki 阅读(337) 评论(0) 推荐(0) 编辑
摘要: try { File file = new File(Environment.getExternalStorageDirectory(),"shuju2"); if(!file.exists()){ file.createNewFile(); } FileWriter fw = new FileWriter(file); BufferedWriter out = ... 阅读全文
posted @ 2016-07-21 17:16 wikiki 阅读(2935) 评论(0) 推荐(0) 编辑
摘要: 在Android中,我们有三种方式来实现视频的播放: 1、使用其自带的播放器。指定Action为ACTION_VIEW,Data为Uri,Type为其MIME类型。 2、使用VideoView来播放。在布局文件中使用VideoView结合MediaController来实现对其控制。 3、使用MediaPlayer类和SurfaceView来实现,这种方式很灵活。 1、调用其自... 阅读全文
posted @ 2016-07-07 16:16 wikiki 阅读(330) 评论(0) 推荐(0) 编辑
摘要: /** * 打开一个app * * @param packageName * @param data * @return */ public static boolean lanuchApp(Context context,String packageName, Bundle data) { try { Intent resolveIntent = co... 阅读全文
posted @ 2016-06-19 18:25 wikiki 阅读(240) 评论(0) 推荐(0) 编辑
摘要: /** * 隐藏软键盘 * * @param context * @param editText */ public static void hideSoftKeyBroad(Context context, View view) { InputMethodManager mgr = (InputMethodManager) context.getSystemS... 阅读全文
posted @ 2016-06-19 18:13 wikiki 阅读(281) 评论(0) 推荐(0) 编辑
摘要: System.currentTimeMillis() new Date().getTime() 阅读全文
posted @ 2016-06-13 17:51 wikiki 阅读(101) 评论(0) 推荐(0) 编辑
摘要: /** * 把文本里面结尾的切割掉 * @param text * @return */ public static String cutOutPrefixImg(String text){ String regex = "]*>"; return text.replaceAll(regex, ""); } 阅读全文
posted @ 2016-06-05 10:50 wikiki 阅读(145) 评论(0) 推荐(0) 编辑
摘要: /** * 计算关键字在文本中出现的次数 * @param text * @param key * @return */ public static int count(String text, String key) { int count = 0, start = 0; while ((start = text.indexOf(key, start)) >... 阅读全文
posted @ 2016-06-05 10:42 wikiki 阅读(350) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 28 下一页