Java Code Examples for springfox.documentation.service.StringVendorExtension

The following examples show how to use springfox.documentation.service.StringVendorExtension. These examples are extracted from open source projects. 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
private List<Parameter> validateParameter(List<Parameter> parameters) {
  for (Parameter parameter : parameters) {
    if ("body".equals(parameter.getParamType()) &&
        "string".equals(parameter.getModelRef().getType())) {
      // TODO: springfox do not support boolean type and can not add a customization
      // springfox has long time no release version since 2018.9 and version 2.9.2
      // use string type instead
      parameter.getVendorExtentions().add(new StringVendorExtension(X_RAW_JSON_TYPE, "true"));
  return parameters;
Example 2
Source Project: swagger-more   Source File:    License: Apache License 2.0 4 votes vote down vote up
private List<VendorExtension> buildExtensions(ResolvedType resolvedType) {
    List<VendorExtension> extensions = Lists.newArrayList();
    extensions.add(new StringVendorExtension("className", resolvedType.toString()));
    return extensions;