* @revision 03 * @license http://creativecommons.org/licenses/by-sa/3.0/de/ Creative Commons Attribution-Share Alike 3.0 Germany * @homepage http://oss.tiggerswelt.net/oscar/ * @copyright Copyright © 2009 tiggersWelt.net */ require_once ("oscar/snac.php"); class Oscar_SNAC_Bart_Download extends Oscar_SNAC { /* About this class */ const SNAC_FAMILY = 0x0010; const SNAC_SERVICE = 0x0006; public $Barts = array (); // {{{ parse /** * @access public * @return void */ public function parse () { while ($this->Data != "") if (is_object ($Bart = new Oscar_Bart_Named ($this->Data, true))) $this->Barts [] = $Bart; else break; } // }}} // {{{ generate /** * Generate an binary string from this snac * * @access public * @return string **/ public function generate () { $this->Data = ""; foreach ($this->Barts as $Bart) $this->Data .= $Bart->generate (); return parent::generate (); } // }}} } ?>