Blesta Source Documentation

LineFormatter extends AbstractItemFormatter

Abstract item formatter

Table of Contents

Properties

$formatFields
$itemFactory

Methods

__construct() Init
format() Formats the given fields
formatService() Formats the given service data
make() Makes a formatted Item from the given fields and the formatted fields available from the given method
makeItem() Creates an item
Properties
Methods

format()

Formats the given fields

public format(stdClass $fields) : Item
Parameters
$fields : stdClass

An stdClass object representing the fields

Return values
Item

An Item instance

formatService()

Formats the given service data

public formatService(stdClass $fields) : Item
Parameters
$fields : stdClass

An stdClass object representing the object data fields

Return values
Item

An Item instance

make()

Makes a formatted Item from the given fields and the formatted fields available from the given method

public make(string $method, stdClass $fields) : Item
Parameters
$method : string

The FormatFields method to call for matching fields

$fields : stdClass

An stdClass object representing the object data fields

Return values
Item

A formatted Item

makeItem()

Creates an item

public makeItem(stdClass|array<string|int, mixed> $fields) : Item
Parameters
$fields : stdClass|array<string|int, mixed>

A set of fields to include on the item

Return values
Item

An Item instance


        
On this page

Search results