blend4php  v0.1
A PHP API for interacting with Galaxy
 All Classes Functions Variables Pages
GalaxyFolders Class Reference

Public Member Functions

 __construct (GalaxyInstance $galaxy)
 
 index ()
 
 show ($params)
 
 create ($params)
 
 getPermissions ($params)
 
 setPermissions ($params)
 
 delete ($params)
 
 update ($params)
 

Constructor & Destructor Documentation

GalaxyFolders::__construct ( GalaxyInstance  $galaxy)

The Folders constructor.

Parameters
GalaxyInstance$galaxyA GalaxyInstance object.
Returns
An instance of a Folders object.

Member Function Documentation

GalaxyFolders::create (   $params)

Create a new folder.

Corresponds to the API function/path: POST /api/folders/{encoded_parent_folder_id}

Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • parent_folder_id: The id of the parent folder that this folder will be created under.
  • name: The name of your new folder.
  • description (optional): The description of your new folder.
Returns
An array containing information on the new folder.
GalaxyFolders::delete (   $params)

Mark the folder as 'deleted' or 'undeleted'.

Corresponds to the Galaxy API function at DELETE /api/folders/{folder_id}/

Only admin users can delete/undelete folders

Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • folder_id: The folder you want to delete/undelete.
  • undelete: Specifying whether the item should be deleted (TRUE) or undeleted (FALSE).
Returns
An array containing information on the deleted (or undeleted) folder.
GalaxyFolders::getPermissions (   $params)

Load all permissions for the folder with the given id.

Corresponds to the Galaxy API/Path: GET /api/folders/{folder_id}/permissions

Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • folder_id: The id of the folder to view permissions. The id can be obtained using the index() function in this class.
Returns
An array containing permission information on a specified folder.
GalaxyFolders::index ( )

Retreive information about folders.

Corresponds to the Galaxy API function/path: GET /api/folders/

Returns
An array containing information about the specified folder.
GalaxyFolders::setPermissions (   $params)

Set permissions for a specified folder.

Corresponds to the Galaxy API function/path at: POST /api/folders/{folder_id}/permissions There are 3 options that can be manipulated:

  1. Modify library item: Users can modify this library ($folder_id) item
  2. Add library item: Users can add library items to this ($folder_id) item
  3. Manage library permissions: Users can manage roles associated with permissions on this library item
Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • folder_id: The folder id you want to set permissions.
  • add_ids: An array of users that will have add item permission on the folder. To obtain a user id, please use the 'Users' class index() function.
  • manage_ids: An array of users that will have manage permission on the folder.
  • modify_ids: An array of users that will have modify permission on the folder.
GalaxyFolders::show (   $params)

Retreive information about a specific folder

Corresponds to the Galaxy API function/path: GET /api/folders/{folder_id}

Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • folder_id: The folder that you would like to see. Please see the index() function in this class to obtain folder ids.
Returns
An array containing information about the specified folder.
GalaxyFolders::update (   $params)

Updated the folder's name and description.

Corresponds to the Galaxy API/path at: PATCH /api/folders/{folder_id}/

Only admin users can update folders.

Parameters
$paramsAn associative array containing the input parameters for this function. The following parameters are available:
  • folder_id: The folder you want to update
  • payload: An array that contains 'name' => [new_name] and 'description' => [can be null].
Returns
An array containing details about the deleted file history content.

The documentation for this class was generated from the following file: