|
Ds\Map::sliceReturns a subset of the map defined by a starting index and length 説明
public Ds\Map Ds\Map::slice(int
$index , int $length = ?)
Returns a subset of the map defined by a starting パラメータ
戻り値A subset of the map defined by a starting index and length. 例例1 Ds\Map::slice example
上の例の出力は、 たとえば以下のようになります。 Array ( [c] => 3 [d] => 4 [e] => 5 ) Array ( [b] => 2 [c] => 3 [d] => 4 ) Array ( [b] => 2 [c] => 3 [d] => 4 [e] => 5 ) Array ( [d] => 4 [e] => 5 ) Array ( [b] => 2 [c] => 3 [d] => 4 ) |