Class AbstractCuratableValueObject<C extends Curatable>

java.lang.Object
ubic.gemma.model.common.IdentifiableValueObject<C>
ubic.gemma.model.common.auditAndSecurity.curation.AbstractCuratableValueObject<C>
All Implemented Interfaces:
Serializable, Identifiable
Direct Known Subclasses:
ArrayDesignValueObject, ExpressionExperimentValueObject

public abstract class AbstractCuratableValueObject<C extends Curatable> extends IdentifiableValueObject<C>
Created by tesarst on 07/03/17. Abstract curatable value object that provides variables and methods for data stored in CurationDetails objects on curatable objects.
See Also:
  • Constructor Details

    • AbstractCuratableValueObject

      protected AbstractCuratableValueObject()
      Required when using the implementing classes as a spring beans.
    • AbstractCuratableValueObject

      protected AbstractCuratableValueObject(Long id)
    • AbstractCuratableValueObject

      protected AbstractCuratableValueObject(C curatable)
    • AbstractCuratableValueObject

      protected AbstractCuratableValueObject(C curatable, boolean skipEvents)
      Variant of AbstractCuratableValueObject(Curatable) that skips reading the three last*Event associations off CurationDetails. Use this when a caller is batch-hydrating the events post-fetch (see ExpressionExperimentDaoImpl's value-object transformer): passing skipEvents=true keeps the three lazy-proxy associations untouched at VO-construction time, avoiding ~3 SELECTs per row, and the caller fills in the three AuditEventValueObject fields via the inherited setters once a batched prefetch is available.
    • AbstractCuratableValueObject

      protected AbstractCuratableValueObject(AbstractCuratableValueObject<C> curatable)
      Copy constructor.
  • Method Details

    • applyLastEventTriple

      public void applyLastEventTriple(@Nullable AbstractCuratableValueObject.LastEventTriple triple)
      Apply a batched AbstractCuratableValueObject.LastEventTriple onto this VO. Wraps non-null AuditEvent references in AuditEventValueObject matching the per-row constructor's behaviour; respects the same admin-only gate on lastNoteUpdateEvent that the per-row ctor uses. Called by callers that constructed this VO with skipEvents=true.
    • getTroubled

      public boolean getTroubled()
    • setTroubled

      public void setTroubled(Boolean troubled)
    • getNeedsAttention

      public boolean getNeedsAttention()
    • setNeedsAttention

      public void setNeedsAttention(Boolean needsAttention)
    • getTroubleDetails

      public String getTroubleDetails()
      Returns:
      a string describing the current trouble of this object. In this case, only the trouble of the Expression Experiment are described. If you also need to include the Array Design trouble info, use ExpressionExperimentDetailsValueObject
    • getTroubleDetails

      public String getTroubleDetails(boolean htmlEscape)
    • getLastUpdated

      public Date getLastUpdated()
    • getLastTroubledEvent

      public AuditEventValueObject getLastTroubledEvent()
    • getLastNeedsAttentionEvent

      public AuditEventValueObject getLastNeedsAttentionEvent()
    • getCurationNote

      public String getCurationNote()
    • getLastNoteUpdateEvent

      public AuditEventValueObject getLastNoteUpdateEvent()
    • setLastUpdated

      public void setLastUpdated(Date lastUpdated)
    • setLastTroubledEvent

      public void setLastTroubledEvent(AuditEventValueObject lastTroubledEvent)
    • setLastNeedsAttentionEvent

      public void setLastNeedsAttentionEvent(AuditEventValueObject lastNeedsAttentionEvent)
    • setCurationNote

      public void setCurationNote(String curationNote)
    • setLastNoteUpdateEvent

      public void setLastNoteUpdateEvent(AuditEventValueObject lastNoteUpdateEvent)