\Ceo\Core\AdaptersVimeoAdapter

Base Vimeo video adapter. The adapter is a placeholder and provides links back to the parent vimeo video

Summary

Methods
Properties
Constants
adapterFor()
canHandle()
__construct()
getType()
getDimensions()
toImage()
previewUrl()
originalUrl()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
registerAdapters()
$adapters
N/A

Properties

$adapters

$adapters : 

Type

Methods

adapterFor()

adapterFor(array  $file, string  $path) : mixed

Locate the first adapter that's able to handle a file.

Each adapter determines its ability to handle a particular file

Parameters

array $file

JSON file information

string $path

Temp file path

Returns

mixed —

Adapter instance if found, false otherwise

canHandle()

canHandle(array  $file, string  $temp_path) : boolean

Vimeo adapter will _always_ return false.

Parameters

array $file

File info

string $temp_path

temporary path

Returns

boolean

__construct()

__construct(  $file = null,   $temp_path = null) 

Parameters

$file
$temp_path

getType()

getType() : string

Adapter type

Returns

string —

Image

getDimensions()

getDimensions() : mixed

Get the original file dimensions, if possible.

Returns NULL otherwise

Returns

mixed —

Array with 'height', 'width' keys. NULL if not able to extract dimensions

toImage()

toImage(array  $size = array(), string  $path = false) : string

Convert to preview image

Return NULL if not possible

Size array MUST allow for either height and/or width to be set without flipping the heck out.

Keep in mind the return string path is temporary and should be processed accordingly

Parameters

array $size

dims

string $path

source path

Returns

string —

output path

previewUrl()

previewUrl(  $attachment) : string

Override previewUrl method Return container's first child preview URL

Parameters

$attachment

Returns

string

originalUrl()

originalUrl(  $attachment) : string

Override originalUrl method Return container's first child original URL

Parameters

$attachment

Returns

string

registerAdapters()

registerAdapters() : boolean

Register all adapters

Returns

boolean