码迷,mamicode.com
首页 >  
搜索关键字:throws    ( 4120个结果
php 将秒数转换为时间(年、天、小时、分、秒)
/** * 秒数转时分格式 * @param $time int * @author jack * @throws string * @return string */ function Sec2Time($time) { if (is_numeric($time)) { return (bool) ...
分类:Web程序   时间:2020-06-24 00:15:41    阅读次数:258
PHP递归所有下级
/** * 获取用户下属ID集合 * @param $uid int * @param $ids string * @author jack * @throws string * @return string */ public function getUnderlingUIds($uid, $id ...
分类:Web程序   时间:2020-06-23 22:53:48    阅读次数:237
IO流,带缓冲区的字符流。
public static void main(String[] args) throws IOException{ BufferedReader br = new BufferedReader (new FileReader("xxx.txt")); BufferedWriter bw = new ...
分类:其他好文   时间:2020-06-22 23:15:57    阅读次数:59
IO流,带缓冲区的流中的特殊方法:readLine()和newLine()方法。
public class Demo4_Buffered(){ public static void main(String[] args) throws IOException{ BufferedReader br = new BufferedReader (new FileRead("xxx.tx ...
分类:其他好文   时间:2020-06-22 22:59:27    阅读次数:74
IO流自定义字符数组的拷贝。
public static void main(String[] args) throws IOException{ FileRead fr = new FileRead ("xxx.txt"); FileWrite fw = new FileWrite ("yyy.txt"); char [] a ...
分类:编程语言   时间:2020-06-22 22:52:44    阅读次数:61
throw throws Throwable 关联于区别
总结:throw 是在方法中抛出一个异常,不能单独使用 。 throws是在方法定义处或者类定义处声明该类或方法可能产生的异常,(一个或者多个). 也可以理解为将方法内部异常不处理直接抛出,让调用处去处理。 throwable 是所有错误和异常的超类,所以当不知道要产生的异常是什么类型时候,直接th ...
分类:其他好文   时间:2020-06-21 22:56:11    阅读次数:55
反射获取成员变量并使用
Field[] getFields() 返回包含一个数组Field对象反射由此表示的类或接口的所有可访问的公共字段类对象。 public class ReflectDemo01 { public static void main(String[] args) throws ClassNotFound ...
分类:其他好文   时间:2020-06-21 15:51:18    阅读次数:67
Map遍历增加key报错如何解决
public static void main(String[] args) throws Exception{ Map<String,Object> aa=new HashMap<String, Object>(); aa.put("a1","a1"); aa.put("a2","a2"); aa ...
分类:其他好文   时间:2020-06-21 15:30:21    阅读次数:89
Android之网络编程
编写Android程序从网络中获取图片资源,练习AsyncHttpClient、SmartImageView等开源框架的使用。 1.编写APP程序,导入AsyncHttpClient、HttpClient、SmartImageView、Gson四个开源框架的Jar文件包。 2.搭建Tomcat网络服 ...
分类:移动开发   时间:2020-06-21 00:25:43    阅读次数:88
反射——获取Class类对象
public class ReflectDemo { public static void main(String[] args) throws ClassNotFoundException { //1.使用类的class属性来获取该类对应的Class对象。 Class<Student> c1 = ...
分类:其他好文   时间:2020-06-20 22:29:40    阅读次数:96
4120条   上一页 1 ... 19 20 21 22 23 ... 412 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!