You'll see I'm messing around with the NBA API and I have this json in particular
Then I have a Parser class
public class Parser {
private Map<String, Object> otherProperties = new HashMap<String, Object>();
@JsonAnySetter
public void set(String name, Object value) {
otherProperties.put(name, value);
}
@Override
public String toString() {
return "Parser{" +
", otherProperties=" + otherProperties +
'}';
}
}
Followed by a main that works properly for me and shows the contents of that json file on screen.
public static void main(String args[]) throws JsonParseException,
JsonMappingException, IOException {
ObjectMapper mapper = new ObjectMapper();
Parser car = mapper.readValue(new File("full_schedule.json"), Parser.class);
System.out.println(car);
}
I want to know if there is a way to check the value returned by the json, not show the entire string itself, if not know if there is any way to iterate this property.