2012-02-04 00:32:06 +04:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* provides search functionalty
|
|
|
|
*/
|
|
|
|
abstract class OC_Migrate_Provider{
|
2012-02-04 01:28:58 +04:00
|
|
|
|
2012-03-10 03:33:11 +04:00
|
|
|
public $id;
|
|
|
|
|
|
|
|
public function __construct( $appid ){
|
|
|
|
$this->id = $appid;
|
|
|
|
OC_Migrate::registerProvider( $this );
|
2012-02-04 00:32:06 +04:00
|
|
|
}
|
2012-03-10 03:33:11 +04:00
|
|
|
|
2012-02-04 00:32:06 +04:00
|
|
|
/**
|
2012-03-10 03:33:11 +04:00
|
|
|
* @breif exports data for apps
|
2012-02-04 00:32:06 +04:00
|
|
|
* @param string $uid
|
2012-03-03 21:30:21 +04:00
|
|
|
* @return array appdata to be exported
|
2012-02-04 00:32:06 +04:00
|
|
|
*/
|
|
|
|
abstract function export($uid);
|
|
|
|
|
|
|
|
/**
|
2012-03-10 03:33:11 +04:00
|
|
|
* @breif imports data for the app
|
2012-03-03 21:30:21 +04:00
|
|
|
* @param $data array of data. eg: array('info'=> APPINFO, 'data'=>APPDATA ARRAY)
|
|
|
|
* @param $info array of info of the source install
|
|
|
|
* @return void
|
2012-02-04 00:32:06 +04:00
|
|
|
*/
|
2012-03-03 21:30:21 +04:00
|
|
|
abstract function import($data,$uid);
|
2012-02-04 00:32:06 +04:00
|
|
|
}
|