Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Released PEAR2_Net_RouterOS-1.0.0b6. #39

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added www/get/PEAR2_Net_RouterOS-1.0.0b6.phar
Binary file not shown.
Binary file added www/get/PEAR2_Net_RouterOS-1.0.0b6.tar
Binary file not shown.
Binary file added www/get/PEAR2_Net_RouterOS-1.0.0b6.tgz
Binary file not shown.
Binary file added www/get/PEAR2_Net_RouterOS-1.0.0b6.zip
Binary file not shown.
3 changes: 2 additions & 1 deletion www/rest/p/pear2_net_routeros/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
<c>pear2.php.net</c>
<ca xlink:href="rest/c/Default" xmlns:xlink="rest/c/Default">Default</ca>
<l>LGPL License 2.1</l>
<s>RouterOS API client implementation.</s>
<s>RouterOS API client implementation.
</s>
<d>RouterOS is the flag product of the company MikroTik and is a powerful router software. One of its many abilities is to allow control over it via an API. This package provides a client for that API, in turn allowing you to use PHP to control RouterOS hosts.</d>
<r xmlns="http://pear.php.net/dtd/rest.package" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://pear.php.net/dtd/rest.package http://pear.php.net/dtd/rest.package.xsd"/>
</p>
46 changes: 46 additions & 0 deletions www/rest/r/pear2_net_routeros/1.0.0b6.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<r xmlns="http://pear.php.net/dtd/rest.release" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://pear.php.net/dtd/rest.release http://pear.php.net/dtd/rest.release.xsd">
<p xlink:href="rest/p/pear2_net_routeros">PEAR2_Net_RouterOS</p>
<c>pear2.php.net</c>
<v>1.0.0b6</v>
<st>beta</st>
<l>LGPL License 2.1</l>
<m>boen_robot</m>
<s>RouterOS API client implementation.
</s>
<d>RouterOS is the flag product of the company MikroTik and is a powerful router software. One of its many abilities is to allow control over it via an API. This package provides a client for that API, in turn allowing you to use PHP to control RouterOS hosts.</d>
<da>2017-05-22 15:41:15</da>
<n>Util stuff, mostly.

