PHP Class Essence\Provider\OEmbed\Config

Show file Open project: benjamminf/craft-embedded-assets Class Usage Examples

Protected Properties

Property Type Description
$_endpoint string Endpoint.
$_format string Format.

Public Methods

Method Description
__construct ( string $endpoint = '', string $format = Format::json ) Constructor.
completeEndpoint ( array $options ) Appends a set of options as parameters to the endpoint.
endpoint ( ) : string Returns the endpoint.
format ( ) : string Returns the format.
setEndpoint ( string $endpoint ) Sets the endpoint.
setFormat ( string $format ) Sets the format.

Method Details

__construct() public method

Constructor.
public __construct ( string $endpoint = '', string $format = Format::json )
$endpoint string The OEmbed endpoint.
$format string The expected response format.

completeEndpoint() public method

Appends a set of options as parameters to the endpoint.
public completeEndpoint ( array $options )
$options array Options to append.

endpoint() public method

Returns the endpoint.
public endpoint ( ) : string
return string Endpoint.

format() public method

Returns the format.
public format ( ) : string
return string Format.

setEndpoint() public method

Sets the endpoint.
public setEndpoint ( string $endpoint )
$endpoint string Endpoint.

setFormat() public method

Sets the format.
public setFormat ( string $format )
$format string Format.

Property Details

$_endpoint protected property

Endpoint.
protected string $_endpoint
return string

$_format protected property

Format.
protected string $_format
return string