PHP Класс Dingo\Blueprint\Blueprint

Показать файл Открыть проект Примеры использования класса

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

Свойство Тип Описание
$files Illuminate\Filesystem\Filesystem Filesytsem instance.
$includePath string Include path for documentation files.
$reader Doctrine\Common\Annotations\SimpleAnnotationReader Simple annotation reader instance.

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

Метод Описание
__construct ( Doctrine\Common\Annotations\SimpleAnnotationReader $reader, Illuminate\Filesystem\Filesystem $files ) : void Create a new generator instance.
generate ( Collection $controllers, string $name, string $version, string $includePath ) : boolean Generate documentation with the name and version.

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

Метод Описание
appendAttributes ( string &$contents, Collection $attributes, integer $indent ) : void Append the attributes subsection to a resource or action.
appendBody ( string &$contents, string $body ) : void Append a body subsection to an action.
appendHeaders ( string &$contents, array $headers ) : void Append a headers subsection to an action.
appendParameters ( string &$contents, Collection $parameters ) : void Append the parameters subsection to a resource or action.
appendRequest ( string &$contents, Dingo\Blueprint\Annotation\Request $request, Resource $resource ) : void Append a request subsection to an action.
appendResponse ( string &$contents, Dingo\Blueprint\Annotation\Response $response, Resource $resource ) : void Append a response subsection to an action.
appendSection ( string &$contents, string $name, integer $indent, integer $lines = 2 ) : void Append a subsection to an action.
generateContentsFromResources ( Collection $resources, string $name ) : string Generate the documentation contents from the resources collection.
getFormat ( ) : string Get the API Blueprint format.
line ( integer $repeat = 1 ) : string Create a new line character.
prepareBody ( string $body, string $contentType ) : string Prepare a body.
registerAnnotationLoader ( ) : void Register the annotation loader.
tab ( integer $repeat = 1 ) : string Create a tab character.

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

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

Create a new generator instance.
public __construct ( Doctrine\Common\Annotations\SimpleAnnotationReader $reader, Illuminate\Filesystem\Filesystem $files ) : void
$reader Doctrine\Common\Annotations\SimpleAnnotationReader
$files Illuminate\Filesystem\Filesystem
Результат void

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

Append the attributes subsection to a resource or action.
protected appendAttributes ( string &$contents, Collection $attributes, integer $indent ) : void
$contents string
$attributes Illuminate\Support\Collection
$indent integer
Результат void

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

Append a body subsection to an action.
protected appendBody ( string &$contents, string $body ) : void
$contents string
$body string
Результат void

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

Append a headers subsection to an action.
protected appendHeaders ( string &$contents, array $headers ) : void
$contents string
$headers array
Результат void

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

Append the parameters subsection to a resource or action.
protected appendParameters ( string &$contents, Collection $parameters ) : void
$contents string
$parameters Illuminate\Support\Collection
Результат void

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

Append a request subsection to an action.
protected appendRequest ( string &$contents, Dingo\Blueprint\Annotation\Request $request, Resource $resource ) : void
$contents string
$request Dingo\Blueprint\Annotation\Request
$resource Resource
Результат void

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

Append a response subsection to an action.
protected appendResponse ( string &$contents, Dingo\Blueprint\Annotation\Response $response, Resource $resource ) : void
$contents string
$response Dingo\Blueprint\Annotation\Response
$resource Resource
Результат void

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

Append a subsection to an action.
protected appendSection ( string &$contents, string $name, integer $indent, integer $lines = 2 ) : void
$contents string
$name string
$indent integer
$lines integer
Результат void

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

Generate documentation with the name and version.
public generate ( Collection $controllers, string $name, string $version, string $includePath ) : boolean
$controllers Illuminate\Support\Collection
$name string
$version string
$includePath string
Результат boolean

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

Generate the documentation contents from the resources collection.
protected generateContentsFromResources ( Collection $resources, string $name ) : string
$resources Illuminate\Support\Collection
$name string
Результат string

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

Get the API Blueprint format.
protected getFormat ( ) : string
Результат string

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

Create a new line character.
protected line ( integer $repeat = 1 ) : string
$repeat integer
Результат string

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

Prepare a body.
protected prepareBody ( string $body, string $contentType ) : string
$body string
$contentType string
Результат string

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

Register the annotation loader.
protected registerAnnotationLoader ( ) : void
Результат void

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

Create a tab character.
protected tab ( integer $repeat = 1 ) : string
$repeat integer
Результат string

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

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

Filesytsem instance.
protected Filesystem,Illuminate\Filesystem $files
Результат Illuminate\Filesystem\Filesystem

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

Include path for documentation files.
protected string $includePath
Результат string

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

Simple annotation reader instance.
protected SimpleAnnotationReader,Doctrine\Common\Annotations $reader
Результат Doctrine\Common\Annotations\SimpleAnnotationReader