29 lines
379 B
Swift
29 lines
379 B
Swift
import Foundation
|
|
|
|
enum PresenceType {
|
|
case chat
|
|
case online
|
|
case away
|
|
case xa
|
|
case dnd
|
|
|
|
var weight: Int {
|
|
switch self {
|
|
case .chat:
|
|
return 5
|
|
|
|
case .online:
|
|
return 4
|
|
|
|
case .away:
|
|
return 3
|
|
|
|
case .xa:
|
|
return 2
|
|
|
|
case .dnd:
|
|
return 1
|
|
}
|
|
}
|
|
}
|