站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Hibernate 3.2.3 正式版 API 英文文档

Validatable (Hibernate API Documentation) - Hibernate 3.2.3 正式版 API 英文文档


org.hibernate.classic
Interface Validatable


public interface Validatable

Implemented by persistent classes with invariants that must be checked before inserting into or updating the database.

Author:
Gavin King

Method Summary
 void validate()
          Validate the state of the object before persisting it.
 

Method Detail

validate

public void validate()
              throws ValidationFailure
Validate the state of the object before persisting it. If a violation occurs, throw a ValidationFailure. This method must not change the state of the object by side-effect.

Throws:
ValidationFailure - if an invariant is violated