Documentation

OverrideTarget
in package

Override Target Object

Represents a target (user or section) for a module assignment override. This is a read-only object that is embedded within ModuleAssignmentOverride responses.

Table of Contents

Properties

$id  : int|null
The ID of the user or section that the override is targeting
$name  : string|null
The name of the user or section that the override is targeting
$type  : string|null
The type of target ('student', 'section', or 'group')

Methods

__construct()  : mixed
Constructor
getId()  : int|null
Get the target ID
getName()  : string|null
Get the target name
getType()  : string|null
Get the type
isGroup()  : bool
Check if this is a group target
isSection()  : bool
Check if this is a section target
isStudent()  : bool
Check if this is a student target
setId()  : void
Set the target ID
setName()  : void
Set the target name
setType()  : void
Set the type
toArray()  : array<string|int, mixed>
Convert to array

Properties

$id

The ID of the user or section that the override is targeting

public int|null $id = null

$name

The name of the user or section that the override is targeting

public string|null $name = null

$type

The type of target ('student', 'section', or 'group')

public string|null $type = null

Methods

__construct()

Constructor

public __construct([array<string|int, mixed> $data = [] ]) : mixed
Parameters
$data : array<string|int, mixed> = []

getId()

Get the target ID

public getId() : int|null
Return values
int|null

getName()

Get the target name

public getName() : string|null
Return values
string|null

getType()

Get the type

public getType() : string|null
Return values
string|null

isGroup()

Check if this is a group target

public isGroup() : bool
Return values
bool

isSection()

Check if this is a section target

public isSection() : bool
Return values
bool

isStudent()

Check if this is a student target

public isStudent() : bool
Return values
bool

setId()

Set the target ID

public setId(int|null $id) : void
Parameters
$id : int|null

setName()

Set the target name

public setName(string|null $name) : void
Parameters
$name : string|null

setType()

Set the type

public setType(string|null $type) : void
Parameters
$type : string|null

toArray()

Convert to array

public toArray() : array<string|int, mixed>
Return values
array<string|int, mixed>

        
On this page

Search results