UpdateMediaObjectDTO
extends AbstractBaseDto
in package
UpdateMediaObjectDTO
Data Transfer Object for updating a MediaObject
Table of Contents
Properties
- $userEnteredTitle : string|null
- $apiPropertyName : string
- The name of the property in the API
Methods
- __construct() : mixed
- Constructor
- fromArray() : self
- Create DTO from array
- toApiArray() : array<string|int, mixed>
- Convert the DTO to an array for API requests
- toArray() : array<string, mixed>
- Convert the DTO to an array for API request
- validate() : void
- Validate the DTO data
Properties
$userEnteredTitle
public
string|null
$userEnteredTitle
= null
$apiPropertyName
The name of the property in the API
protected
string
$apiPropertyName
= ''
Methods
__construct()
Constructor
public
__construct([string|null $userEnteredTitle = null ]) : mixed
Parameters
- $userEnteredTitle : string|null = null
-
The new title for the media object
fromArray()
Create DTO from array
public
static fromArray(array<string, mixed> $data) : self
Parameters
- $data : array<string, mixed>
Return values
selftoApiArray()
Convert the DTO to an array for API requests
public
toApiArray() : array<string|int, mixed>
Return values
array<string|int, mixed>toArray()
Convert the DTO to an array for API request
public
toArray() : array<string, mixed>
Return values
array<string, mixed>validate()
Validate the DTO data
protected
validate() : void