clintropolis commented on a change in pull request #7388: Support LPAD and RPAD 
sql function
URL: https://github.com/apache/incubator-druid/pull/7388#discussion_r273698758
 
 

 ##########
 File path: 
core/src/main/java/org/apache/druid/java/util/common/StringUtils.java
 ##########
 @@ -360,4 +360,93 @@ public static String encodeBase64String(byte[] input)
   {
     return BASE64_DECODER.decode(input);
   }
+
+  /**
+   * Returns the string left-padded with the string pad to a length of len 
characters.
+   * If str is longer than len, the return value is shortened to len 
characters. 
+   *
+   * @param base The base string to be padded
+   * @param len The length of padded string
+   * @param pad The pad string
+   * @return the string left-padded with pad to a lenght of len
+   */
+  public static String lpad(String base, Integer len, String pad)
 
 Review comment:
   Could you add this link in the javadoc for this method?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@druid.apache.org
For additional commands, e-mail: commits-h...@druid.apache.org

Reply via email to