本文整理汇总了PHP中Zend_Feed_Reader::reset方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Feed_Reader::reset方法的具体用法?PHP Zend_Feed_Reader::reset怎么用?PHP Zend_Feed_Reader::reset使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend_Feed_Reader
的用法示例。
在下文中一共展示了Zend_Feed_Reader::reset方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setup
public function setup()
{
Zend_Feed_Reader::reset();
if (Zend_Registry::isRegistered('Zend_Locale')) {
$registry = Zend_Registry::getInstance();
unset($registry['Zend_Locale']);
}
$this->_feedSamplePath = dirname(__FILE__) . '/_files/Common';
}
示例2: setup
public function setup()
{
Zend_Feed_Reader::reset();
$this->_feedSamplePath = dirname(__FILE__) . '/_files/h-online.com-atom10.xml';
$this->_options = Zend_Date::setOptions();
foreach ($this->_options as $k => $v) {
if (is_null($v)) {
unset($this->_options[$k]);
}
}
Zend_Date::setOptions(array('format_type' => 'iso'));
}
示例3: setup
public function setup()
{
Zend_Feed_Reader::reset();
if (Zend_Registry::isRegistered('Zend_Locale')) {
$registry = Zend_Registry::getInstance();
unset($registry['Zend_Locale']);
}
$this->_feedSamplePath = dirname(__FILE__) . '/_files/AtomSource';
$this->_options = Zend_Date::setOptions();
foreach ($this->_options as $k => $v) {
if (is_null($v)) {
unset($this->_options[$k]);
}
}
Zend_Date::setOptions(array('format_type' => 'iso'));
$this->_expectedCats = array(array('term' => 'topic1', 'scheme' => 'http://example.com/schema1', 'label' => 'topic1'), array('term' => 'topic1', 'scheme' => 'http://example.com/schema2', 'label' => 'topic1'), array('term' => 'cat_dog', 'scheme' => 'http://example.com/schema1', 'label' => 'Cat & Dog'));
$this->_expectedCatsDc = array(array('term' => 'topic1', 'scheme' => null, 'label' => 'topic1'), array('term' => 'topic2', 'scheme' => null, 'label' => 'topic2'));
}
示例4: tearDown
public function tearDown()
{
Zend_Feed_Reader::reset();
}
示例5: setup
public function setup()
{
Zend_Feed_Reader::reset();
$this->_feedSamplePath = dirname(__FILE__) . '/_files/wordpress-rss2-dc-atom.xml';
}
示例6: _processResources
private static function _processResources(array $config)
{
if (self::$_lock) {
/**
* @see Conjoon_Log
*/
require_once 'Conjoon/Log.php';
Conjoon_Log::log("Conjoon_Modules_Groupware_Feeds_ImportHelper::_processResources " . "- possible race condition", Zend_Log::INFO);
}
self::$_lock = true;
$uri = $config['uri'];
$requestTimeout = $config['requestTimeout'];
$useCache = $config['useCache'];
$useConditionalGet = $config['useConditionalGet'];
$callback = $config['callback'];
/**
* @see Zend_Feed_Reader
*/
require_once 'Zend/Feed/Reader.php';
if ($useCache !== false) {
// set the reader's cache here
/**
* @see Conjoon_Cache_Factory
*/
require_once 'Conjoon/Cache/Factory.php';
/**
* @see Conjoon_Keys
*/
require_once 'Conjoon/Keys.php';
$frCache = Conjoon_Cache_Factory::getCache(Conjoon_Keys::CACHE_FEED_READER, Zend_Registry::get(Conjoon_Keys::REGISTRY_CONFIG_OBJECT)->toArray());
if ($frCache) {
Zend_Feed_Reader::setCache($frCache);
if ($useConditionalGet !== false) {
Zend_Feed_Reader::useHttpConditionalGet();
}
}
}
Zend_Feed_Reader::getHttpClient()->setConfig(array('timeout' => $requestTimeout));
$result = self::$callback($uri);
Zend_Feed_Reader::reset();
self::$_lock = false;
return $result;
}