Java Code Examples for io.swagger.annotations.ApiModelProperty#hidden()

The following examples show how to use io.swagger.annotations.ApiModelProperty#hidden() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SwaggerJacksonAnnotationIntrospector.java    From netty-rest with Apache License 2.0 5 votes vote down vote up
@Override
public boolean hasIgnoreMarker(AnnotatedMember m)
{
    ApiModelProperty ann = m.getAnnotation(ApiModelProperty.class);
    if (ann != null && ann.hidden()) {
        return true;
    }
    return false;
}
 
Example 2
Source File: SwaggerModule.java    From jsonschema-generator with Apache License 2.0 2 votes vote down vote up
/**
 * Determine whether a given member should be ignored, i.e. excluded from the generated schema.
 *
 * @param member targeted field/method
 * @return whether to ignore the given field/method
 */
protected boolean shouldIgnore(MemberScope<?, ?> member) {
    ApiModelProperty annotation = member.getAnnotationConsideringFieldAndGetter(ApiModelProperty.class);
    return annotation != null && annotation.hidden();
}