diff --git a/src/Collection.php b/src/Collection.php index a5ae6d82..3862b1fa 100644 --- a/src/Collection.php +++ b/src/Collection.php @@ -69,8 +69,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Count items in collection - * - * @return int */ public function count(): int { @@ -92,8 +90,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Return first item in collection - * - * @return mixed */ public function first(): mixed { @@ -106,8 +102,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Returns last item in collection - * - * @return mixed */ public function last(): mixed { @@ -120,9 +114,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Return item at given position starting at 0 - * - * @param int $key - * @return mixed */ public function getAtPosition(int $key = 0, $default = null): mixed { @@ -176,9 +167,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Map each item of collection by given callback - * - * @param callable $callback - * @return self */ public function map(callable $callback): self { @@ -193,9 +181,6 @@ class Collection implements CollectionInterface, IteratorAggregate, Countable /** * Run callback on each item of the collection an remove it if it does not return true - * - * @param callable $callback - * @return self */ public function filter(callable $callback): self { diff --git a/src/Colors/AbstractColorChannel.php b/src/Colors/AbstractColorChannel.php index d415f7b6..5c529092 100644 --- a/src/Colors/AbstractColorChannel.php +++ b/src/Colors/AbstractColorChannel.php @@ -30,8 +30,6 @@ abstract class AbstractColorChannel implements ColorChannelInterface, Stringable /** * Alias of value() - * - * @return int */ public function toInt(): int { diff --git a/src/Colors/Cmyk/Color.php b/src/Colors/Cmyk/Color.php index d3229e6c..978f80e5 100644 --- a/src/Colors/Cmyk/Color.php +++ b/src/Colors/Cmyk/Color.php @@ -20,10 +20,6 @@ class Color extends AbstractColor /** * Create new instance * - * @param int $c - * @param int $m - * @param int $y - * @param int $k * @return void */ public function __construct(int $c, int $m, int $y, int $k) @@ -71,8 +67,6 @@ class Color extends AbstractColor /** * Return the CMYK cyan channel - * - * @return ColorChannelInterface */ public function cyan(): ColorChannelInterface { @@ -82,8 +76,6 @@ class Color extends AbstractColor /** * Return the CMYK magenta channel - * - * @return ColorChannelInterface */ public function magenta(): ColorChannelInterface { @@ -93,8 +85,6 @@ class Color extends AbstractColor /** * Return the CMYK yellow channel - * - * @return ColorChannelInterface */ public function yellow(): ColorChannelInterface { @@ -104,8 +94,6 @@ class Color extends AbstractColor /** * Return the CMYK key channel - * - * @return ColorChannelInterface */ public function key(): ColorChannelInterface { diff --git a/src/Colors/Cmyk/Colorspace.php b/src/Colors/Cmyk/Colorspace.php index db3a97fc..4484ef7c 100644 --- a/src/Colors/Cmyk/Colorspace.php +++ b/src/Colors/Cmyk/Colorspace.php @@ -42,9 +42,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ public function importColor(ColorInterface $color): ColorInterface { @@ -57,9 +55,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return Color */ protected function importRgbColor(ColorInterface $color): CmykColor { diff --git a/src/Colors/Cmyk/Decoders/StringColorDecoder.php b/src/Colors/Cmyk/Decoders/StringColorDecoder.php index f0a67c7a..e160f2e3 100644 --- a/src/Colors/Cmyk/Decoders/StringColorDecoder.php +++ b/src/Colors/Cmyk/Decoders/StringColorDecoder.php @@ -15,9 +15,6 @@ class StringColorDecoder extends AbstractDecoder implements DecoderInterface { /** * Decode CMYK color strings - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Colors/Hsl/Color.php b/src/Colors/Hsl/Color.php index ad03c6cc..e116dca7 100644 --- a/src/Colors/Hsl/Color.php +++ b/src/Colors/Hsl/Color.php @@ -19,9 +19,6 @@ class Color extends AbstractColor /** * Create new color object * - * @param int $h - * @param int $s - * @param int $l * @return void */ public function __construct(int $h, int $s, int $l) @@ -58,8 +55,6 @@ class Color extends AbstractColor /** * Return the Hue channel - * - * @return ColorChannelInterface */ public function hue(): ColorChannelInterface { @@ -69,8 +64,6 @@ class Color extends AbstractColor /** * Return the Saturation channel - * - * @return ColorChannelInterface */ public function saturation(): ColorChannelInterface { @@ -80,8 +73,6 @@ class Color extends AbstractColor /** * Return the Luminance channel - * - * @return ColorChannelInterface */ public function luminance(): ColorChannelInterface { diff --git a/src/Colors/Hsl/Colorspace.php b/src/Colors/Hsl/Colorspace.php index 22a27a46..de4c2cf8 100644 --- a/src/Colors/Hsl/Colorspace.php +++ b/src/Colors/Hsl/Colorspace.php @@ -41,9 +41,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ public function importColor(ColorInterface $color): ColorInterface { @@ -56,9 +54,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importRgbColor(ColorInterface $color): ColorInterface { @@ -107,9 +103,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importHsvColor(ColorInterface $color): ColorInterface { diff --git a/src/Colors/Hsl/Decoders/StringColorDecoder.php b/src/Colors/Hsl/Decoders/StringColorDecoder.php index 21bb96aa..67ff03da 100644 --- a/src/Colors/Hsl/Decoders/StringColorDecoder.php +++ b/src/Colors/Hsl/Decoders/StringColorDecoder.php @@ -15,9 +15,6 @@ class StringColorDecoder extends AbstractDecoder implements DecoderInterface { /** * Decode hsl color strings - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Colors/Hsv/Color.php b/src/Colors/Hsv/Color.php index 62893ec0..9507657d 100644 --- a/src/Colors/Hsv/Color.php +++ b/src/Colors/Hsv/Color.php @@ -19,9 +19,6 @@ class Color extends AbstractColor /** * Create new color object * - * @param int $h - * @param int $s - * @param int $v * @return void */ public function __construct(int $h, int $s, int $v) @@ -58,8 +55,6 @@ class Color extends AbstractColor /** * Return the Hue channel - * - * @return ColorChannelInterface */ public function hue(): ColorChannelInterface { @@ -69,8 +64,6 @@ class Color extends AbstractColor /** * Return the Saturation channel - * - * @return ColorChannelInterface */ public function saturation(): ColorChannelInterface { @@ -80,8 +73,6 @@ class Color extends AbstractColor /** * Return the Value channel - * - * @return ColorChannelInterface */ public function value(): ColorChannelInterface { diff --git a/src/Colors/Hsv/Colorspace.php b/src/Colors/Hsv/Colorspace.php index 8a2f2e49..5cf08e2f 100644 --- a/src/Colors/Hsv/Colorspace.php +++ b/src/Colors/Hsv/Colorspace.php @@ -41,9 +41,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ public function importColor(ColorInterface $color): ColorInterface { @@ -56,9 +54,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importRgbColor(ColorInterface $color): ColorInterface { @@ -104,9 +100,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importHslColor(ColorInterface $color): ColorInterface { diff --git a/src/Colors/Hsv/Decoders/StringColorDecoder.php b/src/Colors/Hsv/Decoders/StringColorDecoder.php index aad50eec..b25a28f7 100644 --- a/src/Colors/Hsv/Decoders/StringColorDecoder.php +++ b/src/Colors/Hsv/Decoders/StringColorDecoder.php @@ -15,9 +15,6 @@ class StringColorDecoder extends AbstractDecoder implements DecoderInterface { /** * Decode hsv/hsb color strings - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Colors/Profile.php b/src/Colors/Profile.php index c8bc1209..b6aa0e9e 100644 --- a/src/Colors/Profile.php +++ b/src/Colors/Profile.php @@ -13,9 +13,7 @@ class Profile extends File implements ProfileInterface /** * Create profile object from path in file system * - * @param string $path * @throws RuntimeException - * @return Profile */ public static function fromPath(string $path): self { diff --git a/src/Colors/Rgb/Color.php b/src/Colors/Rgb/Color.php index 4926a73c..70d84c2a 100644 --- a/src/Colors/Rgb/Color.php +++ b/src/Colors/Rgb/Color.php @@ -19,10 +19,6 @@ class Color extends AbstractColor /** * Create new instance * - * @param int $r - * @param int $g - * @param int $b - * @param int $a * @return ColorInterface */ public function __construct(int $r, int $g, int $b, int $a = 255) @@ -63,8 +59,6 @@ class Color extends AbstractColor /** * Return the RGB red color channel - * - * @return ColorChannelInterface */ public function red(): ColorChannelInterface { @@ -74,8 +68,6 @@ class Color extends AbstractColor /** * Return the RGB green color channel - * - * @return ColorChannelInterface */ public function green(): ColorChannelInterface { @@ -85,8 +77,6 @@ class Color extends AbstractColor /** * Return the RGB blue color channel - * - * @return ColorChannelInterface */ public function blue(): ColorChannelInterface { @@ -96,8 +86,6 @@ class Color extends AbstractColor /** * Return the colors alpha channel - * - * @return ColorChannelInterface */ public function alpha(): ColorChannelInterface { diff --git a/src/Colors/Rgb/Colorspace.php b/src/Colors/Rgb/Colorspace.php index b0da0c2a..dfeaef64 100644 --- a/src/Colors/Rgb/Colorspace.php +++ b/src/Colors/Rgb/Colorspace.php @@ -41,9 +41,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ public function importColor(ColorInterface $color): ColorInterface { @@ -56,9 +54,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importCmykColor(ColorInterface $color): ColorInterface { @@ -74,9 +70,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importHsvColor(ColorInterface $color): ColorInterface { @@ -106,9 +100,7 @@ class Colorspace implements ColorspaceInterface } /** - * @param ColorInterface $color * @throws ColorException - * @return ColorInterface */ protected function importHslColor(ColorInterface $color): ColorInterface { diff --git a/src/Colors/Rgb/Decoders/HexColorDecoder.php b/src/Colors/Rgb/Decoders/HexColorDecoder.php index 2900bc57..b19eee2a 100644 --- a/src/Colors/Rgb/Decoders/HexColorDecoder.php +++ b/src/Colors/Rgb/Decoders/HexColorDecoder.php @@ -15,9 +15,6 @@ class HexColorDecoder extends AbstractDecoder implements DecoderInterface { /** * Decode hexadecimal rgb colors with and without transparency - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Colors/Rgb/Decoders/HtmlColornameDecoder.php b/src/Colors/Rgb/Decoders/HtmlColornameDecoder.php index 2c64f2ba..8fc8e70d 100644 --- a/src/Colors/Rgb/Decoders/HtmlColornameDecoder.php +++ b/src/Colors/Rgb/Decoders/HtmlColornameDecoder.php @@ -160,9 +160,6 @@ class HtmlColornameDecoder extends HexColorDecoder implements DecoderInterface /** * Decode html color names - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Colors/Rgb/Decoders/StringColorDecoder.php b/src/Colors/Rgb/Decoders/StringColorDecoder.php index b28ee3bd..a2ddb6ca 100644 --- a/src/Colors/Rgb/Decoders/StringColorDecoder.php +++ b/src/Colors/Rgb/Decoders/StringColorDecoder.php @@ -15,9 +15,6 @@ class StringColorDecoder extends AbstractDecoder implements DecoderInterface { /** * Decode rgb color strings - * - * @param mixed $input - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface { diff --git a/src/Config.php b/src/Config.php index 0bd1b3b7..997bf690 100644 --- a/src/Config.php +++ b/src/Config.php @@ -11,10 +11,6 @@ class Config /** * Create config object instance * - * @param bool $autoOrientation - * @param bool $decodeAnimation - * @param mixed $blendingColor - * @param bool $strip * @return void */ public function __construct( @@ -29,9 +25,7 @@ class Config /** * Set values of given config options * - * @param mixed $options * @throws InputException - * @return Config */ public function setOptions(mixed ...$options): self { diff --git a/src/Drivers/AbstractDecoder.php b/src/Drivers/AbstractDecoder.php index 65797482..37449111 100644 --- a/src/Drivers/AbstractDecoder.php +++ b/src/Drivers/AbstractDecoder.php @@ -16,9 +16,6 @@ abstract class AbstractDecoder implements DecoderInterface /** * Determine if the given input is GIF data format - * - * @param string $input - * @return bool */ protected function isGifFormat(string $input): bool { @@ -27,9 +24,6 @@ abstract class AbstractDecoder implements DecoderInterface /** * Determine if given input is a path to an existing regular file - * - * @param mixed $input - * @return bool */ protected function isFile(mixed $input): bool { @@ -56,7 +50,6 @@ abstract class AbstractDecoder implements DecoderInterface * Extract and return EXIF data from given input which can be binary image * data or a file path. * - * @param string $path_or_data * @return CollectionInterface */ protected function extractExifData(string $path_or_data): CollectionInterface @@ -85,9 +78,6 @@ abstract class AbstractDecoder implements DecoderInterface /** * Determine if given input is base64 encoded data - * - * @param mixed $input - * @return bool */ protected function isValidBase64(mixed $input): bool { @@ -100,9 +90,6 @@ abstract class AbstractDecoder implements DecoderInterface /** * Parse data uri - * - * @param mixed $input - * @return object */ protected function parseDataUri(mixed $input): object { @@ -115,7 +102,6 @@ abstract class AbstractDecoder implements DecoderInterface { /** * @param array $matches - * @param int|false $result * @return void */ public function __construct(private array $matches, private int|false $result) diff --git a/src/Drivers/AbstractEncoder.php b/src/Drivers/AbstractEncoder.php index 251eaa1b..747cdcbc 100644 --- a/src/Drivers/AbstractEncoder.php +++ b/src/Drivers/AbstractEncoder.php @@ -30,10 +30,7 @@ abstract class AbstractEncoder implements EncoderInterface /** * Build new file pointer, run callback with it and return result as encoded image * - * @param callable $callback - * @param null|string $mediaType * @throws RuntimeException - * @return EncodedImage */ protected function createEncodedImage(callable $callback, ?string $mediaType = null): EncodedImage { diff --git a/src/Drivers/AbstractFontProcessor.php b/src/Drivers/AbstractFontProcessor.php index af984c95..6d0ae663 100644 --- a/src/Drivers/AbstractFontProcessor.php +++ b/src/Drivers/AbstractFontProcessor.php @@ -91,10 +91,7 @@ abstract class AbstractFontProcessor implements FontProcessorInterface /** * Reformat a text block by wrapping each line before the given maximum width * - * @param TextBlock $block - * @param FontInterface $font * @throws FontException - * @return TextBlock */ protected function wrapTextBlock(TextBlock $block, FontInterface $font): TextBlock { @@ -113,8 +110,6 @@ abstract class AbstractFontProcessor implements FontProcessorInterface * The output will be an array of formatted lines that are all within the * maximum width. * - * @param Line $line - * @param FontInterface $font * @throws FontException * @return array */ @@ -154,11 +149,7 @@ abstract class AbstractFontProcessor implements FontProcessorInterface /** * Build pivot point of textblock according to the font settings and based on given position * - * @param TextBlock $block - * @param FontInterface $font - * @param PointInterface $position * @throws FontException - * @return PointInterface */ protected function buildPivot(TextBlock $block, FontInterface $font, PointInterface $position): PointInterface { diff --git a/src/Drivers/Gd/Cloner.php b/src/Drivers/Gd/Cloner.php index ca67b9c6..e8719963 100644 --- a/src/Drivers/Gd/Cloner.php +++ b/src/Drivers/Gd/Cloner.php @@ -17,9 +17,7 @@ class Cloner /** * Create a clone of the given GdImage * - * @param GdImage $gd * @throws ColorException - * @return GdImage */ public static function clone(GdImage $gd): GdImage { @@ -39,11 +37,7 @@ class Cloner * It is optionally possible to change the size of the result and set a * background color. * - * @param GdImage $gd - * @param null|SizeInterface $size - * @param ColorInterface $background * @throws ColorException - * @return GdImage */ public static function cloneEmpty( GdImage $gd, @@ -81,10 +75,7 @@ class Cloner * Create a clone of an GdImage that is positioned on the specified background color. * Possible transparent areas are mixed with this color. * - * @param GdImage $gd - * @param ColorInterface $background * @throws ColorException - * @return GdImage */ public static function cloneBlended(GdImage $gd, ColorInterface $background): GdImage { diff --git a/src/Drivers/Gd/ColorProcessor.php b/src/Drivers/Gd/ColorProcessor.php index 935b57ac..6d738a4f 100644 --- a/src/Drivers/Gd/ColorProcessor.php +++ b/src/Drivers/Gd/ColorProcessor.php @@ -20,7 +20,6 @@ class ColorProcessor implements ColorProcessorInterface /** * Create new color processor object * - * @param ColorspaceInterface $colorspace * @return void */ public function __construct(protected ColorspaceInterface $colorspace = new Colorspace()) @@ -92,13 +91,6 @@ class ColorProcessor implements ColorProcessorInterface /** * Convert input in range (min) to (max) to the corresponding value * in target range (targetMin) to (targetMax). - * - * @param float|int $input - * @param float|int $min - * @param float|int $max - * @param float|int $targetMin - * @param float|int $targetMax - * @return float|int */ protected function convertRange( float|int $input, @@ -116,7 +108,6 @@ class ColorProcessor implements ColorProcessorInterface * i.e. result of imagecolorsforindex() * * @param array $color - * @return bool */ private function isValidArrayColor(array $color): bool { diff --git a/src/Drivers/Gd/Core.php b/src/Drivers/Gd/Core.php index a00d68ff..66424ad1 100644 --- a/src/Drivers/Gd/Core.php +++ b/src/Drivers/Gd/Core.php @@ -107,8 +107,6 @@ class Core extends Collection implements CoreInterface /** * Clone instance - * - * @return void */ public function __clone(): void { diff --git a/src/Drivers/Gd/Decoders/AbstractDecoder.php b/src/Drivers/Gd/Decoders/AbstractDecoder.php index d585f4da..756f2f0a 100644 --- a/src/Drivers/Gd/Decoders/AbstractDecoder.php +++ b/src/Drivers/Gd/Decoders/AbstractDecoder.php @@ -14,9 +14,7 @@ abstract class AbstractDecoder extends SpecializableDecoder implements Specializ /** * Return media (mime) type of the file at given file path * - * @param string $filepath * @throws DecoderException - * @return MediaType */ protected function getMediaTypeByFilePath(string $filepath): MediaType { @@ -32,9 +30,7 @@ abstract class AbstractDecoder extends SpecializableDecoder implements Specializ /** * Return media (mime) type of the given image data * - * @param string $data * @throws DecoderException - * @return MediaType */ protected function getMediaTypeByBinary(string $data): MediaType { diff --git a/src/Drivers/Gd/Decoders/BinaryImageDecoder.php b/src/Drivers/Gd/Decoders/BinaryImageDecoder.php index 5d30accc..ea199580 100644 --- a/src/Drivers/Gd/Decoders/BinaryImageDecoder.php +++ b/src/Drivers/Gd/Decoders/BinaryImageDecoder.php @@ -34,9 +34,7 @@ class BinaryImageDecoder extends NativeObjectDecoder implements DecoderInterface /** * Decode image from given binary data * - * @param string $input * @throws RuntimeException - * @return ImageInterface */ private function decodeBinary(string $input): ImageInterface { diff --git a/src/Drivers/Gd/Decoders/NativeObjectDecoder.php b/src/Drivers/Gd/Decoders/NativeObjectDecoder.php index 78ea021e..874da992 100644 --- a/src/Drivers/Gd/Decoders/NativeObjectDecoder.php +++ b/src/Drivers/Gd/Decoders/NativeObjectDecoder.php @@ -54,9 +54,7 @@ class NativeObjectDecoder extends AbstractDecoder * Depending on the configuration, this is taken over by the native GD function * or, if animations are required, by our own extended decoder. * - * @param mixed $input * @throws RuntimeException - * @return ImageInterface */ protected function decodeGif(mixed $input): ImageInterface { diff --git a/src/Drivers/Gd/Driver.php b/src/Drivers/Gd/Driver.php index 6e0ed89f..a0202e11 100644 --- a/src/Drivers/Gd/Driver.php +++ b/src/Drivers/Gd/Driver.php @@ -155,8 +155,6 @@ class Driver extends AbstractDriver /** * Return version of GD library - * - * @return string */ public static function version(): string { diff --git a/src/Drivers/Gd/Encoders/PngEncoder.php b/src/Drivers/Gd/Encoders/PngEncoder.php index 658ddb6a..fc58e9f0 100644 --- a/src/Drivers/Gd/Encoders/PngEncoder.php +++ b/src/Drivers/Gd/Encoders/PngEncoder.php @@ -34,11 +34,9 @@ class PngEncoder extends GenericPngEncoder implements SpecializedInterface /** * Prepare given image instance for PNG format output according to encoder settings * - * @param ImageInterface $image * @throws RuntimeException * @throws ColorException * @throws AnimationException - * @return GdImage */ private function prepareOutput(ImageInterface $image): GdImage { diff --git a/src/Drivers/Gd/FontProcessor.php b/src/Drivers/Gd/FontProcessor.php index c95f6bff..f43a2cb8 100644 --- a/src/Drivers/Gd/FontProcessor.php +++ b/src/Drivers/Gd/FontProcessor.php @@ -74,9 +74,6 @@ class FontProcessor extends AbstractFontProcessor /** * Return width of a single character - * - * @param int $gdfont - * @return int */ protected function gdCharacterWidth(int $gdfont): int { @@ -85,9 +82,6 @@ class FontProcessor extends AbstractFontProcessor /** * Return height of a single character - * - * @param int $gdfont - * @return int */ protected function gdCharacterHeight(int $gdfont): int { diff --git a/src/Drivers/Gd/Frame.php b/src/Drivers/Gd/Frame.php index 0c12fdf5..5db5f767 100644 --- a/src/Drivers/Gd/Frame.php +++ b/src/Drivers/Gd/Frame.php @@ -20,11 +20,6 @@ class Frame extends AbstractFrame implements FrameInterface /** * Create new frame instance * - * @param GdImage $native - * @param float $delay - * @param int $dispose - * @param int $offset_left - * @param int $offset_top * @return void */ public function __construct( @@ -190,7 +185,6 @@ class Frame extends AbstractFrame implements FrameInterface * This workaround helps cloning GdImages which is currently not possible. * * @throws ColorException - * @return void */ public function __clone(): void { diff --git a/src/Drivers/Gd/Modifiers/AlignRotationModifier.php b/src/Drivers/Gd/Modifiers/AlignRotationModifier.php index 791ae7db..4e453378 100644 --- a/src/Drivers/Gd/Modifiers/AlignRotationModifier.php +++ b/src/Drivers/Gd/Modifiers/AlignRotationModifier.php @@ -35,9 +35,6 @@ class AlignRotationModifier extends GenericAlignRotationModifier implements Spec * Set exif data of image to top-left orientation, marking the image as * aligned and making sure the rotation correction process is not * performed again. - * - * @param ImageInterface $image - * @return ImageInterface */ private function markAligned(ImageInterface $image): ImageInterface { diff --git a/src/Drivers/Gd/Modifiers/DrawBezierModifier.php b/src/Drivers/Gd/Modifiers/DrawBezierModifier.php index 3316ef1c..768d6f85 100644 --- a/src/Drivers/Gd/Modifiers/DrawBezierModifier.php +++ b/src/Drivers/Gd/Modifiers/DrawBezierModifier.php @@ -60,7 +60,7 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize if (array_key_exists($i + 2, $polygon) && array_key_exists($i + 3, $polygon)) { imageline( $frame->native(), - $polygon[$i + 0], + $polygon[$i], $polygon[$i + 1], $polygon[$i + 2], $polygon[$i + 3], @@ -88,7 +88,6 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize /** * Calculate interpolation points for quadratic beziers using the Bernstein polynomial form * - * @param float $t * @return array{'x': float, 'y': float} */ private function calculateQuadraticBezierInterpolationPoint(float $t = 0.05): array @@ -115,7 +114,6 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize /** * Calculate interpolation points for cubic beziers using the Bernstein polynomial form * - * @param float $t * @return array{'x': float, 'y': float} */ private function calculateCubicBezierInterpolationPoint(float $t = 0.05): array @@ -196,7 +194,7 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize $ox = -$dy * $scale; $oy = $dx * $scale; - $inner_polygon[] = $ox + $polygon[$i + 0]; + $inner_polygon[] = $ox + $polygon[$i]; $inner_polygon[] = $oy + $polygon[$i + 1]; $inner_polygon[] = $ox + $polygon[$i + 2]; $inner_polygon[] = $oy + $polygon[$i + 3]; @@ -206,7 +204,7 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize $ox = -$dy * $scale; $oy = $dx * $scale; - $outer_polygon[] = $ox + $polygon[$i + 0]; + $outer_polygon[] = $ox + $polygon[$i]; $outer_polygon[] = $oy + $polygon[$i + 1]; $outer_polygon[] = $ox + $polygon[$i + 2]; $outer_polygon[] = $oy + $polygon[$i + 3]; @@ -218,9 +216,9 @@ class DrawBezierModifier extends GenericDrawBezierModifier implements Specialize for ($i = 0; $i < $inner_polygon_total_points; $i += 2) { if (array_key_exists($i + 2, $inner_polygon) && array_key_exists($i + 3, $inner_polygon)) { $polygon_border_segments[] = [ - $inner_polygon[$i + 0], + $inner_polygon[$i], $inner_polygon[$i + 1], - $outer_polygon[$i + 0], + $outer_polygon[$i], $outer_polygon[$i + 1], $outer_polygon[$i + 2], $outer_polygon[$i + 3], diff --git a/src/Drivers/Gd/Modifiers/PlaceModifier.php b/src/Drivers/Gd/Modifiers/PlaceModifier.php index 9bc264d0..44333c74 100644 --- a/src/Drivers/Gd/Modifiers/PlaceModifier.php +++ b/src/Drivers/Gd/Modifiers/PlaceModifier.php @@ -39,11 +39,7 @@ class PlaceModifier extends GenericPlaceModifier implements SpecializedInterface /** * Insert watermark with 100% opacity * - * @param FrameInterface $frame - * @param ImageInterface $watermark - * @param PointInterface $position * @throws RuntimeException - * @return void */ private function placeOpaque(FrameInterface $frame, ImageInterface $watermark, PointInterface $position): void { @@ -72,11 +68,7 @@ class PlaceModifier extends GenericPlaceModifier implements SpecializedInterface * Please note: Unfortunately, there is still an edge case, when a transparent image * is placed on a transparent background, the "double" transparent areas appear opaque! * - * @param FrameInterface $frame - * @param ImageInterface $watermark - * @param PointInterface $position * @throws RuntimeException - * @return void */ private function placeTransparent(FrameInterface $frame, ImageInterface $watermark, PointInterface $position): void { diff --git a/src/Drivers/Gd/Modifiers/ResizeModifier.php b/src/Drivers/Gd/Modifiers/ResizeModifier.php index 3b6663f4..cfaa295d 100644 --- a/src/Drivers/Gd/Modifiers/ResizeModifier.php +++ b/src/Drivers/Gd/Modifiers/ResizeModifier.php @@ -60,10 +60,8 @@ class ResizeModifier extends GenericResizeModifier implements SpecializedInterfa /** * Return the size the modifier will resize to * - * @param ImageInterface $image * @throws RuntimeException * @throws GeometryException - * @return SizeInterface */ protected function getAdjustedSize(ImageInterface $image): SizeInterface { diff --git a/src/Drivers/Gd/Modifiers/RotateModifier.php b/src/Drivers/Gd/Modifiers/RotateModifier.php index fa5c9042..4db07502 100644 --- a/src/Drivers/Gd/Modifiers/RotateModifier.php +++ b/src/Drivers/Gd/Modifiers/RotateModifier.php @@ -38,10 +38,7 @@ class RotateModifier extends GenericRotateModifier implements SpecializedInterfa * Apply rotation modification on given frame, given background * color is used for newly create image areas * - * @param FrameInterface $frame - * @param ColorInterface $background * @throws ColorException - * @return void */ protected function modifyFrame(FrameInterface $frame, ColorInterface $background): void { diff --git a/src/Drivers/Gd/Modifiers/TextModifier.php b/src/Drivers/Gd/Modifiers/TextModifier.php index f3a46956..05ecb13c 100644 --- a/src/Drivers/Gd/Modifiers/TextModifier.php +++ b/src/Drivers/Gd/Modifiers/TextModifier.php @@ -85,10 +85,8 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Decode text color in GD compatible format * - * @param ImageInterface $image * @throws RuntimeException * @throws ColorException - * @return int */ protected function gdTextColor(ImageInterface $image): int { @@ -101,10 +99,8 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Decode color for stroke (outline) effect in GD compatible format * - * @param ImageInterface $image * @throws RuntimeException * @throws ColorException - * @return int */ protected function gdStrokeColor(ImageInterface $image): int { @@ -128,8 +124,6 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Return GD's internal font size (if no ttf file is set) - * - * @return int */ private function gdFont(): int { diff --git a/src/Drivers/Gd/Modifiers/TrimModifier.php b/src/Drivers/Gd/Modifiers/TrimModifier.php index 26be5d9e..ff86c8b4 100644 --- a/src/Drivers/Gd/Modifiers/TrimModifier.php +++ b/src/Drivers/Gd/Modifiers/TrimModifier.php @@ -48,10 +48,8 @@ class TrimModifier extends GenericTrimModifier implements SpecializedInterface /** * Create an average color from the colors of the four corner points of the given image * - * @param ImageInterface $image * @throws RuntimeException * @throws AnimationException - * @return int */ private function trimColor(ImageInterface $image): int { diff --git a/src/Drivers/Imagick/Core.php b/src/Drivers/Imagick/Core.php index 472cf651..b0e13a40 100644 --- a/src/Drivers/Imagick/Core.php +++ b/src/Drivers/Imagick/Core.php @@ -22,7 +22,6 @@ class Core implements CoreInterface, Iterator /** * Create new core instance * - * @param Imagick $imagick * @return void */ public function __construct(protected Imagick $imagick) @@ -317,8 +316,6 @@ class Core implements CoreInterface, Iterator /** * Clone instance - * - * @return void */ public function __clone(): void { diff --git a/src/Drivers/Imagick/Driver.php b/src/Drivers/Imagick/Driver.php index a8c43d13..61fd05f5 100644 --- a/src/Drivers/Imagick/Driver.php +++ b/src/Drivers/Imagick/Driver.php @@ -159,7 +159,6 @@ class Driver extends AbstractDriver * Return version of ImageMagick library * * @throws DriverException - * @return string */ public static function version(): string { diff --git a/src/Drivers/Imagick/FontProcessor.php b/src/Drivers/Imagick/FontProcessor.php index 50f0630e..16fc4c8e 100644 --- a/src/Drivers/Imagick/FontProcessor.php +++ b/src/Drivers/Imagick/FontProcessor.php @@ -43,12 +43,9 @@ class FontProcessor extends AbstractFontProcessor * the font object as the base and adds an optional passed color to the new * ImagickDraw object. * - * @param FontInterface $font - * @param null|ImagickPixel $color * @throws FontException * @throws ImagickDrawException * @throws ImagickException - * @return ImagickDraw */ public function toImagickDraw(FontInterface $font, ?ImagickPixel $color = null): ImagickDraw { diff --git a/src/Drivers/Imagick/Frame.php b/src/Drivers/Imagick/Frame.php index 2f027e7e..0f9fd639 100644 --- a/src/Drivers/Imagick/Frame.php +++ b/src/Drivers/Imagick/Frame.php @@ -21,7 +21,6 @@ class Frame extends AbstractFrame implements FrameInterface /** * Create new frame object * - * @param Imagick $native * @throws ImagickException * @return void */ diff --git a/src/Drivers/Imagick/Modifiers/TextModifier.php b/src/Drivers/Imagick/Modifiers/TextModifier.php index fcf29cd5..69ff34ca 100644 --- a/src/Drivers/Imagick/Modifiers/TextModifier.php +++ b/src/Drivers/Imagick/Modifiers/TextModifier.php @@ -51,14 +51,11 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Create an ImagickDraw object to draw text on the image * - * @param ImageInterface $image - * @param FontInterface $font * @throws RuntimeException * @throws ColorException * @throws FontException * @throws ImagickDrawException * @throws ImagickException - * @return ImagickDraw */ private function imagickDrawText(ImageInterface $image, FontInterface $font): ImagickDraw { @@ -78,14 +75,11 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Create a ImagickDraw object to draw the outline stroke effect on the Image * - * @param ImageInterface $image - * @param FontInterface $font * @throws RuntimeException * @throws ColorException * @throws FontException * @throws ImagickDrawException * @throws ImagickException - * @return null|ImagickDraw */ private function imagickDrawStroke(ImageInterface $image, FontInterface $font): ?ImagickDraw { @@ -109,12 +103,6 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface /** * Maybe draw given line of text on frame instance depending on given * ImageDraw instance. Optionally move line position by given offset. - * - * @param FrameInterface $frame - * @param Line $textline - * @param null|ImagickDraw $draw - * @param PointInterface $offset - * @return void */ private function maybeDrawTextline( FrameInterface $frame, @@ -137,7 +125,6 @@ class TextModifier extends GenericTextModifier implements SpecializedInterface * Return imagick font processor * * @throws FontException - * @return FontProcessor */ private function processor(): FontProcessor { diff --git a/src/EncodedImage.php b/src/EncodedImage.php index ffe21007..e8c767a0 100644 --- a/src/EncodedImage.php +++ b/src/EncodedImage.php @@ -12,7 +12,6 @@ class EncodedImage extends File implements EncodedImageInterface * Create new instance * * @param string|resource $data - * @param string $mediaType */ public function __construct( mixed $data, diff --git a/src/Encoders/AvifEncoder.php b/src/Encoders/AvifEncoder.php index 8a724247..2cf708d3 100644 --- a/src/Encoders/AvifEncoder.php +++ b/src/Encoders/AvifEncoder.php @@ -11,7 +11,6 @@ class AvifEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/Encoders/FileExtensionEncoder.php b/src/Encoders/FileExtensionEncoder.php index 9736112f..bb0b1b3a 100644 --- a/src/Encoders/FileExtensionEncoder.php +++ b/src/Encoders/FileExtensionEncoder.php @@ -50,9 +50,7 @@ class FileExtensionEncoder extends AutoEncoder /** * Create matching encoder for given file extension * - * @param null|string|FileExtension $extension * @throws EncoderException - * @return EncoderInterface */ protected function encoderByFileExtension(null|string|FileExtension $extension): EncoderInterface { diff --git a/src/Encoders/FilePathEncoder.php b/src/Encoders/FilePathEncoder.php index 5e807c08..62c496da 100644 --- a/src/Encoders/FilePathEncoder.php +++ b/src/Encoders/FilePathEncoder.php @@ -12,7 +12,6 @@ class FilePathEncoder extends FileExtensionEncoder /** * Create new encoder instance to encode to format of file extension in given path * - * @param null|string $path * @return void */ public function __construct(protected ?string $path = null, mixed ...$options) diff --git a/src/Encoders/GifEncoder.php b/src/Encoders/GifEncoder.php index f088c759..0ee950a6 100644 --- a/src/Encoders/GifEncoder.php +++ b/src/Encoders/GifEncoder.php @@ -11,7 +11,6 @@ class GifEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param bool $interlaced * @return void */ public function __construct(public bool $interlaced = false) diff --git a/src/Encoders/HeicEncoder.php b/src/Encoders/HeicEncoder.php index 965d07fa..68168f0f 100644 --- a/src/Encoders/HeicEncoder.php +++ b/src/Encoders/HeicEncoder.php @@ -11,7 +11,6 @@ class HeicEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/Encoders/Jpeg2000Encoder.php b/src/Encoders/Jpeg2000Encoder.php index 8d89a070..d089211e 100644 --- a/src/Encoders/Jpeg2000Encoder.php +++ b/src/Encoders/Jpeg2000Encoder.php @@ -11,7 +11,6 @@ class Jpeg2000Encoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/Encoders/JpegEncoder.php b/src/Encoders/JpegEncoder.php index cbc5bc3e..507b1dee 100644 --- a/src/Encoders/JpegEncoder.php +++ b/src/Encoders/JpegEncoder.php @@ -11,8 +11,6 @@ class JpegEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality - * @param bool $progressive * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/Encoders/MediaTypeEncoder.php b/src/Encoders/MediaTypeEncoder.php index 005e09d6..ede88d2a 100644 --- a/src/Encoders/MediaTypeEncoder.php +++ b/src/Encoders/MediaTypeEncoder.php @@ -49,9 +49,7 @@ class MediaTypeEncoder extends AbstractEncoder /** * Return new encoder by given media (MIME) type * - * @param string|MediaType $mediaType * @throws EncoderException - * @return EncoderInterface */ protected function encoderByMediaType(string|MediaType $mediaType): EncoderInterface { diff --git a/src/Encoders/PngEncoder.php b/src/Encoders/PngEncoder.php index c2530278..f5420738 100644 --- a/src/Encoders/PngEncoder.php +++ b/src/Encoders/PngEncoder.php @@ -11,8 +11,6 @@ class PngEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param bool $interlaced - * @param bool $indexed * @return void */ public function __construct(public bool $interlaced = false, public bool $indexed = false) diff --git a/src/Encoders/TiffEncoder.php b/src/Encoders/TiffEncoder.php index a5fe0c82..b6eb21c5 100644 --- a/src/Encoders/TiffEncoder.php +++ b/src/Encoders/TiffEncoder.php @@ -11,7 +11,6 @@ class TiffEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/Encoders/WebpEncoder.php b/src/Encoders/WebpEncoder.php index 42e2a72f..a740f208 100644 --- a/src/Encoders/WebpEncoder.php +++ b/src/Encoders/WebpEncoder.php @@ -11,7 +11,6 @@ class WebpEncoder extends SpecializableEncoder /** * Create new encoder object * - * @param int $quality * @param null|bool $strip Strip EXIF metadata * @return void */ diff --git a/src/File.php b/src/File.php index 604b6add..fa0b7dcd 100644 --- a/src/File.php +++ b/src/File.php @@ -33,9 +33,7 @@ class File implements FileInterface, Stringable /** * Create file object from path in file system * - * @param string $path * @throws RuntimeException - * @return File */ public static function fromPath(string $path): self { diff --git a/src/FileExtension.php b/src/FileExtension.php index 07ffff69..dce24c53 100644 --- a/src/FileExtension.php +++ b/src/FileExtension.php @@ -35,7 +35,6 @@ enum FileExtension: string * * @param string|Format|MediaType|FileExtension $identifier * @throws NotSupportedException - * @return FileExtension */ public static function create(string|self|Format|MediaType $identifier): self { @@ -81,8 +80,6 @@ enum FileExtension: string /** * Return the matching format for the current file extension - * - * @return Format */ public function format(): Format { @@ -122,8 +119,6 @@ enum FileExtension: string /** * Return the first found media type for the current format - * - * @return MediaType */ public function mediaType(): MediaType { diff --git a/src/Format.php b/src/Format.php index 40acf442..09be895d 100644 --- a/src/Format.php +++ b/src/Format.php @@ -36,7 +36,6 @@ enum Format * * @param string|Format|MediaType|FileExtension $identifier * @throws NotSupportedException - * @return Format */ public static function create(string|self|MediaType|FileExtension $identifier): self { @@ -95,8 +94,6 @@ enum Format /** * Return the first found media type for the current format - * - * @return MediaType */ public function mediaType(): MediaType { @@ -120,8 +117,6 @@ enum Format /** * Return the first found file extension for the current format - * - * @return FileExtension */ public function fileExtension(): FileExtension { @@ -132,9 +127,6 @@ enum Format /** * Create an encoder instance with given options that matches the format - * - * @param mixed $options - * @return EncoderInterface */ public function encoder(mixed ...$options): EncoderInterface { diff --git a/src/Geometry/Bezier.php b/src/Geometry/Bezier.php index 3a5e6957..9e5caf19 100644 --- a/src/Geometry/Bezier.php +++ b/src/Geometry/Bezier.php @@ -27,7 +27,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter * Create new bezier instance * * @param array $points - * @param PointInterface $pivot * @return void */ public function __construct( @@ -71,8 +70,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return current pivot point - * - * @return PointInterface */ public function pivot(): PointInterface { @@ -81,9 +78,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Change pivot point to given point - * - * @param PointInterface $pivot - * @return Bezier */ public function setPivot(PointInterface $pivot): self { @@ -94,8 +88,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return first control point of bezier - * - * @return ?PointInterface */ public function first(): ?PointInterface { @@ -108,8 +100,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return second control point of bezier - * - * @return ?PointInterface */ public function second(): ?PointInterface { @@ -122,8 +112,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return third control point of bezier - * - * @return ?PointInterface */ public function third(): ?PointInterface { @@ -136,8 +124,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return last control point of bezier - * - * @return ?PointInterface */ public function last(): ?PointInterface { @@ -150,8 +136,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Return bezier's point count - * - * @return int */ public function count(): int { @@ -162,7 +146,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter * Determine if point exists at given offset * * @param mixed $offset - * @return bool */ public function offsetExists($offset): bool { @@ -185,7 +168,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter * * @param mixed $offset * @param PointInterface $value - * @return void */ public function offsetSet($offset, $value): void { @@ -196,7 +178,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter * Unset offset at given offset * * @param mixed $offset - * @return void */ public function offsetUnset($offset): void { @@ -205,9 +186,6 @@ class Bezier implements IteratorAggregate, Countable, ArrayAccess, DrawableInter /** * Add given point to bezier - * - * @param PointInterface $point - * @return Bezier */ public function addPoint(PointInterface $point): self { diff --git a/src/Geometry/Circle.php b/src/Geometry/Circle.php index 2211d351..dc2e28b9 100644 --- a/src/Geometry/Circle.php +++ b/src/Geometry/Circle.php @@ -11,8 +11,6 @@ class Circle extends Ellipse /** * Create new Circle instance * - * @param int $diameter - * @param PointInterface $pivot * @return void */ public function __construct( @@ -24,9 +22,6 @@ class Circle extends Ellipse /** * Set diameter of circle - * - * @param int $diameter - * @return Circle */ public function setDiameter(int $diameter): self { @@ -38,8 +33,6 @@ class Circle extends Ellipse /** * Get diameter of circle - * - * @return int */ public function diameter(): int { @@ -48,9 +41,6 @@ class Circle extends Ellipse /** * Set radius of circle - * - * @param int $radius - * @return Circle */ public function setRadius(int $radius): self { @@ -59,8 +49,6 @@ class Circle extends Ellipse /** * Get radius of circle - * - * @return int */ public function radius(): int { diff --git a/src/Geometry/Ellipse.php b/src/Geometry/Ellipse.php index f0d68898..e27c9d8e 100644 --- a/src/Geometry/Ellipse.php +++ b/src/Geometry/Ellipse.php @@ -17,9 +17,6 @@ class Ellipse implements DrawableInterface /** * Create new Ellipse * - * @param int $width - * @param int $height - * @param PointInterface $pivot * @return void */ public function __construct( @@ -54,8 +51,6 @@ class Ellipse implements DrawableInterface /** * Return pivot point of Ellipse - * - * @return PointInterface */ public function pivot(): PointInterface { @@ -64,10 +59,6 @@ class Ellipse implements DrawableInterface /** * Set size of Ellipse - * - * @param int $width - * @param int $height - * @return Ellipse */ public function setSize(int $width, int $height): self { @@ -76,9 +67,6 @@ class Ellipse implements DrawableInterface /** * Set width of Ellipse - * - * @param int $width - * @return Ellipse */ public function setWidth(int $width): self { @@ -89,9 +77,6 @@ class Ellipse implements DrawableInterface /** * Set height of Ellipse - * - * @param int $height - * @return Ellipse */ public function setHeight(int $height): self { @@ -102,8 +87,6 @@ class Ellipse implements DrawableInterface /** * Get width of Ellipse - * - * @return int */ public function width(): int { @@ -112,8 +95,6 @@ class Ellipse implements DrawableInterface /** * Get height of Ellipse - * - * @return int */ public function height(): int { diff --git a/src/Geometry/Factories/BezierFactory.php b/src/Geometry/Factories/BezierFactory.php index cfbb5836..2d8410ba 100644 --- a/src/Geometry/Factories/BezierFactory.php +++ b/src/Geometry/Factories/BezierFactory.php @@ -17,7 +17,6 @@ class BezierFactory implements DrawableFactoryInterface /** * Create new factory instance * - * @param null|Closure|Bezier $init * @return void */ public function __construct(null|Closure|Bezier $init = null) @@ -51,10 +50,6 @@ class BezierFactory implements DrawableFactoryInterface /** * Add a point to the bezier to be produced - * - * @param int $x - * @param int $y - * @return BezierFactory */ public function point(int $x, int $y): self { @@ -65,9 +60,6 @@ class BezierFactory implements DrawableFactoryInterface /** * Set the background color of the bezier to be produced - * - * @param mixed $color - * @return BezierFactory */ public function background(mixed $color): self { @@ -78,10 +70,6 @@ class BezierFactory implements DrawableFactoryInterface /** * Set the border color & border size of the bezier to be produced - * - * @param mixed $color - * @param int $size - * @return BezierFactory */ public function border(mixed $color, int $size = 1): self { @@ -92,8 +80,6 @@ class BezierFactory implements DrawableFactoryInterface /** * Produce the bezier - * - * @return Bezier */ public function __invoke(): Bezier { diff --git a/src/Geometry/Factories/CircleFactory.php b/src/Geometry/Factories/CircleFactory.php index 5ae252c0..f45b5812 100644 --- a/src/Geometry/Factories/CircleFactory.php +++ b/src/Geometry/Factories/CircleFactory.php @@ -18,8 +18,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Create new factory instance * - * @param PointInterface $pivot - * @param null|Closure|Circle $init * @return void */ public function __construct( @@ -56,9 +54,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Set the radius of the circle to be produced - * - * @param int $radius - * @return CircleFactory */ public function radius(int $radius): self { @@ -69,9 +64,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Set the diameter of the circle to be produced - * - * @param int $diameter - * @return CircleFactory */ public function diameter(int $diameter): self { @@ -82,9 +74,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Set the background color of the circle to be produced - * - * @param mixed $color - * @return CircleFactory */ public function background(mixed $color): self { @@ -95,10 +84,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Set the border color & border size of the ellipse to be produced - * - * @param mixed $color - * @param int $size - * @return CircleFactory */ public function border(mixed $color, int $size = 1): self { @@ -109,8 +94,6 @@ class CircleFactory implements DrawableFactoryInterface /** * Produce the circle - * - * @return Circle */ public function __invoke(): Circle { diff --git a/src/Geometry/Factories/Drawable.php b/src/Geometry/Factories/Drawable.php index 1fe2c9b3..e7f14ba9 100644 --- a/src/Geometry/Factories/Drawable.php +++ b/src/Geometry/Factories/Drawable.php @@ -8,8 +8,6 @@ class Drawable { /** * Creeate BezierFactory statically - * - * @return BezierFactory */ public static function bezier(): BezierFactory { @@ -18,8 +16,6 @@ class Drawable /** * Creeate CircleFactory statically - * - * @return CircleFactory */ public static function circle(): CircleFactory { @@ -28,8 +24,6 @@ class Drawable /** * Create EllipseFactory statically - * - * @return EllipseFactory */ public static function ellipse(): EllipseFactory { @@ -38,8 +32,6 @@ class Drawable /** * Creeate LineFactory statically - * - * @return LineFactory */ public static function line(): LineFactory { @@ -48,8 +40,6 @@ class Drawable /** * Creeate PolygonFactory statically - * - * @return PolygonFactory */ public static function polygon(): PolygonFactory { @@ -58,8 +48,6 @@ class Drawable /** * Creeate RectangleFactory statically - * - * @return RectangleFactory */ public static function rectangle(): RectangleFactory { diff --git a/src/Geometry/Factories/EllipseFactory.php b/src/Geometry/Factories/EllipseFactory.php index 2df3556b..806e48c2 100644 --- a/src/Geometry/Factories/EllipseFactory.php +++ b/src/Geometry/Factories/EllipseFactory.php @@ -18,8 +18,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Create new factory instance * - * @param PointInterface $pivot - * @param null|Closure|Ellipse $init * @return void */ public function __construct( @@ -56,10 +54,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Set the size of the ellipse to be produced - * - * @param int $width - * @param int $height - * @return EllipseFactory */ public function size(int $width, int $height): self { @@ -70,9 +64,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Set the width of the ellipse to be produced - * - * @param int $width - * @return EllipseFactory */ public function width(int $width): self { @@ -83,9 +74,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Set the height of the ellipse to be produced - * - * @param int $height - * @return EllipseFactory */ public function height(int $height): self { @@ -96,9 +84,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Set the background color of the ellipse to be produced - * - * @param mixed $color - * @return EllipseFactory */ public function background(mixed $color): self { @@ -109,10 +94,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Set the border color & border size of the ellipse to be produced - * - * @param mixed $color - * @param int $size - * @return EllipseFactory */ public function border(mixed $color, int $size = 1): self { @@ -123,8 +104,6 @@ class EllipseFactory implements DrawableFactoryInterface /** * Produce the ellipse - * - * @return Ellipse */ public function __invoke(): Ellipse { diff --git a/src/Geometry/Factories/LineFactory.php b/src/Geometry/Factories/LineFactory.php index e78f855a..ce65433a 100644 --- a/src/Geometry/Factories/LineFactory.php +++ b/src/Geometry/Factories/LineFactory.php @@ -17,7 +17,6 @@ class LineFactory implements DrawableFactoryInterface /** * Create the factory instance * - * @param null|Closure|Line $init * @return void */ public function __construct(null|Closure|Line $init = null) @@ -51,9 +50,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the color of the line to be produced - * - * @param mixed $color - * @return LineFactory */ public function color(mixed $color): self { @@ -65,9 +61,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the (background) color of the line to be produced - * - * @param mixed $color - * @return LineFactory */ public function background(mixed $color): self { @@ -79,10 +72,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the border size & border color of the line to be produced - * - * @param mixed $color - * @param int $size - * @return LineFactory */ public function border(mixed $color, int $size = 1): self { @@ -95,9 +84,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the width of the line to be produced - * - * @param int $size - * @return LineFactory */ public function width(int $size): self { @@ -108,10 +94,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the coordinates of the starting point of the line to be produced - * - * @param int $x - * @param int $y - * @return LineFactory */ public function from(int $x, int $y): self { @@ -122,10 +104,6 @@ class LineFactory implements DrawableFactoryInterface /** * Set the coordinates of the end point of the line to be produced - * - * @param int $x - * @param int $y - * @return LineFactory */ public function to(int $x, int $y): self { @@ -136,8 +114,6 @@ class LineFactory implements DrawableFactoryInterface /** * Produce the line - * - * @return Line */ public function __invoke(): Line { diff --git a/src/Geometry/Factories/PolygonFactory.php b/src/Geometry/Factories/PolygonFactory.php index bc006f79..d065eb86 100644 --- a/src/Geometry/Factories/PolygonFactory.php +++ b/src/Geometry/Factories/PolygonFactory.php @@ -17,7 +17,6 @@ class PolygonFactory implements DrawableFactoryInterface /** * Create new factory instance * - * @param null|Closure|Polygon $init * @return void */ public function __construct(null|Closure|Polygon $init = null) @@ -51,10 +50,6 @@ class PolygonFactory implements DrawableFactoryInterface /** * Add a point to the polygon to be produced - * - * @param int $x - * @param int $y - * @return PolygonFactory */ public function point(int $x, int $y): self { @@ -65,9 +60,6 @@ class PolygonFactory implements DrawableFactoryInterface /** * Set the background color of the polygon to be produced - * - * @param mixed $color - * @return PolygonFactory */ public function background(mixed $color): self { @@ -78,10 +70,6 @@ class PolygonFactory implements DrawableFactoryInterface /** * Set the border color & border size of the polygon to be produced - * - * @param mixed $color - * @param int $size - * @return PolygonFactory */ public function border(mixed $color, int $size = 1): self { @@ -92,8 +80,6 @@ class PolygonFactory implements DrawableFactoryInterface /** * Produce the polygon - * - * @return Polygon */ public function __invoke(): Polygon { diff --git a/src/Geometry/Factories/RectangleFactory.php b/src/Geometry/Factories/RectangleFactory.php index 29f5a3b4..34732f24 100644 --- a/src/Geometry/Factories/RectangleFactory.php +++ b/src/Geometry/Factories/RectangleFactory.php @@ -18,8 +18,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Create new instance * - * @param PointInterface $pivot - * @param null|Closure|Rectangle $init * @return void */ public function __construct( @@ -56,10 +54,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Set the size of the rectangle to be produced - * - * @param int $width - * @param int $height - * @return RectangleFactory */ public function size(int $width, int $height): self { @@ -70,9 +64,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Set the width of the rectangle to be produced - * - * @param int $width - * @return RectangleFactory */ public function width(int $width): self { @@ -83,9 +74,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Set the height of the rectangle to be produced - * - * @param int $height - * @return RectangleFactory */ public function height(int $height): self { @@ -96,9 +84,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Set the background color of the rectangle to be produced - * - * @param mixed $color - * @return RectangleFactory */ public function background(mixed $color): self { @@ -109,10 +94,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Set the border color & border size of the rectangle to be produced - * - * @param mixed $color - * @param int $size - * @return RectangleFactory */ public function border(mixed $color, int $size = 1): self { @@ -123,8 +104,6 @@ class RectangleFactory implements DrawableFactoryInterface /** * Produce the rectangle - * - * @return Rectangle */ public function __invoke(): Rectangle { diff --git a/src/Geometry/Line.php b/src/Geometry/Line.php index a1aed2f0..14dd062d 100644 --- a/src/Geometry/Line.php +++ b/src/Geometry/Line.php @@ -17,9 +17,6 @@ class Line implements DrawableInterface /** * Create new line instance * - * @param PointInterface $start - * @param PointInterface $end - * @param int $width * @return void */ public function __construct( @@ -54,8 +51,6 @@ class Line implements DrawableInterface /** * Return line width - * - * @return int */ public function width(): int { @@ -64,9 +59,6 @@ class Line implements DrawableInterface /** * Set line width - * - * @param int $width - * @return Line */ public function setWidth(int $width): self { @@ -77,8 +69,6 @@ class Line implements DrawableInterface /** * Get starting point of line - * - * @return PointInterface */ public function start(): PointInterface { @@ -87,8 +77,6 @@ class Line implements DrawableInterface /** * get end point of line - * - * @return PointInterface */ public function end(): PointInterface { @@ -97,9 +85,6 @@ class Line implements DrawableInterface /** * Set starting point of line - * - * @param PointInterface $start - * @return Line */ public function setStart(PointInterface $start): self { @@ -110,10 +95,6 @@ class Line implements DrawableInterface /** * Set starting point of line by coordinates - * - * @param int $x - * @param int $y - * @return Line */ public function from(int $x, int $y): self { @@ -125,10 +106,6 @@ class Line implements DrawableInterface /** * Set end point of line by coordinates - * - * @param int $x - * @param int $y - * @return Line */ public function to(int $x, int $y): self { @@ -140,9 +117,6 @@ class Line implements DrawableInterface /** * Set end point of line - * - * @param PointInterface $end - * @return Line */ public function setEnd(PointInterface $end): self { diff --git a/src/Geometry/Pixel.php b/src/Geometry/Pixel.php index a6afce60..dc5c5804 100644 --- a/src/Geometry/Pixel.php +++ b/src/Geometry/Pixel.php @@ -11,9 +11,6 @@ class Pixel extends Point /** * Create new pixel instance * - * @param ColorInterface $background - * @param int $x - * @param int $y * @return void */ public function __construct( diff --git a/src/Geometry/Point.php b/src/Geometry/Point.php index 2cc67518..f23cd565 100644 --- a/src/Geometry/Point.php +++ b/src/Geometry/Point.php @@ -17,8 +17,6 @@ class Point implements PointInterface, IteratorAggregate /** * Create new point instance * - * @param int $x - * @param int $y * @return void */ public function __construct( diff --git a/src/Geometry/Polygon.php b/src/Geometry/Polygon.php index bdca5c03..82c84724 100644 --- a/src/Geometry/Polygon.php +++ b/src/Geometry/Polygon.php @@ -27,7 +27,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte * Create new polygon instance * * @param array $points - * @param PointInterface $pivot * @return void */ public function __construct( @@ -71,8 +70,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return current pivot point - * - * @return PointInterface */ public function pivot(): PointInterface { @@ -81,9 +78,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Change pivot point to given point - * - * @param PointInterface $pivot - * @return Polygon */ public function setPivot(PointInterface $pivot): self { @@ -94,8 +88,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return first point of polygon - * - * @return ?PointInterface */ public function first(): ?PointInterface { @@ -108,8 +100,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return last point of polygon - * - * @return ?PointInterface */ public function last(): ?PointInterface { @@ -122,8 +112,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return polygon's point count - * - * @return int */ public function count(): int { @@ -134,7 +122,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte * Determine if point exists at given offset * * @param mixed $offset - * @return bool */ public function offsetExists($offset): bool { @@ -157,7 +144,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte * * @param mixed $offset * @param PointInterface $value - * @return void */ public function offsetSet($offset, $value): void { @@ -168,7 +154,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte * Unset offset at given offset * * @param mixed $offset - * @return void */ public function offsetUnset($offset): void { @@ -177,9 +162,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Add given point to polygon - * - * @param PointInterface $point - * @return Polygon */ public function addPoint(PointInterface $point): self { @@ -190,8 +172,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Calculate total horizontal span of polygon - * - * @return int */ public function width(): int { @@ -200,8 +180,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Calculate total vertical span of polygon - * - * @return int */ public function height(): int { @@ -210,8 +188,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return most left point of all points in polygon - * - * @return PointInterface */ public function mostLeftPoint(): PointInterface { @@ -229,8 +205,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return most right point in polygon - * - * @return PointInterface */ public function mostRightPoint(): PointInterface { @@ -248,8 +222,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return most top point in polygon - * - * @return PointInterface */ public function mostTopPoint(): PointInterface { @@ -267,8 +239,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return most bottom point in polygon - * - * @return PointInterface */ public function mostBottomPoint(): PointInterface { @@ -286,8 +256,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Return point in absolute center of the polygon - * - * @return PointInterface */ public function centerPoint(): PointInterface { @@ -299,9 +267,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Align all points of polygon horizontally to given position around pivot point - * - * @param string $position - * @return Polygon */ public function align(string $position): self { @@ -332,9 +297,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Align all points of polygon vertically to given position around pivot point - * - * @param string $position - * @return Polygon */ public function valign(string $position): self { @@ -365,9 +327,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Rotate points of polygon around pivot point with given angle - * - * @param float $angle - * @return Polygon */ public function rotate(float $angle): self { @@ -401,9 +360,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Move all points by given amount on the x-axis - * - * @param int $amount - * @return Polygon */ public function movePointsX(int $amount): self { @@ -416,9 +372,6 @@ class Polygon implements IteratorAggregate, Countable, ArrayAccess, DrawableInte /** * Move all points by given amount on the y-axis - * - * @param int $amount - * @return Polygon */ public function movePointsY(int $amount): self { diff --git a/src/Geometry/Rectangle.php b/src/Geometry/Rectangle.php index 484364f9..01e57f9b 100644 --- a/src/Geometry/Rectangle.php +++ b/src/Geometry/Rectangle.php @@ -14,9 +14,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Create new rectangle instance * - * @param int $width - * @param int $height - * @param PointInterface $pivot * @return void */ public function __construct( @@ -32,10 +29,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Set size of rectangle - * - * @param int $width - * @param int $height - * @return Rectangle */ public function setSize(int $width, int $height): self { @@ -44,9 +37,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Set width of rectangle - * - * @param int $width - * @return Rectangle */ public function setWidth(int $width): self { @@ -58,9 +48,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Set height of rectangle - * - * @param int $height - * @return Rectangle */ public function setHeight(int $height): self { @@ -72,8 +59,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Return pivot point of rectangle - * - * @return PointInterface */ public function pivot(): PointInterface { @@ -82,9 +67,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Set pivot point of rectangle - * - * @param PointInterface $pivot - * @return Rectangle */ public function setPivot(PointInterface $pivot): self { @@ -96,11 +78,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Move pivot to the given position in the rectangle and adjust the new * position by given offset values. - * - * @param string $position - * @param int $offset_x - * @param int $offset_y - * @return Rectangle */ public function movePivot(string $position, int $offset_x = 0, int $offset_y = 0): self { @@ -182,10 +159,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Align pivot relative to given size at given position - * - * @param SizeInterface $size - * @param string $position - * @return Rectangle */ public function alignPivotTo(SizeInterface $size, string $position): self { @@ -201,9 +174,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Return relative position to given rectangle - * - * @param SizeInterface $rectangle - * @return PointInterface */ public function relativePositionTo(SizeInterface $rectangle): PointInterface { @@ -215,8 +185,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Return aspect ration of rectangle - * - * @return float */ public function aspectRatio(): float { @@ -225,9 +193,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Determine if rectangle fits into given rectangle - * - * @param SizeInterface $size - * @return bool */ public function fitsInto(SizeInterface $size): bool { @@ -244,8 +209,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Determine if rectangle has landscape format - * - * @return bool */ public function isLandscape(): bool { @@ -254,8 +217,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Determine if rectangle has landscape format - * - * @return bool */ public function isPortrait(): bool { @@ -264,8 +225,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Return most top left point of rectangle - * - * @return PointInterface */ public function topLeftPoint(): PointInterface { @@ -274,8 +233,6 @@ class Rectangle extends Polygon implements SizeInterface /** * Return bottom right point of rectangle - * - * @return PointInterface */ public function bottomRightPoint(): PointInterface { @@ -355,10 +312,7 @@ class Rectangle extends Polygon implements SizeInterface /** * Create resizer instance with given target size * - * @param null|int $width - * @param null|int $height * @throws GeometryException - * @return RectangleResizer */ protected function resizer(?int $width = null, ?int $height = null): RectangleResizer { diff --git a/src/Geometry/Tools/RectangleResizer.php b/src/Geometry/Tools/RectangleResizer.php index 705783d5..7136b367 100644 --- a/src/Geometry/Tools/RectangleResizer.php +++ b/src/Geometry/Tools/RectangleResizer.php @@ -11,8 +11,6 @@ use Intervention\Image\Interfaces\SizeInterface; class RectangleResizer { /** - * @param null|int $width - * @param null|int $height * @throws GeometryException * @return void */ @@ -36,9 +34,7 @@ class RectangleResizer /** * Static factory method to create resizer with given target size * - * @param mixed $arguments * @throws GeometryException - * @return RectangleResizer */ public static function to(mixed ...$arguments): self { @@ -47,8 +43,6 @@ class RectangleResizer /** * Determine if resize has target width - * - * @return bool */ protected function hasTargetWidth(): bool { @@ -57,8 +51,6 @@ class RectangleResizer /** * Return target width of resizer if available - * - * @return null|int */ protected function getTargetWidth(): ?int { @@ -67,8 +59,6 @@ class RectangleResizer /** * Determine if resize has target height - * - * @return bool */ protected function hasTargetHeight(): bool { @@ -77,8 +67,6 @@ class RectangleResizer /** * Return target width of resizer if available - * - * @return null|int */ protected function getTargetHeight(): ?int { @@ -89,7 +77,6 @@ class RectangleResizer * Return target size object * * @throws GeometryException - * @return SizeInterface */ protected function getTargetSize(): SizeInterface { @@ -102,9 +89,6 @@ class RectangleResizer /** * Set target width of resizer - * - * @param int $width - * @return RectangleResizer */ public function toWidth(int $width): self { @@ -115,9 +99,6 @@ class RectangleResizer /** * Set target height of resizer - * - * @param int $height - * @return RectangleResizer */ public function toHeight(int $height): self { @@ -128,9 +109,6 @@ class RectangleResizer /** * Set target size to given size object - * - * @param SizeInterface $size - * @return RectangleResizer */ public function toSize(SizeInterface $size): self { @@ -142,9 +120,6 @@ class RectangleResizer /** * Get proportinal width - * - * @param SizeInterface $size - * @return int */ protected function getProportionalWidth(SizeInterface $size): int { @@ -157,9 +132,6 @@ class RectangleResizer /** * Get proportinal height - * - * @param SizeInterface $size - * @return int */ protected function getProportionalHeight(SizeInterface $size): int { @@ -172,9 +144,6 @@ class RectangleResizer /** * Resize given size to target size of the resizer - * - * @param SizeInterface $size - * @return SizeInterface */ public function resize(SizeInterface $size): SizeInterface { @@ -193,9 +162,6 @@ class RectangleResizer /** * Resize given size to target size of the resizer but do not exceed original size - * - * @param SizeInterface $size - * @return SizeInterface */ public function resizeDown(SizeInterface $size): SizeInterface { @@ -218,9 +184,6 @@ class RectangleResizer /** * Resize given size to target size proportinally - * - * @param SizeInterface $size - * @return SizeInterface */ public function scale(SizeInterface $size): SizeInterface { @@ -248,9 +211,6 @@ class RectangleResizer /** * Resize given size to target size proportinally but do not exceed original size - * - * @param SizeInterface $size - * @return SizeInterface */ public function scaleDown(SizeInterface $size): SizeInterface { @@ -295,7 +255,6 @@ class RectangleResizer * * @param SizeInterface $size Size to be resized * @throws GeometryException - * @return SizeInterface */ public function cover(SizeInterface $size): SizeInterface { @@ -319,7 +278,6 @@ class RectangleResizer * * @param SizeInterface $size Size to be resized * @throws GeometryException - * @return SizeInterface */ public function contain(SizeInterface $size): SizeInterface { @@ -343,7 +301,6 @@ class RectangleResizer * * @param SizeInterface $size Size to be resized * @throws GeometryException - * @return SizeInterface */ public function containDown(SizeInterface $size): SizeInterface { @@ -373,10 +330,6 @@ class RectangleResizer /** * Crop target size out of given size at given position (i.e. move the pivot point) - * - * @param SizeInterface $size - * @param string $position - * @return SizeInterface */ public function crop(SizeInterface $size, string $position = 'top-left'): SizeInterface { diff --git a/src/Image.php b/src/Image.php index 8777dc5d..738d0fec 100644 --- a/src/Image.php +++ b/src/Image.php @@ -104,17 +104,12 @@ final class Image implements ImageInterface { /** * The origin from which the image was created - * - * @var Origin */ private Origin $origin; /** * Create new instance * - * @param DriverInterface $driver - * @param CoreInterface $core - * @param CollectionInterface $exif * @throws RuntimeException * @return void */ @@ -941,9 +936,7 @@ final class Image implements ImageInterface /** * Alias of self::toJpeg() * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toJpg(mixed ...$options): EncodedImageInterface { @@ -963,9 +956,7 @@ final class Image implements ImageInterface /** * ALias of self::toJpeg2000() * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toJp2(mixed ...$options): EncodedImageInterface { @@ -1016,7 +1007,6 @@ final class Image implements ImageInterface * Alias if self::toBitmap() * * @throws RuntimeException - * @return EncodedImageInterface */ public function toBmp(mixed ...$options): EncodedImageInterface { @@ -1046,9 +1036,7 @@ final class Image implements ImageInterface /** * Alias of self::toTiff() * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toTif(mixed ...$options): EncodedImageInterface { @@ -1084,8 +1072,6 @@ final class Image implements ImageInterface /** * Clone image - * - * @return void */ public function __clone(): void { diff --git a/src/ImageManager.php b/src/ImageManager.php index 57b0c4d2..16e608b7 100644 --- a/src/ImageManager.php +++ b/src/ImageManager.php @@ -20,8 +20,6 @@ final class ImageManager implements ImageManagerInterface /** * @link https://image.intervention.io/v3/basics/configuration-drivers#create-a-new-image-manager-instance * - * @param string|DriverInterface $driver - * @param mixed $options * @throws DriverException * @throws InputException */ @@ -35,11 +33,8 @@ final class ImageManager implements ImageManagerInterface * * @link https://image.intervention.io/v3/basics/configuration-drivers#static-constructor * - * @param string|DriverInterface $driver - * @param mixed $options * @throws DriverException * @throws InputException - * @return ImageManager */ public static function withDriver(string|DriverInterface $driver, mixed ...$options): self { @@ -51,10 +46,8 @@ final class ImageManager implements ImageManagerInterface * * @link https://image.intervention.io/v3/basics/configuration-drivers#static-gd-driver-constructor * - * @param mixed $options * @throws DriverException * @throws InputException - * @return ImageManager */ public static function gd(mixed ...$options): self { @@ -66,10 +59,8 @@ final class ImageManager implements ImageManagerInterface * * @link https://image.intervention.io/v3/basics/configuration-drivers#static-imagick-driver-constructor * - * @param mixed $options * @throws DriverException * @throws InputException - * @return ImageManager */ public static function imagick(mixed ...$options): self { @@ -125,11 +116,8 @@ final class ImageManager implements ImageManagerInterface /** * Return driver object from given input which might be driver classname or instance of DriverInterface * - * @param string|DriverInterface $driver - * @param mixed $options * @throws DriverException * @throws InputException - * @return DriverInterface */ private static function resolveDriver(string|DriverInterface $driver, mixed ...$options): DriverInterface { diff --git a/src/InputHandler.php b/src/InputHandler.php index a0720d13..bdd9fbab 100644 --- a/src/InputHandler.php +++ b/src/InputHandler.php @@ -59,8 +59,6 @@ class InputHandler implements InputHandlerInterface /** * Driver with which the decoder classes are specialized - * - * @var null|DriverInterface */ protected ?DriverInterface $driver = null; @@ -81,8 +79,6 @@ class InputHandler implements InputHandlerInterface * Static factory method * * @param array $decoders - * @param null|DriverInterface $driver - * @return InputHandler */ public static function withDecoders(array $decoders, ?DriverInterface $driver = null): self { @@ -115,10 +111,8 @@ class InputHandler implements InputHandlerInterface /** * Resolve the given classname to an decoder object * - * @param string|DecoderInterface $decoder * @throws DriverException * @throws NotSupportedException - * @return DecoderInterface */ private function resolve(string|DecoderInterface $decoder): DecoderInterface { diff --git a/src/Interfaces/AnalyzerInterface.php b/src/Interfaces/AnalyzerInterface.php index 9a44690e..d11d874d 100644 --- a/src/Interfaces/AnalyzerInterface.php +++ b/src/Interfaces/AnalyzerInterface.php @@ -11,9 +11,7 @@ interface AnalyzerInterface /** * Analyze given image and return the retrieved data * - * @param ImageInterface $image * @throws RuntimeException - * @return mixed */ public function analyze(ImageInterface $image): mixed; } diff --git a/src/Interfaces/CollectionInterface.php b/src/Interfaces/CollectionInterface.php index 376072f4..30f72146 100644 --- a/src/Interfaces/CollectionInterface.php +++ b/src/Interfaces/CollectionInterface.php @@ -13,9 +13,6 @@ interface CollectionInterface extends Traversable { /** * Determine if the collection has item at given key - * - * @param int|string $key - * @return bool */ public function has(int|string $key): bool; @@ -30,39 +27,29 @@ interface CollectionInterface extends Traversable /** * Return item for given key or return default is key does not exist * - * @param int|string $key * @param mixed $default - * @return mixed */ public function get(int|string $key, $default = null): mixed; /** * Return item at given numeric position starting at 0 * - * @param int $key * @param mixed $default - * @return mixed */ public function getAtPosition(int $key = 0, $default = null): mixed; /** * Return first item in collection - * - * @return mixed */ public function first(): mixed; /** * Return last item in collection - * - * @return mixed */ public function last(): mixed; /** * Return item count of collection - * - * @return int */ public function count(): int; @@ -83,8 +70,6 @@ interface CollectionInterface extends Traversable /** * Extract items based on given values and discard the rest. * - * @param int $offset - * @param null|int $length * @return CollectionInterface */ public function slice(int $offset, ?int $length = 0): self; diff --git a/src/Interfaces/ColorChannelInterface.php b/src/Interfaces/ColorChannelInterface.php index f7509f63..ed705570 100644 --- a/src/Interfaces/ColorChannelInterface.php +++ b/src/Interfaces/ColorChannelInterface.php @@ -11,23 +11,17 @@ interface ColorChannelInterface /** * Create new instance by either value or normalized value * - * @param int|null $value - * @param float|null $normalized * @throws ColorException */ public function __construct(?int $value = null, ?float $normalized = null); /** * Return color channels integer value - * - * @return int */ public function value(): int; /** * Return the channels value normalized to a float value form 0 to 1 by its range - * - * @return float */ public function normalize(int $precision = 32): float; @@ -36,14 +30,11 @@ interface ColorChannelInterface * otherwise the value is returned unchanged. * * @throws ColorException - * @return mixed */ public function validate(mixed $value): mixed; /** * Return the the minimal possible value of the color channel - * - * @return int */ public function min(): int; @@ -56,15 +47,11 @@ interface ColorChannelInterface /** * Cast color channel's value to string - * - * @return string */ public function toString(): string; /** * Cast color channel's value to string - * - * @return string */ public function __toString(): string; } diff --git a/src/Interfaces/ColorInterface.php b/src/Interfaces/ColorInterface.php index b14b913b..2770b154 100644 --- a/src/Interfaces/ColorInterface.php +++ b/src/Interfaces/ColorInterface.php @@ -13,23 +13,17 @@ interface ColorInterface * Static color factory method that takes any supported color format * and returns a corresponding color object * - * @param mixed $input * @throws RuntimeException - * @return ColorInterface */ public static function create(mixed $input): self; /** * Return colorspace of current color - * - * @return ColorspaceInterface */ public function colorspace(): ColorspaceInterface; /** * Cast color object to string - * - * @return string */ public function toString(): string; @@ -42,8 +36,6 @@ interface ColorInterface /** * Cast color object to hex encoded web color - * - * @return string */ public function toHex(string $prefix = ''): string; @@ -64,44 +56,32 @@ interface ColorInterface /** * Retrieve the color channel by its classname * - * @param string $classname * @throws ColorException - * @return ColorChannelInterface */ public function channel(string $classname): ColorChannelInterface; /** * Convert color to given colorspace - * - * @return ColorInterface */ public function convertTo(string|ColorspaceInterface $colorspace): self; /** * Determine if the current color is gray - * - * @return bool */ public function isGreyscale(): bool; /** * Determine if the current color is (semi) transparent - * - * @return bool */ public function isTransparent(): bool; /** * Determine whether the current color is completely transparent - * - * @return bool */ public function isClear(): bool; /** * Cast color object to string - * - * @return string */ public function __toString(): string; } diff --git a/src/Interfaces/ColorProcessorInterface.php b/src/Interfaces/ColorProcessorInterface.php index a5ee9092..c8e3690c 100644 --- a/src/Interfaces/ColorProcessorInterface.php +++ b/src/Interfaces/ColorProcessorInterface.php @@ -11,7 +11,6 @@ interface ColorProcessorInterface /** * Turn given color in the driver's color implementation * - * @param ColorInterface $color * @throws ColorException * @return mixed */ @@ -20,9 +19,7 @@ interface ColorProcessorInterface /** * Turn the given driver's definition of a color into a color object * - * @param mixed $native * @throws ColorException - * @return ColorInterface */ public function nativeToColor(mixed $native): ColorInterface; } diff --git a/src/Interfaces/ColorspaceInterface.php b/src/Interfaces/ColorspaceInterface.php index f7fc0a7c..b11a55b3 100644 --- a/src/Interfaces/ColorspaceInterface.php +++ b/src/Interfaces/ColorspaceInterface.php @@ -8,9 +8,6 @@ interface ColorspaceInterface { /** * Convert given color to the format of the current colorspace - * - * @param ColorInterface $color - * @return ColorInterface */ public function importColor(ColorInterface $color): ColorInterface; @@ -18,7 +15,6 @@ interface ColorspaceInterface * Create new color in colorspace from given normalized channel values * * @param array $normalized - * @return ColorInterface */ public function colorFromNormalized(array $normalized): ColorInterface; } diff --git a/src/Interfaces/CoreInterface.php b/src/Interfaces/CoreInterface.php index 5374f736..40829844 100644 --- a/src/Interfaces/CoreInterface.php +++ b/src/Interfaces/CoreInterface.php @@ -12,46 +12,37 @@ interface CoreInterface extends CollectionInterface * return driver's representation of the image core. * * @throws AnimationException - * @return mixed */ public function native(): mixed; /** * Set driver's representation of the image core. * - * @param mixed $native * @return CoreInterface */ public function setNative(mixed $native): self; /** * Count number of frames of animated image core - * - * @return int */ public function count(): int; /** * Return frame of given position in an animated image * - * @param int $position * @throws AnimationException - * @return FrameInterface */ public function frame(int $position): FrameInterface; /** * Add new frame to core * - * @param FrameInterface $frame * @return CoreInterface */ public function add(FrameInterface $frame): self; /** * Return number of repetitions of an animated image - * - * @return int */ public function loops(): int; @@ -59,7 +50,6 @@ interface CoreInterface extends CollectionInterface * Set the number of repetitions for an animation. Where a * value of 0 means infinite repetition. * - * @param int $loops * @return CoreInterface */ public function setLoops(int $loops): self; @@ -68,7 +58,6 @@ interface CoreInterface extends CollectionInterface * Get first frame in core * * @throws AnimationException - * @return FrameInterface */ public function first(): FrameInterface; @@ -76,7 +65,6 @@ interface CoreInterface extends CollectionInterface * Get last frame in core * * @throws AnimationException - * @return FrameInterface */ public function last(): FrameInterface; } diff --git a/src/Interfaces/DecoderInterface.php b/src/Interfaces/DecoderInterface.php index 6d67cc4c..3383269d 100644 --- a/src/Interfaces/DecoderInterface.php +++ b/src/Interfaces/DecoderInterface.php @@ -11,9 +11,7 @@ interface DecoderInterface /** * Decode given input either to color or image * - * @param mixed $input * @throws RuntimeException - * @return ImageInterface|ColorInterface */ public function decode(mixed $input): ImageInterface|ColorInterface; } diff --git a/src/Interfaces/DrawableFactoryInterface.php b/src/Interfaces/DrawableFactoryInterface.php index e29f11dc..e9046cdf 100644 --- a/src/Interfaces/DrawableFactoryInterface.php +++ b/src/Interfaces/DrawableFactoryInterface.php @@ -10,40 +10,26 @@ interface DrawableFactoryInterface { /** * Create a new factory instance statically - * - * @param null|Closure|DrawableInterface $init - * @return DrawableFactoryInterface */ public static function init(null|Closure|DrawableInterface $init = null): self; /** * Create the end product of the factory - * - * @return DrawableInterface */ public function create(): DrawableInterface; /** * Define the background color of the drawable object - * - * @param mixed $color - * @return DrawableFactoryInterface */ public function background(mixed $color): self; /** * Set the border size & color of the drawable object to be produced - * - * @param mixed $color - * @param int $size - * @return DrawableFactoryInterface */ public function border(mixed $color, int $size = 1): self; /** * Create the end product by invoking the factory - * - * @return DrawableInterface */ public function __invoke(): DrawableInterface; } diff --git a/src/Interfaces/DrawableInterface.php b/src/Interfaces/DrawableInterface.php index 691f6791..ac36d982 100644 --- a/src/Interfaces/DrawableInterface.php +++ b/src/Interfaces/DrawableInterface.php @@ -8,84 +8,56 @@ interface DrawableInterface { /** * Position of the drawable object - * - * @return PointInterface */ public function position(): PointInterface; /** * Set position of the drawable object - * - * @param PointInterface $position - * @return DrawableInterface */ public function setPosition(PointInterface $position): self; /** * Set the background color of the drawable object - * - * @param mixed $color - * @return DrawableInterface */ public function setBackgroundColor(mixed $color): self; /** * Return background color of drawable object - * - * @return mixed */ public function backgroundColor(): mixed; /** * Determine if a background color was set - * - * @return bool */ public function hasBackgroundColor(): bool; /** * Set border color & size of the drawable object - * - * @param mixed $color - * @param int $size - * @return DrawableInterface */ public function setBorder(mixed $color, int $size = 1): self; /** * Set border size of the drawable object - * - * @param int $size - * @return DrawableInterface */ public function setBorderSize(int $size): self; /** * Set border color of the drawable object - * - * @param mixed $color - * @return DrawableInterface */ public function setBorderColor(mixed $color): self; /** * Get border size - * - * @return int */ public function borderSize(): int; /** * Get border color of drawable object - * - * @return mixed */ public function borderColor(): mixed; /** * Determine if the drawable object has a border - * - * @return bool */ public function hasBorder(): bool; } diff --git a/src/Interfaces/DriverInterface.php b/src/Interfaces/DriverInterface.php index 95503160..95a715cf 100644 --- a/src/Interfaces/DriverInterface.php +++ b/src/Interfaces/DriverInterface.php @@ -16,25 +16,19 @@ interface DriverInterface { /** * Return drivers unique id - * - * @return string */ public function id(): string; /** * Get driver configuration - * - * @return Config */ public function config(): Config; /** * Resolve given object into a specialized version for the current driver * - * @param ModifierInterface|AnalyzerInterface|EncoderInterface|DecoderInterface $object * @throws NotSupportedException * @throws DriverException - * @return ModifierInterface|AnalyzerInterface|EncoderInterface|DecoderInterface */ public function specialize( ModifierInterface|AnalyzerInterface|EncoderInterface|DecoderInterface $object @@ -53,44 +47,32 @@ interface DriverInterface /** * Create new image instance with the current driver in given dimensions * - * @param int $width - * @param int $height * @throws RuntimeException - * @return ImageInterface */ public function createImage(int $width, int $height): ImageInterface; /** * Create new animated image * - * @param callable $init * @throws RuntimeException - * @return ImageInterface */ public function createAnimation(callable $init): ImageInterface; /** * Handle given input by decoding it to ImageInterface or ColorInterface * - * @param mixed $input * @param array $decoders * @throws RuntimeException - * @return ImageInterface|ColorInterface */ public function handleInput(mixed $input, array $decoders = []): ImageInterface|ColorInterface; /** * Return color processor for the given colorspace - * - * @param ColorspaceInterface $colorspace - * @return ColorProcessorInterface */ public function colorProcessor(ColorspaceInterface $colorspace): ColorProcessorInterface; /** * Return font processor of the current driver - * - * @return FontProcessorInterface */ public function fontProcessor(): FontProcessorInterface; @@ -99,16 +81,12 @@ interface DriverInterface * throw exception if the check fails. * * @throws DriverException - * @return void */ public function checkHealth(): void; /** * Check if the current driver supports the given format and if the * underlying PHP extension was built with support for the format. - * - * @param string|Format|FileExtension|MediaType $identifier - * @return bool */ public function supports(string|Format|FileExtension|MediaType $identifier): bool; } diff --git a/src/Interfaces/EncodedImageInterface.php b/src/Interfaces/EncodedImageInterface.php index 46c1dc04..d521d8e0 100644 --- a/src/Interfaces/EncodedImageInterface.php +++ b/src/Interfaces/EncodedImageInterface.php @@ -8,22 +8,16 @@ interface EncodedImageInterface extends FileInterface { /** * Return Media (MIME) Type of encoded image - * - * @return string */ public function mediaType(): string; /** * Alias of self::mediaType() - * - * @return string */ public function mimetype(): string; /** * Transform encoded image data into an data uri string - * - * @return string */ public function toDataUri(): string; } diff --git a/src/Interfaces/EncoderInterface.php b/src/Interfaces/EncoderInterface.php index 53e9bcc6..b2bd34dd 100644 --- a/src/Interfaces/EncoderInterface.php +++ b/src/Interfaces/EncoderInterface.php @@ -11,9 +11,7 @@ interface EncoderInterface /** * Encode given image * - * @param ImageInterface $image * @throws RuntimeException - * @return EncodedImageInterface */ public function encode(ImageInterface $image): EncodedImageInterface; } diff --git a/src/Interfaces/FileInterface.php b/src/Interfaces/FileInterface.php index 6aa7e421..c6943223 100644 --- a/src/Interfaces/FileInterface.php +++ b/src/Interfaces/FileInterface.php @@ -11,9 +11,7 @@ interface FileInterface /** * Save data in given path in file system * - * @param string $filepath * @throws RuntimeException - * @return void */ public function save(string $filepath): void; @@ -26,22 +24,16 @@ interface FileInterface /** * Return size in bytes - * - * @return int */ public function size(): int; /** * Turn encoded data into string - * - * @return string */ public function toString(): string; /** * Cast encoded data into string - * - * @return string */ public function __toString(): string; } diff --git a/src/Interfaces/FontInterface.php b/src/Interfaces/FontInterface.php index d410cdbd..09d2d888 100644 --- a/src/Interfaces/FontInterface.php +++ b/src/Interfaces/FontInterface.php @@ -10,152 +10,104 @@ interface FontInterface { /** * Set color of font - * - * @param mixed $color - * @return FontInterface */ public function setColor(mixed $color): self; /** * Get color of font - * - * @return mixed */ public function color(): mixed; /** * Set stroke color of font - * - * @param mixed $color - * @return FontInterface */ public function setStrokeColor(mixed $color): self; /** * Get stroke color of font - * - * @return mixed */ public function strokeColor(): mixed; /** - /** - * Set stroke width of font - * - * @param int $width - * @throws FontException - * @return FontInterface - */ + /** + * Set stroke width of font + * + * @throws FontException + */ public function setStrokeWidth(int $width): self; /** * Get stroke width of font - * - * @return int */ public function strokeWidth(): int; /** * Determine if the font is drawn with outline stroke effect - * - * @return bool */ public function hasStrokeEffect(): bool; /** * Set font size - * - * @param float $size - * @return FontInterface */ public function setSize(float $size): self; /** * Get font size - * - * @return float */ public function size(): float; /** * Set rotation angle of font - * - * @param float $angle - * @return FontInterface */ public function setAngle(float $angle): self; /** * Get rotation angle of font - * - * @return float */ public function angle(): float; /** * Set font filename - * - * @param string $filename - * @return FontInterface */ public function setFilename(string $filename): self; /** * Get font filename - * - * @return null|string */ public function filename(): ?string; /** * Determine if font has a corresponding filename - * - * @return bool */ public function hasFilename(): bool; /** * Set horizontal alignment of font - * - * @param string $align - * @return FontInterface */ public function setAlignment(string $align): self; /** * Get horizontal alignment of font - * - * @return string */ public function alignment(): string; /** * Set vertical alignment of font - * - * @param string $align - * @return FontInterface */ public function setValignment(string $align): self; /** * Get vertical alignment of font - * - * @return string */ public function valignment(): string; /** * Set typographical line height - * - * @param float $value - * @return FontInterface */ public function setLineHeight(float $value): self; /** * Get line height of font - * - * @return float */ public function lineHeight(): float; @@ -163,14 +115,11 @@ interface FontInterface * Set the wrap width with which the text is rendered * * @param int $width - * @return FontInterface */ public function setWrapWidth(?int $width): self; /** * Get wrap width with which the text is rendered - * - * @return null|int */ public function wrapWidth(): ?int; } diff --git a/src/Interfaces/FontProcessorInterface.php b/src/Interfaces/FontProcessorInterface.php index d2742c50..c9b9c2ee 100644 --- a/src/Interfaces/FontProcessorInterface.php +++ b/src/Interfaces/FontProcessorInterface.php @@ -13,7 +13,6 @@ interface FontProcessorInterface * Calculate size of bounding box of given text in conjunction with the given font * * @throws FontException - * @return SizeInterface */ public function boxSize(string $text, FontInterface $font): SizeInterface; @@ -21,18 +20,12 @@ interface FontProcessorInterface * Build TextBlock object from text string and align every line according * to text modifier's font object and position. * - * @param string $text - * @param FontInterface $font - * @param PointInterface $position * @throws FontException - * @return TextBlock */ public function textBlock(string $text, FontInterface $font, PointInterface $position): TextBlock; /** * Calculate the actual font size to pass at the driver level - * - * @return float */ public function nativeFontSize(FontInterface $font): float; @@ -40,25 +33,20 @@ interface FontProcessorInterface * Calculate the typographical font size in pixels * * @throws FontException - * @return int */ public function typographicalSize(FontInterface $font): int; /** * Calculates typographical cap height * - * @param FontInterface $font * @throws FontException - * @return int */ public function capHeight(FontInterface $font): int; /** * Calculates typographical leading size * - * @param FontInterface $font * @throws FontException - * @return int */ public function leading(FontInterface $font): int; } diff --git a/src/Interfaces/FrameInterface.php b/src/Interfaces/FrameInterface.php index d28ee38c..c94a4443 100644 --- a/src/Interfaces/FrameInterface.php +++ b/src/Interfaces/FrameInterface.php @@ -10,8 +10,6 @@ interface FrameInterface { /** * Return image data of frame in driver specific format - * - * @return mixed */ public function native(): mixed; @@ -19,91 +17,63 @@ interface FrameInterface * Set image data of drame in driver specific format * * @param mixed $native - * @return FrameInterface */ public function setNative($native): self; /** * Transform frame into an image * - * @param DriverInterface $driver * @throws RuntimeException - * @return ImageInterface */ public function toImage(DriverInterface $driver): ImageInterface; /** * Get image size of current frame - * - * @return SizeInterface */ public function size(): SizeInterface; /** * Return animation delay of current frame in seconds - * - * @return float */ public function delay(): float; /** * Set animation frame delay in seoncds - * - * @param float $delay - * @return FrameInterface */ public function setDelay(float $delay): self; /** * Get disposal method of current frame - * - * @return int */ public function dispose(): int; /** * Set disposal method of current frame - * - * @return FrameInterface */ public function setDispose(int $dispose): self; /** * Set pixel offset of current frame - * - * @param int $left - * @param int $top - * @return FrameInterface */ public function setOffset(int $left, int $top): self; /** * Get left offset in pixels - * - * @return int */ public function offsetLeft(): int; /** * Set left pixel offset for current frame - * - * @param int $offset - * @return FrameInterface */ public function setOffsetLeft(int $offset): self; /** * Get top pixel offset of current frame - * - * @return int */ public function offsetTop(): int; /** * Set top pixel offset of current frame - * - * @param int $offset - * @return FrameInterface */ public function setOffsetTop(int $offset): self; } diff --git a/src/Interfaces/ImageInterface.php b/src/Interfaces/ImageInterface.php index ea87be31..f59fd12e 100644 --- a/src/Interfaces/ImageInterface.php +++ b/src/Interfaces/ImageInterface.php @@ -27,30 +27,21 @@ interface ImageInterface extends IteratorAggregate, Countable { /** * Return driver of current image - * - * @return DriverInterface */ public function driver(): DriverInterface; /** * Return core of current image - * - * @return CoreInterface */ public function core(): CoreInterface; /** * Return the origin of the image - * - * @return Origin */ public function origin(): Origin; /** * Set the origin of the image - * - * @param Origin $origin - * @return ImageInterface */ public function setOrigin(Origin $origin): self; @@ -60,7 +51,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/meta-information#read-the-pixel-width * * @throws RuntimeException - * @return int */ public function width(): int; @@ -70,7 +60,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/meta-information#read-the-pixel-height * * @throws RuntimeException - * @return int */ public function height(): int; @@ -80,7 +69,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/meta-information#read-the-image-size-as-an-object * * @throws RuntimeException - * @return SizeInterface */ public function size(): SizeInterface; @@ -89,9 +77,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-images * - * @param EncoderInterface $encoder * @throws RuntimeException - * @return EncodedImageInterface */ public function encode(EncoderInterface $encoder = new AutoEncoder()): EncodedImageInterface; @@ -101,9 +87,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode--save-combined * - * @param null|string $path * @throws RuntimeException - * @return ImageInterface */ public function save(?string $path = null, mixed ...$options): self; @@ -112,18 +96,14 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/custom-modifiers * - * @param ModifierInterface $modifier * @throws RuntimeException - * @return ImageInterface */ public function modify(ModifierInterface $modifier): self; /** * Analyzer current image with given analyzer * - * @param AnalyzerInterface $analyzer * @throws RuntimeException - * @return mixed */ public function analyze(AnalyzerInterface $analyzer): mixed; @@ -131,8 +111,6 @@ interface ImageInterface extends IteratorAggregate, Countable * Determine if current image is animated * * @link https://image.intervention.io/v3/modifying-images/animations#check-the-current-image-instance-for-animation - * - * @return bool */ public function isAnimated(): bool; @@ -146,9 +124,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/animations#remove-animation * - * @param int|string $position * @throws RuntimeException - * @return ImageInterface */ public function removeAnimation(int|string $position = 0): self; @@ -157,10 +133,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/animations#change-the-animation-iteration-count * - * @param int $offset - * @param null|int $length * @throws RuntimeException - * @return ImageInterface */ public function sliceAnimation(int $offset = 0, ?int $length = null): self; @@ -168,8 +141,6 @@ interface ImageInterface extends IteratorAggregate, Countable * Return loop count of animated image * * @link https://image.intervention.io/v3/modifying-images/animations#read-the-animation-iteration-count - * - * @return int */ public function loops(): int; @@ -177,9 +148,6 @@ interface ImageInterface extends IteratorAggregate, Countable * Set loop count of animated image * * @link https://image.intervention.io/v3/modifying-images/animations#change-the-animation-iteration-count - * - * @param int $loops - * @return ImageInterface */ public function setLoops(int $loops): self; @@ -187,16 +155,11 @@ interface ImageInterface extends IteratorAggregate, Countable * Return exif data of current image * * @link https://image.intervention.io/v3/basics/meta-information#exif-information - * - * @return mixed */ public function exif(?string $query = null): mixed; /** * Set exif data for the image object - * - * @param CollectionInterface $exif - * @return ImageInterface */ public function setExif(CollectionInterface $exif): self; @@ -206,7 +169,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/meta-information#image-resolution * * @throws RuntimeException - * @return ResolutionInterface */ public function resolution(): ResolutionInterface; @@ -215,10 +177,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/meta-information#image-resolution * - * @param float $x - * @param float $y * @throws RuntimeException - * @return ImageInterface */ public function setResolution(float $x, float $y): self; @@ -228,7 +187,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/colors#read-the-image-colorspace * * @throws RuntimeException - * @return ColorspaceInterface */ public function colorspace(): ColorspaceInterface; @@ -237,9 +195,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/colors#change-the-image-colorspace * - * @param string|ColorspaceInterface $colorspace * @throws RuntimeException - * @return ImageInterface */ public function setColorspace(string|ColorspaceInterface $colorspace): self; @@ -248,11 +204,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/colors#color-information * - * @param int $x - * @param int $y - * @param int $frame_key * @throws RuntimeException - * @return ColorInterface */ public function pickColor(int $x, int $y, int $frame_key = 0): ColorInterface; @@ -261,10 +213,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/colors#color-information * - * @param int $x - * @param int $y * @throws RuntimeException - * @return CollectionInterface */ public function pickColors(int $x, int $y): CollectionInterface; @@ -273,7 +222,6 @@ interface ImageInterface extends IteratorAggregate, Countable * does not support transparency. * * @throws RuntimeException - * @return ColorInterface */ public function blendingColor(): ColorInterface; @@ -281,18 +229,14 @@ interface ImageInterface extends IteratorAggregate, Countable * Set blending color will have no effect unless image is converted into a format * which does not support transparency. * - * @param mixed $color * @throws RuntimeException - * @return ImageInterface */ public function setBlendingColor(mixed $color): self; /** * Replace transparent areas of the image with given color * - * @param mixed $color * @throws RuntimeException - * @return ImageInterface */ public function blendTransparency(mixed $color = null): self; @@ -302,7 +246,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/colors#color-profiles * * @throws RuntimeException - * @return ProfileInterface */ public function profile(): ProfileInterface; @@ -311,9 +254,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/colors#color-profiles * - * @param ProfileInterface $profile * @throws RuntimeException - * @return ImageInterface */ public function setProfile(ProfileInterface $profile): self; @@ -323,7 +264,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/basics/colors#color-profiles * * @throws RuntimeException - * @return ImageInterface */ public function removeProfile(): self; @@ -332,10 +272,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#reduce-colors * - * @param int $limit - * @param mixed $background * @throws RuntimeException - * @return ImageInterface */ public function reduceColors(int $limit, mixed $background = 'transparent'): self; @@ -344,9 +281,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#sharpening-effect * - * @param int $amount * @throws RuntimeException - * @return ImageInterface */ public function sharpen(int $amount = 10): self; @@ -356,7 +291,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/modifying-images/effects#convert-image-to-a-greyscale-version * * @throws RuntimeException - * @return ImageInterface */ public function greyscale(): self; @@ -365,9 +299,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#change-the-image-brightness * - * @param int $level * @throws RuntimeException - * @return ImageInterface */ public function brightness(int $level): self; @@ -376,9 +308,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#change-the-image-contrast * - * @param int $level * @throws RuntimeException - * @return ImageInterface */ public function contrast(int $level): self; @@ -387,9 +317,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#gamma-correction * - * @param float $gamma * @throws RuntimeException - * @return ImageInterface */ public function gamma(float $gamma): self; @@ -398,11 +326,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#color-correction * - * @param int $red - * @param int $green - * @param int $blue * @throws RuntimeException - * @return ImageInterface */ public function colorize(int $red = 0, int $green = 0, int $blue = 0): self; @@ -412,7 +336,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/modifying-images/effects#mirror-image-vertically * * @throws RuntimeException - * @return ImageInterface */ public function flip(): self; @@ -422,7 +345,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/modifying-images/effects#mirror-image-horizontally * * @throws RuntimeException - * @return ImageInterface */ public function flop(): self; @@ -431,9 +353,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#blur-effect * - * @param int $amount * @throws RuntimeException - * @return ImageInterface */ public function blur(int $amount = 5): self; @@ -443,7 +363,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/modifying-images/effects#invert-colors * * @throws RuntimeException - * @return ImageInterface */ public function invert(): self; @@ -452,9 +371,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#pixelation-effect * - * @param int $size * @throws RuntimeException - * @return ImageInterface */ public function pixelate(int $size): self; @@ -463,10 +380,8 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/effects#image-rotation * - * @param float $angle * @param string $background * @throws RuntimeException - * @return ImageInterface */ public function rotate(float $angle, mixed $background = 'ffffff'): self; @@ -476,7 +391,6 @@ interface ImageInterface extends IteratorAggregate, Countable * @link https://image.intervention.io/v3/modifying-images/effects#image-orientation-according-to-exif-data * * @throws RuntimeException - * @return ImageInterface */ public function orient(): self; @@ -485,12 +399,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/text-fonts * - * @param string $text - * @param int $x - * @param int $y - * @param callable|Closure|FontInterface $font * @throws RuntimeException - * @return ImageInterface */ public function text(string $text, int $x, int $y, callable|Closure|FontInterface $font): self; @@ -499,10 +408,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#simple-image-resizing * - * @param null|int $width - * @param null|int $height * @throws RuntimeException - * @return ImageInterface */ public function resize(?int $width = null, ?int $height = null): self; @@ -511,10 +417,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#resize-without-exceeding-the-original-size * - * @param null|int $width - * @param null|int $height * @throws RuntimeException - * @return ImageInterface */ public function resizeDown(?int $width = null, ?int $height = null): self; @@ -523,10 +426,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#resize-images-proportionally * - * @param null|int $width - * @param null|int $height * @throws RuntimeException - * @return ImageInterface */ public function scale(?int $width = null, ?int $height = null): self; @@ -536,10 +436,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#scale-images-but-do-not-exceed-the-original-size * - * @param null|int $width - * @param null|int $height * @throws RuntimeException - * @return ImageInterface */ public function scaleDown(?int $width = null, ?int $height = null): self; @@ -551,11 +448,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#cropping--resizing-combined * - * @param int $width - * @param int $height - * @param string $position * @throws RuntimeException - * @return ImageInterface */ public function cover(int $width, int $height, string $position = 'center'): self; @@ -564,11 +457,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#fitted-resizing-without-exceeding-the-original-size * - * @param int $width - * @param int $height - * @param string $position * @throws RuntimeException - * @return ImageInterface */ public function coverDown(int $width, int $height, string $position = 'center'): self; @@ -580,12 +469,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#resize-image-boundaries-without-resampling-the-original-image * - * @param null|int $width - * @param null|int $height - * @param string $position - * @param mixed $background * @throws RuntimeException - * @return ImageInterface */ public function resizeCanvas( ?int $width = null, @@ -601,12 +485,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#resize-image-boundaries-relative-to-the-original * - * @param null|int $width - * @param null|int $height - * @param string $position - * @param mixed $background * @throws RuntimeException - * @return ImageInterface */ public function resizeCanvasRelative( ?int $width = null, @@ -626,12 +505,8 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#resizing--padding-combined * - * @param int $width - * @param int $height * @param string $background - * @param string $position * @throws RuntimeException - * @return ImageInterface */ public function pad( int $width, @@ -646,12 +521,8 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#padded-resizing-with-upscaling * - * @param int $width - * @param int $height * @param string $background - * @param string $position * @throws RuntimeException - * @return ImageInterface */ public function contain( int $width, @@ -667,14 +538,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#cut-out-a-rectangular-part * - * @param int $width - * @param int $height - * @param int $offset_x - * @param int $offset_y - * @param mixed $background - * @param string $position * @throws RuntimeException - * @return ImageInterface */ public function crop( int $width, @@ -690,10 +554,8 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/resizing#remove-border-areas-in-similar-color * - * @param int $tolerance * @throws RuntimeException * @throws AnimationException - * @return ImageInterface */ public function trim(int $tolerance = 0): self; @@ -702,13 +564,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/inserting#insert-images * - * @param mixed $element - * @param string $position - * @param int $offset_x - * @param int $offset_y - * @param int $opacity * @throws RuntimeException - * @return ImageInterface */ public function place( mixed $element, @@ -730,11 +586,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#fill-images-with-color * - * @param mixed $color - * @param null|int $x - * @param null|int $y * @throws RuntimeException - * @return ImageInterface */ public function fill(mixed $color, ?int $x = null, ?int $y = null): self; @@ -743,11 +595,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-pixels * - * @param int $x - * @param int $y - * @param mixed $color * @throws RuntimeException - * @return ImageInterface */ public function drawPixel(int $x, int $y, mixed $color): self; @@ -756,11 +604,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-a-rectangle * - * @param int $x - * @param int $y - * @param callable|Closure|Rectangle $init * @throws RuntimeException - * @return ImageInterface */ public function drawRectangle(int $x, int $y, callable|Closure|Rectangle $init): self; @@ -769,11 +613,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-ellipses * - * @param int $x - * @param int $y - * @param callable|Closure|Ellipse $init * @throws RuntimeException - * @return ImageInterface */ public function drawEllipse(int $x, int $y, callable|Closure|Ellipse $init): self; @@ -782,11 +622,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-a-circle * - * @param int $x - * @param int $y - * @param callable|Closure|Circle $init * @throws RuntimeException - * @return ImageInterface */ public function drawCircle(int $x, int $y, callable|Closure|Circle $init): self; @@ -795,9 +631,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-a-polygon * - * @param callable|Closure|Polygon $init * @throws RuntimeException - * @return ImageInterface */ public function drawPolygon(callable|Closure|Polygon $init): self; @@ -806,9 +640,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-a-line * - * @param callable|Closure|Line $init * @throws RuntimeException - * @return ImageInterface */ public function drawLine(callable|Closure|Line $init): self; @@ -817,9 +649,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/modifying-images/drawing#draw-bezier-curves * - * @param callable|Closure|Bezier $init * @throws RuntimeException - * @return ImageInterface */ public function drawBezier(callable|Closure|Bezier $init): self; @@ -829,9 +659,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-images-by-media-mime-type * - * @param null|string|MediaType $type * @throws RuntimeException - * @return EncodedImageInterface */ public function encodeByMediaType(null|string|MediaType $type = null, mixed ...$options): EncodedImageInterface; @@ -842,9 +670,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-images-by-file-extension * - * @param null|string|FileExtension $extension * @throws RuntimeException - * @return EncodedImageInterface */ public function encodeByExtension( null|string|FileExtension $extension = null, @@ -858,9 +684,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-images-by-file-path * - * @param null|string $path * @throws RuntimeException - * @return EncodedImageInterface */ public function encodeByPath(?string $path = null, mixed ...$options): EncodedImageInterface; @@ -869,11 +693,8 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-jpeg-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ - public function toJpeg(mixed ...$options): EncodedImageInterface; /** @@ -881,9 +702,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-jpeg-2000-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toJpeg2000(mixed ...$options): EncodedImageInterface; @@ -892,9 +711,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-webp-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toWebp(mixed ...$options): EncodedImageInterface; @@ -903,9 +720,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-png-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toPng(mixed ...$options): EncodedImageInterface; @@ -914,9 +729,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-gif-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toGif(mixed ...$options): EncodedImageInterface; @@ -925,9 +738,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-windows-bitmap-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toBitmap(mixed ...$options): EncodedImageInterface; @@ -936,9 +747,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-av1-image-file-format-avif * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toAvif(mixed ...$options): EncodedImageInterface; @@ -947,9 +756,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-tiff-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toTiff(mixed ...$options): EncodedImageInterface; @@ -958,9 +765,7 @@ interface ImageInterface extends IteratorAggregate, Countable * * @link https://image.intervention.io/v3/basics/image-output#encode-heic-format * - * @param mixed $options * @throws RuntimeException - * @return EncodedImageInterface */ public function toHeic(mixed ...$options): EncodedImageInterface; } diff --git a/src/Interfaces/ImageManagerInterface.php b/src/Interfaces/ImageManagerInterface.php index d1fae099..92652ec2 100644 --- a/src/Interfaces/ImageManagerInterface.php +++ b/src/Interfaces/ImageManagerInterface.php @@ -13,10 +13,7 @@ interface ImageManagerInterface * * @link https://image.intervention.io/v3/basics/instantiation#create-new-images * - * @param int $width - * @param int $height * @throws RuntimeException - * @return ImageInterface */ public function create(int $width, int $height): ImageInterface; @@ -45,10 +42,8 @@ interface ImageManagerInterface * * @link https://image.intervention.io/v3/basics/instantiation#read-image-sources * - * @param mixed $input * @param string|array|DecoderInterface $decoders * @throws RuntimeException - * @return ImageInterface */ public function read(mixed $input, string|array|DecoderInterface $decoders = []): ImageInterface; @@ -57,16 +52,12 @@ interface ImageManagerInterface * * @link https://image.intervention.io/v3/basics/instantiation#create-animations * - * @param callable $init * @throws RuntimeException - * @return ImageInterface */ public function animate(callable $init): ImageInterface; /** * Return currently used driver - * - * @return DriverInterface */ public function driver(): DriverInterface; } diff --git a/src/Interfaces/InputHandlerInterface.php b/src/Interfaces/InputHandlerInterface.php index 6d89f07e..25b01c1e 100644 --- a/src/Interfaces/InputHandlerInterface.php +++ b/src/Interfaces/InputHandlerInterface.php @@ -13,7 +13,6 @@ interface InputHandlerInterface * * @param mixed $input * @throws RuntimeException - * @return ImageInterface|ColorInterface */ public function handle($input): ImageInterface|ColorInterface; } diff --git a/src/Interfaces/ModifierInterface.php b/src/Interfaces/ModifierInterface.php index a68def25..df1f0833 100644 --- a/src/Interfaces/ModifierInterface.php +++ b/src/Interfaces/ModifierInterface.php @@ -11,9 +11,7 @@ interface ModifierInterface /** * Apply modifications of the current modifier to the given image * - * @param ImageInterface $image * @throws RuntimeException - * @return ImageInterface */ public function apply(ImageInterface $image): ImageInterface; } diff --git a/src/Interfaces/PointInterface.php b/src/Interfaces/PointInterface.php index 8d660988..962f9fde 100644 --- a/src/Interfaces/PointInterface.php +++ b/src/Interfaces/PointInterface.php @@ -8,72 +8,46 @@ interface PointInterface { /** * Return x position - * - * @return int */ public function x(): int; /** * Return y position - * - * @return int */ public function y(): int; /** * Set x position - * - * @param int $x - * @return PointInterface */ public function setX(int $x): self; /** * Set y position - * - * @param int $y - * @return PointInterface */ public function setY(int $y): self; /** * Move X coordinate - * - * @param int $value */ public function moveX(int $value): self; /** * Move Y coordinate - * - * @param int $value */ public function moveY(int $value): self; /** * Move position of current point by given coordinates - * - * @param int $x - * @param int $y - * @return PointInterface */ public function move(int $x, int $y): self; /** * Set position of point - * - * @param int $x - * @param int $y - * @return PointInterface */ public function setPosition(int $x, int $y): self; /** * Rotate point counter clock wise around given pivot point - * - * @param float $angle - * @param PointInterface $pivot - * @return PointInterface */ public function rotate(float $angle, self $pivot): self; } diff --git a/src/Interfaces/ProfileInterface.php b/src/Interfaces/ProfileInterface.php index 8453fda7..a10f5de8 100644 --- a/src/Interfaces/ProfileInterface.php +++ b/src/Interfaces/ProfileInterface.php @@ -8,8 +8,6 @@ interface ProfileInterface { /** * Cast color profile object to string - * - * @return string */ public function __toString(): string; } diff --git a/src/Interfaces/ResolutionInterface.php b/src/Interfaces/ResolutionInterface.php index edcd94ab..ccdd5190 100644 --- a/src/Interfaces/ResolutionInterface.php +++ b/src/Interfaces/ResolutionInterface.php @@ -8,66 +8,46 @@ interface ResolutionInterface { /** * Return resolution of x-axis - * - * @return float */ public function x(): float; /** * Set resolution on x-axis - * - * @param float $x - * @return ResolutionInterface */ public function setX(float $x): self; /** * Return resolution on y-axis - * - * @return float */ public function y(): float; /** * Set resolution on y-axis - * - * @param float $y - * @return ResolutionInterface */ public function setY(float $y): self; /** * Convert the resolution to DPI - * - * @return ResolutionInterface */ public function perInch(): self; /** * Convert the resolution to DPCM - * - * @return ResolutionInterface */ public function perCm(): self; /** * Return string representation of unit - * - * @return string */ public function unit(): string; /** * Transform object to string - * - * @return string */ public function toString(): string; /** * Cast object to string - * - * @return string */ public function __toString(): string; } diff --git a/src/Interfaces/SizeInterface.php b/src/Interfaces/SizeInterface.php index d62fa6ed..d49db62f 100644 --- a/src/Interfaces/SizeInterface.php +++ b/src/Interfaces/SizeInterface.php @@ -10,103 +10,67 @@ interface SizeInterface { /** * Get width - * - * @return int */ public function width(): int; /** * Get height - * - * @return int */ public function height(): int; /** * Get pivot point - * - * @return PointInterface */ public function pivot(): PointInterface; /** * Set width - * - * @param int $width - * @return SizeInterface */ public function setWidth(int $width): self; /** * Set height - * - * @param int $height - * @return SizeInterface */ public function setHeight(int $height): self; /** * Set pivot point - * - * @param PointInterface $pivot - * @return SizeInterface */ public function setPivot(PointInterface $pivot): self; /** * Calculate aspect ratio of the current size - * - * @return float */ public function aspectRatio(): float; /** * Determine if current size fits into given size - * - * @param SizeInterface $size - * @return bool */ public function fitsInto(self $size): bool; /** * Determine if size is in landscape format - * - * @return bool */ public function isLandscape(): bool; /** * Determine if size is in portrait format - * - * @return bool */ public function isPortrait(): bool; /** * Move pivot to given position in size - * - * @param string $position - * @param int $offset_x - * @param int $offset_y - * @return SizeInterface */ public function movePivot(string $position, int $offset_x = 0, int $offset_y = 0): self; /** * Align pivot of current object to given position - * - * @param SizeInterface $size - * @param string $position - * @return SizeInterface */ public function alignPivotTo(self $size, string $position): self; /** * Calculate the relative position to another Size * based on the pivot point settings of both sizes. - * - * @param SizeInterface $size - * @return PointInterface */ public function relativePositionTo(self $size): PointInterface; diff --git a/src/Interfaces/SpecializableInterface.php b/src/Interfaces/SpecializableInterface.php index 5c188d01..ce964998 100644 --- a/src/Interfaces/SpecializableInterface.php +++ b/src/Interfaces/SpecializableInterface.php @@ -19,16 +19,12 @@ interface SpecializableInterface /** * Set the driver for which the object is specialized * - * @param DriverInterface $driver * @throws DriverException - * @return SpecializableInterface */ public function setDriver(DriverInterface $driver): self; /** * Return the driver for which the object was specialized - * - * @return DriverInterface */ public function driver(): DriverInterface; } diff --git a/src/MediaType.php b/src/MediaType.php index ff11b2ff..7718a549 100644 --- a/src/MediaType.php +++ b/src/MediaType.php @@ -43,7 +43,6 @@ enum MediaType: string * * @param string|Format|MediaType|FileExtension $identifier * @throws NotSupportedException - * @return MediaType */ public static function create(string|self|Format|FileExtension $identifier): self { @@ -89,8 +88,6 @@ enum MediaType: string /** * Return the matching format for the current media (MIME) type - * - * @return Format */ public function format(): Format { @@ -138,8 +135,6 @@ enum MediaType: string /** * Return the first file extension for the current media type - * - * @return FileExtension */ public function fileExtension(): FileExtension { diff --git a/src/ModifierStack.php b/src/ModifierStack.php index 215ac27e..aacfa15a 100644 --- a/src/ModifierStack.php +++ b/src/ModifierStack.php @@ -22,9 +22,6 @@ class ModifierStack implements ModifierInterface /** * Apply all modifiers in stack to the given image - * - * @param ImageInterface $image - * @return ImageInterface */ public function apply(ImageInterface $image): ImageInterface { @@ -37,9 +34,6 @@ class ModifierStack implements ModifierInterface /** * Append new modifier to the stack - * - * @param ModifierInterface $modifier - * @return ModifierStack */ public function push(ModifierInterface $modifier): self { diff --git a/src/Modifiers/AbstractDrawModifier.php b/src/Modifiers/AbstractDrawModifier.php index 3c10e0fb..123b1638 100644 --- a/src/Modifiers/AbstractDrawModifier.php +++ b/src/Modifiers/AbstractDrawModifier.php @@ -14,8 +14,6 @@ abstract class AbstractDrawModifier extends SpecializableModifier { /** * Return the drawable object which will be rendered by the modifier - * - * @return DrawableInterface */ abstract public function drawable(): DrawableInterface; diff --git a/src/Modifiers/BlendTransparencyModifier.php b/src/Modifiers/BlendTransparencyModifier.php index 2e82759a..ab074f23 100644 --- a/src/Modifiers/BlendTransparencyModifier.php +++ b/src/Modifiers/BlendTransparencyModifier.php @@ -19,7 +19,6 @@ class BlendTransparencyModifier extends SpecializableModifier /** * Create new modifier object * - * @param mixed $color * @return void */ public function __construct(public mixed $color = null) @@ -33,7 +32,6 @@ class BlendTransparencyModifier extends SpecializableModifier * * @throws RuntimeException * @throws ColorException - * @return ColorInterface */ protected function blendingColor(DriverInterface $driver): ColorInterface { diff --git a/src/Modifiers/ColorizeModifier.php b/src/Modifiers/ColorizeModifier.php index 34a7d94d..e000d67b 100644 --- a/src/Modifiers/ColorizeModifier.php +++ b/src/Modifiers/ColorizeModifier.php @@ -11,9 +11,6 @@ class ColorizeModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $red - * @param int $green - * @param int $blue * @return void */ public function __construct( diff --git a/src/Modifiers/ContrastModifier.php b/src/Modifiers/ContrastModifier.php index dfa0074d..77f7b17e 100644 --- a/src/Modifiers/ContrastModifier.php +++ b/src/Modifiers/ContrastModifier.php @@ -11,7 +11,6 @@ class ContrastModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $level * @return void */ public function __construct(public int $level) diff --git a/src/Modifiers/CoverModifier.php b/src/Modifiers/CoverModifier.php index a8ff2363..72a65977 100644 --- a/src/Modifiers/CoverModifier.php +++ b/src/Modifiers/CoverModifier.php @@ -15,9 +15,6 @@ class CoverModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $width - * @param int $height - * @param string $position * @return void */ public function __construct( diff --git a/src/Modifiers/CropModifier.php b/src/Modifiers/CropModifier.php index 8cdcb032..c9aa5855 100644 --- a/src/Modifiers/CropModifier.php +++ b/src/Modifiers/CropModifier.php @@ -15,12 +15,6 @@ class CropModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $width - * @param int $height - * @param int $offset_x - * @param int $offset_y - * @param mixed $background - * @param string $position * @return void */ public function __construct( diff --git a/src/Modifiers/DrawBezierModifier.php b/src/Modifiers/DrawBezierModifier.php index c7f2238c..d4e14e3c 100644 --- a/src/Modifiers/DrawBezierModifier.php +++ b/src/Modifiers/DrawBezierModifier.php @@ -12,7 +12,6 @@ class DrawBezierModifier extends AbstractDrawModifier /** * Create new modifier object * - * @param Bezier $drawable * @return void */ public function __construct(public Bezier $drawable) @@ -22,8 +21,6 @@ class DrawBezierModifier extends AbstractDrawModifier /** * Return object to be drawn - * - * @return DrawableInterface */ public function drawable(): DrawableInterface { diff --git a/src/Modifiers/DrawLineModifier.php b/src/Modifiers/DrawLineModifier.php index c6bf5260..26a86e37 100644 --- a/src/Modifiers/DrawLineModifier.php +++ b/src/Modifiers/DrawLineModifier.php @@ -12,7 +12,6 @@ class DrawLineModifier extends AbstractDrawModifier /** * Create new modifier object * - * @param Line $drawable * @return void */ public function __construct(public Line $drawable) @@ -22,8 +21,6 @@ class DrawLineModifier extends AbstractDrawModifier /** * Return object to be drawn - * - * @return DrawableInterface */ public function drawable(): DrawableInterface { diff --git a/src/Modifiers/DrawPixelModifier.php b/src/Modifiers/DrawPixelModifier.php index 305acf19..3faeabcf 100644 --- a/src/Modifiers/DrawPixelModifier.php +++ b/src/Modifiers/DrawPixelModifier.php @@ -12,8 +12,6 @@ class DrawPixelModifier extends SpecializableModifier /** * Create new modifier object * - * @param PointInterface $position - * @param mixed $color * @return void */ public function __construct( diff --git a/src/Modifiers/DrawRectangleModifier.php b/src/Modifiers/DrawRectangleModifier.php index a018f960..005b79a8 100644 --- a/src/Modifiers/DrawRectangleModifier.php +++ b/src/Modifiers/DrawRectangleModifier.php @@ -12,7 +12,6 @@ class DrawRectangleModifier extends AbstractDrawModifier /** * Create new modifier object * - * @param Rectangle $drawable * @return void */ public function __construct(public Rectangle $drawable) @@ -22,8 +21,6 @@ class DrawRectangleModifier extends AbstractDrawModifier /** * Return object to be drawn - * - * @return DrawableInterface */ public function drawable(): DrawableInterface { diff --git a/src/Modifiers/PlaceModifier.php b/src/Modifiers/PlaceModifier.php index 3fe9c4bd..5e86fc1b 100644 --- a/src/Modifiers/PlaceModifier.php +++ b/src/Modifiers/PlaceModifier.php @@ -14,11 +14,6 @@ class PlaceModifier extends SpecializableModifier /** * Create new modifier object * - * @param mixed $element - * @param string $position - * @param int $offset_x - * @param int $offset_y - * @param int $opacity * @return void */ public function __construct( diff --git a/src/Modifiers/QuantizeColorsModifier.php b/src/Modifiers/QuantizeColorsModifier.php index 1a4bf4f5..193c12b1 100644 --- a/src/Modifiers/QuantizeColorsModifier.php +++ b/src/Modifiers/QuantizeColorsModifier.php @@ -11,8 +11,6 @@ class QuantizeColorsModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $limit - * @param mixed $background * @return void */ public function __construct( diff --git a/src/Modifiers/RemoveAnimationModifier.php b/src/Modifiers/RemoveAnimationModifier.php index 8530cc85..a72697fa 100644 --- a/src/Modifiers/RemoveAnimationModifier.php +++ b/src/Modifiers/RemoveAnimationModifier.php @@ -28,9 +28,7 @@ class RemoveAnimationModifier extends SpecializableModifier /** * Return the position of the selected frame as integer * - * @param ImageInterface $image * @throws InputException - * @return int */ protected function normalizePosition(ImageInterface $image): int { diff --git a/src/Modifiers/ResizeCanvasModifier.php b/src/Modifiers/ResizeCanvasModifier.php index 6ef313f5..ae42b7a5 100644 --- a/src/Modifiers/ResizeCanvasModifier.php +++ b/src/Modifiers/ResizeCanvasModifier.php @@ -15,10 +15,6 @@ class ResizeCanvasModifier extends SpecializableModifier /** * Create new modifier object * - * @param null|int $width - * @param null|int $height - * @param mixed $background - * @param string $position * @return void */ public function __construct( @@ -33,10 +29,7 @@ class ResizeCanvasModifier extends SpecializableModifier /** * Build the crop size to be used for the ResizeCanvas process * - * @param ImageInterface $image - * @param bool $relative * @throws RuntimeException - * @return SizeInterface */ protected function cropSize(ImageInterface $image, bool $relative = false): SizeInterface { diff --git a/src/Modifiers/ResizeModifier.php b/src/Modifiers/ResizeModifier.php index 0faf8694..1b48615b 100644 --- a/src/Modifiers/ResizeModifier.php +++ b/src/Modifiers/ResizeModifier.php @@ -11,8 +11,6 @@ class ResizeModifier extends SpecializableModifier /** * Create new modifier object * - * @param null|int $width - * @param null|int $height * @return void */ public function __construct(public ?int $width = null, public ?int $height = null) diff --git a/src/Modifiers/ResolutionModifier.php b/src/Modifiers/ResolutionModifier.php index 6bb68cd9..9d66378e 100644 --- a/src/Modifiers/ResolutionModifier.php +++ b/src/Modifiers/ResolutionModifier.php @@ -11,8 +11,6 @@ class ResolutionModifier extends SpecializableModifier /** * Create new modifier object * - * @param float $x - * @param float $y * @return void */ public function __construct(public float $x, public float $y) diff --git a/src/Modifiers/RotateModifier.php b/src/Modifiers/RotateModifier.php index 3d0e73a0..15b758d9 100644 --- a/src/Modifiers/RotateModifier.php +++ b/src/Modifiers/RotateModifier.php @@ -16,8 +16,6 @@ class RotateModifier extends SpecializableModifier /** * Restrict rotations beyond 360 degrees * because the end result is the same - * - * @return float */ public function rotationAngle(): float { diff --git a/src/Modifiers/TextModifier.php b/src/Modifiers/TextModifier.php index 86bbcf4d..b48772ea 100644 --- a/src/Modifiers/TextModifier.php +++ b/src/Modifiers/TextModifier.php @@ -17,9 +17,6 @@ class TextModifier extends SpecializableModifier /** * Create new modifier object * - * @param string $text - * @param PointInterface $position - * @param FontInterface $font * @return void */ public function __construct( @@ -40,7 +37,6 @@ class TextModifier extends SpecializableModifier * * @throws RuntimeException * @throws ColorException - * @return ColorInterface */ protected function textColor(): ColorInterface { @@ -60,7 +56,6 @@ class TextModifier extends SpecializableModifier * * @throws RuntimeException * @throws ColorException - * @return ColorInterface */ protected function strokeColor(): ColorInterface { @@ -78,7 +73,6 @@ class TextModifier extends SpecializableModifier /** * Return array of offset points to draw text stroke effect below the actual text * - * @param FontInterface $font * @return array */ protected function strokeOffsets(FontInterface $font): array diff --git a/src/Modifiers/TrimModifier.php b/src/Modifiers/TrimModifier.php index 18bf1a85..6d7959b3 100644 --- a/src/Modifiers/TrimModifier.php +++ b/src/Modifiers/TrimModifier.php @@ -11,7 +11,6 @@ class TrimModifier extends SpecializableModifier /** * Create new modifier object * - * @param int $tolerance * @return void */ public function __construct(public int $tolerance = 0) diff --git a/src/Origin.php b/src/Origin.php index f0f2c262..522a7f21 100644 --- a/src/Origin.php +++ b/src/Origin.php @@ -9,8 +9,6 @@ class Origin /** * Create new origin instance * - * @param string $mediaType - * @param null|string $filePath * @return void */ public function __construct( @@ -22,8 +20,6 @@ class Origin /** * Return media type of origin - * - * @return string */ public function mediaType(): string { @@ -40,9 +36,6 @@ class Origin /** * Set media type of current instance - * - * @param string|MediaType $type - * @return Origin */ public function setMediaType(string|MediaType $type): self { @@ -56,8 +49,6 @@ class Origin /** * Return file path of origin - * - * @return null|string */ public function filePath(): ?string { @@ -66,9 +57,6 @@ class Origin /** * Set file path for origin - * - * @param string $path - * @return Origin */ public function setFilePath(string $path): self { @@ -79,8 +67,6 @@ class Origin /** * Return file extension if origin was created from file path - * - * @return null|string */ public function fileExtension(): ?string { diff --git a/src/Resolution.php b/src/Resolution.php index 1e614ce3..64ab07c6 100644 --- a/src/Resolution.php +++ b/src/Resolution.php @@ -20,10 +20,6 @@ class Resolution implements ResolutionInterface, Stringable, IteratorAggregate /** * Create new instance - * - * @param float $x - * @param float $y - * @param int $per_unit */ public function __construct( protected float $x, diff --git a/src/Traits/CanBeDriverSpecialized.php b/src/Traits/CanBeDriverSpecialized.php index eb597be3..5671c63d 100644 --- a/src/Traits/CanBeDriverSpecialized.php +++ b/src/Traits/CanBeDriverSpecialized.php @@ -13,8 +13,6 @@ trait CanBeDriverSpecialized { /** * The driver with which the instance may be specialized - * - * @var DriverInterface */ protected DriverInterface $driver; @@ -67,9 +65,6 @@ trait CanBeDriverSpecialized /** * Determine if the given object belongs to the driver's namespace - * - * @param object $object - * @return bool */ protected function belongsToDriver(object $object): bool { diff --git a/src/Typography/FontFactory.php b/src/Typography/FontFactory.php index 78d7071a..72590126 100644 --- a/src/Typography/FontFactory.php +++ b/src/Typography/FontFactory.php @@ -30,9 +30,6 @@ class FontFactory /** * Set the filename of the font to be built - * - * @param string $value - * @return FontFactory */ public function filename(string $value): self { @@ -54,10 +51,7 @@ class FontFactory /** * Set outline stroke effect for the font to be built * - * @param mixed $color - * @param int $width * @throws FontException - * @return FontFactory */ public function stroke(mixed $color, int $width = 1): self { @@ -69,9 +63,6 @@ class FontFactory /** * Set color for the font to be built - * - * @param mixed $value - * @return FontFactory */ public function color(mixed $value): self { @@ -82,9 +73,6 @@ class FontFactory /** * Set the size for the font to be built - * - * @param float $value - * @return FontFactory */ public function size(float $value): self { @@ -95,9 +83,6 @@ class FontFactory /** * Set the horizontal alignment of the font to be built - * - * @param string $value - * @return FontFactory */ public function align(string $value): self { @@ -108,9 +93,6 @@ class FontFactory /** * Set the vertical alignment of the font to be built - * - * @param string $value - * @return FontFactory */ public function valign(string $value): self { @@ -121,9 +103,6 @@ class FontFactory /** * Set the line height of the font to be built - * - * @param float $value - * @return FontFactory */ public function lineHeight(float $value): self { @@ -134,9 +113,6 @@ class FontFactory /** * Set the rotation angle of the font to be built - * - * @param float $value - * @return FontFactory */ public function angle(float $value): self { @@ -147,9 +123,6 @@ class FontFactory /** * Set the maximum width of the text block to be built - * - * @param int $width - * @return FontFactory */ public function wrap(int $width): self { @@ -160,8 +133,6 @@ class FontFactory /** * Build font - * - * @return FontInterface */ public function __invoke(): FontInterface { diff --git a/src/Typography/Line.php b/src/Typography/Line.php index 62652192..aeb0cca1 100644 --- a/src/Typography/Line.php +++ b/src/Typography/Line.php @@ -28,7 +28,6 @@ class Line implements IteratorAggregate, Countable, Stringable * Create new text line object with given text & position * * @param string $text - * @param PointInterface $position * @return void */ public function __construct( @@ -42,9 +41,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Add word to current line - * - * @param string $word - * @return Line */ public function add(string $word): self { @@ -65,8 +61,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Get Position of line - * - * @return PointInterface */ public function position(): PointInterface { @@ -75,9 +69,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Set position of current line - * - * @param PointInterface $point - * @return Line */ public function setPosition(PointInterface $point): self { @@ -88,8 +79,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Count segments (individual words including punctuation marks) of line - * - * @return int */ public function count(): int { @@ -98,8 +87,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Count characters of line - * - * @return int */ public function length(): int { @@ -125,8 +112,6 @@ class Line implements IteratorAggregate, Countable, Stringable /** * Cast line to string - * - * @return string */ public function __toString(): string { diff --git a/src/Typography/TextBlock.php b/src/Typography/TextBlock.php index 8a40887a..67f6969e 100644 --- a/src/Typography/TextBlock.php +++ b/src/Typography/TextBlock.php @@ -11,7 +11,6 @@ class TextBlock extends Collection /** * Create new text block object * - * @param string $text * @return void */ public function __construct(string $text) @@ -35,7 +34,6 @@ class TextBlock extends Collection * Set lines of the text block * * @param array $lines - * @return self */ public function setLines(array $lines): self { @@ -48,7 +46,6 @@ class TextBlock extends Collection * Get line by given key * * @param mixed $key - * @return null|Line */ public function line($key): ?Line { @@ -61,8 +58,6 @@ class TextBlock extends Collection /** * Return line with most characters of text block - * - * @return Line */ public function longestLine(): Line { diff --git a/tests/BaseTestCase.php b/tests/BaseTestCase.php index 9c81589f..3b162c29 100644 --- a/tests/BaseTestCase.php +++ b/tests/BaseTestCase.php @@ -38,12 +38,6 @@ abstract class BaseTestCase extends MockeryTestCase /** * Assert that given color equals the given color channel values in the given optional tolerance * - * @param int $r - * @param int $g - * @param int $b - * @param int $a - * @param ColorInterface $color - * @param int $tolerance * @throws ExpectationFailedException * @return void */ diff --git a/tests/ImagickTestCase.php b/tests/ImagickTestCase.php index 051d497a..6c4f8ecc 100644 --- a/tests/ImagickTestCase.php +++ b/tests/ImagickTestCase.php @@ -24,10 +24,7 @@ abstract class ImagickTestCase extends BaseTestCase /** * Create test image with red (#ff0000) background * - * @param int $width - * @param int $height * @throws ImagickException - * @return Image */ public static function createTestImage(int $width, int $height): Image { diff --git a/tests/Traits/CanDetectProgressiveJpeg.php b/tests/Traits/CanDetectProgressiveJpeg.php index b945d2b2..887c3a7c 100644 --- a/tests/Traits/CanDetectProgressiveJpeg.php +++ b/tests/Traits/CanDetectProgressiveJpeg.php @@ -15,7 +15,6 @@ trait CanDetectProgressiveJpeg * Checks if the given image data is progressive encoded Jpeg format * * @param EncodedImage $imagedata - * @return bool */ private function isProgressiveJpeg(EncodedImage $image): bool { diff --git a/tests/Traits/CanInspectPngFormat.php b/tests/Traits/CanInspectPngFormat.php index bb290d8e..f1ac466a 100644 --- a/tests/Traits/CanInspectPngFormat.php +++ b/tests/Traits/CanInspectPngFormat.php @@ -13,9 +13,6 @@ trait CanInspectPngFormat /** * Checks if the given image data is interlaced encoded PNG format - * - * @param EncodedImage $image - * @return bool */ private function isInterlacedPng(EncodedImage $image): bool { @@ -28,9 +25,6 @@ trait CanInspectPngFormat /** * Try to detect PNG color type from given binary data - * - * @param EncodedImage $image - * @return string */ private function pngColorType(EncodedImage $image): string {