-
Notifications
You must be signed in to change notification settings - Fork 57
Migration guide from v4 to v5
Raúl Ferràs edited this page Feb 11, 2018
·
2 revisions
A lot of changes were made to v5 to improve usability on PoParser.
All classes were under the namespace Sepia
.
It now goes all under Sepia\PoParser
.
Sepia\PoParser
did too much work, it parsed, edited and dumped PO catalogs.
This has now been split into components:
-
Sepia\PoParser\Parser
handles the parsing of a PO source data. -
Sepia\PoParser\PoCompiler
handles the dumping of a PO catalog back to a file. -
Sepia\PoParser\Catalog\CatalogArray
stores a collection of PO entries. It contains methods to read and modify them.
Old PoParser
class has received a lot of changes:
- Constructor does not accept options anymore. Improvements in how entries are stored in the catalog, there's no need for
multiline-glue
norcontext-glue
to control how entries with Context or multi lines are saved in the catalog. -
parser
method now returns a Catalog. Optionally it accepts a Catalog as an input argument. TheParser
class does not longer stores entries in aentries
property.