Skip to content

Commit 4a54a50

Browse files
committed
Updated README.md
1 parent d5abf96 commit 4a54a50

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ It's an abstract class that can be extended to emulate enumerables.
1313

1414
# API
1515

16-
Enum
16+
Mabe_Enum
1717
{
1818
protected $value = null;
1919
final public function __construct($value = null);
@@ -29,7 +29,7 @@ It's an abstract class that can be extended to emulate enumerables.
2929
## Examples:
3030

3131
// Enum with ONE as default value
32-
class MyEnumWithDefaultValue
32+
class MyEnumWithDefaultValue extends Mabe_Enum
3333
{
3434
const ONE = 1;
3535
const TWO = 2;
@@ -38,23 +38,23 @@ It's an abstract class that can be extended to emulate enumerables.
3838

3939
// Enum without a default value
4040
// No argument on constructor results in InvalidArgumentException
41-
class MyEnumWithoutDefaultValue
41+
class MyEnumWithoutDefaultValue extends Mabe_Enum
4242
{
4343
const ONE = 1;
4444
const TWO = 2;
4545
}
4646

4747
// Because the $value object property is defined as NULL
4848
// a constant with a NULL value gets the default value automatically
49-
class MyEnumWithNullAsDefaultValue
49+
class MyEnumWithNullAsDefaultValue extends Mabe_Enum
5050
{
5151
const NONE = null;
5252
const ONE = 1;
5353
const TWO = 2;
5454
}
5555

5656
// To disable the last behavior it's possible to set the default value to an unknown value
57-
class MyEnumWithoutNullAsDefaultValue
57+
class MyEnumWithoutNullAsDefaultValue extends Mabe_Enum
5858
{
5959
const NONE = null;
6060
const ONE = 1;
@@ -105,7 +105,7 @@ It's an abstract class that can be extended to emulate enumerables.
105105

106106
## The way of php-enum:
107107

108-
class UserStatusEnum extends Enum
108+
class UserStatusEnum extends Mabe_Enum
109109
{
110110
const INACTIVE = 0;
111111
const ACTIVE = 1;
@@ -143,7 +143,7 @@ It's an abstract class that can be extended to emulate enumerables.
143143
Default user status: INACTIVE (0)
144144
Changed user status: ACTIVE (1)
145145

146-
* Validation already done on basic class ```Enum```
146+
* Validation already done on basic class ```Mabe_Enum```
147147
* Using type-hint makes arguments save
148148
* Human readable name of a value is simple accessable
149149

0 commit comments

Comments
 (0)