Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

(no description)

File Size: 131 lines (5 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: nrps_info  - X-Ref

Class nrps_info, instances of which represent a names and roles provisioning service for a resource.

For information about Names and Role Provisioning Services 2.0, see http://www.imsglobal.org/spec/lti-nrps/v2p0.

__construct(\moodle_url $contextmembershipsurl, array $serviceversions = [self::SERVICE_VERSION_2])   X-Ref
The private nrps_info constructor.

param: \moodle_url $contextmembershipsurl the memberships URL.
param: string[] $serviceversions the supported service versions.

create(\moodle_url $contextmembershipsurl,array $serviceversions = [self::SERVICE_VERSION_2])   X-Ref
Factory method to create a new nrps_info instance.

return: nrps_info the object instance.
param: \moodle_url $contextmembershipsurl the memberships URL.
param: string[] $serviceversions the supported service versions.

is_valid_service_version(string $serviceversion)   X-Ref
Check whether the supplied service version is valid or not.

return: bool true if valid, false otherwise.
param: string $serviceversion the service version to check.

set_service_versions(array $serviceversions)   X-Ref
Tries to set the supported service versions for this instance.

param: array $serviceversions the service versions to set.

get_context_memberships_url()   X-Ref
Get the service URL for this grade service instance.

return: \moodle_url the service URL.

get_service_versions()   X-Ref
Get the supported service versions for this grade service instance.

return: string[] the array of supported service versions.

get_service_scope()   X-Ref
Get the nrps service scope.

return: string the service scope.