程序包 cn.nukkit.utils
接口 PlayerDataSerializer
- 所有已知实现类:
DefaultPlayerDataSerializer
public interface PlayerDataSerializer
-
方法概要
修饰符和类型方法说明Reads player data fromInputStream
if the file exists otherwise it will create the default data.Writes player data to givenOutputStream
.
-
方法详细资料
-
read
Reads player data fromInputStream
if the file exists otherwise it will create the default data.- 参数:
name
- name of player orUUID
asString
uuid
- uuid of player. Could be null if name is used.- 返回:
InputStream
if the player data exists- 抛出:
IOException
-
write
Writes player data to givenOutputStream
.- 参数:
name
- name of player orUUID
asString
uuid
- uuid of player. Could be null if name is used.- 返回:
- stream to write player data
- 抛出:
IOException
-