/** * Set the content of this component using a JSON object. * @param obj - the JSON that represents the new component. */ public void setJson(String obj) { this.handle = deserialize(obj); this.cache = obj; }
/** * Construct a new chat component wrapper from the given JSON string. * @param json - the json. * @return The chat component wrapper. */ public static WrappedChatComponent fromJson(String json) { return new WrappedChatComponent(deserialize(json), json); }