litesoft
Diff Revisions
947
vs
948
for /trunk/GWT_Sandbox/InitFrom/src/org/litesoft/initfrom/client/support/Role.java
|
@@ -3,8 +3,7 @@ |
3 |
3 |
|
import org.litesoft.commonfoundation.typeutils.*; |
4 |
4 |
|
import org.litesoft.core.util.*; |
5 |
5 |
|
|
6 |
|
- |
public enum Role implements BitAccessor |
7 |
|
- |
{ |
|
6 |
+ |
public enum Role implements BitAccessor { |
8 |
7 |
|
EndUser, |
9 |
8 |
|
EndUserManager, |
10 |
9 |
|
Developer, |
|
@@ -15,18 +14,15 @@ |
15 |
14 |
|
|
16 |
15 |
|
private int mBit = Permissions.BIT.next(); |
17 |
16 |
|
|
18 |
|
- |
public int getBit() |
19 |
|
- |
{ |
|
17 |
+ |
public int getBit() { |
20 |
18 |
|
return mBit; |
21 |
19 |
|
} |
22 |
20 |
|
|
23 |
|
- |
public static int getBitFor( String pRole ) |
24 |
|
- |
{ |
|
21 |
+ |
public static int getBitFor( String pRole ) { |
25 |
22 |
|
return Objects.deNull( valueFor( pRole ), Permissions.BIT ).getBit(); |
26 |
23 |
|
} |
27 |
24 |
|
|
28 |
|
- |
public static Role valueFor( String pRole ) |
29 |
|
- |
{ |
|
25 |
+ |
public static Role valueFor( String pRole ) { |
30 |
26 |
|
return Enums.fromString( Role.class, pRole ); |
31 |
27 |
|
} |
32 |
28 |
|
} |