(These methods are added for consistent naming - see #120)
added immutable methods
with($enumerator, $value)
withIterable(iterable $map)
without($enumerator)
withoutIterable(iterable $enumerators)
other changes
added get($enumerator) : returns mapped data value or exception if missing
offsetGet($enumerator) now returns null if missing - this change is done to be consistent with offsetExists($enumerator) which gets called by isset and should follow this behavior
add($enumerator, $value)
addIterable(iterable $map)
remove($enumerator)
removeIterable(iterable $enumerators)
with($enumerator, $value)
withIterable(iterable $map)
without($enumerator)
withoutIterable(iterable $enumerators)
get($enumerator)
: returns mapped data value or exception if missingoffsetGet($enumerator)
now returnsnull
if missing - this change is done to be consistent withoffsetExists($enumerator)
which gets called byisset
and should follow this behavior