Results of 1 - 10 of about 23 for Slice (0.001 sec.)
- Ds\Deque::slice — Returns a sub-deque of a given range | PHP 8.3 11210
- Ds\Deque::slice (PECL ds >= 1.0.0) Ds\Deque::slice — Returns a sub-deque of a given range 説明 public function Ds\Deque::slice ( int $index , int $length = ? ): Ds\Deque Creates a sub-deque of a given range. パラメータ index The index at wh
... ill contain all values between the index and the end of the deque. 戻り値 A sub-deque of the given range. 例 例1 Ds\Deque::slice() example <?php $deque = new \Ds\Deque ([ "a" , "b" , "c" , "d" , "e" ]); // Slice from 2 onwards print_r ( $deque -> slic ... e ( 2 )); // Slice from 1, for a length of 3 print_r ( $deque -> slice ( 1 , 3 )); // Slice from 1 onwards print_r ( $deque -> slice ( 1 )); ... // Slice from 2 from the end onwards print_r ( $deque -> slice (- 2 )); // Slice from 1 to 1 from the end print_r ( $deque -> slice ...
-
https://man.mtool.work/php/8.3/ds-deque.slice.html
- Ds\Sequence::slice — Returns a sub-sequence of a given range | PHP 8.3 11210
- Ds\Sequence::slice (PECL ds >= 1.0.0) Ds\Sequence::slice — Returns a sub-sequence of a given range 説明 abstract public function Ds\Sequence::slice ( int $index , int $length = ? ): Ds\Sequence Creates a sub-sequence of a given range. パラメ
... in all values between the index and the end of the sequence. 戻り値 A sub-sequence of the given range. 例 例1 Ds\Sequence::slice() example <?php $sequence = new \Ds\Vector ([ "a" , "b" , "c" , "d" , "e" ]); // Slice from 2 onwards print_r ( $sequence ... -> slice ( 2 )); // Slice from 1, for a length of 3 print_r ( $sequence -> slice ( 1 , 3 )); // Slice from 1 onwards print_r ( $seq ... uence -> slice ( 1 )); // Slice from 2 from the end onwards print_r ( $sequence -> slice (- 2 )); // Slice from 1 to 1 from the end print ...
-
https://man.mtool.work/php/8.3/ds-sequence.slice.html
- Ds\Set::slice — Returns a sub-set of a given range | PHP 8.3 11210
- Ds\Set::slice (PECL ds >= 1.0.0) Ds\Set::slice — Returns a sub-set of a given range 説明 public function Ds\Set::slice ( int $index , int $length = ? ): Ds\Set Creates a sub-set of a given range. パラメータ index The index at which the sub-
... set will contain all values between the index and the end of the set. 戻り値 A sub-set of the given range. 例 例1 Ds\Set::slice() example <?php $set = new \Ds\Set ([ "a" , "b" , "c" , "d" , "e" ]); // Slice from 2 onwards print_r ( $set -> slice ( 2 ... )); // Slice from 1, for a length of 3 print_r ( $set -> slice ( 1 , 3 )); // Slice from 1 onwards print_r ( $set -> slice ( 1 )); // S ... lice from 2 from the end onwards print_r ( $set -> slice (- 2 )); // Slice from 1 to 1 from the end print_r ( $set -> slice ( 1 , - 1 )); ?> 上の例の出力は、 たとえば以下のようにな ...
-
https://man.mtool.work/php/8.3/ds-set.slice.html
- Ds\Vector::slice — Returns a sub-vector of a given range | PHP 8.3 11210
- Ds\Vector::slice (PECL ds >= 1.0.0) Ds\Vector::slice — Returns a sub-vector of a given range 説明 public function Ds\Vector::slice ( int $index , int $length = ? ): Ds\Vector Creates a sub-vector of a given range. パラメータ index The index
... contain all values between the index and the end of the vector. 戻り値 A sub-vector of the given range. 例 例1 Ds\Vector::slice() example <?php $vector = new \Ds\Vector ([ "a" , "b" , "c" , "d" , "e" ]); // Slice from 2 onwards print_r ( $vector -> s ... lice ( 2 )); // Slice from 1, for a length of 3 print_r ( $vector -> slice ( 1 , 3 )); // Slice from 1 onwards print_r ( $vector -> slice ( 1 )) ... ; // Slice from 2 from the end onwards print_r ( $vector -> slice (- 2 )); // Slice from 1 to 1 from the end print_r ( $vector -> sli ...
-
https://man.mtool.work/php/8.3/ds-vector.slice.html
- Ds\Map::slice — Returns a subset of the map defined by a starting index and len... 11193
- Ds\Map::slice (PECL ds >= 1.0.0) Ds\Map::slice — Returns a subset of the map defined by a starting index and length 説明 public function Ds\Map::slice ( int $index , int $length = ? ): Ds\Map Returns a subset of the map defined by a startin
... etween the index and the end of the map. 戻り値 A subset of the map defined by a starting index and length. 例 例1 Ds\Map::slice() example <?php $map = new \Ds\Map ([ "a" => 1 , "b" => 2 , "c" => 3 , "d" => 4 , "e" => 5 ]); // Slice from 2 onwards pri ... nt_r ( $map -> slice ( 2 )-> toArray ()); // Slice from 1, for a length of 3 print_r ( $map -> slice ( 1 , 3 )-> toArray ()); // Slice from 1 o ... nwards print_r ( $map -> slice ( 1 )-> toArray ()); // Slice from 2 from the end onwards print_r ( $map -> slice (- 2 )-> toArray ()); // Slice from 1 to ...
-
https://man.mtool.work/php/8.3/ds-map.slice.html
- array_slice — 配列の一部を展開する | PHP 8.3 11026
- array_slice (PHP 4, PHP 5, PHP 7, PHP 8) array_slice — 配列の一部を展開する 説明 function array_slice ( array $array , int $offset , ? int $length = null , bool $preserve_keys = false ): array array_slice() は、 array から引数 offset および
... 取り除いた配列が返されます。 省略された場合、 offset から配列の最後までの全ての要素が返されます。 preserve_keys 注意 : array_slice() はデフォルトで配列の数値キーを並べなおし、 リセットします。 preserve_keys を true にする事でこの動作を変更することができ ... 保存されます。 戻り値 切り取った部分を返します。オフセットが配列のサイズより大きい場合は、空の配列を返します。 例 例1 array_slice() の例 <?php $input = array( "a" , "b" , "c" , "d" , "e" ); $output = array_slice ( $input , 2 ); // "c", "d", "e" を返す ... $output = array_slice ( $input , - 2 , 1 ); // "d" を返す $output = array_slice ( $input , 0 , 3 ); // "a", "b", "c" を返す // 配列キーの違いに注 ...
-
https://man.mtool.work/php/8.3/function.array-slice.html
- Data Structures | PHP 8.3 7724
- Data Structures はじめに Efficient data structures for PHP 7, provided as an alternative to the array . See » this blog post for benchmarks, discussion and frequently asked questions. インストール/設定 要件 インストール手順 例 Ds\Collection
... Ds\Sequence::set — Updates a value at a given index Ds\Sequence::shift — Removes and returns the first value Ds\Sequence::slice — Returns a sub-sequence of a given range Ds\Sequence::sort — Sorts the sequence in-place Ds\Sequence::sorted — Returns a ... ations Ds\Vector::set — Updates a value at a given index Ds\Vector::shift — Removes and returns the first value Ds\Vector::slice — Returns a sub-vector of a given range Ds\Vector::sort — Sorts the vector in-place Ds\Vector::sorted — Returns a sorted c ... rotations Ds\Deque::set — Updates a value at a given index Ds\Deque::shift — Removes and returns the first value Ds\Deque::slice — Returns a sub-deque of a given range Ds\Deque::sort — Sorts the deque in-place Ds\Deque::sorted — Returns a sorted copy ...
-
https://man.mtool.work/php/8.3/book.ds.html
- The Sequence interface | PHP 8.3 7507
- The Sequence interface (PECL ds >= 1.0.0) はじめに A Sequence describes the behaviour of values arranged in a single, linear dimension. Some languages refer to this as a "List". It's similar to an array that uses incremental integer keys, w
... public function set ( int $index , mixed $value ): void abstract public function shift (): mixed abstract public function slice ( int $index , int $length = ? ): Ds\Sequence abstract public function sort ( callable $comparator = ? ): void abstract pu ... Ds\Sequence::set — Updates a value at a given index Ds\Sequence::shift — Removes and returns the first value Ds\Sequence::slice — Returns a sub-sequence of a given range Ds\Sequence::sort — Sorts the sequence in-place Ds\Sequence::sorted — Returns a ...
-
https://man.mtool.work/php/8.3/class.ds-sequence.html
- The Set class | PHP 8.3 7507
- The Set class (PECL ds >= 1.0.0) はじめに A Set is a sequence of unique values. This implementation uses the same hash table as Ds\Map , where values are used as keys and the mapped value is ignored. Strengths Values can be any type, includ
... ion remove ( mixed ...$values ): void public function reverse (): void public function reversed (): Ds\Set public function slice ( int $index , int $length = ? ): Ds\Set public function sort ( callable $comparator = ? ): void public function sorted ( ... l given values from the set Ds\Set::reverse — Reverses the set in-place Ds\Set::reversed — Returns a reversed copy Ds\Set::slice — Returns a sub-set of a given range Ds\Set::sort — Sorts the set in-place Ds\Set::sorted — Returns a sorted copy Ds\Set:: ...
-
https://man.mtool.work/php/8.3/class.ds-set.html
- The Vector class | PHP 8.3 7507
- The Vector class (PECL ds >= 1.0.0) はじめに A Vector is a sequence of values in a contiguous buffer that grows and shrinks automatically. It's the most efficient sequential structure because a value's index is a direct mapping to its index
... $rotations ): void public function set ( int $index , mixed $value ): void public function shift (): mixed public function slice ( int $index , int $length = ? ): Ds\Vector public function sort ( callable $comparator = ? ): void public function sorted ... ations Ds\Vector::set — Updates a value at a given index Ds\Vector::shift — Removes and returns the first value Ds\Vector::slice — Returns a sub-vector of a given range Ds\Vector::sort — Sorts the vector in-place Ds\Vector::sorted — Returns a sorted c ...
-
https://man.mtool.work/php/8.3/class.ds-vector.html