Example #1
0
 public function info($secure = false)
 {
     return array('name' => $this->getName(), 'size_readable' => Am_Storage_File::getSizeReadable($this->getSize()), 'upload_id' => $secure ? Am_Form_Element_Upload::signValue($this->storage->getPath($this->getPath())) : $this->storage->getPath($this->getPath()), 'mime' => $this->getMime(), 'ok' => true);
 }
Example #2
0
 function getSizeReadable()
 {
     return Am_Storage_File::getSizeReadable($this->getSize());
 }
Example #3
0
 public function getUrl(Am_Storage_File $file, $expTime)
 {
     list($bucket, $uri) = explode('/', $file->getPath(), 2);
     return $this->getConnector()->getAuthenticatedURL($bucket, $uri, $expTime, $this->getConfig('links_container'));
 }