code: public void setUserAgent(String userAgent) {
          if (userAgent == null) {
              this.userAgent = DEFAULT_USER_AGENT;
          } else if (userAgent.endsWith(DEFAULT_USER_AGENT)) {
              this.userAgent = userAgent;
          } else {
              this.userAgent = userAgent + ", " + DEFAULT_USER_AGENT;
          }
      }
docs: Sets the User-Agent header value to use when sending requests to BCE services.
  <p>
  If the specified value is null, DEFAULT_USER_AGENT is used. If the specified value does not end with
  DEFAULT_USER_AGENT, DEFAULT_USER_AGENT is appended.
  
  @param userAgent the User-Agent header value to use when sending requests to BCE services.