PHP Класс Bootstrapper\MediaObject

Наследование: extends bootstrapper\RenderedObject
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$contents The contents of the media object
$list Whether the list

Открытые методы

Метод Описание
asList ( ) Force the media object to become a list
render ( ) : string Renders the media object
withContents ( array $contents ) Sets the contents of the media object

Защищенные методы

Метод Описание
getBody ( array $contents ) : string Get the body of the contents array
getHeading ( array $contents ) : string Get the heading of the media object
getImage ( array $contents, string $alt ) : string Get the image of the media object
getLink ( array $contents, string $image, string $position ) : string Turn the image into a link/div
getPosition ( array $contents ) : string Get the position
renderItem ( array $contents, string $tag ) : string Renders an item in the string
renderList ( ) : string Renders a list

Описание методов

asList() публичный Метод

Force the media object to become a list
public asList ( )

getBody() защищенный Метод

Get the body of the contents array
protected getBody ( array $contents ) : string
$contents array
Результат string

getHeading() защищенный Метод

Get the heading of the media object
protected getHeading ( array $contents ) : string
$contents array
Результат string

getImage() защищенный Метод

Get the image of the media object
protected getImage ( array $contents, string $alt ) : string
$contents array
$alt string The alt text of the image
Результат string

getPosition() защищенный Метод

Get the position
protected getPosition ( array $contents ) : string
$contents array
Результат string pull-right if the position key equals right. pull-left otherwise

render() публичный Метод

Renders the media object
public render ( ) : string
Результат string

renderItem() защищенный Метод

Renders an item in the string
protected renderItem ( array $contents, string $tag ) : string
$contents array
$tag string The tag to wrap the item in
Результат string

renderList() защищенный Метод

Renders a list
protected renderList ( ) : string
Результат string

withContents() публичный Метод

Sets the contents of the media object
public withContents ( array $contents )
$contents array The contents of the media object

Описание свойств

$contents защищенное свойство

The contents of the media object
protected $contents

$list защищенное свойство

Whether the list
protected $list