Parser and the API used for writing Ubiquity commands have changed in Ubiquity 0.5. In this discussion, the new parser will be named Parser 2 and previous one Parser 1 (i.e, used by Ubiquity 0.1.9 and below). Ubiquity 0.5, by default, uses Parser 2 and Parser 1 (and the Parser 1 API) will be deprecated in the future.
Parser 1 is forward-compatible to use commands written for Parser2, but Parser 2 is not backwards compatible to use commands written for Parser1. If you have commands written for Parser 1 and have updated to Ubiquity 0.5, you have the following options:
- Rewrite commands with new API
- Go to the Ubiquity 0.5 settings page and turn off "use Parser 2". However, this is an interim solution because Parser 1 will be deprecated in the future.
Ubiquity is still an experimental product. It has evolved and will evolve further in the future. However, Ubiquity designers have tried to make Parser 2 API future-proof and flexible enough to support plans for the foreseeable future. So, hopefully we won't have to migrate again after this. Let's see if Ubiquity designers can keep their promises or not.
if (CmdUtils.parserVersion == 2)
//parser 2 command here
else
//parser 1 command here
1 comment:
phone girls in London
Post a Comment