摘要: Java注解是在JDK1.5引入的,以@注解名存在代码中。声明一个注解使用@interface,其中每个方法实际上是声明了一个配置参数,方法名即参数名,返回类型即参数类型。通过default来设置默认值。@Retention和@Target用来声明注解的本身的行为。@Retention指明注解保留策略,有RetentionPolicy.SOURCE(源码)、RetentionPolicy.RUNTIME(JVM运行时)、RetentionPolicy.CLASS(类文件)3种。只有当声明为RUNTIME时才可以通过java的反射API来获取注解信息。@Target指明了注解作用的类型,有包、类 阅读全文
posted @ 2013-11-19 18:21 烟花易冷丶人心易凉 阅读(397) 评论(0) 推荐(0) 编辑
摘要: 1.使用select intobegin select dno into v_dno from tbl where xxx.exception when no_data_found then --无数据end; 2.游标fetchopen mycursor;fetch mycursor into rec; if mycursor%notfound then --无数据 end if;close mycursor;3.游标%rowcount属性判断open mycursor; if mycursor%rowcount =0 then --无数据 end if; clo... 阅读全文
posted @ 2013-11-19 17:36 烟花易冷丶人心易凉 阅读(3050) 评论(0) 推荐(0) 编辑