Skip to content

Commit b4a7b93

Browse files
author
Marc Bennewitz
committed
Update README.md
1 parent 489d400 commit b4a7b93

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
[![Latest Unstable Version](https://poser.pugx.org/marc-mabe/php-enum/v/unstable.png)](https://packagist.org/packages/marc-mabe/php-enum)
77
[![Dependency Status](https://www.versioneye.com/php/marc-mabe:php-enum/dev-master/badge.png)](https://www.versioneye.com/php/marc-mabe:php-enum/dev-master)
88

9-
This is a native PHP implementation to add enumeration support to PHP >= 5.3
9+
This is a native PHP implementation to add enumeration support to PHP >= 5.3.
1010
It's an abstract class that needs to be extended to use it.
1111

1212

@@ -49,7 +49,7 @@ It's an abstract class that needs to be extended to use it.
4949
$status->getOrdinal(); // returns the ordinal number of the selected constant
5050
(string) $status; // returns the selected constant name
5151

52-
// The same enumerations of the same class holds the same instance
52+
// same enumerations of the same class holds the same instance
5353
UserStatus::get(UserStatus::ACTIVE) === UserStatus::ACTIVE()
5454
UserStatus::get(UserStatus::DELETED) != UserStatus::INACTIVE()
5555

@@ -101,7 +101,7 @@ Internally the ```EnumMap``` is based of ```SplObjectStorage```.
101101
// iterate
102102
var_dump(iterator_to_array($enumSet)); // array(0 => UserStatus{$value=1});
103103

104-
// it's possible to define the key and the value used for iteration
104+
// define key and value used for iteration
105105
$enumSet->setFlags(EnumSet::KEY_AS_NAME | EnumSet::CURRENT_AS_DATA);
106106
var_dump(iterator_to_array($enumSet)); // array('ACTIVE' => 'aktiv');
107107

@@ -132,8 +132,8 @@ Internally it's based of a list (array) of ordinal values.
132132
# Why not ```SplEnum```
133133

134134
* ```SplEnum``` is not build-in into PHP and requires pecl extension installed.
135-
* Instances of the same value of an ```SplEnum``` are not the same instances.
136-
* ```SplEnum``` doesn't have an implementaiton for ```EnumMap``` and ```EnumSet```.
135+
* Instances of the same value of an ```SplEnum``` are not the same instance.
136+
* ```SplEnum``` doesn't have implemented ```EnumMap``` or ```EnumSet```.
137137

138138

139139
# Install

0 commit comments

Comments
 (0)