Skip to content

Releases: xp-forge/sequence

2.1.1: Bugfix with sorted()

10 May 21:56

Choose a tag to compare

  • Don't keep index association when sorting, this yields arrays like
    [1 => 'second', 0 => 'first']. These arrays are not zero-based and
    considered maps e.g. by typeof()
    (@thekid)

2.1.0: Collectors, iteration, concat varargs, each efficiency

10 May 21:55

Choose a tag to compare

  • Heads up: Removed sum() operation, it can easily be rewritten to
    either $sum= $seq->reduce(0, function($a, $b) { return $a + $b; })
    or $sum= $seq->collect(Collectors::summing()) which are more flexible.
    (@thekid)
  • Made functions to Collectors::summing and Collectors::averaging
    optional. If omitted, the elements themselves will be used for the
    numbers.
    (@thekid)
  • Added support for referring to instance methods via string. Depends
    on xp-framework/core#44, see pull request #17 - @thekid
  • Added Sequence::toMap() - see pull request #10 - @thekid
  • Added Sequence::iterator() - see pull request #16 - @thekid
  • Added the ability to pass a variable number of arguments to
    Sequence::concat(). At the same time, the method is changed to
    be more liberal in what it accepts. See pull request #13.
    (@thekid)
  • Implemented variant of Sequence::each() which iterates elements
    without callback and is thus more memory-efficient than calling
    e.g. toArray() and discarding the results. See pull request #12.
    (@thekid)

2.0.0: Keys, Sequence::of(null) support

22 Dec 12:10

Choose a tag to compare

This release contains:

  • The possibility to capture array offsets and map keys in filter(), map(), flatten(), peek(), each(), skip() and limit() by merging PR #5
  • Support for Sequence::of(null) returning empty sequences - see PR #7

v1.0.0

03 Nov 21:03

Choose a tag to compare

Hello, sequence!

v0.7.4

27 Sep 13:26

Choose a tag to compare

Composer integration

v0.7.3

22 Sep 22:18

Choose a tag to compare

0.7.3