Overview

Namespaces

  • NGS
    • Client
      • Exception
    • Converter
    • Patterns
  • PHP

Classes

  • AggregateDomainEvent
  • AggregateRoot
  • CubeBuilder
  • DomainEvent
  • GenericSearch
  • Identifiable
  • OlapCube
  • Repository
  • Search
  • Searchable
  • SearchBuilder
  • Snapshot
  • Specification
  • Templater

Interfaces

  • IDomainObject
  • IIdentifiable
  • Overview
  • Namespace
  • Class
  • Tree

Class Templater

Service for creating documents based on templates and data. Data can be provided or specification can be sent so data is queried on the server.

Byte array is returned from the server which represents docx, xlsx, text or converted pdf file.

More info about Templater library can be found at http://templater.info

Namespace: NGS\Patterns
Located at Patterns/Templater.php
Methods summary
public
# __construct( string $file, string $class = null )

Creates a generic templater

Creates a generic templater

Parameters

$file
string
$file Name of template file located on server
$class
string
$class Class name of domain object

Throws

InvalidArgumentException
If invalid arguments provided
public string
# find( string $uri )

Fills template with domain object

Fills template with domain object

Parameters

$uri
string
$uri

Returns

string
Binary content of genarated template

Throws

InvalidArgumentException
If data source was invalid type
public string
# search( NGS\Patterns\Specification|NGS\Patterns\GenericSearch $source )

Fills template with data returned from specification or generic search

Fills template with data returned from specification or generic search

Parameters

$source
NGS\Patterns\Specification|NGS\Patterns\GenericSearch
$source data source

Returns

string
Binary content of genarated template

Throws

InvalidArgumentException
If data source was invalid type
API documentation generated by ApiGen 2.8.0