|
Moodle
2.2.1
http://www.collinsharper.com
|
00001 <?php 00033 class Zend_Service_Technorati_GetInfoResult 00034 { 00041 protected $_author; 00042 00049 protected $_weblogs = array(); 00050 00051 00057 public function __construct(DomDocument $dom) 00058 { 00059 $xpath = new DOMXPath($dom); 00060 00064 require_once 'Zend/Service/Technorati/Author.php'; 00065 00066 $result = $xpath->query('//result'); 00067 if ($result->length == 1) { 00068 $this->_author = new Zend_Service_Technorati_Author($result->item(0)); 00069 } 00070 00074 require_once 'Zend/Service/Technorati/Weblog.php'; 00075 00076 $result = $xpath->query('//item/weblog'); 00077 if ($result->length >= 1) { 00078 foreach ($result as $weblog) { 00079 $this->_weblogs[] = new Zend_Service_Technorati_Weblog($weblog); 00080 } 00081 } 00082 } 00083 00084 00090 public function getAuthor() { 00091 return $this->_author; 00092 } 00093 00099 public function getWeblogs() { 00100 return $this->_weblogs; 00101 } 00102 00103 }