Calculate the build URL of a build of BuildFlow type, traversing its downstream builds graph

@return the build URL of a BuildFlow build, with all its downstream builds
432142
@SuppressWarnings("unchecked")
    @Override
    public String calculateBuildUrl(String publishedURL) {
        Iterator<JobInvocation> iterator = (Iterator<JobInvocation>) downstreamProjects();

        StringBuilder sb = new StringBuilder();

        while (iterator.hasNext()) {
            JobInvocation jobInvocation = iterator.next();

            sb.append("\n");
            sb.append("<a href='");
            sb.append(jobInvocation.getBuildUrl());
            sb.append("'>");
            sb.append(jobInvocation.getBuildUrl());
            sb.append("</a>");
        }

        return sb.toString();
    }
180837
def build_url(self):
        
        url = "%s/1.0/%s/%s/%s" % (
            self.request.endpoint.get_url(),
            self.request.api_object,
            self.request.api_method,
            to_hex(self.request.nonce)
        )
        return url
1349319
public Graph<Node> dependenceGraph() {
        Graph.Builder<Node> builder = new Graph.Builder<>();

        archives().stream()
            .map(analyzer.results::get)
            .filter(deps -> !deps.dependencies().isEmpty())
            .flatMap(deps -> deps.dependencies().stream())
            .forEach(d -> addEdge(builder, d));
        return builder.build();
    }
1018173
public OAuthFlow build() {
        if(httpClient == null){
            httpClient = new DefaultHttpClient();
        }

        if(tokenURL == null){
            tokenURL = DEFAULT_TOKEN_URL;
        }

        if(authorizationURL == null){
            authorizationURL = DEFAULT_AUTHORIZATION_URL;
        }

        if(jsonSerializer == null){
            jsonSerializer = new JacksonJsonSerializer();
        }

        if(clientId == null || clientSecret == null || redirectURL == null){
            throw new IllegalStateException();
        }

        return new OAuthFlowImpl(clientId, clientSecret, redirectURL, authorizationURL, tokenURL, httpClient,
                jsonSerializer);
    }
31998
@RequestMapping(value = "builds/{buildId}/links/{targetBuildId}", method = RequestMethod.PUT)
    public Build addBuildLink(@PathVariable ID buildId, @PathVariable ID targetBuildId) {
        Build build = structureService.getBuild(buildId);
        Build targetBuild = structureService.getBuild(targetBuildId);
        structureService.addBuildLink(build, targetBuild);
        return build;
    }
192363
function (options) {
    return (
        options.paths
        && options.baseUrl
        && type(options.paths) === TYPES.OBJECT
        && type(options.baseUrl) === TYPES.STRING
      ) || (
        options.buildProfile
        && type(options.buildProfile) === TYPES.STRING
    );
  }
776164
protected String buildBridgeBaseURL() {
        String protocol = "443".equals(bridgeAppPort) ? "https" : "http";
        return MessageFormat.format("{0}://{1}:{2}/bridge",
                                    protocol,
                                    bridgeAppHost,
                                    bridgeAppPort);
    }
44866
function getBuildGradlePath() {
    var target = path.join("platforms", "android", "app", "build.gradle");
    if (fs.existsSync(target)) {
        return target;
    }

    return path.join("platforms", "android", "build.gradle");
}
657439
public static String getProbHomeProperty()
	{
		final Bundle bundle = Platform.getBundle(ORG_OVERTURE_IDE_PLUGINS_PROBRUNTIME);
		if (bundle != null)
		{
			URL buildInfoUrl = FileLocator.find(bundle, new Path("prob/build_info.txt"), null);

			try
			{
				if (buildInfoUrl != null)
				{
					URL buildInfofileUrl = FileLocator.toFileURL(buildInfoUrl);
					if (buildInfofileUrl != null)
					{
						File file = new File(buildInfofileUrl.getFile());

						return "system."+"prob.home=" + file.getParentFile().getPath().replace('\\', '/');
					}

				}
			} catch (IOException e)
			{
			}
		}
		return "";
	}
