-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: Add DeviceID and Device Type to User spec
- Loading branch information
1 parent
3112988
commit 8d2b7a4
Showing
2 changed files
with
24 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package messagerosa.core.model; | ||
|
||
public enum DeviceType { | ||
PHONE("phone"); | ||
|
||
private String name; | ||
|
||
DeviceType(String deviceType) { | ||
name=deviceType; | ||
} | ||
|
||
public String toString(){ | ||
return name; | ||
} | ||
|
||
public static String getEnumByString(String code){ | ||
for(DeviceType e : DeviceType.values()){ | ||
if(e.name.equals(code)) return e.name(); | ||
} | ||
return null; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters