 2 | Method javax.jdo.Query long deletePersistentAll( Object... parameters ) Deletes all the instances of the candidate class that pass the filter. Parameters: parameters - for the query Returns: the number of instances of the candidate class that were deleted Since: JDO 2.0 See Also: deletePersistentAll() |
 2 | Method javax.jdo.identity.LongIdentity long getKey() Return the key. Returns: the key Since: JDO 1.0 |
 2 | :
@Id
public Long getId() { return id; } Since: JPA 1.0 See Also: Column GeneratedValue Learn |
 2 | .PESSIMISTIC_WRITE, and LockModeType.PESSIMISTIC_FORCE_INCREMENT are used to immediately obtain long |
 2 | ;
...
}
@Entity
public class Movie {
@Id long id;
String title |
 2 | . Example:
@Entity
public class CreditCard {
@Id long ccNumber;
@OneToMany |
 2 | Constructor javax.jdo.identity.LongIdentity LongIdentity( Class pcClass, Long key ) Constructor with class and key. Parameters: pcClass - the class key - the key Since: JDO 1.0 |
 2 | static final long serialVersionUID = 998L;
@Id @GeneratedValue long id;
@Index private Long instrumentId;
private SafeLong tStamp; The SafeLong class is a very simple wrapper of a long -
@Embeddable
public class SafeLong implements Serializable, Comparable{
public long |
 2 | Method javax.jdo.spi.StateManager void providedLongField( PersistenceCapable pc, int field, long currentValue ) The value of the field requested to be provided to the StateManager. Parameters: pc - the calling PersistenceCapable instance field - the field number currentValue - the current value of the field Since: JDO 1.0 |
 2 | Method javax.jdo.spi.StateManager long replacingLongField( PersistenceCapable pc, int field ) The replacement value of the field in the calling instance. Parameters: pc - the calling PersistenceCapable instance field - the field number Returns: the new value for the field Since: JDO 1.0 |