Moodle  2.2.1
http://www.collinsharper.com
repository_filesystem Class Reference
Inheritance diagram for repository_filesystem:
Collaboration diagram for repository_filesystem:

Public Member Functions

 __construct ($repositoryid, $context=SYSCONTEXTID, $options=array())
 get_listing ($path= '', $page= '')
 check_login ()
 print_login ()
 global_search ()
 get_file ($file, $title= '')
 logout ()
 set_option ($options=array())
 instance_config_form ($mform)
 supported_returntypes ()

Static Public Member Functions

static get_instance_option_names ()
static create ($type, $userid, $context, $params, $readonly=0)
static instance_form_validation ($mform, $data, $errors)

Detailed Description

Definition at line 31 of file lib.php.


Constructor & Destructor Documentation

__construct ( repositoryid,
context = SYSCONTEXTID,
options = array() 
)

Definition at line 32 of file lib.php.

Here is the call graph for this function:


Member Function Documentation

To check whether the user is logged in.

Returns:
boolean

Reimplemented from repository.

Definition at line 108 of file lib.php.

static create ( type,
userid,
context,
params,
readonly = 0 
) [static]

Create an instance for this plug-in object $CFG object $DB

Parameters:
string$typethe type of the repository
integer$useridthe user id
object$contextthe context
array$paramsthe options for this instance
integer$readonlywhether to create it readonly or not (defaults to not)
Returns:
mixed

Reimplemented from repository.

Definition at line 183 of file lib.php.

Here is the call graph for this function:

get_file ( file,
title = '' 
)

Return file path

Returns:
array

Reimplemented from repository.

Definition at line 121 of file lib.php.

static get_instance_option_names ( ) [static]

Return names of the instance options By default: no instance option name

Returns:
array

Reimplemented from repository.

Definition at line 138 of file lib.php.

get_listing ( path = '',
page = '' 
)

Given a path, and perhaps a search, get a list of files.

See details on http://docs.moodle.org/dev/Repository_plugins

Parameters:
string$path,thisparameter can a folder name, or a identification of folder
string$page,thepage number of file list
Returns:
array the list of files, including meta infomation, containing the following keys manage, url to manage url client_id login, login form repo_id, active repository id login_btn_action, the login button action login_btn_label, the login button label total, number of results perpage, items per page page pages, total pages issearchresult, is it a search result? list, file list path, current path and parent path

Reimplemented from repository.

Definition at line 51 of file lib.php.

Here is the call graph for this function:

is it possible to do glboal search?

Returns:
boolean

Reimplemented from repository.

Definition at line 114 of file lib.php.

instance_config_form ( mform)

Edit/Create Instance Settings Moodle form

Parameters:
object$mformMoodle form (passed by reference)

Reimplemented from repository.

Definition at line 148 of file lib.php.

Here is the call graph for this function:

static instance_form_validation ( mform,
data,
errors 
) [static]

Reimplemented from repository.

Definition at line 192 of file lib.php.

logout ( )

Logout from repository instance By default, this function will return a login form

Returns:
string

Reimplemented from repository.

Definition at line 134 of file lib.php.

Show the login screen, if required

Reimplemented from repository.

Definition at line 111 of file lib.php.

set_option ( options = array())

Save settings for repository instance $repo->set_option(array('api_key'=>'f2188bde132', 'name'=>'dongsheng')); object $DB

Parameters:
array$optionssettings
Returns:
int Id of the record

Reimplemented from repository.

Definition at line 142 of file lib.php.

Here is the call graph for this function:

does it return a file url or a item_id

Returns:
string

Reimplemented from repository.

Definition at line 179 of file lib.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations