mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2024-11-26 19:36:52 +03:00
de1b39c8e5
if a bridge needs to modify some of the data that were initialized there, ::__construct() should be used instead. Signed-off-by: Pierre Mazière <pierre.maziere@gmx.com>
53 lines
1.3 KiB
PHP
53 lines
1.3 KiB
PHP
<?php
|
|
class DemoBridge extends BridgeAbstract{
|
|
|
|
public $maintainer = "teromene";
|
|
public $name = "DemoBridge";
|
|
public $uri = "http://github.com/sebsauvage/rss-bridge";
|
|
public $description = "Bridge used for demos";
|
|
|
|
public $parameters = array(
|
|
'testCheckbox' => array(
|
|
'testCheckbox'=>array(
|
|
'type'=>'checkbox',
|
|
'name'=>'test des checkbox'
|
|
)
|
|
),
|
|
|
|
'testList' => array(
|
|
'testList'=>array(
|
|
'type'=>'list',
|
|
'name'=>'test des listes',
|
|
'values'=>array(
|
|
'Test'=>'test',
|
|
'Test 2'=>'test2'
|
|
)
|
|
)
|
|
),
|
|
|
|
'testNumber' => array(
|
|
'testNumber'=>array(
|
|
'type'=>'number',
|
|
'name'=>'test des numéros',
|
|
'exampleValue'=>'1515632'
|
|
)
|
|
)
|
|
);
|
|
|
|
public function collectData(){
|
|
|
|
$item = array();
|
|
$item['author'] = "Me!";
|
|
$item['title'] = "Test";
|
|
$item['content'] = "Awesome content !";
|
|
$item['id'] = "Lalala";
|
|
$item['uri'] = "http://test.test/test";
|
|
|
|
$this->items[] = $item;
|
|
|
|
}
|
|
|
|
public function getCacheDuration(){
|
|
return 00; // 1 hour
|
|
}
|
|
}
|