|
1 <?php |
|
2 /** |
|
3 * Zend Framework |
|
4 * |
|
5 * LICENSE |
|
6 * |
|
7 * This source file is subject to the new BSD license that is bundled |
|
8 * with this package in the file LICENSE.txt. |
|
9 * It is also available through the world-wide-web at this URL: |
|
10 * http://framework.zend.com/license/new-bsd |
|
11 * If you did not receive a copy of the license and are unable to |
|
12 * obtain it through the world-wide-web, please send an email |
|
13 * to license@zend.com so we can send you a copy immediately. |
|
14 * |
|
15 * @category Zend |
|
16 * @package Zend_Gdata |
|
17 * @subpackage Analytics |
|
18 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) |
|
19 * @license http://framework.zend.com/license/new-bsd New BSD License |
|
20 * @version $Id$ |
|
21 */ |
|
22 |
|
23 /** |
|
24 * @see Zend_Gdata_Entry |
|
25 */ |
|
26 require_once 'Zend/Gdata/Entry.php'; |
|
27 |
|
28 /** |
|
29 * @see Zend_Gdata_Analytics_Extension_Dimension |
|
30 */ |
|
31 require_once 'Zend/Gdata/Analytics/Extension/Dimension.php'; |
|
32 |
|
33 /** |
|
34 * @see Zend_Gdata_Analytics_Extension_Metric |
|
35 */ |
|
36 require_once 'Zend/Gdata/Analytics/Extension/Metric.php'; |
|
37 |
|
38 /** |
|
39 * @see Zend_Gdata_Analytics_Extension_Property |
|
40 */ |
|
41 require_once 'Zend/Gdata/Analytics/Extension/Property.php'; |
|
42 |
|
43 /** |
|
44 * @see Zend_Gdata_Analytics_Extension_TableId |
|
45 */ |
|
46 require_once 'Zend/Gdata/Analytics/Extension/TableId.php'; |
|
47 |
|
48 /** |
|
49 * @category Zend |
|
50 * @package Zend_Gdata |
|
51 * @subpackage Analytics |
|
52 */ |
|
53 class Zend_Gdata_Analytics_AccountEntry extends Zend_Gdata_Entry |
|
54 { |
|
55 protected $_accountId; |
|
56 protected $_accountName; |
|
57 protected $_profileId; |
|
58 protected $_webPropertyId; |
|
59 protected $_currency; |
|
60 protected $_timezone; |
|
61 protected $_tableId; |
|
62 protected $_profileName; |
|
63 protected $_goal; |
|
64 |
|
65 /** |
|
66 * @see Zend_Gdata_Entry::__construct() |
|
67 */ |
|
68 public function __construct($element = null) |
|
69 { |
|
70 $this->registerAllNamespaces(Zend_Gdata_Analytics::$namespaces); |
|
71 parent::__construct($element); |
|
72 } |
|
73 |
|
74 /** |
|
75 * @param DOMElement $child |
|
76 * @return void |
|
77 */ |
|
78 protected function takeChildFromDOM($child) |
|
79 { |
|
80 $absoluteNodeName = $child->namespaceURI . ':' . $child->localName; |
|
81 switch ($absoluteNodeName){ |
|
82 case $this->lookupNamespace('analytics') . ':' . 'property'; |
|
83 $property = new Zend_Gdata_Analytics_Extension_Property(); |
|
84 $property->transferFromDOM($child); |
|
85 $this->{$property->getName()} = $property; |
|
86 break; |
|
87 case $this->lookupNamespace('analytics') . ':' . 'tableId'; |
|
88 $tableId = new Zend_Gdata_Analytics_Extension_TableId(); |
|
89 $tableId->transferFromDOM($child); |
|
90 $this->_tableId = $tableId; |
|
91 break; |
|
92 case $this->lookupNamespace('ga') . ':' . 'goal'; |
|
93 $goal = new Zend_Gdata_Analytics_Extension_Goal(); |
|
94 $goal->transferFromDOM($child); |
|
95 $this->_goal = $goal; |
|
96 break; |
|
97 default: |
|
98 parent::takeChildFromDOM($child); |
|
99 break; |
|
100 } |
|
101 } |
|
102 } |