Skip to content

Make method naming consistent #9

@rotexdegba

Description

@rotexdegba

For consistency sake, wherever possible always have a me or my version of each method where possible: like makeAllKeysNumeric and makeAllMyKeysNumeric. Some already exist like mergeWith and mergeMeWith.

  • The me or my version of each method would modify the collection object upon which the method is being invoked and should consequently always return $this for fluency sake.
  • The non-(me or my) version of each method should perform the operation on a new copy of the collection and return the modified new copy of the collection (THE COLLECTION OBJECT UPON WHICH THE METHOD IS BEING INVOKED SHOULD NEVER BE MODIFIED).
    • Need to figure out if the copy should only copy items alone or should it also copy other collection properties like the registered methods?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions