This commit is contained in:
Paolo A
2024-08-13 13:44:16 +00:00
parent 1bbb23088d
commit e796d76612
4001 changed files with 30101 additions and 40075 deletions

View File

@@ -129,8 +129,7 @@ interface QueueInterface extends ArrayInterface
* Implementations should use a more-specific exception that extends
* `\RuntimeException`.
*/
// phpcs:ignore SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint
public function add($element): bool;
public function add(mixed $element): bool;
/**
* Retrieves, but does not remove, the head of this queue.
@@ -144,7 +143,7 @@ interface QueueInterface extends ArrayInterface
*
* @throws NoSuchElementException if this queue is empty.
*/
public function element();
public function element(): mixed;
/**
* Inserts the specified element into this queue if it is possible to do so
@@ -160,8 +159,7 @@ interface QueueInterface extends ArrayInterface
*
* @return bool `true` if the element was added to this queue, else `false`.
*/
// phpcs:ignore SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint
public function offer($element): bool;
public function offer(mixed $element): bool;
/**
* Retrieves, but does not remove, the head of this queue, or returns `null`
@@ -169,9 +167,9 @@ interface QueueInterface extends ArrayInterface
*
* @see self::element()
*
* @return T|null the head of this queue, or `null` if this queue is empty.
* @return T | null the head of this queue, or `null` if this queue is empty.
*/
public function peek();
public function peek(): mixed;
/**
* Retrieves and removes the head of this queue, or returns `null`
@@ -179,9 +177,9 @@ interface QueueInterface extends ArrayInterface
*
* @see self::remove()
*
* @return T|null the head of this queue, or `null` if this queue is empty.
* @return T | null the head of this queue, or `null` if this queue is empty.
*/
public function poll();
public function poll(): mixed;
/**
* Retrieves and removes the head of this queue.
@@ -195,7 +193,7 @@ interface QueueInterface extends ArrayInterface
*
* @throws NoSuchElementException if this queue is empty.
*/
public function remove();
public function remove(): mixed;
/**
* Returns the type associated with this queue.