Class LocationAdapter
java.lang.Object
me.fami6xx.rpuniverse.core.misc.gsonadapters.LocationAdapter
- All Implemented Interfaces:
com.google.gson.JsonDeserializer<org.bukkit.Location>,com.google.gson.JsonSerializer<org.bukkit.Location>
public class LocationAdapter
extends Object
implements com.google.gson.JsonSerializer<org.bukkit.Location>, com.google.gson.JsonDeserializer<org.bukkit.Location>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.bukkit.Locationdeserialize(com.google.gson.JsonElement json, Type typeOfT, com.google.gson.JsonDeserializationContext context)com.google.gson.JsonElementserialize(org.bukkit.Location src, Type typeOfSrc, com.google.gson.JsonSerializationContext context)
-
Constructor Details
-
LocationAdapter
public LocationAdapter()
-
-
Method Details
-
serialize
public com.google.gson.JsonElement serialize(org.bukkit.Location src, Type typeOfSrc, com.google.gson.JsonSerializationContext context)- Specified by:
serializein interfacecom.google.gson.JsonSerializer<org.bukkit.Location>
-
deserialize
public org.bukkit.Location deserialize(com.google.gson.JsonElement json, Type typeOfT, com.google.gson.JsonDeserializationContext context) throws com.google.gson.JsonParseException- Specified by:
deserializein interfacecom.google.gson.JsonDeserializer<org.bukkit.Location>- Throws:
com.google.gson.JsonParseException
-