Documentation

UploadedMediaObject
in package
implements MediaObjectInterface

Class UploadedMediaObject

Table of Contents

Interfaces

MediaObjectInterface
Media Object Interface

Properties

$object  : FormFlashInterface
$placeholderImage  : string
$field  : string|null
$filename  : string
$id  : string
$meta  : array<string|int, mixed>
$uploadedFile  : UploadedFileInterface|null

Methods

__construct()  : mixed
__debugInfo()  : array<string|int, string>
createFromFlash()  : static
createResponse()  : Response
Create media response.
exists()  : bool
Returns true if the object exists.
get()  : mixed|null
getId()  : string
Get identifier's ID.
getMeta()  : array<string|int, mixed>
Get metadata associated to the media object.
getType()  : string
Get identifier's type.
getUploadedFile()  : UploadedFileInterface|null
getUrl()  : string
Return URL pointing to the media object.
jsonSerialize()  : array<string|int, mixed>

Properties

$placeholderImage

public static string $placeholderImage = 'image://media/thumb.png'

Methods

__construct()

public __construct(string $id, string|null $field, string $filename[, UploadedFileInterface|null $uploadedFile = null ]) : mixed
Parameters
$id : string
$field : string|null
$filename : string
$uploadedFile : UploadedFileInterface|null = null

__debugInfo()

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

createFromFlash()

public static createFromFlash(FlexFormFlash $flash, string|null $field, string $filename[, UploadedFileInterface|null $uploadedFile = null ]) : static
Parameters
$flash : FlexFormFlash
$field : string|null
$filename : string
$uploadedFile : UploadedFileInterface|null = null
Return values
static

createResponse()

Create media response.

public createResponse(array<string|int, mixed> $actions) : Response
Parameters
$actions : array<string|int, mixed>
Return values
Response

exists()

Returns true if the object exists.

public exists() : bool
Return values
bool

get()

public get(string $field) : mixed|null
Parameters
$field : string
Return values
mixed|null

getMeta()

Get metadata associated to the media object.

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

getUploadedFile()

public getUploadedFile() : UploadedFileInterface|null
Return values
UploadedFileInterface|null

getUrl()

Return URL pointing to the media object.

public getUrl() : string
Return values
string

jsonSerialize()

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

        
On this page

Search results