VersionSearch
in package
Tags
Table of Contents
Methods
- search() : mixed
- Implements a modified binary search to find a version number that exists within predefined version ranges. The binary search is run against the start version of each version range. Once a matching range is found an additional check is performed to verify the end of the range if it is defined.
- __construct() : mixed
- handleEndOfRange() : Component|null
- If an end version is define verify the searchVersion is less or equal to it.
Methods
search()
Implements a modified binary search to find a version number that exists within predefined version ranges. The binary search is run against the start version of each version range. Once a matching range is found an additional check is performed to verify the end of the range if it is defined.
public
static search(mixed $components, mixed $searchVersion) : mixed
Parameters
- $components : mixed
- $searchVersion : mixed
__construct()
private
__construct() : mixed
handleEndOfRange()
If an end version is define verify the searchVersion is less or equal to it.
private
static handleEndOfRange(Component $component, Version $searchVersion) : Component|null