Class Revision

java.lang.Object
de.aristaflow.adept2.model.common.Revision
All Implemented Interfaces:
Serializable

public class Revision extends Object implements Serializable
Entities are tracked by revisions, whereas each revision is identified by a system-wide unique count. Additionally, a revision has a timestamp from the time the corresponding revision has been created, the agent creating (releasing) a revision and an arbitrary comment for the revision.
Author:
Ulrich Kreher
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final QualifiedAgent
    The agent releasing this revision.
    protected final String
    The comment for this revision.
    protected final long
    The revision count of this revision.
    protected final long
    The timestamp of this revision.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Revision(long revision, long timestamp, QualifiedAgent agent, String comment)
    Creates a new revision object with the designated revision count, the timestamp, the agent and the comment.
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the agent releasing this revision.
    Gets the comment for this revision, that is arbitrary text provided by the releasing agent.
    long
    Gets the revision count of this revision.
    long
    Gets the timestamp of this revision, that is the time, this revision has been created.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • revision

      protected final long revision
      The revision count of this revision.
    • timestamp

      protected final long timestamp
      The timestamp of this revision.
    • agent

      protected final QualifiedAgent agent
      The agent releasing this revision.
    • comment

      protected final String comment
      The comment for this revision.
  • Constructor Details

    • Revision

      public Revision(long revision, long timestamp, QualifiedAgent agent, String comment)
      Creates a new revision object with the designated revision count, the timestamp, the agent and the comment.
      Parameters:
      revision - The revision count of this revision.
      timestamp - The timestamp of this revision.
      agent - The agent releasing this revision.
      comment - The comment for this revision.
  • Method Details

    • getRevision

      public long getRevision()
      Gets the revision count of this revision. 0 is for the initial revision, that is the corresponding entity is not versioned yet.
      Returns:
      The revision count of this revision.
    • getTimestamp

      public long getTimestamp()
      Gets the timestamp of this revision, that is the time, this revision has been created. 0 is for the initial revision, that is the corresponding entity is not versioned yet.
      Returns:
      The timestamp of this revision.
    • getAgent

      public QualifiedAgent getAgent()
      Gets the agent releasing this revision. null is for the initial revision, that is the corresponding entity is not versioned yet.
      Returns:
      The agent releasing this revision.
    • getComment

      public String getComment()
      Gets the comment for this revision, that is arbitrary text provided by the releasing agent. The empty string is for the initial revision, that is the corresponding entity is not versioned yet.
      Returns:
      The comment for this revision.