Search in sources :

Example 1 with SingleExperimentAnalysis

use of ubic.gemma.model.analysis.SingleExperimentAnalysis in project Gemma by PavlidisLab.

the class AclAdvice method createOrUpdateAclSpecialCases.

@Override
protected void createOrUpdateAclSpecialCases(MutableAcl acl, Acl parentAcl, Sid sid, Securable object) {
    // If aclParent is passed to this method we overwrite it.
    if (SingleExperimentAnalysis.class.isAssignableFrom(object.getClass())) {
        SingleExperimentAnalysis experimentAnalysis = (SingleExperimentAnalysis) object;
        BioAssaySet bioAssaySet = experimentAnalysis.getExperimentAnalyzed();
        ObjectIdentity oi_temp = this.makeObjectIdentity(bioAssaySet);
        try {
            parentAcl = this.getAclService().readAclById(oi_temp);
        } catch (NotFoundException nfe) {
            // This is possible if making an EESubSet is part of the transaction.
            parentAcl = this.getAclService().createAcl(oi_temp);
        }
        acl.setEntriesInheriting(true);
        acl.setParent(parentAcl);
        // noinspection UnusedAssignment //Owner of the experiment owns analyses even if administrator ran them.
        sid = parentAcl.getOwner();
    }
}
Also used : BioAssaySet(ubic.gemma.model.expression.experiment.BioAssaySet) SingleExperimentAnalysis(ubic.gemma.model.analysis.SingleExperimentAnalysis)

Aggregations

SingleExperimentAnalysis (ubic.gemma.model.analysis.SingleExperimentAnalysis)1 BioAssaySet (ubic.gemma.model.expression.experiment.BioAssaySet)1