@Test public void testDeserialization() throws IOException { String json = "{\"locked\":true}"; LockResult lockResult = JsonUtil.deserialize(json, LockResult.class); assertTrue(lockResult.isLocked()); json = "{\"locked\":false}"; lockResult = JsonUtil.deserialize(json, LockResult.class); assertFalse(lockResult.isLocked()); }
public boolean isLocked() { return locked; }
LockResult { public boolean isLocked() { return locked; } }
LockResult { public boolean isLocked() { return locked; } @JsonCreator  LockResult(@JsonProperty(value = "locked", required = true) boolean locked); }
LockResult { public boolean isLocked() { return locked; } @JsonCreator  LockResult(@JsonProperty(value = "locked", required = true) boolean locked); boolean isLocked(); @Override boolean equals(Object other); @Override int hashCode(); @Override String toString(); }
LockResult { public boolean isLocked() { return locked; } @JsonCreator  LockResult(@JsonProperty(value = "locked", required = true) boolean locked); boolean isLocked(); @Override boolean equals(Object other); @Override int hashCode(); @Override String toString();  }