Package org.hibernate.envers.query
Class AuditEntity
- java.lang.Object
-
- org.hibernate.envers.query.AuditEntity
-
public class AuditEntity extends java.lang.Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static AuditCriterion
and(AuditCriterion lhs, AuditCriterion rhs)
Return the conjuction of two criterions.static AuditConjunction
conjunction()
Group criterions together in a single conjunction (A and B and C...).static AuditDisjunction
disjunction()
Group criterions together in a single disjunction (A or B or C...).static AuditId
id()
static AuditId
id(java.lang.String alias)
static AuditCriterion
not(AuditCriterion expression)
Return the negation of a criterion.static AuditCriterion
or(AuditCriterion lhs, AuditCriterion rhs)
Return the disjuction of two criterions.static AuditProperty<java.lang.Object>
property(java.lang.String propertyName)
Create restrictions, projections and specify order for a property of an audited entity.static AuditProperty<java.lang.Object>
property(java.lang.String alias, java.lang.String propertyName)
Create restrictions, projections and specify order for a property of an audited entity.static AuditRelatedId
relatedId(java.lang.String propertyName)
Create restrictions on an id of a related entity.static AuditRelatedId
relatedId(java.lang.String alias, java.lang.String propertyName)
Create restrictions on an id of a related entity.static AuditProperty<java.lang.Number>
revisionNumber()
Create restrictions, projections and specify order for the revision number, corresponding to an audited entity.static AuditProperty<java.lang.Number>
revisionNumber(java.lang.String alias)
Create restrictions, projections and specify order for the revision number, corresponding to an audited entity.static AuditProperty<java.lang.Object>
revisionProperty(java.lang.String propertyName)
Create restrictions, projections and specify order for a property of the revision entity, corresponding to an audited entity.static AuditProperty<java.lang.Object>
revisionProperty(java.lang.String alias, java.lang.String propertyName)
Create restrictions, projections and specify order for a property of the revision entity, corresponding to an audited entity.static AuditProperty<RevisionType>
revisionType()
Create restrictions, projections and specify order for the revision type, corresponding to an audited entity.static AuditProperty<RevisionType>
revisionType(java.lang.String alias)
Create restrictions, projections and specify order for the revision type, corresponding to an audited entity.static AuditProjection
selectEntity(boolean distinct)
Adds a projection to the current entity itself.
-
-
-
Method Detail
-
id
public static AuditId id()
-
id
public static AuditId id(java.lang.String alias)
-
property
public static AuditProperty<java.lang.Object> property(java.lang.String propertyName)
Create restrictions, projections and specify order for a property of an audited entity.- Parameters:
propertyName
- Name of the property.
-
property
public static AuditProperty<java.lang.Object> property(java.lang.String alias, java.lang.String propertyName)
Create restrictions, projections and specify order for a property of an audited entity.- Parameters:
alias
- the alias of the entity which owns the property.propertyName
- Name of the property.
-
revisionNumber
public static AuditProperty<java.lang.Number> revisionNumber()
Create restrictions, projections and specify order for the revision number, corresponding to an audited entity.
-
revisionNumber
public static AuditProperty<java.lang.Number> revisionNumber(java.lang.String alias)
Create restrictions, projections and specify order for the revision number, corresponding to an audited entity.- Parameters:
alias
- the alias of the entity which owns the revision number.
-
revisionProperty
public static AuditProperty<java.lang.Object> revisionProperty(java.lang.String propertyName)
Create restrictions, projections and specify order for a property of the revision entity, corresponding to an audited entity.- Parameters:
propertyName
- Name of the property.
-
revisionProperty
public static AuditProperty<java.lang.Object> revisionProperty(java.lang.String alias, java.lang.String propertyName)
Create restrictions, projections and specify order for a property of the revision entity, corresponding to an audited entity.- Parameters:
alias
- the alias of the entity which owns the revision property.propertyName
- Name of the property.
-
revisionType
public static AuditProperty<RevisionType> revisionType()
Create restrictions, projections and specify order for the revision type, corresponding to an audited entity.
-
revisionType
public static AuditProperty<RevisionType> revisionType(java.lang.String alias)
Create restrictions, projections and specify order for the revision type, corresponding to an audited entity.- Parameters:
alias
- the alias of the entity which owns the revision type.
-
relatedId
public static AuditRelatedId relatedId(java.lang.String propertyName)
Create restrictions on an id of a related entity.- Parameters:
propertyName
- Name of the property, which is the relation.
-
relatedId
public static AuditRelatedId relatedId(java.lang.String alias, java.lang.String propertyName)
Create restrictions on an id of a related entity.- Parameters:
alias
- the alias of the entity which owns the relation property.propertyName
- Name of the property, which is the relation.
-
and
public static AuditCriterion and(AuditCriterion lhs, AuditCriterion rhs)
Return the conjuction of two criterions.
-
or
public static AuditCriterion or(AuditCriterion lhs, AuditCriterion rhs)
Return the disjuction of two criterions.
-
not
public static AuditCriterion not(AuditCriterion expression)
Return the negation of a criterion.
-
conjunction
public static AuditConjunction conjunction()
Group criterions together in a single conjunction (A and B and C...).
-
disjunction
public static AuditDisjunction disjunction()
Group criterions together in a single disjunction (A or B or C...).
-
selectEntity
public static AuditProjection selectEntity(boolean distinct)
Adds a projection to the current entity itself. Useful for selecting entities which are reached through associations within the query.- Parameters:
distinct
- whether to distinct select the entity
-
-