PHP Class Crummy\Phlack\Common\Formatter\LinkFormatter

Inheritance: implements Crummy\Phlack\Common\Formatter\FormatterInterface
Mostrar archivo Open project: mcrumm/phlack

Public Methods

Method Description
format ( string $text ) : string

Protected Methods

Method Description
getMatchFormatter ( integer $linkIdx = 1, integer $labelIdx = 2 ) : Closure

Method Details

format() public method

public format ( string $text ) : string
$text string
return string

getMatchFormatter() protected method

protected getMatchFormatter ( integer $linkIdx = 1, integer $labelIdx = 2 ) : Closure
$linkIdx integer The index of the matches containing the resource link
$labelIdx integer The index of the matches containing the label (if one exists)
return Closure A callable to be passed to preg_replace_callback