IPRangesCsvWriter
class IPRangesCsvWriter (View source)
Properties
protected Writer | $writer | The writer we use to output. |
|
protected int | $type | One of the IPService::IPRANGETYPE_... constants. |
|
protected Date | $dateHelper | The date localization service. |
Methods
insertHeaders()
Insert a header row for this result set.
array[]|Generator
projectRanges($ranges)
A generator that takes a collection of IPRange ranges and converts it to CSV rows.
string[]
string[]
getHeaders()
Get the headers of the CSV.
Details
__construct(Writer $writer, int $type, Date $dateHelper)
No description
insertHeaders()
Insert a header row for this result set.
insertRanges(IPRange[]|Generator $ranges)
Insert a list of IPRange instances.
insertRange(IPRange $range)
Insert an IPRange instance.
private array[]|Generator
projectRanges($ranges)
A generator that takes a collection of IPRange ranges and converts it to CSV rows.
private string[]
projectRange(IPRange $range)
Turn an IPRange instance into an array.
private string[]
getHeaders()
Get the headers of the CSV.