Current File : /home/k/a/r/karenpetzb/www/items/category/App.zip |
PK *I[yF��Y Y
Extension.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Base
*/
require_once 'Zend/Gdata/App/Base.php';
/**
* Gdata App extensions
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
abstract class Zend_Gdata_App_Extension extends Zend_Gdata_App_Base
{
}
PK *I[��cA� � InvalidArgumentException.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* Zend_Gdata_App_Exception
*/
require_once 'Zend/Gdata/App/Exception.php';
/**
* Gdata exceptions
*
* Class to represent exceptions that occur during Gdata operations.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_InvalidArgumentException extends Zend_Gdata_App_Exception
{
}
PK *I[��C� Extension/Title.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension_Text
*/
require_once 'Zend/Gdata/App/Extension/Text.php';
/**
* Represents the atom:title element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Title extends Zend_Gdata_App_Extension_Text
{
protected $_rootElement = 'title';
}
PK *I[(?_ Extension/Icon.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:icon element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Icon extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'icon';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[�d�D Extension/Uri.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an uri
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:uri element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Uri extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'uri';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[�nP� Extension/Email.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:email element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Email extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'email';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[�5�� � Extension/Summary.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension_Text
*/
require_once 'Zend/Gdata/App/Extension/Text.php';
/**
* Represents the atom:summary element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Summary extends Zend_Gdata_App_Extension_Text
{
protected $_rootElement = 'summary';
}
PK *I[�9�� � Extension/Content.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension_Text
*/
require_once 'Zend/Gdata/App/Extension/Text.php';
/**
* Represents the atom:content element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Content extends Zend_Gdata_App_Extension_Text
{
protected $_rootElement = 'content';
protected $_src = null;
public function __construct($text = null, $type = 'text', $src = null)
{
parent::__construct($text, $type);
$this->_src = $src;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_src !== null) {
$element->setAttribute('src', $this->_src);
}
return $element;
}
protected function takeAttributeFromDOM($attribute)
{
switch ($attribute->localName) {
case 'src':
$this->_src = $attribute->nodeValue;
break;
default:
parent::takeAttributeFromDOM($attribute);
}
}
/**
* @return string
*/
public function getSrc()
{
return $this->_src;
}
/**
* @param string $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setSrc($value)
{
$this->_src = $value;
return $this;
}
}
PK *I[�\2�� � Extension/Subtitle.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension_Text
*/
require_once 'Zend/Gdata/App/Extension/Text.php';
/**
* Represents the atom:subtitle element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Subtitle extends Zend_Gdata_App_Extension_Text
{
protected $_rootElement = 'subtitle';
}
PK *I[�o�c\
\
Extension/Control.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* @see Zend_Gdata_App_Extension_Draft
*/
require_once 'Zend/Gdata/App/Extension/Draft.php';
/**
* Represents the app:control element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Control extends Zend_Gdata_App_Extension
{
protected $_rootNamespace = 'app';
protected $_rootElement = 'control';
protected $_draft = null;
public function __construct($draft = null)
{
parent::__construct();
$this->_draft = $draft;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_draft != null) {
$element->appendChild($this->_draft->getDOM($element->ownerDocument));
}
return $element;
}
protected function takeChildFromDOM($child)
{
$absoluteNodeName = $child->namespaceURI . ':' . $child->localName;
switch ($absoluteNodeName) {
case $this->lookupNamespace('app') . ':' . 'draft':
$draft = new Zend_Gdata_App_Extension_Draft();
$draft->transferFromDOM($child);
$this->_draft = $draft;
break;
default:
parent::takeChildFromDOM($child);
break;
}
}
/**
* @return Zend_Gdata_App_Extension_Draft
*/
public function getDraft()
{
return $this->_draft;
}
/**
* @param Zend_Gdata_App_Extension_Draft $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setDraft($value)
{
$this->_draft = $value;
return $this;
}
}
PK *I[���� � Extension/Author.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension/Person.php';
/**
* Represents the atom:author element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Author extends Zend_Gdata_App_Extension_Person
{
protected $_rootElement = 'author';
}
PK *I[�N��< < Extension/Person.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* @see Zend_Gdata_App_Extension_Name
*/
require_once 'Zend/Gdata/App/Extension/Name.php';
/**
* @see Zend_Gdata_App_Extension_Email
*/
require_once 'Zend/Gdata/App/Extension/Email.php';
/**
* @see Zend_Gdata_App_Extension_Uri
*/
require_once 'Zend/Gdata/App/Extension/Uri.php';
/**
* Base class for people (currently used by atom:author, atom:contributor)
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
abstract class Zend_Gdata_App_Extension_Person extends Zend_Gdata_App_Extension
{
protected $_rootElement = null;
protected $_name = null;
protected $_email = null;
protected $_uri = null;
public function __construct($name = null, $email = null, $uri = null)
{
parent::__construct();
$this->_name = $name;
$this->_email = $email;
$this->_uri = $uri;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_name != null) {
$element->appendChild($this->_name->getDOM($element->ownerDocument));
}
if ($this->_email != null) {
$element->appendChild($this->_email->getDOM($element->ownerDocument));
}
if ($this->_uri != null) {
$element->appendChild($this->_uri->getDOM($element->ownerDocument));
}
return $element;
}
protected function takeChildFromDOM($child)
{
$absoluteNodeName = $child->namespaceURI . ':' . $child->localName;
switch ($absoluteNodeName) {
case $this->lookupNamespace('atom') . ':' . 'name':
$name = new Zend_Gdata_App_Extension_Name();
$name->transferFromDOM($child);
$this->_name = $name;
break;
case $this->lookupNamespace('atom') . ':' . 'email':
$email = new Zend_Gdata_App_Extension_Email();
$email->transferFromDOM($child);
$this->_email = $email;
break;
case $this->lookupNamespace('atom') . ':' . 'uri':
$uri = new Zend_Gdata_App_Extension_Uri();
$uri->transferFromDOM($child);
$this->_uri = $uri;
break;
default:
parent::takeChildFromDOM($child);
break;
}
}
/**
* @return Zend_Gdata_App_Extension_Name
*/
public function getName()
{
return $this->_name;
}
/**
* @param Zend_Gdata_App_Extension_Name $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setName($value)
{
$this->_name = $value;
return $this;
}
/**
* @return Zend_Gdata_App_Extension_Email
*/
public function getEmail()
{
return $this->_email;
}
/**
* @param Zend_Gdata_App_Extension_Email $value
* @return Zend_Gdata_App_Extension_Person Provides a fluent interface
*/
public function setEmail($value)
{
$this->_email = $value;
return $this;
}
/**
* @return Zend_Gdata_App_Extension_Uri
*/
public function getUri()
{
return $this->_uri;
}
/**
* @param Zend_Gdata_App_Extension_Uri $value
* @return Zend_Gdata_App_Extension_Person Provides a fluent interface
*/
public function setUri($value)
{
$this->_uri = $value;
return $this;
}
}
PK *I[�t'�
�
Extension/Category.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:category element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Category extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'category';
protected $_term = null;
protected $_scheme = null;
protected $_label = null;
public function __construct($term = null, $scheme = null, $label=null)
{
parent::__construct();
$this->_term = $term;
$this->_scheme = $scheme;
$this->_label = $label;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_term !== null) {
$element->setAttribute('term', $this->_term);
}
if ($this->_scheme !== null) {
$element->setAttribute('scheme', $this->_scheme);
}
if ($this->_label !== null) {
$element->setAttribute('label', $this->_label);
}
return $element;
}
protected function takeAttributeFromDOM($attribute)
{
switch ($attribute->localName) {
case 'term':
$this->_term = $attribute->nodeValue;
break;
case 'scheme':
$this->_scheme = $attribute->nodeValue;
break;
case 'label':
$this->_label = $attribute->nodeValue;
break;
default:
parent::takeAttributeFromDOM($attribute);
}
}
/**
* @return string|null
*/
public function getTerm()
{
return $this->_term;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Extension_Category Provides a fluent interface
*/
public function setTerm($value)
{
$this->_term = $value;
return $this;
}
/**
* @return string|null
*/
public function getScheme()
{
return $this->_scheme;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Extension_Category Provides a fluent interface
*/
public function setScheme($value)
{
$this->_scheme = $value;
return $this;
}
/**
* @return string|null
*/
public function getLabel()
{
return $this->_label;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Extension_Category Provides a fluent interface
*/
public function setLabel($value)
{
$this->_label = $value;
return $this;
}
}
PK *I[Pjk�� � Extension/Link.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_Extension
*/
require_once 'Zend/Gdata/Extension.php';
/**
* Data model for representing an atom:link element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Link extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'link';
protected $_href = null;
protected $_rel = null;
protected $_type = null;
protected $_hrefLang = null;
protected $_title = null;
protected $_length = null;
public function __construct($href = null, $rel = null, $type = null,
$hrefLang = null, $title = null, $length = null)
{
parent::__construct();
$this->_href = $href;
$this->_rel = $rel;
$this->_type = $type;
$this->_hrefLang = $hrefLang;
$this->_title = $title;
$this->_length = $length;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_href !== null) {
$element->setAttribute('href', $this->_href);
}
if ($this->_rel !== null) {
$element->setAttribute('rel', $this->_rel);
}
if ($this->_type !== null) {
$element->setAttribute('type', $this->_type);
}
if ($this->_hrefLang !== null) {
$element->setAttribute('hreflang', $this->_hrefLang);
}
if ($this->_title !== null) {
$element->setAttribute('title', $this->_title);
}
if ($this->_length !== null) {
$element->setAttribute('length', $this->_length);
}
return $element;
}
protected function takeAttributeFromDOM($attribute)
{
switch ($attribute->localName) {
case 'href':
$this->_href = $attribute->nodeValue;
break;
case 'rel':
$this->_rel = $attribute->nodeValue;
break;
case 'type':
$this->_type = $attribute->nodeValue;
break;
case 'hreflang':
$this->_hrefLang = $attribute->nodeValue;
break;
case 'title':
$this->_title = $attribute->nodeValue;
break;
case 'length':
$this->_length = $attribute->nodeValue;
break;
default:
parent::takeAttributeFromDOM($attribute);
}
}
/**
* @return string|null
*/
public function getHref()
{
return $this->_href;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setHref($value)
{
$this->_href = $value;
return $this;
}
/**
* @return string|null
*/
public function getRel()
{
return $this->_rel;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setRel($value)
{
$this->_rel = $value;
return $this;
}
/**
* @return string|null
*/
public function getType()
{
return $this->_type;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setType($value)
{
$this->_type = $value;
return $this;
}
/**
* @return string|null
*/
public function getHrefLang()
{
return $this->_hrefLang;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setHrefLang($value)
{
$this->_hrefLang = $value;
return $this;
}
/**
* @return string|null
*/
public function getTitle()
{
return $this->_title;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setTitle($value)
{
$this->_title = $value;
return $this;
}
/**
* @return string|null
*/
public function getLength()
{
return $this->_length;
}
/**
* @param string|null $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setLength($value)
{
$this->_length = $value;
return $this;
}
}
PK *I[R"�{� � Extension/Source.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Entry
*/
require_once 'Zend/Gdata/App/Entry.php';
/**
* @see Zend_Gdata_App_FeedSourceParent
*/
require_once 'Zend/Gdata/App/FeedSourceParent.php';
/**
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Source extends Zend_Gdata_App_FeedSourceParent
{
protected $_rootElement = 'source';
}
PK *I[�f Extension/Name.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:name element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Name extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'name';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[W�TD Extension/Logo.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:logo element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Logo extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'logo';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[�X�n Extension/Published.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:published element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Published extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'published';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[!h�>
Extension/Id.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:id element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Id extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'id';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[�ׇ� Extension/Updated.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:updated element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Updated extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'updated';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[���19 9 Extension/Draft.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the app:draft element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Draft extends Zend_Gdata_App_Extension
{
protected $_rootNamespace = 'app';
protected $_rootElement = 'draft';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[E@�% % Extension/Rights.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension_Text
*/
require_once 'Zend/Gdata/App/Extension/Text.php';
/**
* Represents the atom:rights element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Rights extends Zend_Gdata_App_Extension_Text
{
protected $_rootElement = 'rights';
public function __construct($text = null)
{
parent::__construct();
$this->_text = $text;
}
}
PK *I[���C C Extension/Text.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Abstract class for data models that require only text and type-- such as:
* title, summary, etc.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
abstract class Zend_Gdata_App_Extension_Text extends Zend_Gdata_App_Extension
{
protected $_rootElement = null;
protected $_type = 'text';
public function __construct($text = null, $type = 'text')
{
parent::__construct();
$this->_text = $text;
$this->_type = $type;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_type !== null) {
$element->setAttribute('type', $this->_type);
}
return $element;
}
protected function takeAttributeFromDOM($attribute)
{
switch ($attribute->localName) {
case 'type':
$this->_type = $attribute->nodeValue;
break;
default:
parent::takeAttributeFromDOM($attribute);
}
}
/*
* @return Zend_Gdata_App_Extension_Type
*/
public function getType()
{
return $this->_type;
}
/*
* @param string $value
* @return Zend_Gdata_App_Extension_Text Provides a fluent interface
*/
public function setType($value)
{
$this->_type = $value;
return $this;
}
}
PK *I[ꧮS� � Extension/Generator.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Represents the atom:generator element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Generator extends Zend_Gdata_App_Extension
{
protected $_rootElement = 'generator';
protected $_uri = null;
protected $_version = null;
public function __construct($text = null, $uri = null, $version = null)
{
parent::__construct();
$this->_text = $text;
$this->_uri = $uri;
$this->_version = $version;
}
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_uri !== null) {
$element->setAttribute('uri', $this->_uri);
}
if ($this->_version !== null) {
$element->setAttribute('version', $this->_version);
}
return $element;
}
protected function takeAttributeFromDOM($attribute)
{
switch ($attribute->localName) {
case 'uri':
$this->_uri = $attribute->nodeValue;
break;
case 'version':
$this->_version= $attribute->nodeValue;
break;
default:
parent::takeAttributeFromDOM($attribute);
}
}
/**
* @return Zend_Gdata_App_Extension_Uri
*/
public function getUri()
{
return $this->_uri;
}
/**
* @param Zend_Gdata_App_Extension_Uri $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setUri($value)
{
$this->_uri = $value;
return $this;
}
/**
* @return Zend_Gdata_App_Extension_Version
*/
public function getVersion()
{
return $this->_version;
}
/**
* @param Zend_Gdata_App_Extension_Version $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setVersion($value)
{
$this->_version = $value;
return $this;
}
}
PK *I[;�Q�� � Extension/Contributor.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension/Person.php';
/**
* Represents the atom:contributor element
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Contributor extends Zend_Gdata_App_Extension_Person
{
protected $_rootElement = 'contributor';
}
PK *I[�|�� � Extension/Element.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Extension
*/
require_once 'Zend/Gdata/App/Extension.php';
/**
* Class that represents elements which were not handled by other parsing
* code in the library.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Extension_Element extends Zend_Gdata_App_Extension
{
public function __construct($rootElement=null, $rootNamespace=null, $rootNamespaceURI=null, $text=null){
parent::__construct();
$this->_rootElement = $rootElement;
$this->_rootNamespace = $rootNamespace;
$this->_rootNamespaceURI = $rootNamespaceURI;
$this->_text = $text;
}
public function transferFromDOM($node)
{
parent::transferFromDOM($node);
$this->_rootNamespace = null;
$this->_rootNamespaceURI = $node->namespaceURI;
$this->_rootElement = $node->localName;
}
}
PK *I[��@�
�
CaptchaRequiredException.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_CaptchaRequiredException
*/
require_once 'Zend/Gdata/App/AuthException.php';
/**
* Gdata exceptions
*
* Class to represent an exception that occurs during the use of ClientLogin.
* This particular exception happens when a CAPTCHA challenge is issued. This
* challenge is a visual puzzle presented to the user to prove that they are
* not an automated system.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_CaptchaRequiredException extends Zend_Gdata_App_AuthException
{
/**
* The Google Accounts URL prefix.
*/
const ACCOUNTS_URL = 'https://www.google.com/accounts/';
/**
* The token identifier from the server.
*
* @var string
*/
private $captchaToken;
/**
* The URL of the CAPTCHA image.
*
* @var string
*/
private $captchaUrl;
/**
* Constructs the exception to handle a CAPTCHA required response.
*
* @param string $captchaToken The CAPTCHA token ID provided by the server.
* @param string $captchaUrl The URL to the CAPTCHA challenge image.
*/
public function __construct($captchaToken, $captchaUrl) {
$this->captchaToken = $captchaToken;
$this->captchaUrl = Zend_Gdata_App_CaptchaRequiredException::ACCOUNTS_URL . $captchaUrl;
parent::__construct('CAPTCHA challenge issued by server');
}
/**
* Retrieves the token identifier as provided by the server.
*
* @return string
*/
public function getCaptchaToken() {
return $this->captchaToken;
}
/**
* Retrieves the URL CAPTCHA image as provided by the server.
*
* @return string
*/
public function getCaptchaUrl() {
return $this->captchaUrl;
}
}
PK *I[,�c%� � AuthException.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_Exception
*/
require_once 'Zend/Gdata/App/Exception.php';
/**
* Gdata exceptions
*
* Class to represent exceptions that occur during Gdata operations.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_AuthException extends Zend_Gdata_App_Exception
{
}
PK *I[��G~� � Util.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* Utility class for static functions needed by Zend_Gdata_App
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Util
{
/**
* Convert timestamp into RFC 3339 date string.
* 2005-04-19T15:30:00
*
* @param int $timestamp
* @throws Zend_Gdata_App_InvalidArgumentException
*/
public static function formatTimestamp($timestamp)
{
$rfc3339 = '/^(\d{4})\-?(\d{2})\-?(\d{2})((T|t)(\d{2})\:?(\d{2})' .
'\:?(\d{2})(\.\d{1,})?((Z|z)|([\+\-])(\d{2})\:?(\d{2})))?$/';
if (ctype_digit($timestamp)) {
return gmdate('Y-m-d\TH:i:sP', $timestamp);
} elseif (preg_match($rfc3339, $timestamp) > 0) {
// timestamp is already properly formatted
return $timestamp;
} else {
$ts = strtotime($timestamp);
if ($ts === false) {
require_once 'Zend/Gdata/App/InvalidArgumentException.php';
throw new Zend_Gdata_App_InvalidArgumentException("Invalid timestamp: $timestamp.");
}
return date('Y-m-d\TH:i:s', $ts);
}
}
/** Find the greatest key that is less than or equal to a given upper
* bound, and return the value associated with that key.
*
* @param integer|null $maximumKey The upper bound for keys. If null, the
* maxiumum valued key will be found.
* @param array $collection An two-dimensional array of key/value pairs
* to search through.
* @returns mixed The value corresponding to the located key.
* @throws Zend_Gdata_App_Exception Thrown if $collection is empty.
*/
public static function findGreatestBoundedValue($maximumKey, $collection)
{
$found = false;
$foundKey = $maximumKey;
// Sanity check: Make sure that the collection isn't empty
if (sizeof($collection) == 0) {
require_once 'Zend/Gdata/App/Exception.php';
throw new Zend_Gdata_App_Exception("Empty namespace collection encountered.");
}
if (is_null($maximumKey)) {
// If the key is null, then we return the maximum available
$keys = array_keys($collection);
sort($keys);
$found = true;
$foundKey = end($keys);
} else {
// Otherwise, we optimistically guess that the current version
// will have a matching namespce. If that fails, we decrement the
// version until we find a match.
while (!$found && $foundKey >= 0) {
if (array_key_exists($foundKey, $collection))
$found = true;
else
$foundKey--;
}
}
// Guard: A namespace wasn't found. Either none were registered, or
// the current protcol version is lower than the maximum namespace.
if (!$found) {
require_once 'Zend/Gdata/App/Exception.php';
throw new Zend_Gdata_App_Exception("Namespace compatible with current protocol not found.");
}
return $foundKey;
}
}
PK *I[�'#��* �* Entry.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_FeedEntryParent
*/
require_once 'Zend/Gdata/App/FeedEntryParent.php';
/**
* @see Zend_Gdata_App_Extension_Content
*/
require_once 'Zend/Gdata/App/Extension/Content.php';
/**
* @see Zend_Gdata_App_Extension_Published
*/
require_once 'Zend/Gdata/App/Extension/Published.php';
/**
* @see Zend_Gdata_App_Extension_Source
*/
require_once 'Zend/Gdata/App/Extension/Source.php';
/**
* @see Zend_Gdata_App_Extension_Summary
*/
require_once 'Zend/Gdata/App/Extension/Summary.php';
/**
* @see Zend_Gdata_App_Extension_Control
*/
require_once 'Zend/Gdata/App/Extension/Control.php';
/**
* Concrete class for working with Atom entries.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_Entry extends Zend_Gdata_App_FeedEntryParent
{
/**
* Root XML element for Atom entries.
*
* @var string
*/
protected $_rootElement = 'entry';
/**
* Class name for each entry in this feed*
*
* @var string
*/
protected $_entryClassName = 'Zend_Gdata_App_Entry';
/**
* atom:content element
*
* @var Zend_Gdata_App_Extension_Content
*/
protected $_content = null;
/**
* atom:published element
*
* @var Zend_Gdata_App_Extension_Published
*/
protected $_published = null;
/**
* atom:source element
*
* @var Zend_Gdata_App_Extension_Source
*/
protected $_source = null;
/**
* atom:summary element
*
* @var Zend_Gdata_App_Extension_Summary
*/
protected $_summary = null;
/**
* app:control element
*
* @var Zend_Gdata_App_Extension_Control
*/
protected $_control = null;
public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
{
$element = parent::getDOM($doc, $majorVersion, $minorVersion);
if ($this->_content != null) {
$element->appendChild($this->_content->getDOM($element->ownerDocument));
}
if ($this->_published != null) {
$element->appendChild($this->_published->getDOM($element->ownerDocument));
}
if ($this->_source != null) {
$element->appendChild($this->_source->getDOM($element->ownerDocument));
}
if ($this->_summary != null) {
$element->appendChild($this->_summary->getDOM($element->ownerDocument));
}
if ($this->_control != null) {
$element->appendChild($this->_control->getDOM($element->ownerDocument));
}
return $element;
}
protected function takeChildFromDOM($child)
{
$absoluteNodeName = $child->namespaceURI . ':' . $child->localName;
switch ($absoluteNodeName) {
case $this->lookupNamespace('atom') . ':' . 'content':
$content = new Zend_Gdata_App_Extension_Content();
$content->transferFromDOM($child);
$this->_content = $content;
break;
case $this->lookupNamespace('atom') . ':' . 'published':
$published = new Zend_Gdata_App_Extension_Published();
$published->transferFromDOM($child);
$this->_published = $published;
break;
case $this->lookupNamespace('atom') . ':' . 'source':
$source = new Zend_Gdata_App_Extension_Source();
$source->transferFromDOM($child);
$this->_source = $source;
break;
case $this->lookupNamespace('atom') . ':' . 'summary':
$summary = new Zend_Gdata_App_Extension_Summary();
$summary->transferFromDOM($child);
$this->_summary = $summary;
break;
case $this->lookupNamespace('app') . ':' . 'control':
$control = new Zend_Gdata_App_Extension_Control();
$control->transferFromDOM($child);
$this->_control = $control;
break;
default:
parent::takeChildFromDOM($child);
break;
}
}
/**
* Uploads changes in this entry to the server using Zend_Gdata_App
*
* @param string|null $uri The URI to send requests to, or null if $data
* contains the URI.
* @param string|null $className The name of the class that should we
* deserializing the server response. If null, then
* 'Zend_Gdata_App_Entry' will be used.
* @param array $extraHeaders Extra headers to add to the request, as an
* array of string-based key/value pairs.
* @return Zend_Gdata_App_Entry The updated entry.
* @throws Zend_Gdata_App_Exception
*/
public function save($uri = null, $className = null, $extraHeaders = array())
{
return $this->getService()->updateEntry($this,
$uri,
$className,
$extraHeaders);
}
/**
* Deletes this entry to the server using the referenced
* Zend_Http_Client to do a HTTP DELETE to the edit link stored in this
* entry's link collection.
*
* @return void
* @throws Zend_Gdata_App_Exception
*/
public function delete()
{
$this->getService()->delete($this);
}
/**
* Reload the current entry. Returns a new copy of the entry as returned
* by the server, or null if no changes exist. This does not
* modify the current entry instance.
*
* @param string|null The URI to send requests to, or null if $data
* contains the URI.
* @param string|null The name of the class that should we deserializing
* the server response. If null, then 'Zend_Gdata_App_Entry' will
* be used.
* @param array $extraHeaders Extra headers to add to the request, as an
* array of string-based key/value pairs.
* @return mixed A new instance of the current entry with updated data, or
* null if the server reports that no changes have been made.
* @throws Zend_Gdata_App_Exception
*/
public function reload($uri = null, $className = null, $extraHeaders = array())
{
// Get URI
$editLink = $this->getEditLink();
if (is_null($uri) && $editLink != null) {
$uri = $editLink->getHref();
}
// Set classname to current class, if not otherwise set
if (is_null($className)) {
$className = get_class($this);
}
// Append ETag, if present (Gdata v2 and above, only) and doesn't
// conflict with existing headers
if ($this->_etag != null
&& !array_key_exists('If-Match', $extraHeaders)
&& !array_key_exists('If-None-Match', $extraHeaders)) {
$extraHeaders['If-None-Match'] = $this->_etag;
}
// If an HTTP 304 status (Not Modified)is returned, then we return
// null.
$result = null;
try {
$result = $this->service->importUrl($uri, $className, $extraHeaders);
} catch (Zend_Gdata_App_HttpException $e) {
if ($e->getResponse()->getStatus() != '304')
throw $e;
}
return $result;
}
/**
* Gets the value of the atom:content element
*
* @return Zend_Gdata_App_Extension_Content
*/
public function getContent()
{
return $this->_content;
}
/**
* Sets the value of the atom:content element
*
* @param Zend_Gdata_App_Extension_Content $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setContent($value)
{
$this->_content = $value;
return $this;
}
/**
* Sets the value of the atom:published element
* This represents the publishing date for an entry
*
* @return Zend_Gdata_App_Extension_Published
*/
public function getPublished()
{
return $this->_published;
}
/**
* Sets the value of the atom:published element
* This represents the publishing date for an entry
*
* @param Zend_Gdata_App_Extension_Published $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setPublished($value)
{
$this->_published = $value;
return $this;
}
/**
* Gets the value of the atom:source element
*
* @return Zend_Gdata_App_Extension_Source
*/
public function getSource()
{
return $this->_source;
}
/**
* Sets the value of the atom:source element
*
* @param Zend_Gdata_App_Extension_Source $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setSource($value)
{
$this->_source = $value;
return $this;
}
/**
* Gets the value of the atom:summary element
* This represents a textual summary of this entry's content
*
* @return Zend_Gdata_App_Extension_Summary
*/
public function getSummary()
{
return $this->_summary;
}
/**
* Sets the value of the atom:summary element
* This represents a textual summary of this entry's content
*
* @param Zend_Gdata_App_Extension_Summary $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setSummary($value)
{
$this->_summary = $value;
return $this;
}
/**
* Gets the value of the app:control element
*
* @return Zend_Gdata_App_Extension_Control
*/
public function getControl()
{
return $this->_control;
}
/**
* Sets the value of the app:control element
*
* @param Zend_Gdata_App_Extension_Control $value
* @return Zend_Gdata_App_Entry Provides a fluent interface
*/
public function setControl($value)
{
$this->_control = $value;
return $this;
}
}
PK *I[h�3sp p MediaFileSource.phpnu &1i� <?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@zend.com so we can send you a copy immediately.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
/**
* @see Zend_Gdata_App_MediaData
*/
require_once 'Zend/Gdata/App/BaseMediaSource.php';
/**
* Concrete class to use a file handle as an attachment within a MediaEntry.
*
* @category Zend
* @package Zend_Gdata
* @subpackage App
* @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Gdata_App_MediaFileSource extends Zend_Gdata_App_BaseMediaSource
{
/**
* The filename which is represented
*
* @var string
*/
protected $_filename = null;
/**
* The content type for the file attached (example image/png)
*
* @var string
*/
protected $_contentType = null;
/**
* Create a new Zend_Gdata_App_MediaFileSource object.
*
* @param string $filename The name of the file to read from.
*/
public function __construct($filename)
{
$this->setFilename($filename);
}
/**
* Return the MIME multipart representation of this MediaEntry.
*
* @return string
* @throws Zend_Gdata_App_IOException
*/
public function encode()
{
if ($this->getFilename() !== null &&
is_readable($this->getFilename())) {
// Retrieves the file, using the include path
$fileHandle = fopen($this->getFilename(), 'r', true);
$result = fread($fileHandle, filesize($this->getFilename()));
if ($result === false) {
require_once 'Zend/Gdata/App/IOException.php';
throw new Zend_Gdata_App_IOException("Error reading file - " .
$this->getFilename() . '. Read failed.');
}
fclose($fileHandle);
return $result;
} else {
require_once 'Zend/Gdata/App/IOException.php';
throw new Zend_Gdata_App_IOException("Error reading file - " .
$this->getFilename() . '. File is not readable.');
}
}
/**
* Get the filename associated with this reader.
*
* @return string
*/
public function getFilename()
{
return $this->_filename;
}
/**
* Set the filename which is to be read.
*
* @param string $value The desired file handle.
* @return Zend_Gdata_App_MediaFileSource Provides a fluent interface.
*/
public function setFilename($value)
{
$this->_filename = $value;
return $this;
}
/**
* The content type for the file attached (example image/png)
*
* @return string The content type
*/
public function getContentType()
{
return $this->_contentType;
}
/**
* Set the content type for the file attached (example image/png)
*
* @param string $value The content type
* @return Zend_Gdata_App_MediaFileSource Provides a fluent interface
*/
public function setContentType($value)
{
$this->_contentType = $value;
return $this;
}
/**
* Alias for getFilename().
*
* @return string
*/
public function __toString()
{
return $this->getFilename();
}
}
PK *I[�U
�
"