nikolaposa/version
SemVer value object for PHP. Create versions from components or strings, access major/minor/patch plus pre-release/build metadata, compare versions (lt/gt/eq), and match against constraints for validation and dependency-style checks.
VersionsCollection to VersionCollectionVersion->getPreRelease() now explicitly returns nullable typeVersion->getBuild() now explicitly returns nullable typeVersion::fromParts() to Version::from()Version->getVersionString() to Version->toString()beberlei/assert library for input validationVersion\Comparator namespace to Version\ComparisonVersion\Constraint namespace to Version\Comparison\ConstraintComparatorInterface to ComparatorComparisonConstraint to OpeationConstraintComparisonConstraintParser to OpeationConstraintParserVersion\Exception\ExceptionInterface to Version\Exception\VersionExceptionVersion\Comparision\Exception namespace-Exception suffix from all concrete exception namesBaseExtension to ExtensionPreRelease::fromIdentifiers() to PreRelease::from()Build::fromIdentifiers() to Build::from()PreRelease::fromIdentifiersString() to PreRelease::fromString()Build::fromIdentifiersString() to Build::fromString()Version\VersionAwareInterfaceVersion\VersionAwareTraitVersion\Extension\NoPreReleaseVersion\Extension\NoBuildVersion->isBuild()VersionCollection->sort()PreRelease->isEmpty()PreRelease->__toString()Build->isEmpty()Build->__toString()OperationConstraint::equalsTo() named constructorOperationConstraint::notEqualTo() named constructorOperationConstraint::greaterThan() named constructorOperationConstraint::greaterOrEqualTo() named constructorOperationConstraint::lessThan() named constructorOperationConstraint::lessOrEqualTo() named constructorVersion::fromString() is captured and included in toString() resultVersionsCollection::isEmpty() methodVersionsCollection::toArray() methodVersionsCollection::sortedAscending() and VersionsCollection::sortedDescending() methods; mark VersionsCollection::sort() as deprecatedVersionsCollection::first() methodVersionsCollection::last() methodVersionsCollection::majorReleases() methodVersionsCollection::minorReleases() methodVersionsCollection::patchReleases() methodVersionsCollection::matching() fails if all the versions do not satisfy constraint; allow VersionsCollection to be emptyVersion::fromElements() to Version::fromParts()Version::fromParts() requires PreRelease and Build instancesVersion::withMajorIncremented() to Version::incrementMajor()Version::withMinorIncremented() to Version::incrementMinor()Version::withPatchIncremented() to Version::incrementPatch()VersionAwareInterfaceVersion::from(Major|Minor|Path|PreRelease|Build) named constructors in favor of having a single Version::fromParts() named constructor with optional parametersVersionCollection::fromArray(); constructor with variadic Version arguments should be used insteadVersion::isNotEqualTo() method.fromArray) for creating VersionsCollection.null values.Version::fromMajor(), Version::fromPreRelease().increment* methods in Version\Version class were renamed to with*Incremented.Version\Identifier\PreRelease renamed to Version\Identifier\PreReleaseIdentifier.Version\Identifier\Build renamed to Version\Identifier\BuildIdentifier.This release is abandoned, please consider upgrading to 2.x.
How can I help you explore Laravel packages today?