code: @Override
      public String joinElementsToId(List<String> elements) {
          Preconditions.checkNotNull(elements, "elements argument");
          StringBuilder sb = new StringBuilder();
          for (String el : elements) {
              // Skip null elements
              if (el == null) {
                  continue;
              }
  
              // Trim the elements and skip any empty ones
              String trimmedEl = el.trim();
              if (trimmedEl.length() < 1)  {
                  continue;
              }
  
              // \ -> \\
              trimmedEl = MATCH_BACKSLASH.matcher(trimmedEl).replaceAll("\\\\\\\\");
              // : -> \:
              trimmedEl = MATCH_COLON.matcher(trimmedEl).replaceAll("\\\\:");
  
              if (sb.length() > 0) {
                  sb.append(SEPARATOR);
              }
              sb.append(trimmedEl);
          }
          return sb.toString();
      }
docs: Joins a list of elements into a resource id, escaping
  special characters if required.
  
  See {@link #splitIdIntoElements(String)} for details.
  
  @param elements a list of elements
  @return the resource id