mirror of
https://github.com/moodle/moodle.git
synced 2025-01-29 11:46:19 +01:00
MDL-63924 privacy: Add shared user providers to subsytsems
This commit is contained in:
parent
44e56956c6
commit
c96cd71102
@ -87,11 +87,17 @@ class metadata_registry {
|
||||
$internaldata['deprecated'] = true;
|
||||
}
|
||||
|
||||
// Check that the userlist provider is implemented.
|
||||
// Check that the core_userlist_provider is implemented for all user data providers.
|
||||
if ($componentclass instanceof \core_privacy\local\request\core_user_data_provider
|
||||
&& !$componentclass instanceof \core_privacy\local\request\core_userlist_provider) {
|
||||
$internaldata['userlistnoncompliance'] = true;
|
||||
}
|
||||
|
||||
// Check that any type of userlist_provider is implemented for all shared data providers.
|
||||
if ($componentclass instanceof \core_privacy\local\request\shared_data_provider
|
||||
&& !$componentclass instanceof \core_privacy\local\request\userlist_provider) {
|
||||
$internaldata['userlistnoncompliance'] = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -36,7 +36,10 @@ defined('MOODLE_INTERNAL') || die();
|
||||
* @author Adrian Greeve <adriangreeve.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
interface logstore_userlist_provider extends \core_privacy\local\request\plugin\subplugin_provider {
|
||||
interface logstore_userlist_provider extends
|
||||
\core_privacy\local\request\plugin\subplugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Add user IDs that contain user information for the specified context.
|
||||
|
4
cache/classes/privacy/provider.php
vendored
4
cache/classes/privacy/provider.php
vendored
@ -39,7 +39,9 @@ class provider implements
|
||||
\core_privacy\local\metadata\provider,
|
||||
|
||||
// The cache subsystem stores data on behalf of other components.
|
||||
\core_privacy\local\request\subsystem\plugin_provider {
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -37,7 +37,11 @@ use \core_privacy\local\request\userlist;
|
||||
* @copyright 2018 Adrian Greeve <adrian@moodle.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class provider implements \core_privacy\local\metadata\provider, \core_privacy\local\request\subsystem\plugin_provider {
|
||||
class provider implements
|
||||
\core_privacy\local\metadata\provider,
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -41,7 +41,11 @@ require_once($CFG->dirroot . '/comment/lib.php');
|
||||
* @copyright 2018 Adrian Greeve <adrian@moodle.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class provider implements \core_privacy\local\metadata\provider, \core_privacy\local\request\subsystem\plugin_provider {
|
||||
class provider implements
|
||||
\core_privacy\local\metadata\provider,
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -48,7 +48,8 @@ class provider implements
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\core_userlist_provider,
|
||||
// We store a userkey for token-based file access.
|
||||
\core_privacy\local\request\subsystem\provider {
|
||||
\core_privacy\local\request\subsystem\provider,
|
||||
\core_privacy\local\request\shared_userlist_provider {
|
||||
|
||||
/**
|
||||
* Returns metadata.
|
||||
|
@ -26,7 +26,9 @@ namespace core_grading\privacy;
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
interface gradingform_provider_v2 extends
|
||||
\core_privacy\local\request\plugin\subsystem_provider {
|
||||
\core_privacy\local\request\plugin\subsystem_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Export user data relating to an instance ID.
|
||||
|
@ -51,7 +51,9 @@ class provider implements
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
|
||||
// This plugin is capable of determining which users have data within it.
|
||||
\core_privacy\local\request\core_userlist_provider {
|
||||
\core_privacy\local\request\core_userlist_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -39,9 +39,11 @@ use core_privacy\local\request\userlist;
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class provider implements
|
||||
\core_privacy\local\metadata\provider,
|
||||
\core_privacy\local\metadata\provider,
|
||||
|
||||
\core_privacy\local\request\subsystem\plugin_provider {
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -28,7 +28,10 @@ namespace mod_assign\privacy;
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
interface assignfeedback_user_provider extends \core_privacy\local\request\plugin\subplugin_provider {
|
||||
interface assignfeedback_user_provider extends
|
||||
\core_privacy\local\request\plugin\subplugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* If you have tables that contain userids and you can generate entries in your tables without creating an
|
||||
@ -49,4 +52,4 @@ interface assignfeedback_user_provider extends \core_privacy\local\request\plugi
|
||||
*/
|
||||
public static function delete_feedback_for_grades(assign_plugin_request_data $deletedata);
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -30,7 +30,10 @@ use core_privacy\local\request\userlist;
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
interface assignsubmission_user_provider extends \core_privacy\local\request\plugin\subplugin_provider {
|
||||
interface assignsubmission_user_provider extends
|
||||
\core_privacy\local\request\plugin\subplugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* If you have tables that contain userids and you can generate entries in your tables without creating an
|
||||
@ -51,4 +54,4 @@ interface assignsubmission_user_provider extends \core_privacy\local\request\plu
|
||||
*/
|
||||
public static function delete_submissions(assign_plugin_request_data $deletedata);
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -33,7 +33,13 @@ defined('MOODLE_INTERNAL') || die();
|
||||
* @copyright 2018 Marina Glancy
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
interface datafield_provider extends \core_privacy\local\request\plugin\subplugin_provider {
|
||||
interface datafield_provider extends
|
||||
\core_privacy\local\request\plugin\subplugin_provider,
|
||||
|
||||
// The data subplugins do not need to do anything themselves for the shared_userlist.
|
||||
// This is all handled by the parent plugin.
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Exports data about one record in {data_content} table.
|
||||
|
@ -33,7 +33,10 @@ defined('MOODLE_INTERNAL') || die();
|
||||
* @copyright 2018 David Mudrák <david@moodle.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
interface workshopform_provider extends \core_privacy\local\request\plugin\subplugin_provider {
|
||||
interface workshopform_provider extends
|
||||
\core_privacy\local\request\plugin\subplugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Return details of the filled assessment form.
|
||||
|
@ -34,7 +34,8 @@ defined('MOODLE_INTERNAL') || die();
|
||||
*/
|
||||
interface plagiarism_user_provider extends
|
||||
// The plagiarism_provider should be implemented by plugins which only provide information to a subsystem.
|
||||
\core_privacy\local\request\plugin\subsystem_provider {
|
||||
\core_privacy\local\request\plugin\subsystem_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider {
|
||||
|
||||
/**
|
||||
* Delete all user information for the provided users and context.
|
||||
|
@ -40,7 +40,9 @@ class provider implements
|
||||
\core_privacy\local\metadata\provider,
|
||||
|
||||
// The Plagiarism subsystem will be called by other components and will forward requests to each plagiarism plugin implementing its APIs.
|
||||
\core_privacy\local\request\subsystem\plugin_provider {
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -34,7 +34,10 @@ defined('MOODLE_INTERNAL') || die();
|
||||
*/
|
||||
interface portfolio_provider extends
|
||||
// The portfolio_provider should be implemented by plugins which only provide information to a subsystem.
|
||||
\core_privacy\local\request\plugin\subsystem_provider {
|
||||
\core_privacy\local\request\plugin\subsystem_provider,
|
||||
|
||||
// The implementation for prtfolios is handled in the subsystem itself.
|
||||
\core_privacy\local\request\shared_userlist_provider {
|
||||
|
||||
/**
|
||||
* Export all portfolio data from each portfolio plugin for the specified userid and context.
|
||||
|
@ -45,7 +45,9 @@ class provider implements
|
||||
\core_privacy\local\request\plugin\provider,
|
||||
\core_privacy\local\request\core_userlist_provider,
|
||||
// The portfolio subsystem will be called by other components.
|
||||
\core_privacy\local\request\subsystem\plugin_provider {
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
|
||||
\core_privacy\local\request\shared_userlist_provider {
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
@ -61,7 +61,10 @@ class provider implements
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
|
||||
// This plugin is capable of determining which users have data within it.
|
||||
\core_privacy\local\request\core_userlist_provider
|
||||
\core_privacy\local\request\core_userlist_provider,
|
||||
|
||||
// This plugin is capable of determining which users have data within it for the plugins it provides data to.
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
|
@ -46,7 +46,9 @@ class provider implements
|
||||
// as a result.
|
||||
|
||||
// The ratings subsystem provides a data service to other components.
|
||||
\core_privacy\local\request\subsystem\plugin_provider {
|
||||
\core_privacy\local\request\subsystem\plugin_provider,
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns metadata about the ratings subsystem.
|
||||
|
@ -51,7 +51,10 @@ class provider implements
|
||||
\core_privacy\local\request\core_userlist_provider,
|
||||
|
||||
// The tag subsystem may have data that belongs to this user.
|
||||
\core_privacy\local\request\plugin\provider {
|
||||
\core_privacy\local\request\plugin\provider,
|
||||
|
||||
\core_privacy\local\request\shared_userlist_provider
|
||||
{
|
||||
|
||||
/**
|
||||
* Returns meta data about this system.
|
||||
|
Loading…
x
Reference in New Issue
Block a user