Class DesignCommitPlan

java.lang.Object
ubic.gemma.persistence.service.expression.experiment.DesignCommitPlan

public class DesignCommitPlan extends Object
Side-channel the web-layer design mapper hands to ExpressionExperimentService.commitCuration(ExpressionExperiment, CurationCommitRequest, boolean) so the service can, after applying the proposed design, (1) resolve each new entity's clientRef to the database id it was assigned and (2) wire sample assignments that target freshly-created factor values.

The proposed ExperimentalDesignValueObject carries new entities as id == null; it cannot express which clientRef each corresponds to, nor can its bioMaterialAssignments (which reference factor values by Long id) target a not-yet-created factor value. This plan closes both gaps.

Correlation is order-based. The rebuilt design read after apply sorts factors and factor values by ascending id, database ids are monotonic in creation order, and creation follows the proposed-items order — so the k-th newly-created entity corresponds to the k-th recorded clientRef. The preExisting* id sets tell the service which ids in the rebuilt design are "new" (absent from these sets).

  • Constructor Details

    • DesignCommitPlan

      public DesignCommitPlan()
  • Method Details

    • getPreExistingFactorIds

      public Set<Long> getPreExistingFactorIds()
    • setPreExistingFactorIds

      public void setPreExistingFactorIds(Set<Long> preExistingFactorIds)
    • getPreExistingFactorValueIds

      public Set<Long> getPreExistingFactorValueIds()
    • setPreExistingFactorValueIds

      public void setPreExistingFactorValueIds(Set<Long> preExistingFactorValueIds)
    • getNewFactorClientRefs

      public List<String> getNewFactorClientRefs()
    • setNewFactorClientRefs

      public void setNewFactorClientRefs(List<String> newFactorClientRefs)
    • getNewFactorValueClientRefsByParentKey

      public Map<String, List<String>> getNewFactorValueClientRefsByParentKey()
    • setNewFactorValueClientRefsByParentKey

      public void setNewFactorValueClientRefsByParentKey(Map<String, List<String>> newFactorValueClientRefsByParentKey)
    • getPendingAssignments

      public List<DesignCommitPlan.PendingAssignment> getPendingAssignments()
    • setPendingAssignments

      public void setPendingAssignments(List<DesignCommitPlan.PendingAssignment> pendingAssignments)
    • existingFactorKey

      public static String existingFactorKey(Long factorId)
      Parent-key helpers keep the "F:" / "C:" convention in one place.
    • newFactorKey

      public static String newFactorKey(String factorClientRef)