public function getImgFileMetaInfo($fileId, $scaledWidth, $scaledHeight) { if (empty($fileId)) { throw $this->createServiceException("参数不正确"); } $file = $this->getFile($fileId); if (empty($file)) { throw $this->createServiceException("文件不存在"); } $parsed = $this->parseFileUri($file["uri"]); list($naturalSize, $scaledSize) = FileToolkit::getImgInfo($parsed['fullpath'], $scaledWidth, $scaledHeight); return array($parsed["path"], $naturalSize, $scaledSize); }