1
0
mirror of https://github.com/php/php-src.git synced 2026-03-26 09:12:14 +01:00
Files
archived-php-src/ext/spl/spl_fixedarray.stub.php
Nikita Popov 805471e86b Fix bug #81112: Implement JsonSerializable for SplFixedArray
This returns an array for SplFixedArray JSON encoding, which
is more appropriate than an object with integer string keys.

Closes GH-7117.
2021-06-14 10:07:45 +02:00

55 lines
1.1 KiB
PHP

<?php
/** @generate-class-entries */
class SplFixedArray implements IteratorAggregate, ArrayAccess, Countable, JsonSerializable
{
public function __construct(int $size = 0) {}
/** @return void */
public function __wakeup() {}
/** @return int */
public function count() {}
/** @return array */
public function toArray() {}
/** @return SplFixedArray */
public static function fromArray(array $array, bool $preserveKeys = true) {}
/** @return int */
public function getSize() {}
/** @return bool */
public function setSize(int $size) {}
/**
* @param int $index
* @return bool
*/
public function offsetExists($index) {}
/**
* @param int $index
* @return mixed
*/
public function offsetGet($index) {}
/**
* @param int $index
* @return void
*/
public function offsetSet($index, mixed $value) {}
/**
* @param int $index
* @return void
*/
public function offsetUnset($index) {}
public function getIterator(): Iterator {}
public function jsonSerialize(): array {}
}