- java.lang.Object
-
- com.atlassian.confluence.api.impl.service.relation.DefaultValidatingRelationDescriptor<S,T>
-
- com.atlassian.confluence.api.impl.service.relation.AuthenticatedUserRelationDescriptor<S,T>
-
- All Implemented Interfaces:
RelationDescriptor<S,T>
,ValidatingRelationDescriptor<S,T>
public class AuthenticatedUserRelationDescriptor<S extends User,T extends Relatable> extends DefaultValidatingRelationDescriptor<S,T>
AValidatingRelationDescriptor
which checks that theUser
for which the relation is being created is also the currently authenticated user. Used to validate relations where users can only create relations for themselves.- Since:
- 5.11
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
AuthenticatedUserRelationDescriptor(RelationDescriptor relationDescriptor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ValidationResult
canRelate(S source, T target)
ReturnsValidationResult
, which indicates if two given entities may form a relation, described by thisRelationDescriptor
object-
Methods inherited from class com.atlassian.confluence.api.impl.service.relation.DefaultValidatingRelationDescriptor
getRelationName, getSourceClass, getTargetClass
-
-
-
-
Constructor Detail
-
AuthenticatedUserRelationDescriptor
protected AuthenticatedUserRelationDescriptor(RelationDescriptor relationDescriptor)
-
-
Method Detail
-
canRelate
public ValidationResult canRelate(S source, T target)
Description copied from interface:ValidatingRelationDescriptor
ReturnsValidationResult
, which indicates if two given entities may form a relation, described by thisRelationDescriptor
object
-
-