コード例 #1
0
 /**
  *
  * @param TemporaryFile $file
  * @return FileInfoRepresentation
  */
 private function buildFileRepresentation(TemporaryFile $file)
 {
     $reference = new FileInfoRepresentation();
     return $reference->build($file->getId(), $file->getCreatorId(), $file->getDescription(), $file->getName(), $file->getSize(), $file->getType(), null, null);
 }
コード例 #2
0
 public function buildFileInfoData(Tracker_Artifact_Attachment_TemporaryFile $file, $path)
 {
     return array('id' => $file->getTemporaryName(), 'submitted_by' => $file->getCreatorId(), 'description' => $file->getDescription(), 'name' => $file->getName(), 'tmp_name' => $path, 'size' => $file->getSize(), 'type' => $file->getType(), 'error' => UPLOAD_ERR_OK, 'action' => '');
 }