LTI Integration Library 5.1.4
PHP class library for building LTI integrations
 
Loading...
Searching...
No Matches
MoodleApiContext Class Reference

Class to implement Context services for a Moodle platform via its web services. More...

+ Inheritance diagram for MoodleApiContext:

Public Member Functions

 __construct (Context $context)
 Class constructor.
 
bool getGroups ()
 Get course group sets and groups.
 
array bool getMemberships (bool $withGroups=false)
 Get Memberships.
 
- Public Member Functions inherited from ApiContext
bool isConfigured ()
 Check if the API hook has been configured.
 
array bool getToolSettings (?ToolSettingsMode $mode=null, bool $simple=true)
 Get Tool Settings.
 
bool setToolSettings (array $settings=[])
 Perform a Tool Settings service request.
 
- Public Member Functions inherited from MoodleApi
bool isConfigured ()
 Check if the API hook has been configured.
 

Additional Inherited Members

- Protected Attributes inherited from ApiContext
Context $context
 Context object.
 

Detailed Description

Class to implement Context services for a Moodle platform via its web services.

Author
Tony Butler a.but.nosp@m.ler4.nosp@m.@lanc.nosp@m.aste.nosp@m.r.ac..nosp@m.uk
Stephen P Vickers steph.nosp@m.en@s.nosp@m.pvsof.nosp@m.twar.nosp@m.eprod.nosp@m.ucts.nosp@m..com
Licence: http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public License, version 3

Constructor & Destructor Documentation

◆ __construct()

__construct ( Context $context)

Class constructor.

Parameters
Context$context

Reimplemented from ApiContext.

Member Function Documentation

◆ getGroups()

bool getGroups ( )

Get course group sets and groups.

Returns
bool True if the request was successful

Reimplemented from ApiContext.

◆ getMemberships()

array bool getMemberships ( bool $withGroups = false)

Get Memberships.

Parameters
bool$withGroupsTrue is group information is to be requested as well
Returns
array|bool Array of UserResult objects or false if the request was not successful

Reimplemented from ApiContext.