public function SocialRemoveRoleUser::__construct in Open Social 8.9
Same name and namespace in other branches
- 8.7 modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
- 8.8 modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
- 10.3.x modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
- 10.0.x modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
- 10.1.x modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
- 10.2.x modules/social_features/social_user/src/Plugin/Action/SocialRemoveRoleUser.php \Drupal\social_user\Plugin\Action\SocialRemoveRoleUser::__construct()
Constructs a \Drupal\Component\Plugin\PluginBase object.
Parameters
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin_id for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
Overrides ChangeUserRoleBase::__construct
File
- modules/
social_features/ social_user/ src/ Plugin/ Action/ SocialRemoveRoleUser.php, line 42
Class
- SocialRemoveRoleUser
- Removes a role from a user but restricted by role.
Namespace
Drupal\social_user\Plugin\ActionCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeInterface $entity_type, AccountProxyInterface $currentUser, DelegatableRolesInterface $delegatableRoles) {
parent::__construct($configuration, $plugin_id, $plugin_definition, $entity_type);
$this->entityType = $entity_type;
$this->currentUser = $currentUser
->getAccount();
$this->delegatableRoles = $delegatableRoles;
}