PHP Класс M1\Vars\Resource\ResourceProvider

С версии: 0.1.0
Наследование: extends AbstractResource, use trait M1\Vars\Traits\ResourceFlagsTrait
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$vars M1\Vars\Vars The parent Vars class

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

Метод Описание
__construct ( Vars $vars, string | array $entity, boolean $relative = true, boolean $recursive = false ) The ResourceProvider constructor creates the content from the entity
addParentContent ( array $content ) Adds content to the parent content array
getParentContent ( ) : mixed Returns the parent content
mergeParentContent ( ) : ResourceProvider Merges the content and the parent content together

Приватные методы

Метод Описание
addContent ( array $content ) Adds content to the parent contents
createResources ( array $resources, string $type ) Creates the FileResource|ResourceProvider from the resource
getSupportedFilesInDir ( string $entity ) : array | boolean Returns the supported files using the extensions from the loaders in the entity which is a directory
mergeContents ( ) : array Merges various configuration contents into one array
parseEntity ( string $entity ) Creates the content from the entity
processEntity ( string | array $entity, string $type ) Creates the content from the entity

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

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

The ResourceProvider constructor creates the content from the entity
public __construct ( Vars $vars, string | array $entity, boolean $relative = true, boolean $recursive = false )
$vars M1\Vars\Vars The calling Vars class
$entity string | array The configuration entity
$relative boolean Is the entity relative to the calling entity or class
$recursive boolean If entity a dir, do you want to recursively check directories

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

Adds content to the parent content array
public addParentContent ( array $content )
$content array The content to add

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

Returns the parent content
public getParentContent ( ) : mixed
Результат mixed The parent content

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

Merges the content and the parent content together
public mergeParentContent ( ) : ResourceProvider
Результат ResourceProvider

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

$vars публичное свойство

The parent Vars class
public Vars,M1\Vars $vars
Результат M1\Vars\Vars