code: protected String trimEndSlash(@NonNull String target) {
          while (target.endsWith(File.separator)) target = target.substring(0, target.length() - 1);
          return target;
      }
docs: Remove '/' at the ending.
  
  @param target target string.
  
  @return rule result.