Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions api/src/org/labkey/api/data/MaterializedQueryHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,12 @@ public boolean peekValid(long createdTime)
return peekValid();
}

/** Supplier value as of the last {@link #stillValid} or {@link #markValidAs}; null before either. */
public @Nullable String snapshot()
{
return _result.get();
}

/**
* Current supplier value, with no change to the stored snapshot. Capture this before doing work,
* then pass it to {@link #markValidAs} once the work has committed.
Expand Down
3 changes: 3 additions & 0 deletions api/src/org/labkey/api/exp/api/SampleTypeService.java
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ default Map<String, Long> incrementSampleCounts(@Nullable Date counterDate)

int recomputeSampleTypeRollup(@NotNull ExpSampleType sampleType, Set<Long> rootRowIds, Set<String> parentNames, Container container) throws IllegalStateException, SQLException;

/** Callers that delete exp.material rows directly must call this, or the sample type's materialized view keeps them. @param deletedRowIds null forces a full reconcile */
void refreshSampleTypeMaterializedViewAfterDelete(@NotNull ExpSampleType st, @Nullable Collection<Long> deletedRowIds);

Map<String, Integer> moveSamples(Collection<? extends ExpMaterial> samples, @NotNull Container sourceContainer, @NotNull Container targetContainer, @NotNull User user, @Nullable String userComment, @Nullable AuditBehaviorType auditBehavior) throws ExperimentException, BatchValidationException;

long getCurrentCount(NameGenerator.EntityCounter counterType, Container container);
Expand Down
Loading
Loading