You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicecomb.apache.org by GitBox <gi...@apache.org> on 2018/01/09 00:56:39 UTC

[GitHub] wujimin closed pull request #493: [SCB-195] Support swagger @Api annotation to specify default tags

wujimin closed pull request #493: [SCB-195] Support swagger @Api annotation to specify default tags
URL: https://github.com/apache/incubator-servicecomb-java-chassis/pull/493
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/AbstractSwaggerGeneratorContext.java b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/AbstractSwaggerGeneratorContext.java
index 922624c29..ab5067c5b 100644
--- a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/AbstractSwaggerGeneratorContext.java
+++ b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/AbstractSwaggerGeneratorContext.java
@@ -33,6 +33,7 @@
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiImplicitParamsClassProcessor;
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiImplicitParamsMethodProcessor;
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiOperationProcessor;
+import io.servicecomb.swagger.generator.core.processor.annotation.ApiProcessor;
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiResponseClassProcessor;
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiResponseMethodProcessor;
 import io.servicecomb.swagger.generator.core.processor.annotation.ApiResponsesClassProcessor;
@@ -42,6 +43,7 @@
 import io.servicecomb.swagger.generator.core.processor.annotation.SwaggerDefinitionProcessor;
 import io.servicecomb.swagger.generator.core.processor.parametertype.RawJsonRequestBodyProcessor;
 import io.servicecomb.swagger.generator.core.processor.response.DefaultResponseTypeProcessor;
+import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiImplicitParam;
 import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiOperation;
@@ -104,6 +106,7 @@ public String resolveStringValue(String strVal) {
   }
 
   protected void initClassAnnotationMgr() {
+    classAnnotationMgr.register(Api.class, new ApiProcessor());
     classAnnotationMgr.register(SwaggerDefinition.class, new SwaggerDefinitionProcessor());
 
     classAnnotationMgr.register(ApiImplicitParams.class, new ApiImplicitParamsClassProcessor());
diff --git a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/OperationGenerator.java b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/OperationGenerator.java
index e0a8cc81a..e961bb721 100644
--- a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/OperationGenerator.java
+++ b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/OperationGenerator.java
@@ -221,6 +221,24 @@ protected void scanMethodAnnotation() {
       }
       processor.process(annotation, this);
     }
+
+    setDefaultTag();
+  }
+
+  private void setDefaultTag() {
+    // if tag has been defined, do nothing
+    if (null != operation.getTags()) {
+      for (String tag : operation.getTags()) {
+        if (!StringUtils.isEmpty(tag)) {
+          return;
+        }
+      }
+    }
+
+    // if there is no tag, set default tag
+    if (!swaggerGenerator.getDefaultTags().isEmpty()) {
+      operation.setTags(new ArrayList<>(swaggerGenerator.getDefaultTags()));
+    }
   }
 
   /**
diff --git a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/SwaggerGenerator.java b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/SwaggerGenerator.java
index aa4fa3353..0956ec33d 100644
--- a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/SwaggerGenerator.java
+++ b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/SwaggerGenerator.java
@@ -22,19 +22,23 @@
 import java.util.Arrays;
 import java.util.Comparator;
 import java.util.HashMap;
+import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Locale;
 import java.util.Map;
+import java.util.Set;
 
 import javax.ws.rs.core.MediaType;
 
 import org.springframework.util.StringUtils;
 
+import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.models.Info;
 import io.swagger.models.Operation;
 import io.swagger.models.Path;
 import io.swagger.models.Swagger;
+import io.swagger.models.Tag;
 import io.swagger.models.parameters.Parameter;
 
 /**
@@ -61,6 +65,13 @@
 
   protected Swagger swagger;
 
+  /**
+   * According to the definition of swagger, the {@link Tag} defined in {@link Api#tags()} will be set
+   * to all of the operations in this swagger. And the {@link Tag} definde in {@link ApiOperation#tags()} will overwrite
+   * the {@link Api#tags()}.
+   */
+  protected Set<String> defaultTags = new LinkedHashSet<>();
+
   private Map<String, OperationGenerator> operationGeneratorMap = new HashMap<>();
 
   private String httpMethod;
@@ -281,4 +292,20 @@ public void setBasePath(String basePath) {
 
     throw new Error("method not found, name=" + methodName);
   }
