$gojira->putkeep('Pogo3', 'cat3') ? 'success' : 'error'; $gojira->putkeep('Pogo4', 'cat4') ? 'success' : 'error'; $gojira->putkeep('Pogo5', 'cat5') ? 'success' : 'error'; $gojira->putkeep('Pogo6', 'cat6') ? 'success' : 'error'; $gojira->putkeep('Pogo7', 'cat7') ? 'success' : 'error'; */ //$gojira->put('GH5Like', 1); //$gojira->mget(array('Pogo3', 'Pogo1', 'Pogo6')); //$gojira->fwmkeys('Pogo', 7); //echo $gojira->putnr('Pogo6', 'CatzManDu!!') ? 'success' : 'error'; //echo "<br>"; /* $data = $gojira->get('Pogo5'); echo $data === false ? 'error' : $data; echo "<br>"; echo $gojira->out('Pogo5') ? 'deleted' : 'error'; echo "<br>"; */ //$data = $gojira->get('Pogo7'); //echo $data === false ? 'error' : $data; //echo "<br>"; //$gojira->put('ghlike', 9); //echo $gojira->addint('GH5Like', 9); //$data = $gojira->get('ghlike'); //echo $data === false ? 'error' : $data; //echo "<br>"; //$gojira->vanish(); echo $gojira->rnum() . "<br>"; //echo $gojira->size(); //echo $gojira->stat();
* * Copyright (C) 2009 Adam Venturella * * LICENSE: * * Licensed under the Apache License, Version 2.0 (the "License"); you may not * use this file except in compliance with the License. You may obtain a copy * of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR * PURPOSE. See the License for the specific language governing permissions and * limitations under the License. * * Author: Adam Venturella - aventurella@gmail.com * * @package Sample * @author Adam Venturella <*****@*****.**> * @copyright Copyright (C) 2009 Adam Venturella * @license http://www.apache.org/licenses/LICENSE-2.0 Apache 2.0 * **/ /** * Sample */ require 'tinygojira/TinyGojira.php'; $db = new TinyGojira(); echo "Number of records in the cabinet: " . $db->rnum();
* * http://www.apache.org/licenses/LICENSE-2.0 * * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR * PURPOSE. See the License for the specific language governing permissions and * limitations under the License. * * Author: Adam Venturella - aventurella@gmail.com * * @package Sample * @author Adam Venturella <*****@*****.**> * @copyright Copyright (C) 2009 Adam Venturella * @license http://www.apache.org/licenses/LICENSE-2.0 Apache 2.0 * **/ /** * Sample */ require 'tinygojira/TinyGojira.php'; // assuming starting with an empty database $db = new TinyGojira(); $db->put('Godzilla', 'Monster1'); $db->put('Mothra', 'Monster2'); $db->put('Gamera', 'Monster3'); $db->put('Megalon', 'Monster4'); echo "Records Before Vanish: " . $db->rnum() . "<br>"; // 4 $db->vanish(); echo "Records After Vanish: " . $db->rnum(); // 0