mirror of
https://github.com/Intervention/image.git
synced 2025-08-18 19:51:22 +02:00
Remove redundant code & double doc blocks
This commit is contained in:
@@ -21,9 +21,9 @@ class EncodedImage extends File implements EncodedImageInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return media (mime) type of encoed image data
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return string
|
* @see EncodedImageInterface::mediaType()
|
||||||
*/
|
*/
|
||||||
public function mediaType(): string
|
public function mediaType(): string
|
||||||
{
|
{
|
||||||
@@ -31,9 +31,9 @@ class EncodedImage extends File implements EncodedImageInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Alias of self::mediaType()
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return string
|
* @see EncodedImageInterface::mimetype()
|
||||||
*/
|
*/
|
||||||
public function mimetype(): string
|
public function mimetype(): string
|
||||||
{
|
{
|
||||||
@@ -41,9 +41,9 @@ class EncodedImage extends File implements EncodedImageInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Transform encoded image data into an data uri string
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return string
|
* @see EncodedImageInterface::toDataUri()
|
||||||
*/
|
*/
|
||||||
public function toDataUri(): string
|
public function toDataUri(): string
|
||||||
{
|
{
|
||||||
|
22
src/File.php
22
src/File.php
@@ -22,11 +22,9 @@ class File implements FileInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Save encoded image data in file system
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @codeCoverageIgnore
|
* @see FileInterface::save()
|
||||||
* @param string $filepath
|
|
||||||
* @return void
|
|
||||||
*/
|
*/
|
||||||
public function save(string $filepath): void
|
public function save(string $filepath): void
|
||||||
{
|
{
|
||||||
@@ -54,9 +52,9 @@ class File implements FileInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Cast encoded image object to string
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return string
|
* @see FilterInterface::toString()
|
||||||
*/
|
*/
|
||||||
public function toString(): string
|
public function toString(): string
|
||||||
{
|
{
|
||||||
@@ -64,9 +62,9 @@ class File implements FileInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create file pointer from encoded image
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return resource
|
* @see FilterInterface::toFilePointer()
|
||||||
*/
|
*/
|
||||||
public function toFilePointer()
|
public function toFilePointer()
|
||||||
{
|
{
|
||||||
@@ -74,9 +72,9 @@ class File implements FileInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return byte size of encoded image
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return int
|
* @see FileInterface::size()
|
||||||
*/
|
*/
|
||||||
public function size(): int
|
public function size(): int
|
||||||
{
|
{
|
||||||
@@ -84,9 +82,9 @@ class File implements FileInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Cast encoded image object to string
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @return string
|
* @see FileInterface::__toString()
|
||||||
*/
|
*/
|
||||||
public function __toString(): string
|
public function __toString(): string
|
||||||
{
|
{
|
||||||
|
@@ -21,45 +21,9 @@ interface EncodedImageInterface extends FileInterface
|
|||||||
public function mimetype(): string;
|
public function mimetype(): string;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Turn encoded image into DataUri format
|
* Transform encoded image data into an data uri string
|
||||||
*
|
*
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function toDataUri(): string;
|
public function toDataUri(): string;
|
||||||
|
|
||||||
/**
|
|
||||||
* Save encoded image in filesystem
|
|
||||||
*
|
|
||||||
* @param string $filepath
|
|
||||||
* @return void
|
|
||||||
*/
|
|
||||||
public function save(string $filepath): void;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Cast encoded image to string
|
|
||||||
*
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function toString(): string;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Return file pointer of encoded image data
|
|
||||||
*
|
|
||||||
* @return resource
|
|
||||||
*/
|
|
||||||
public function toFilePointer();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Return size in bytes of encoded image
|
|
||||||
*
|
|
||||||
* @return int
|
|
||||||
*/
|
|
||||||
public function size(): int;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Cast encoded image data to string
|
|
||||||
*
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function __toString(): string;
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user