652552
def get_build_info(self):
        """"""
        # Retrieve build by revision
        th = treeherder.Treeherder(
            APPLICATIONS_TO_FTP_DIRECTORY.get(self.application, self.application),
            'try',
            self.platform)
        builds = th.query_builds_by_revision(
            self.revision, job_type_name='Build', debug_build=self.debug_build)

        if not builds:
            raise errors.NotFoundError('No builds have been found for revision', self.revision)

        # Extract username and revision from build folders
        self.builds = [build.rsplit('/', 3)[1] for build in builds]
        self.show_matching_builds(self.builds)

        # There is only a single build per revision and platform
        self.build_index = 0
        self.logger.info('Selected build: %s' % self.builds[self.build_index])
140132
public String build() {
        String url = buffer.toString();

        if (url.length() > 2083) {
            LOG.warning("URL " + url + " is longer than 2083 chars (" + buffer.length()
                        + "). It may not work properly in old IE versions.");
        }

        return url;
    }
388833
@SuppressWarnings({ "rawtypes", "unchecked" })
	private IntegrationFlowBuilder getFlowBuilder() {

		IntegrationFlowBuilder flowBuilder;
		URLName urlName = this.properties.getUrl();

		if (this.properties.isIdleImap()) {
			flowBuilder = getIdleImapFlow(urlName);
		}
		else {

			MailInboundChannelAdapterSpec adapterSpec;
			switch (urlName.getProtocol().toUpperCase()) {
				case "IMAP":
				case "IMAPS":
					adapterSpec = getImapFlowBuilder(urlName);
					break;
				case "POP3":
				case "POP3S":
					adapterSpec = getPop3FlowBuilder(urlName);
					break;
				default:
					throw new IllegalArgumentException(
							"Unsupported mail protocol: " + urlName.getProtocol());
			}
			flowBuilder = IntegrationFlows.from(
					adapterSpec.javaMailProperties(getJavaMailProperties(urlName))
							.selectorExpression(this.properties.getExpression())
							.shouldDeleteMessages(this.properties.isDelete()),
					new Consumer<SourcePollingChannelAdapterSpec>() {

						@Override
						public void accept(
								SourcePollingChannelAdapterSpec sourcePollingChannelAdapterSpec) {
							sourcePollingChannelAdapterSpec.poller(MailSourceConfiguration.this.defaultPoller);
						}

					});

		}
		return flowBuilder;
	}
189027
def get_build_info(self):
        """"""
        # Retrieve build by revision
        if self.revision:
            th = treeherder.Treeherder(
                APPLICATIONS_TO_FTP_DIRECTORY.get(self.application, self.application),
                self.branch,
                self.platform)
            builds = th.query_builds_by_revision(
                self.revision,
                job_type_name='L10n Nightly' if self.locale_build else 'Nightly')

            if not builds:
                raise errors.NotFoundError('No builds have been found for revision', self.revision)

            # Extract the build folders which are prefixed with the buildid
            self.builds = [build.rsplit('/', 2)[1] for build in builds]
            self.show_matching_builds(self.builds)

            # There is only a single build per revision and platform
            self.build_index = 0
            self.logger.info('Selected build: %s' % self.builds[self.build_index])

            # Retrieve the date from the build folder which is always 19 chars long
            self.date = datetime.strptime(self.builds[self.build_index][:19],
                                          '%Y-%m-%d-%H-%M-%S')

            return

        # Internally we access builds via index
        if self.build_number is not None:
            self.build_index = int(self.build_number) - 1
        else:
            self.build_index = None

        if self.build_id:
            # A build id has been specified. Split up its components so the
            # date and time can be extracted:
            # '20111212042025' -> '2011-12-12 04:20:25'
            self.date = datetime.strptime(self.build_id, '%Y%m%d%H%M%S')

        elif self.date:
            # A date (without time) has been specified. Use its value and the
            # build index to find the requested build for that day.
            try:
                self.date = datetime.strptime(self.date, '%Y-%m-%d')
            except Exception:
                raise ValueError('%s is not a valid date' % self.date)
        else:
            # If no querying option has been specified the latest available
            # build of the given branch has to be identified. We also have to
            # retrieve the date of the build via its build id.
            self.date = self.get_latest_build_date()

        self.builds, self.build_index = self.get_build_info_for_date(
            self.date, self.build_index)
