You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
1.3 KiB
36 lines
1.3 KiB
package org.poopki.duckdns.user_db; |
|
|
|
import java.util.HashMap; |
|
import java.util.Map; |
|
import java.util.Set; |
|
import java.util.UUID; |
|
|
|
public class UserInfoArray { |
|
private Map<UUID, UserInfo> m_UserInfoArray = new HashMap<UUID, UserInfo>(); |
|
private Map<String, UUID> m_UserNameUUID = new HashMap(); |
|
public String getUserName(UUID uuid){ // 유저 이름 return |
|
return m_UserInfoArray.get(uuid).getUserName(); |
|
} |
|
public boolean checkNewUser(UUID uuid){ // 유저 목록 check |
|
return m_UserInfoArray.containsKey(uuid); |
|
} |
|
public Set<UUID> getKeySet(){ // 유저 목록 return |
|
return m_UserInfoArray.keySet(); |
|
} |
|
|
|
public UUID getUserGroupUUID(UUID PlayerUUID, String GroupType){ |
|
return m_UserInfoArray.get(PlayerUUID).GetGroupUUID(GroupType); |
|
} |
|
public UUID getUserUUID(String Name){ |
|
return m_UserNameUUID.get(Name); |
|
} |
|
public void setUserGroupUUID(String GroupType, UUID PlayerUUID, UUID GroupUUID){ |
|
m_UserInfoArray.get(PlayerUUID).SetGroupUUID(GroupType,GroupUUID); |
|
} |
|
|
|
public void putUserInfo(UUID uuid,String Name, UUID Nation, UUID Squad, UUID Farm, UUID Party) { // UserInfoArray entry 입력 |
|
m_UserInfoArray.put(uuid, new UserInfo(uuid,Name, Nation, Squad, Farm, Party)); |
|
m_UserNameUUID.put(Name, uuid); |
|
} |
|
|
|
} |