fri.util.database.jpa.tree
Interface Temporal

All Known Subinterfaces:
TemporalNestedSetsTreeNode, TemporalTreePath
All Known Implementing Classes:
PersonDeletedFlagTreePath, PersonTemporalTreePath, PersonTnst, TemporalNestedSetsTreePojo, TemporalTreePathImpl

public interface Temporal

Responsibilities of a temporal entity. Such entities support a valid-from and a valid-to date that reflect their validity. A removed entity would have at least validTo set to a past date.

These properties are not required, implement them by do-nothing methods if your entities perform another validity check, e.g. using a "deleted" flag. In that case, be sure to pass null as validXXXPropertyName into the DAO constructor, and to override appendValidityCondition(), assignValidity(), appendInvalidityCondition(), assignInvalidity() and isValid() DAO methods.

Author:
Fritz Ritzberger, 12.10.2011

Field Summary
static java.lang.String VALID_FROM
          Default property names for the valid-from property as given by this interface.
static java.lang.String VALID_TO
          Default property names for the valid-to property as given by this interface.
 
Method Summary
 java.util.Date getValidFrom()
           
 java.util.Date getValidTo()
           
 void setValidFrom(java.util.Date validFrom)
          Sets the temporal valid-from date of this node.
 void setValidTo(java.util.Date validTo)
          Sets the temporal valid-to date of this node.
 

Field Detail

VALID_FROM

static final java.lang.String VALID_FROM
Default property names for the valid-from property as given by this interface.

See Also:
Constant Field Values

VALID_TO

static final java.lang.String VALID_TO
Default property names for the valid-to property as given by this interface.

See Also:
Constant Field Values
Method Detail

getValidTo

java.util.Date getValidTo()
Returns:
the temporal valid-to date of this node.

setValidTo

void setValidTo(java.util.Date validTo)
Sets the temporal valid-to date of this node.


getValidFrom

java.util.Date getValidFrom()
Returns:
the temporal valid-from date of this node.

setValidFrom

void setValidFrom(java.util.Date validFrom)
Sets the temporal valid-from date of this node.