381046
protected String buildBridgeURL(GetSnapshotContentsTaskParameters taskParams) {
        int pageNumber = taskParams.getPageNumber();
        if (pageNumber < SnapshotConstants.DEFAULT_CONTENT_PAGE_NUMBER) {
            pageNumber = SnapshotConstants.DEFAULT_CONTENT_PAGE_NUMBER;
        }
        int pageSize = taskParams.getPageSize();
        if (pageSize < SnapshotConstants.MIN_CONTENT_PAGE_SIZE ||
            pageSize > SnapshotConstants.MAX_CONTENT_PAGE_SIZE) {
            pageSize = SnapshotConstants.MAX_CONTENT_PAGE_SIZE;
        }
        String snapshotId = taskParams.getSnapshotId();
        String prefix = taskParams.getPrefix();
        String prefixParam = "&prefix=" + (prefix != null ? prefix : "");

        return MessageFormat.format(
            "{0}/snapshot/{1}/content?page={2}&pageSize={3}{4}",
            buildBridgeBaseURL(),
            snapshotId,
            String.valueOf(pageNumber),
            String.valueOf(pageSize),
            prefixParam);
    }
81556
function urlBuilder(params) {
  var builtUrl = params.base;

  builtUrl += '?';

  if (params.apiKey) {
    builtUrl += 'key=' + params.apiKey + '&';
  }

  if (params.client) {
    builtUrl += 'client=' + params.client + '&';
  }

  if (params.libraries.length > 0) {
    builtUrl += 'libraries=';

    params.libraries.forEach(function(library, index) {
      builtUrl += library;

      if (index !== params.libraries.length - 1) {
        builtUrl += ',';
      }
    });

    builtUrl += '&';
  }

  if (params.language) {
    builtUrl += 'language=' + params.language + '&';
  }

  if (params.version) {
    builtUrl += 'v=' + params.version + '&';
  }

  builtUrl += 'callback=' + params.callback;

  return builtUrl;
}
355318
protected String getUrl() {
        String shortUrl = null;
        if (branchReferral_ != null) {
            ServerRequestCreateUrl req = new ServerRequestCreateUrl(context_, alias_, type_, duration_, tags_,
                    channel_, feature_, stage_, campaign_,
                    BranchUtil.formatLinkParam(params_), null, false, defaultToLongUrl_);
            shortUrl = branchReferral_.generateShortLinkInternal(req);
        }
        return shortUrl;
    }
537296
protected function buildUrl()
    {
        $url = '';

        if (isset($this->info['content'])) {
            return 'data:'.$this->info['content'];
        }

        if (isset($this->info['scheme'])) {
            $url .= $this->info['scheme'].'://';
        }

        $user = isset($this->info['user']) ? $this->info['user'] : '';
        $pass = isset($this->info['pass']) ? ':'.$this->info['pass'] : '';
        if ($user || $pass) {
            $url .= $user.$pass.'@';
        }

        if (isset($this->info['host'])) {
            $url .= $this->info['host'];
        }

        if (isset($this->info['port'])) {
            $url .= ':'.$this->info['port'];
        }

        $url .= $this->getPath();

        if (!empty($this->info['query'])) {
            $url .= '?'.rtrim(http_build_query($this->info['query']), '=');
        }
        if (isset($this->info['fragment'])) {
            $url .= '#'.$this->info['fragment'];
        }

        return $url;
    }