Class BwUnversionedDbentity<T>

java.lang.Object
org.bedework.calfacade.base.DumpEntity<T>
org.bedework.calfacade.base.BwUnversionedDbentity<T>
Type Parameters:
T -
All Implemented Interfaces:
Serializable, Comparable<T>, org.bedework.util.logging.Logged
Direct Known Subclasses:
BwDbentity, BwLastMod, EventInfo

public class BwUnversionedDbentity<T> extends DumpEntity<T> implements Comparable<T>, Serializable
Base type for a database entity. We require an id and the subclasses must implement get/setHref, hashcode and compareTo.
Version:
1.0
Author:
Mike Douglass
See Also:
  • Constructor Details

    • BwUnversionedDbentity

      public BwUnversionedDbentity()
  • Method Details

    • setId

      public void setId(int val)
      Parameters:
      val -
    • getId

      public int getId()
      Returns:
      int id
    • unsaved

      public boolean unsaved()
      Returns:
      true if this entity is not saved.
    • markUnsaved

      public void markUnsaved()
      Mark this entity as not saved.
    • setHref

      public void setHref(String val)
      Parameters:
      val - the href - may be ignored
    • getHref

      public String getHref()
      Returns:
      non null unique href for the entity
    • toStringSegment

      protected void toStringSegment(org.bedework.util.misc.ToString ts)
      Add our stuff to the ToString object
      Parameters:
      ts - ToString for result
    • clone

      public Object clone()
      Make visible
      Overrides:
      clone in class Object
      Returns:
      Object of class T
    • compareTo

      public int compareTo(T o)
      Specified by:
      compareTo in interface Comparable<T>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object