protected function takeChildFromDOM($child)
 {
     $absoluteNodeName = $child->namespaceURI . ':' . $child->localName;
     switch ($absoluteNodeName) {
         case $this->lookupNamespace('atom') . ':' . 'author':
             $author = new Zend_Gdata_App_Extension_Author();
             $author->transferFromDOM($child);
             $this->_author[] = $author;
             break;
         case $this->lookupNamespace('atom') . ':' . 'category':
             $category = new Zend_Gdata_App_Extension_Category();
             $category->transferFromDOM($child);
             $this->_category[] = $category;
             break;
         case $this->lookupNamespace('atom') . ':' . 'contributor':
             $contributor = new Zend_Gdata_App_Extension_Contributor();
             $contributor->transferFromDOM($child);
             $this->_contributor[] = $contributor;
             break;
         case $this->lookupNamespace('atom') . ':' . 'id':
             $id = new Zend_Gdata_App_Extension_Id();
             $id->transferFromDOM($child);
             $this->_id = $id;
             break;
         case $this->lookupNamespace('atom') . ':' . 'link':
             $link = new Zend_Gdata_App_Extension_Link();
             $link->transferFromDOM($child);
             $this->_link[] = $link;
             break;
         case $this->lookupNamespace('atom') . ':' . 'rights':
             $rights = new Zend_Gdata_App_Extension_Rights();
             $rights->transferFromDOM($child);
             $this->_rights = $rights;
             break;
         case $this->lookupNamespace('atom') . ':' . 'title':
             $title = new Zend_Gdata_App_Extension_Title();
             $title->transferFromDOM($child);
             $this->_title = $title;
             break;
         case $this->lookupNamespace('atom') . ':' . 'updated':
             $updated = new Zend_Gdata_App_Extension_Updated();
             $updated->transferFromDOM($child);
             $this->_updated = $updated;
             break;
         default:
             parent::takeChildFromDOM($child);
             break;
     }
 }
 public function testExtensionAttributes()
 {
     $extensionAttributes = $this->author->extensionAttributes;
     $extensionAttributes['foo1'] = array('name' => 'foo1', 'value' => 'bar');
     $extensionAttributes['foo2'] = array('name' => 'foo2', 'value' => 'rab');
     $this->author->extensionAttributes = $extensionAttributes;
     $this->assertEquals('bar', $this->author->extensionAttributes['foo1']['value']);
     $this->assertEquals('rab', $this->author->extensionAttributes['foo2']['value']);
     $authorXml = $this->author->saveXML();
     $newAuthor = new Zend_Gdata_App_Extension_Author();
     $newAuthor->transferFromXML($authorXml);
     //var_dump($this->author);
     //print $authorXml;
     $this->assertEquals('bar', $newAuthor->extensionAttributes['foo1']['value']);
     $this->assertEquals('rab', $newAuthor->extensionAttributes['foo2']['value']);
 }