00001 <?php
00002
00015
00016 import('lib.pkp.classes.controllers.grid.GridHandler');
00017
00018
00019 import('classes.controllers.grid.files.SubmissionFilesGridHandlerImplementation');
00020
00021 class SubmissionFilesGridHandler extends GridHandler {
00022
00024 var $_handlerImplementation;
00025
00033 function SubmissionFilesGridHandler(&$dataProvider, $stageId, $capabilities, $gridHandlerImplementationClass = null) {
00034 parent::GridHandler($dataProvider);
00035
00036 if (is_null($gridHandlerImplementationClass)) {
00037 $gridHandlerImplementationClass = 'SubmissionFilesGridHandlerImplementation';
00038 }
00039 $handlerImplementation = new $gridHandlerImplementationClass($this, $stageId, $capabilities);
00040
00041 if (is_a($handlerImplementation, 'SubmissionFilesGridHandlerImplementation')) {
00042 $this->setHandlerImplementation($handlerImplementation);
00043 } else {
00044 assert(false);
00045 }
00046 }
00047
00048
00049
00050
00051
00056 function &getHandlerImplementation() {
00057 return $this->_handlerImplementation;
00058 }
00059
00064 function setHandlerImplementation(&$handlerImplementation) {
00065 $this->_handlerImplementation =& $handlerImplementation;
00066 }
00067
00072 function getStageId() {
00073 return $this->_handlerImplementation->getStageId();
00074 }
00075
00080 function &getMonograph() {
00081 return $this->_handlerImplementation->getMonograph();
00082 }
00083
00088 function canAdd() {
00089 return $this->_handlerImplementation->canAdd();
00090 }
00091
00096 function setCanAdd($canAdd) {
00097 $this->_handlerImplementation->setCanAdd((boolean) $canAdd);
00098 }
00099
00104 function canViewNotes() {
00105 return $this->_handlerImplementation->canViewNotes();
00106 }
00107
00112 function canDownloadAll() {
00113 return $this->_handlerImplementation->canDownloadAll();
00114 }
00115
00120 function canDelete() {
00121 return $this->_handlerImplementation->canDelete();
00122 }
00123
00128 function setCanDelete($canDelete) {
00129 $this->_handlerImplementation->setCanDelete((boolean) $canDelete);
00130 }
00131
00132
00133
00134
00135
00139 function authorize(&$request, &$args, $roleAssignments) {
00140 $this->_handlerImplementation->authorize($request, $args, $roleAssignments);
00141
00142 return parent::authorize($request, $args, $roleAssignments);
00143 }
00144
00148 function initialize(&$request) {
00149 parent::initialize($request);
00150
00151 $this->_handlerImplementation->initialize($request);
00152 }
00153
00154
00155
00156
00157
00161 function &getRowInstance() {
00162 return $this->_handlerImplementation->getRowInstance();
00163 }
00164
00165
00166
00167
00168
00169 function getFilesToDownload(&$request) {
00170 return $this->getGridDataElements($request);
00171 }
00172 }
00173
00174 ?>