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

Class to implement the Result service. More...

+ Inheritance diagram for Result:

Public Member Functions

 __construct (Platform $platform, string $endpoint, ?int $limit=null, bool $pagingMode=false)
 Class constructor.
 
Outcome[] bool getAll (?int $limit=null)
 Retrieve all outcomes for a line-item.
 
Outcome null bool get (User $user)
 Retrieve an outcome for a user.
 
- Public Member Functions inherited from AssignmentGrade
 __construct (Platform $platform, string $endpoint, string $path='')
 Class constructor.
 
- Public Member Functions inherited from Service
 __construct (Platform $platform, ?string $endpoint)
 Class constructor.
 
Platform getPlatform ()
 Get platform.
 
string getScope ()
 Get access scope.
 
HttpMessage send (string $method, ?array $parameters=[], string $body='')
 Send a service request.
 
HttpMessage getHttpMessage ()
 Get HttpMessage object for last request.
 

Public Attributes

const MEDIA_TYPE_RESULT = 'application/vnd.ims.lis.v2.resultcontainer+json'
 Media type for the Result service.
 
- Public Attributes inherited from Service
bool $unsigned = false
 Whether service request should be sent unsigned.
 

Static Public Attributes

static string $SCOPE = 'https://purl.imsglobal.org/spec/lti-ags/scope/result.readonly'
 Access scope.
 
static int $defaultLimit = 500
 Default limit on size of container to be returned from requests.
 

Additional Inherited Members

- Protected Member Functions inherited from Service
array parseContextsInArray (object|array $contexts, array $arr)
 Parse the JSON for context references.
 
- Protected Attributes inherited from Service
string $endpoint = null
 Service endpoint.
 
string $scope = null
 Service access scope.
 
string $mediaType = null
 Media type of message body.
 

Detailed Description

Class to implement the Result service.

Author
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 ( Platform $platform,
string $endpoint,
?int $limit = null,
bool $pagingMode = false )

Class constructor.

Parameters
Platform$platformPlatform object for this service request
string$endpointService endpoint
int | null$limitLimit of results to be returned in each request, null for all
bool$pagingModeTrue if only a single page should be requested when a limit is set

Member Function Documentation

◆ get()

Outcome null bool get ( User $user)

Retrieve an outcome for a user.

Parameters
User$userUser object
Returns
Outcome|null|bool Outcome object, or null if none, or false on error

◆ getAll()

Outcome[] bool getAll ( ?int $limit = null)

Retrieve all outcomes for a line-item.

Parameters
int | null$limitLimit of results to be returned in each request, null for service default
Returns
Outcome[]|bool Array of Outcome objects or false on error