All Implemented Interfaces:
Serializable

@Entity(name="EventFile") public class EventFile extends BaseEntity<Long>
The EventFile entity represents a file with information (other than the race's results) concerning an Event or an event's Race.

An EventFile may refer to the event's guide, regulations, courses or media images.

The EventFile's fields are defined as follows:

  • id : the unique identifier of the EventFile that is automatically generated and is the primary key.
  • title : the title of the file that should describe the EventFile's content.
  • fileType : the FileType used to classify the type of EventFile that is associated with an Event.
  • fileName : the file name that has exactly 24 characters and has the format YYYYMMDDXXXNNN-TTTYYY-VV.ext. In this format, "YYYYMMDDXXXNNN" corresponds to the Event's reference, "TTT", written in upper case letters, corresponds to the document type ("GDE" for guides, "REG" for Regulations, "MAP" for course maps, "IMG" for images and "STL" for start lists), "YYY" is the document's order number (in the cases where there are, for example, different regulations in the same event: middle distance regulations and full distance regulations), "VV" corresponds to the document's revision number (the first revision always starts at "01") and "ext" corresponds to the file extension (always in lower case letters).
  • revisionNumber : the revision number of the file. The first revision always starts at "01".
  • isActive : flag that indicates the most recent version of a EventFile. It is set to true for the file with the highest revisionNumber and false for all previous versions.
See Also:
  • Constructor Details

    • EventFile

      public EventFile()
      Default constructor for the EventFile entity.
  • Method Details

    • getTitle

      public String getTitle()
    • setTitle

      public void setTitle(String title)
    • getFileType

      public FileType getFileType()
    • setFileType

      public void setFileType(FileType fileType)
    • getFileName

      public String getFileName()
    • setFileName

      public void setFileName(String fileName)
    • getRevision

      public Integer getRevision()
    • setRevision

      public void setRevision(Integer revision)
    • getActive

      public Boolean getActive()
    • setActive

      public void setActive(Boolean active)
    • equals

      public boolean equals(Object o)
      Description copied from class: BaseEntity
      Equality is based on the entity's identifier. Two entities are considered equal if they are of the same class and have the same non-null identifier.

      If the ID is null, we treat it as a transient (new) object. Transient objects are only equal if they are the exact same instance.

      Overrides:
      equals in class BaseEntity<Long>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class BaseEntity<Long>
    • toString

      public String toString()
      Overrides:
      toString in class Object