com.anasoft.os.daofusion.bitemporal
Class BitemporalTrace

java.lang.Object
  extended by com.anasoft.os.daofusion.bitemporal.BitemporalTrace
All Implemented Interfaces:
java.io.Serializable

public class BitemporalTrace
extends java.lang.Object
implements java.io.Serializable

A trace of Bitemporal objects, bitemporally tracking some value (for instance the name of a person). A bitemporal trace works on top of (wraps) a collection of Bitemporal objects, representing the raw data to query and manipulate.

Together with Bitemporal, BitemporalTrace provides a low-level API for bitemporal data tracking and manipulation expressed in terms of Bitemporal objects.

A bitemporal trace will be serializable if all Bitemporal objects it contains are serializable.

A bitemporal trace is not thread-safe.

Author:
Erwin Vervaet, Christophe Vanfleteren, igor.mihalik
See Also:
Bitemporal, Serialized Form

Constructor Summary
BitemporalTrace(java.util.Collection<Bitemporal> data)
          Create a new bitemporal trace working on top of given data collection.
 
Method Summary
 void add(Bitemporal newValue)
          Adds the given Bitemporal object to the trace, manipulating the trace as necessary.
 java.util.Collection<Bitemporal> get(org.joda.time.DateTime validOn, org.joda.time.DateTime knownOn)
          Returns Bitemporal objects valid on given date as known on specified date.
 java.util.Collection<Bitemporal> getData()
          Returns the wrapped data collection.
 java.util.Collection<Bitemporal> getEvolution(org.joda.time.DateTime validOn)
          Returns the evolution of the tracked value for a specified validity date.
 java.util.Collection<Bitemporal> getHistory(org.joda.time.DateTime knownOn)
          Returns the history of the tracked value, as known on specified time.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BitemporalTrace

public BitemporalTrace(java.util.Collection<Bitemporal> data)
Create a new bitemporal trace working on top of given data collection.

Method Detail

getData

public java.util.Collection<Bitemporal> getData()
Returns the wrapped data collection.


get

public java.util.Collection<Bitemporal> get(org.joda.time.DateTime validOn,
                                            org.joda.time.DateTime knownOn)
Returns Bitemporal objects valid on given date as known on specified date.


getHistory

public java.util.Collection<Bitemporal> getHistory(org.joda.time.DateTime knownOn)
Returns the history of the tracked value, as known on specified time. The history informs you about how the valid value changed over time.


getEvolution

public java.util.Collection<Bitemporal> getEvolution(org.joda.time.DateTime validOn)
Returns the evolution of the tracked value for a specified validity date. The evolution informs you about how knowledge about the value valid at a certain date evolved.


add

public void add(Bitemporal newValue)
Adds the given Bitemporal object to the trace, manipulating the trace as necessary. This is essentially the basic bitemporal data manipulation operation.


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2008-2009 ANASOFT and contributors. All Rights Reserved.