Skip to content

Commit

Permalink
Merge ac063ca into 99be3a6
Browse files Browse the repository at this point in the history
  • Loading branch information
Gappa committed Aug 21, 2018
2 parents 99be3a6 + ac063ca commit 2a179c1
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

## Link Generator

There is a tiny extension which provides cachable LinkGenerator. LinkGenerator is a external service for creating
URL addreses / links out of presenter scope. For example in mail templates.
A tiny extension which provides cacheable LinkGenerator. LinkGenerator is an external service for creating
URL addresses / links out of presenter scope, e.g. in mail templates.

```yaml
extensions:
Expand All @@ -30,16 +30,16 @@ extensions:

### Presenter

Extending `BasePresenter` you can use these methods:
By extending the `BasePresenter` you can use these methods:

| Methods | Return | Description |
|---------|--------|-------------|
| `isModuleCurrent($module)` | `boolean` | Is current presenter in given module? |
| `getModuleName()` | `string` | Get current presenter module's name. |
| `isModuleCurrent($module)` | `boolean` | Is the current presenter in a given module? |
| `getModuleName()` | `string` | Get current presenter's module name. |

#### Structured Templates

Trait which modifies where are presenter templates located.
A trait which modifies where the presenter templates are loaded from.

- Views
- `%presenterDir%/templates/%view%.latte`
Expand Down Expand Up @@ -110,7 +110,7 @@ $presenter->sendResponse(new PSR7StreamResponse($stream, 'invoice.pdf', 'applica

There are 2 types of fly response:

- **FlyResponse** - For common purpose and your custom solutions.
- **FlyResponse** - General purpose fly response.
- **FlyFileResponse** - Special response for handling files on-the-fly.

### XmlResponse
Expand All @@ -123,13 +123,13 @@ $presenter->sendResponse(new XmlResponse($xml));

#### ProcessAdapter

Execute command over [popen](http://php.net/manual/en/function.popen.php).
Execute a command over [popen](http://php.net/manual/en/function.popen.php).

```php
use Contributte\Application\Response\Fly\Adapter\ProcessAdapter;
use Contributte\Application\Response\Fly\FlyFileResponse;

// Compress current folder and send to response
// Compress the current folder and send it to a response
$adapter = new ProcessAdapter('tar cf - ./ | gzip -c -f');
$response = new FlyFileResponse($adapter, 'folder.tgz');

Expand Down

0 comments on commit 2a179c1

Please sign in to comment.