[ 
https://issues.apache.org/jira/browse/SCB-928?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16648951#comment-16648951
 ] 

ASF GitHub Bot commented on SCB-928:
------------------------------------

wujimin commented on a change in pull request #952: [SCB-928] support 
"collection-format" feature on query param
URL: 
https://github.com/apache/incubator-servicecomb-java-chassis/pull/952#discussion_r224960727
 
 

 ##########
 File path: 
swagger/swagger-generator/generator-core/src/main/java/org/apache/servicecomb/swagger/converter/property/SwaggerParamCollectionFormat.java
 ##########
 @@ -57,6 +68,41 @@ public String getSeparator() {
     if (null == rawParam) {
       return new String[0];
     }
-    return rawParam.split(separator);
+    return rawParam.split(separator, -1);
+  }
+
+  /**
+   * Join params with {@link #separator}.
+   * Null element will be ignored since {@code null} cannot be described in 
query array param.
+   *
+   * @return joined params, or return {@code null} if {@code params} is null 
or all elements of {@code params} are null.
+   */
+  public String joinParam(Collection<?> params) {
+    if (null == params) {
 
 Review comment:
   try org.apache.commons.lang3.StringUtils#join(java.lang.Iterable<?>, char)?

----------------------------------------------------------------
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:
us...@infra.apache.org


> support swagger "collection-format" feature
> -------------------------------------------
>
>                 Key: SCB-928
>                 URL: https://issues.apache.org/jira/browse/SCB-928
>             Project: Apache ServiceComb
>          Issue Type: Task
>          Components: Java-Chassis
>            Reporter: wujimin
>            Assignee: YaoHaishi
>            Priority: Major
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to