本文整理了Java中io.swagger.v3.oas.models.parameters.Parameter.getAllowEmptyValue()
方法的一些代码示例,展示了Parameter.getAllowEmptyValue()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Parameter.getAllowEmptyValue()
方法的具体详情如下:
包路径:io.swagger.v3.oas.models.parameters.Parameter
类名称:Parameter
方法名:getAllowEmptyValue
[英]returns the allowEmptyValue property from a Parameter instance.
[中]从参数实例返回allowEmptyValue属性。
代码示例来源:origin: quen2404/openapi-diff
@Override
public DiffResult isCoreChanged() {
if (!changeRequired
&& !deprecated
&& !changeAllowEmptyValue
&& !changeStyle
&& !changeExplode) {
return DiffResult.NO_CHANGES;
}
if ((!changeRequired || Boolean.TRUE.equals(oldParameter.getRequired()))
&& (!changeAllowEmptyValue || Boolean.TRUE.equals(newParameter.getAllowEmptyValue()))
&& !changeStyle
&& !changeExplode) {
return DiffResult.COMPATIBLE;
}
return DiffResult.INCOMPATIBLE;
}
}
代码示例来源:origin: quen2404/openapi-diff
&& Boolean.TRUE.equals(right.getDeprecated()))
.setChangeAllowEmptyValue(
getBooleanDiff(left.getAllowEmptyValue(), right.getAllowEmptyValue()))
.setChangeStyle(!Objects.equals(left.getStyle(), right.getStyle()))
.setChangeExplode(getBooleanDiff(left.getExplode(), right.getExplode()));
代码示例来源:origin: org.ballerinalang/swagger-to-ballerina-generator
@Override
public BallerinaParameter buildContext(Parameter parameter, OpenAPI openAPI) throws BallerinaOpenApiException {
this.name = parameter.getName();
this.in = parameter.getIn();
this.description = parameter.getDescription();
this.required = parameter.getRequired();
this.deprecated = parameter.getDeprecated();
this.allowEmptyValue = parameter.getAllowEmptyValue();
this.ref = parameter.get$ref();
this.style = parameter.getStyle();
this.explode = parameter.getExplode();
this.allowReserved = parameter.getAllowReserved();
this.examples = parameter.getExamples();
this.example = parameter.getExample();
this.content = parameter.getContent();
this.extensions = parameter.getExtensions();
this.schema = new BallerinaSchema().buildContext(parameter.getSchema(), openAPI);
return this;
}
内容来源于网络,如有侵权,请联系作者删除!