+
+  /**
+   * Add a tag to {@link #defaultTags} if the corresponding tag not exists.
+   * @param tagName the name of the added tag
+   */
+  public void addDefaultTag(String tagName) {
+    if (StringUtils.isEmpty(tagName) || defaultTags.contains(tagName)) {
+      return;
+    }
+
+    defaultTags.add(tagName);
+  }
+
+  public Set<String> getDefaultTags() {
+    return defaultTags;
+  }
 }
diff --git a/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessor.java b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessor.java
new file mode 100644
index 000000000..c024059ca
--- /dev/null
+++ b/swagger/swagger-generator/generator-core/src/main/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessor.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package io.servicecomb.swagger.generator.core.processor.annotation;
+
+import org.springframework.util.StringUtils;
+
+import io.servicecomb.swagger.generator.core.ClassAnnotationProcessor;
+import io.servicecomb.swagger.generator.core.SwaggerGenerator;
+import io.swagger.annotations.Api;
+
+public class ApiProcessor implements ClassAnnotationProcessor {
+  @Override
+  public void process(Object annotation, SwaggerGenerator swaggerGenerator) {
+    Api api = (Api) annotation;
+
+    setTags(api, swaggerGenerator);
+  }
+
+  private void setTags(Api api, SwaggerGenerator swaggerGenerator) {
+    String[] tags = api.tags();
+    for (String tagName : tags) {
+      if (StringUtils.isEmpty(tagName)) {
+        continue;
+      }
+      swaggerGenerator.addDefaultTag(tagName);
+    }
+  }
+}
diff --git a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestOperationGenerator.java b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestOperationGenerator.java
index abbc52852..fd1c36419 100644
--- a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestOperationGenerator.java
+++ b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestOperationGenerator.java
@@ -17,14 +17,20 @@
 
 package io.servicecomb.swagger.generator.core;
 
+import static org.hamcrest.Matchers.contains;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertThat;
+
+import java.lang.reflect.Method;
 import java.util.Collections;
+import java.util.List;
 
-import org.junit.Assert;
 import org.junit.Test;
 import org.springframework.util.StringValueResolver;
 
 import io.servicecomb.foundation.test.scaffolding.spring.SpringUtils;
 import io.servicecomb.swagger.generator.pojo.PojoSwaggerGeneratorContext;
+import io.swagger.annotations.ApiOperation;
 
 public class TestOperationGenerator {
   @Test
@@ -39,6 +45,59 @@ public void testPathPlaceHolder() {
     OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, null);
     operationGenerator.setPath("/a/${var}/b");
 
-    Assert.assertEquals("/a/varValue/b", operationGenerator.getPath());
+    assertEquals("/a/varValue/b", operationGenerator.getPath());
+  }
+
+  @Test
+  public void testConvertTags() throws NoSuchMethodException {
+    Method function = TestClass.class.getMethod("function");
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), TestClass.class);
+    OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, function);
+
+    operationGenerator.generate();
+
+    List<String> tagList = operationGenerator.getOperation().getTags();
+    assertThat(tagList, contains("tag1", "tag2"));
+  }
+
+  @Test
+  public void testConvertTagsOnMethodWithNoTag() throws NoSuchMethodException {
+    Method function = TestClass.class.getMethod("functionWithNoTag");
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), TestClass.class);
+    OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, function);
+    swaggerGenerator.addDefaultTag("default0");
+    swaggerGenerator.addDefaultTag("default1");
+
+    operationGenerator.generate();
+
+    List<String> tagList = operationGenerator.getOperation().getTags();
+    assertThat(tagList, contains("default0", "default1"));
+  }
+
+  @Test
+  public void testConvertTagsOnMethodWithNoAnnotation() throws NoSuchMethodException {
+    Method function = TestClass.class.getMethod("functionWithNoAnnotation");
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), TestClass.class);
+    OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, function);
+    swaggerGenerator.addDefaultTag("default0");
+    swaggerGenerator.addDefaultTag("default1");
+
+    operationGenerator.generate();
+
+    List<String> tagList = operationGenerator.getOperation().getTags();
+    assertThat(tagList, contains("default0", "default1"));
+  }
+
+  private static class TestClass {
+    @ApiOperation(value = "value1", tags = {"tag1", "tag2"})
+    public void function() {
+    }
+
+    @ApiOperation(value = "value2")
+    public void functionWithNoTag() {
+    }
+
+    public void functionWithNoAnnotation() {
+    }
   }
 }
