net.paoding.rose.jade.core
类 Identity

java.lang.Object
  继承者 java.lang.Number
      继承者 net.paoding.rose.jade.core.Identity
所有已实现的接口:
Serializable

已过时。

@Deprecated
public class Identity
extends Number

请改成这样使用:

 1、在@SQL上声明注解@ReturnGeneratedKeys
 2、方法返回值改为欲返回的数值类型,比如long、int等
 例子:
 
 @ReturnGeneratedKeys
 @SQL("insert into role(id, name) values(myseq.nextal, :1)")
 public long save(String name);
 
在Jade DAO方法声明其返回类型为 Identity表示,在执行插入语句后返回数据库设置的ID(自增ID等)

作者:
王志亮 [qieqie.wang@gmail.com], 廖涵 [in355hz@gmail.com]
另请参见:
序列化表格

字段摘要
protected  Number number
          已过时。  
 
构造方法摘要
Identity(Number number)
          已过时。 构造对象容纳返回的对象 ID.
 
方法摘要
 double doubleValue()
          已过时。  
 float floatValue()
          已过时。  
 int intValue()
          已过时。  
 long longValue()
          已过时。  
 String toString()
          已过时。  
 
从类 java.lang.Number 继承的方法
byteValue, shortValue
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

字段详细信息

number

protected Number number
已过时。 
构造方法详细信息

Identity

public Identity(Number number)
已过时。 
构造对象容纳返回的对象 ID.

参数:
number - - 返回的对象 ID
方法详细信息

intValue

public int intValue()
已过时。 
指定者:
Number 中的 intValue

longValue

public long longValue()
已过时。 
指定者:
Number 中的 longValue

floatValue

public float floatValue()
已过时。 
指定者:
Number 中的 floatValue

doubleValue

public double doubleValue()
已过时。 
指定者:
Number 中的 doubleValue

toString

public String toString()
已过时。 
覆盖:
Object 中的 toString


Copyright © 2012. All Rights Reserved.