Skip to content

Commit c9fc515

Browse files
Improve inline documentation
1 parent 658735f commit c9fc515

File tree

3 files changed

+21
-5
lines changed

3 files changed

+21
-5
lines changed

src/AbstractComponent.php

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,29 @@
22

33
namespace Snappy;
44

5+
/**
6+
* Base class for generator components.
7+
*
8+
* @method void generate(array|string $input, string $output, array $options, bool $overwrite)
9+
* @method void generateFromHtml(array|string $html, string $output, array $options, bool $overwrite)
10+
* @method string getOutput(array|string $input, array $options)
11+
* @method string getOutputFromHtml(array|string $html, array $options)
12+
*/
513
abstract class AbstractComponent extends \CApplicationComponent
614
{
715
/**
8-
* @var string
16+
* @var string Path to wkhtmltox binary
917
*/
1018
public $binary;
1119
/**
12-
* @var array
20+
* @var array Command line options
1321
*/
1422
public $options = array();
1523

1624
/**
17-
* @return \Knp\Snappy\GeneratorInterface
25+
* Creates and returns generator instance.
26+
*
27+
* @return \Knp\Snappy\AbstractGenerator
1828
*/
1929
abstract protected function getGenerator();
2030

src/ImageComponent.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,13 @@
22

33
namespace Snappy;
44

5+
/**
6+
* Image generator component.
7+
*/
58
class ImageComponent extends AbstractComponent
69
{
710
/**
8-
* {@inheritdoc}
11+
* @return \Knp\Snappy\Image
912
*/
1013
protected function getGenerator()
1114
{

src/PdfComponent.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,13 @@
22

33
namespace Snappy;
44

5+
/**
6+
* PDF generator component.
7+
*/
58
class PdfComponent extends AbstractComponent
69
{
710
/**
8-
* {@inheritdoc}
11+
* @return \Knp\Snappy\Pdf
912
*/
1013
protected function getGenerator()
1114
{

0 commit comments

Comments
 (0)