cFriendshipRelationType2DartType static method
int
cFriendshipRelationType2DartType(- int relationType
)
Implementation
static int cFriendshipRelationType2DartType(int relationType) {
switch (relationType) {
case CFriendshipRelationType.friendshipRelationTypeNone:
return FriendType.V2TIM_FRIEND_TYPE_NONE;
case CFriendshipRelationType.friendshipRelationTypeInMyFriendList:
case CFriendshipRelationType.friendshipRelationTypeInOtherFriendList:
return FriendType.V2TIM_FRIEND_TYPE_SINGLE;
case CFriendshipRelationType.friendshipRelationTypeBothFriend:
return FriendType.V2TIM_FRIEND_TYPE_BOTH;
default:
print('error: invalid c friendship relation type');
return FriendType.V2TIM_FRIEND_TYPE_NONE;
}
}