diff options
author | provokateurin <kate@provokateurin.de> | 2024-09-02 10:15:10 +0200 |
---|---|---|
committer | provokateurin <kate@provokateurin.de> | 2024-09-02 14:57:17 +0200 |
commit | 031166c1771cff50f4069098031a94a8e8da35c5 (patch) | |
tree | e1579022c2330a9b206e26247aac1fa86302d7de /lib/public | |
parent | 3973a8f722c4acf5da82a611ee50f04e19627727 (diff) | |
download | nextcloud-server-031166c1771cff50f4069098031a94a8e8da35c5.tar.gz nextcloud-server-031166c1771cff50f4069098031a94a8e8da35c5.zip |
fix(OCP): Fix Image interface
Signed-off-by: provokateurin <kate@provokateurin.de>
Diffstat (limited to 'lib/public')
-rw-r--r-- | lib/public/IImage.php | 20 | ||||
-rw-r--r-- | lib/public/Image.php | 8 |
2 files changed, 27 insertions, 1 deletions
diff --git a/lib/public/IImage.php b/lib/public/IImage.php index b201754536d..7ba08c889da 100644 --- a/lib/public/IImage.php +++ b/lib/public/IImage.php @@ -8,6 +8,8 @@ declare(strict_types=1); */ namespace OCP; +use GdImage; + /** * Class for basic image manipulation * @since 8.1.0 @@ -202,4 +204,22 @@ interface IImage { * @since 19.0.0 */ public function resizeCopy(int $maxSize): IImage; + + /** + * Loads an image from a string of data. + * + * @param string $str A string of image data as read from a file. + * + * @since 31.0.0 + */ + public function loadFromData(string $str): GdImage|false; + + /** + * Reads the EXIF data for an image. + * + * @param string $data EXIF data + * + * @since 31.0.0 + */ + public function readExif(string $data): void; } diff --git a/lib/public/Image.php b/lib/public/Image.php index a9aab778207..84d07d6a4b4 100644 --- a/lib/public/Image.php +++ b/lib/public/Image.php @@ -14,5 +14,11 @@ namespace OCP; * This class provides functions to handle images * @since 6.0.0 */ -class Image extends \OC\Image { +class Image extends \OC\Image implements \OCP\IImage { + /** + * @since 31.0.0 + */ + public function __construct() { + parent::__construct(); + } } |