diff --git a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestSwaggerGenerator.java b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestSwaggerGenerator.java
index d30e1b4b7..bb5ebe8f2 100644
--- a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestSwaggerGenerator.java
+++ b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/TestSwaggerGenerator.java
@@ -17,6 +17,9 @@
 
 package io.servicecomb.swagger.generator.core;
 
+import static org.hamcrest.Matchers.contains;
+import static org.junit.Assert.assertThat;
+
 import java.util.Collections;
 
 import org.junit.Assert;
@@ -40,4 +43,16 @@ public void testBasePathPlaceHolder() {
 
     Assert.assertEquals("/a/varValue/b", swaggerGenerator.getSwagger().getBasePath());
   }
+
+  @Test
+  public void testAddDefaultTag() {
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), null);
+
+    swaggerGenerator.addDefaultTag("test1");
+    swaggerGenerator.addDefaultTag("");
+    swaggerGenerator.addDefaultTag(null);
+    swaggerGenerator.addDefaultTag("test2");
+
+    assertThat(swaggerGenerator.getDefaultTags(), contains("test1", "test2"));
+  }
 }
diff --git a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiOperationProcessorTest.java b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiOperationProcessorTest.java
new file mode 100644
index 000000000..5e1aa6e20
--- /dev/null
+++ b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiOperationProcessorTest.java
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package io.servicecomb.swagger.generator.core.processor.annotation;
+
+import static org.hamcrest.Matchers.containsInAnyOrder;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertThat;
+
+import java.lang.reflect.Method;
+import java.util.List;
+
+import org.junit.Test;
+
+import io.servicecomb.swagger.generator.core.OperationGenerator;
+import io.servicecomb.swagger.generator.core.SwaggerGenerator;
+import io.servicecomb.swagger.generator.pojo.PojoSwaggerGeneratorContext;
+import io.swagger.annotations.ApiOperation;
+
+public class ApiOperationProcessorTest {
+
+  @Test
+  public void testConvertTags() throws NoSuchMethodException {
+    ApiOperationProcessor apiOperationProcessor = new ApiOperationProcessor();
+
+    Method function = TestClass.class.getMethod("function");
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), TestClass.class);
+    OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, function);
+
+    apiOperationProcessor.process(function.getAnnotation(ApiOperation.class),
+        operationGenerator);
+
+    assertThat(operationGenerator.getOperation().getTags(), containsInAnyOrder("tag1", "tag2"));
+  }
+
+  @Test
+  public void testConvertTagsOnMethodWithNoTag() throws NoSuchMethodException {
+    ApiOperationProcessor apiOperationProcessor = new ApiOperationProcessor();
+
+    Method function = TestClass.class.getMethod("functionWithNoTag");
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(new PojoSwaggerGeneratorContext(), TestClass.class);
+    OperationGenerator operationGenerator = new OperationGenerator(swaggerGenerator, function);
+
+    apiOperationProcessor.process(function.getAnnotation(ApiOperation.class),
+        operationGenerator);
+
+    List<String> tagList = operationGenerator.getOperation().getTags();
+    assertNull(tagList);
+  }
+
+  private static class TestClass {
+    @ApiOperation(value = "value1", tags = {"tag1", "tag2"})
+    public void function() {
+    }
+
+    @ApiOperation(value = "value2")
+    public void functionWithNoTag() {
+    }
+  }
+}
diff --git a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessorTest.java b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessorTest.java
new file mode 100644
index 000000000..d44b7a9ae
--- /dev/null
+++ b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/ApiProcessorTest.java
@@ -0,0 +1,63 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package io.servicecomb.swagger.generator.core.processor.annotation;
+
+import static org.hamcrest.Matchers.contains;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertThat;
+
+import java.util.Set;
+
+import org.junit.Test;
+import org.mockito.Mockito;
+
+import io.servicecomb.swagger.generator.core.SwaggerGenerator;
+import io.servicecomb.swagger.generator.core.SwaggerGeneratorContext;
+import io.swagger.annotations.Api;
+
+public class ApiProcessorTest {
+  private ApiProcessor apiProcessor = new ApiProcessor();
+
+  @Test
+  public void process() {
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(Mockito.mock(SwaggerGeneratorContext.class),
+        null);
+    apiProcessor.process(SwaggerTestTarget.class.getAnnotation(Api.class),
+        swaggerGenerator);
+
+    assertThat(swaggerGenerator.getDefaultTags(), contains("tag1", "tag2"));
+  }
+
+  @Test
+  public void processOnNoTag() {
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(Mockito.mock(SwaggerGeneratorContext.class),
+        null);
+    apiProcessor.process(SwaggerTestTargetWithNoTag.class.getAnnotation(Api.class), swaggerGenerator);
+
+    Set<String> tags = swaggerGenerator.getDefaultTags();
+    assertEquals(0, tags.size());
+  }
+
+  @Api(tags = {"tag1", "tag2", "", "tag1"})
+  private class SwaggerTestTarget {
+  }
+
+  @Api
+  private class SwaggerTestTargetWithNoTag {
+  }
+}
diff --git a/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/SwaggerDefinitionProcessorTest.java b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/SwaggerDefinitionProcessorTest.java
new file mode 100644
index 000000000..6fd97ac15
--- /dev/null
+++ b/swagger/swagger-generator/generator-core/src/test/java/io/servicecomb/swagger/generator/core/processor/annotation/SwaggerDefinitionProcessorTest.java
@@ -0,0 +1,75 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package io.servicecomb.swagger.generator.core.processor.annotation;
+
+import static org.hamcrest.Matchers.contains;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertThat;
+
+import org.junit.Test;
+import org.mockito.Mockito;
+
+import io.servicecomb.swagger.generator.core.SwaggerGenerator;
+import io.servicecomb.swagger.generator.core.SwaggerGeneratorContext;
+import io.swagger.annotations.Contact;
+import io.swagger.annotations.ExternalDocs;
+import io.swagger.annotations.Info;
+import io.swagger.annotations.License;
+import io.swagger.annotations.SwaggerDefinition;
+import io.swagger.annotations.SwaggerDefinition.Scheme;
+import io.swagger.annotations.Tag;
+import io.swagger.models.Swagger;
+
+public class SwaggerDefinitionProcessorTest {
+
+  private SwaggerDefinitionProcessor swaggerDefinitionProcessor = new SwaggerDefinitionProcessor();
+
+  @Test
+  public void testProcess() {
+    SwaggerGenerator swaggerGenerator = new SwaggerGenerator(Mockito.mock(SwaggerGeneratorContext.class),
+        null);
+    swaggerDefinitionProcessor.process(SwaggerTestTarget.class.getAnnotation(SwaggerDefinition.class),
+        swaggerGenerator);
+
+    Swagger swagger = swaggerGenerator.getSwagger();
+    assertEquals(1, swagger.getTags().size());
+    io.swagger.models.Tag tag = swagger.getTags().get(0);
+    assertEquals("testTag", tag.getName());
+    assertEquals("desc", tag.getDescription());
+    assertEquals("testValue", tag.getExternalDocs().getDescription());
+    assertEquals("testUrl", tag.getExternalDocs().getUrl());
+    assertEquals("127.0.0.1", swagger.getHost());
+    assertThat(swagger.getSchemes(), contains(io.swagger.models.Scheme.HTTP, io.swagger.models.Scheme.HTTPS));
+    io.swagger.models.Info info = swagger.getInfo();
+    assertEquals("title", info.getTitle());
+    assertEquals("version", info.getVersion());
+    assertEquals("desc", info.getDescription());
+    assertEquals("contactName", info.getContact().getName());
+    assertEquals("licenseName", info.getLicense().getName());
+  }
+
+  @SwaggerDefinition(tags = {
+      @Tag(name = "testTag", description = "desc", externalDocs = @ExternalDocs(value = "testValue", url = "testUrl"))
+  },
+      host = "127.0.0.1",
+      schemes = {Scheme.HTTP, Scheme.HTTPS},
+      info = @Info(title = "title", version = "version", description = "desc", contact =
+      @Contact(name = "contactName"), license = @License(name = "licenseName")))
+  private class SwaggerTestTarget {
+  }
+}


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services