Skip to content

[BC Break] Practical design: Concrete classes and benchmarking #2

@gabbydgab

Description

@gabbydgab

Currently, ArrayUtils class has many responsibility, thus breaking it into specific usage will open more opportunities to enhance its features - also to properly benchmark edge cases of each functionality (e.g. caching validation and array merging strategies)

Responsibilities

  1. Validation Strategies
    • hasStringKey
    • hasIntegerKey
    • hasNumericKeys
    • isList
    • isHashTable
    • isCachable (proposed/new feature)
  2. Merging Strategies
    • Integer and String Keys
    • Integer and String With Preserved Numeric Keys
    • Recursive Merging
    • Merging with Null arrays
    • Replacing/Removing Keys
    • Prioritized Merging (proposed/new feature)
  3. Filtering Strategies
    • Without key filtering
    • Key specific filtering
    • With and without key filtering
  4. Iterator to Array Conversion Strategies
    • Simple Iterator
    • Recursive Iterator

Benchmarking

Benchmarking the merging and caching strategies is a MUST.

One way of validating performance issue is to benchmark, especially, configuration from Zend\ServiceManager, Zend\View, Zend\Router, etc.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions