Class NewDataSetPredicate
- java.lang.Object
-
- ch.systemsx.cisd.openbis.dss.generic.shared.api.internal.authorization.NewDataSetPredicate
-
- All Implemented Interfaces:
IAuthorizationGuardPredicate<ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.IDssServiceRpcGeneric,ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO>
,IDataSetPredicate<ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO>
public class NewDataSetPredicate extends java.lang.Object implements IAuthorizationGuardPredicate<ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.IDssServiceRpcGeneric,ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO>
Predicate for checking that the new data set can be registered (i.e., user has access to the space for the new data set).This is an internal class. Do not use it as a user of the API.
-
-
Constructor Summary
Constructors Constructor Description NewDataSetPredicate()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ch.systemsx.cisd.common.exceptions.Status
evaluate(ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.IDssServiceRpcGeneric receiver, java.lang.String sessionToken, ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO newDataSet)
Evaluate the predicate for the receiver object, sessionToken, and predicate argument.java.util.List<java.lang.String>
getDataSetCodes(ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO argument)
Extracts from the specified argument data set codes.
-
-
-
Method Detail
-
getDataSetCodes
public java.util.List<java.lang.String> getDataSetCodes(ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO argument)
Description copied from interface:IDataSetPredicate
Extracts from the specified argument data set codes. Returns an empty list if there is no data set code to extract.- Specified by:
getDataSetCodes
in interfaceIDataSetPredicate<ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO>
-
evaluate
public ch.systemsx.cisd.common.exceptions.Status evaluate(ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.IDssServiceRpcGeneric receiver, java.lang.String sessionToken, ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO newDataSet) throws ch.systemsx.cisd.common.exceptions.UserFailureException
Description copied from interface:IAuthorizationGuardPredicate
Evaluate the predicate for the receiver object, sessionToken, and predicate argument.- Specified by:
evaluate
in interfaceIAuthorizationGuardPredicate<ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.IDssServiceRpcGeneric,ch.systemsx.cisd.openbis.dss.generic.shared.api.v1.NewDataSetDTO>
- Parameters:
receiver
- The object on which the guarded method was calledsessionToken
- A token identifying the usernewDataSet
- The argument to the predicate- Returns:
- Status.OK if the action is allowed, Status.createError() otherwise.
- Throws:
ch.systemsx.cisd.common.exceptions.UserFailureException
-
-