A class representing a line/column offset into a combined generated file, for index map generation.
More...
|
| __construct (int $line, int $column) |
|
| toArray () |
| Convert the object to plain data.
|
|
| add (self $nextSize) |
| Advance the offset, assuming a file of the specified size was added to the combined file.
|
|
|
static | newFromText (string $text) |
| Count the number of lines and columns in the specified string, and create an IndexMapOffset representing the corresponding size.
|
|
static | newFromArray (array $data) |
| Restore an IndexMapOffset which was serialized with toArray().
|
|
A class representing a line/column offset into a combined generated file, for index map generation.
Or it can represent the past-the-end offset of a single specified file, that is, the number of lines in the file and the number of columns in the last line of the file.
◆ __construct()
Wikimedia\Minify\IndexMapOffset::__construct |
( |
int | $line, |
|
|
int | $column ) |
- Parameters
-
int | $line | The zero-based line number |
int | $column | The zero-based column number |
◆ add()
Wikimedia\Minify\IndexMapOffset::add |
( |
self | $nextSize | ) |
|
Advance the offset, assuming a file of the specified size was added to the combined file.
- Parameters
-
- Returns
- void
◆ newFromArray()
static Wikimedia\Minify\IndexMapOffset::newFromArray |
( |
array | $data | ) |
|
|
static |
Restore an IndexMapOffset which was serialized with toArray().
- Parameters
-
- Returns
- self
◆ newFromText()
static Wikimedia\Minify\IndexMapOffset::newFromText |
( |
string | $text | ) |
|
|
static |
Count the number of lines and columns in the specified string, and create an IndexMapOffset representing the corresponding size.
- Parameters
-
- Returns
- self
◆ toArray()
Wikimedia\Minify\IndexMapOffset::toArray |
( |
| ) |
|
Convert the object to plain data.
- Returns
- array
The documentation for this class was generated from the following file: