@JsonIgnoreType(false) static class NotWhitelistedButAnnotated { private String property = "bar"; public String getProperty() { return property; } public void setProperty(String property) { } }
private boolean isProvidable(Class<?> type) { final JsonIgnoreType ignore = type.getAnnotation(JsonIgnoreType.class); return (ignore == null) || !ignore.value(); }
@JsonIgnoreType abstract static class MethodHandlerMixin { private MethodHandlerMixin() { } }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = _findAnnotation(ac, JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
@JsonIgnoreType public static class Name { public String firstName; public String lastName; public Name(String firstName, String lastName) { this.firstName = firstName; this.lastName = lastName; } } }
private boolean isProvidable(Class<?> type) { final JsonIgnoreType ignore = type.getAnnotation(JsonIgnoreType.class); return (ignore == null) || !ignore.value(); }
/** *special case attribute to pass object from outside in the application. *the ObjectValue ist not serialised or merged */ @JsonIgnoreType public class ObjectValueAttribute<T> extends ImmutableValueAttribute<T,ObjectValueAttribute<T>> { public ObjectValueAttribute() { super(null); } @Override public boolean internal_ignoreForMerging() { return true; } }
private boolean isProvidable(Class<?> type) { final JsonIgnoreType ignore = type.getAnnotation(JsonIgnoreType.class); return (ignore == null) || !ignore.value(); }
@JsonIgnoreType public interface DefaultJsonIgnoreTypeMixin { }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = ac.getAnnotation(JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
@JsonIgnoreType public class MyMixInForIgnoreType { }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = _findAnnotation(ac, JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
/** * <p>Listener interface.</p> * * @author icode */ @JsonIgnoreType public interface Listener<E extends Event> { /** * <p>onReceive.</p> * * @param event a E object. */ void onReceive(E event); }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = _findAnnotation(ac, JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
/** * DataView view are just additional information and navigation help, they have no effect on the datainjection <br> * They should be never used as constructor parameter<br> * see also: <strong>Factory</strong>ViewListReferenceAttribute */ @JsonIgnoreType public class DataViewListReferenceAttribute<R extends Data, T extends Data> extends ViewListReferenceAttribute<R,T,DataViewListReferenceAttribute<R,T>> { public DataViewListReferenceAttribute(Function<R,List<T>> view) { super(view); } @JsonCreator DataViewListReferenceAttribute() { super(null); } }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = _findAnnotation(ac, JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
/** * DataView view are just additional information and navigation help, they have no effect on the data injection <br> * They should be never used as constructor parameter<br> * see also: <strong>Factory</strong>ViewReferenceAttribute */ @JsonIgnoreType public class DataViewReferenceAttribute<R extends Data, T extends Data> extends ViewReferenceAttribute<R,T,DataViewReferenceAttribute<R,T>> { public DataViewReferenceAttribute(Function<R,T> view) { super(view); } @JsonCreator DataViewReferenceAttribute() { super(null); } }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = _findAnnotation(ac, JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }
@JsonIgnoreType class MethodHandlerChain implements MethodHandler, MethodFilter { private List<ConditionalMethodHandler> delegateHandlers; MethodHandlerChain(List<ConditionalMethodHandler> delegateHandlers) { this.delegateHandlers = new ArrayList<>(delegateHandlers); } @Override public Object invoke(Object self, Method thisMethod, Method proceed, Object[] args) throws Throwable { for (ConditionalMethodHandler handler : delegateHandlers) { if (handler.supports(thisMethod)) { return handler.invoke(self, thisMethod, proceed, args); } } throw new IllegalStateException(String.format("invoke called for non-handled method %s", thisMethod)); } @Override public boolean isHandled(Method method) { return delegateHandlers.stream().anyMatch(h -> h.supports(method)); } }
@Override public Boolean isIgnorableType(AnnotatedClass ac) { JsonIgnoreType ignore = ac.getAnnotation(JsonIgnoreType.class); return (ignore == null) ? null : ignore.value(); }