* __BREAKING CHANGES:__
- Removed all $mode arguments from all Countable implementations (turns out no stable 5.6+ releases uses it...), and the COUNT_RECURSIVE implementations (which were mostly useless anyway). Util::count() has the $query argument as its first one, and a new $from argument as a second one.
- All Util CRUD methods throw RouterErrorException when the router returns an error. Previously, you'd need to inspect the returned value to check if there's an error.
- Util::edit() is no longer an alias of Util::set(). It's now its own method that can modify or unset a single specified property.
- Util::fileGetContents() now throws RouterErrorException if the file doesn't exist or if there are other problems with getting its contents. Previously, it returned FALSE for such cases.
- Util's escapeValue(), escapeString(), parseValue(), prepareScript() and appendScript() methods are now in their own new class called &quot;Script&quot;, with the last two now being called just prepare() and append().
- Script::escapeValue() now converts DateTime objects into a string having the &quot;M/d/Y H:i:s&quot; format (used across RouterOS), or just &quot;M/d/Y&quot; if the time is exactly midnight, and the timezone is UTC. The old behaviour can be achieved by &quot;manually&quot; adding the DateTime to &quot;new DateTime('@0')&quot;.
* New Util methods:
- comment()
- getCurrentTime()
- newRequest()
* Script::escapeString() no longer escapes bytes above 0x7F. This means that parameter string values are now influenced by charset settings, and thus no additional conversion is necessary. A new second argument can be set to TRUE to escape all bytes, including the previously untouched ASCII alphanumeric characters and underscores.
* Stream parameters in Script::append() (and inherently, Script::prepare() and Util::exec()) now have ALL bytes escaped.
* Script::escapeValue() converts NULL to &quot;nil&quot; instead of &quot;nothing&quot;.
* The $params array in Script::append() can declare variables with a value of type &quot;nothing&quot; by using numeric keys, and the variable names as values.
* Script::parseValue() now supports letter notation for time (1h2m3s), not just double colon notation (01:02:03), modeled after RouterOS. Related to that is also that leading zeroes, and zero minutes and seconds are now optional (e.g. &quot;1:&quot; is a valid way of saying 1 hour). Sub-second information is rounded up to the nearest second on current PHP versions (future versions are expected to support sub-second information in DateInterval by allowing seconds to be a double; The code currently attempts to give DateInterval a double, falling back to rounding to a second).
* Script::parseValue() now recognizes dates in the &quot;M/d/Y H:i:s&quot; format (used across RouterOS), and turns that into a DateTime object for that time (or midnight in UTC if the time part is omitted).
* Util::getAll() now throws a NotSupportedException if the arguments &quot;follow&quot;, &quot;follow-only&quot; or &quot;count-only&quot; are used. The first two, because PHP would hang (since Client::sendSync() is used under the hood), and the last one because it's unredable in the returned output (use Util::count() instead).
* Util::setMenu() can now go back to the root menu.
* Util::exec() and stream valued arguments in both Util and Client no longer cause a hang when using charset conversion.
* Util::get() can now accept a query as an argument for $number
* Util::get() can have $valueName set to NULL (as is now by default), in which case all properties are retrieved in an array, parsed with Script::parseValueToArray().
* Util::get() no longer fallbacks automatically with a &quot;print&quot; request for buggy versions. You may &quot;manually&quot; call Util::getAll() if you suspect that's an issue.
* Util::find() now works even when the underlying Client streams responses.
* Util::move()'s second argument $destination is now optional, and without it (or if set to NULL), the item is moved at the bottom of the menu.
* Client::login() consumes the !done or !fatal response even when called on an already logged in connection.
* Client::sendAsync() no longer throws an exception if a request is canceled multiple times by the returned value of a callback.
* The console now checks whether PEAR2_CommandLine is installed, ensuring better error messages when this package is installed without its optional dependencies.</n>
<f>1052110</f>
<g>http://pear2.php.net/get/PEAR2_Net_RouterOS-1.0.0b6</g>
<x xlink:href="package.1.0.0b6.xml"/>
</r>
4 changes: 4 additions & 0 deletions www/rest/r/pear2_net_routeros/allreleases.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
<a xmlns="http://pear.php.net/dtd/rest.allreleases" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://pear.php.net/dtd/rest.allreleases http://pear.php.net/dtd/rest.allreleases.xsd">
<p>PEAR2_Net_RouterOS</p>
<c>pear2.php.net</c>
<r>
<v>1.0.0b6</v>
<s>beta</s>
</r>
<r>
<v>1.0.0b5</v>
<s>beta</s>
Expand Down
5 changes: 5 additions & 0 deletions www/rest/r/pear2_net_routeros/allreleases2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
<a xmlns="http://pear.php.net/dtd/rest.allreleases2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://pear.php.net/dtd/rest.allreleases2 http://pear.php.net/dtd/rest.allreleases2.xsd">
<p>PEAR2_Net_RouterOS</p>
<c>pear2.php.net</c>
<r>
<v>1.0.0b6</v>
<s>beta</s>
<m>5.3.0</m>
</r>
<r>
<v>1.0.0b5</v>
<s>beta</s>
Expand Down
2 changes: 1 addition & 1 deletion www/rest/r/pear2_net_routeros/beta.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.0b5
1.0.0b6
1 change: 1 addition & 0 deletions www/rest/r/pear2_net_routeros/deps.1.0.0b6.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
a:2:{s:8:"required";a:4:{s:3:"php";a:1:{s:3:"min";s:5:"5.3.0";}s:13:"pearinstaller";a:1:{s:3:"min";s:5:"1.4.0";}s:7:"package";a:3:{s:4:"name";s:21:"PEAR2_Net_Transmitter";s:7:"channel";s:13:"pear2.php.net";s:3:"min";s:7:"1.0.0b1";}s:9:"extension";a:1:{s:4:"name";s:4:"pcre";}}s:8:"optional";a:2:{s:7:"package";a:4:{i:0;a:3:{s:4:"name";s:14:"PEAR2_Autoload";s:7:"channel";s:13:"pear2.php.net";s:3:"min";s:5:"0.2.4";}i:1;a:3:{s:4:"name";s:15:"PEAR2_Cache_SHM";s:7:"channel";s:13:"pear2.php.net";s:3:"min";s:5:"0.1.3";}i:2;a:3:{s:4:"name";s:25:"PEAR2_Console_CommandLine";s:7:"channel";s:13:"pear2.php.net";s:3:"min";s:5:"0.2.2";}i:3;a:3:{s:4:"name";s:19:"PEAR2_Console_Color";s:7:"channel";s:13:"pear2.php.net";s:3:"min";s:5:"1.0.0";}}s:9:"extension";a:1:{s:4:"name";s:5:"iconv";}}}
2 changes: 1 addition & 1 deletion www/rest/r/pear2_net_routeros/latest.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.0b5
1.0.0b6
Loading