Codota Logo
PullRequest.getSourceRepository
Code IndexAdd Codota to your IDE (free)

How to use
getSourceRepository
method
in
org.guvnor.structure.repositories.PullRequest

Best Java code snippets using org.guvnor.structure.repositories.PullRequest.getSourceRepository (Showing top 8 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Dictionary d =
  • Codota Iconnew Hashtable()
  • Codota IconBundle bundle;bundle.getHeaders()
  • Codota Iconnew Properties()
  • Smart code suggestions by Codota
}
origin: kiegroup/appformer

protected void createHiddenBranch(final PullRequest pullRequest) {
  final Path source = this.buildPath(pullRequest.getSourceRepository(),
                    pullRequest.getSourceBranch());
  final Path target = this.buildHiddenPath(pullRequest);
  ioService.copy(source,
          target);
  if (logger.isDebugEnabled()) {
    logger.debug("Hidden branch {} created.",
           target.toString());
  }
}
origin: org.guvnor/guvnor-structure-backend

protected void createHiddenBranch(final PullRequest pullRequest) {
  final Path source = this.buildPath(pullRequest.getSourceRepository(),
                    pullRequest.getSourceBranch());
  final Path target = this.buildHiddenPath(pullRequest);
  ioService.copy(source,
          target);
  if (logger.isDebugEnabled()) {
    logger.debug("Hidden branch {} created.",
           target.toString());
  }
}
origin: org.guvnor/guvnor-structure-backend

private String buildHiddenBranchName(PullRequest pullRequest) {
  return String.format("PR-%s-%s/%s-%s",
             pullRequest.getId(),
             pullRequest.getSourceRepository(),
             pullRequest.getSourceBranch(),
             pullRequest.getTargetBranch());
}
origin: kiegroup/appformer

private String buildHiddenBranchName(PullRequest pullRequest) {
  return String.format("PR-%s-%s/%s-%s",
             pullRequest.getId(),
             pullRequest.getSourceRepository(),
             pullRequest.getSourceBranch(),
             pullRequest.getTargetBranch());
}
origin: kiegroup/appformer

  @Override
  public boolean exists(final PullRequest pullRequest) {
    return this.getPullRequests().stream().anyMatch(
        pr -> {
          return pr.getSourceBranch().equals(pullRequest.getSourceBranch())
              && pr.getSourceRepository().equals(pullRequest.getSourceRepository())
              && pr.getTargetBranch().equals(pullRequest.getTargetBranch())
              && pr.getTargetRepository().equals(pullRequest.getTargetRepository())
              && pr.getStatus().equals(pullRequest.getStatus());
        });
  }
}
origin: kiegroup/appformer

@Override
public PullRequest getPullRequest(long id) {
  final List<PullRequest> prs = this.getPullRequests(elem -> elem.getId() == id);
  if (prs.size() == 0) {
    throw new NoSuchElementException("The Pull Request with ID #" + id + " not found");
  }
  final PullRequest pr = prs.get(0);
  return new PullRequestImpl(pr.getId(),
                pr.getSourceSpace(),
                pr.getSourceRepository(),
                pr.getSourceBranch(),
                pr.getTargetSpace(),
                pr.getTargetRepository(),
                pr.getTargetBranch(),
                pr.getStatus());
}
origin: org.guvnor/guvnor-structure-backend

protected void changePullRequestStatus(final String repository,
                    final long id,
                    final PullRequestStatus status) {
  checkNotEmpty("repository",
         repository);
  checkNotNull("status",
         status);
  GitMetadata metadata = getRepositoryMetadata(repository);
  PullRequest pullRequest = metadata.getPullRequest(id);
  PullRequestImpl finalPullRequest = new PullRequestImpl(pullRequest.getId(),
                              pullRequest.getSourceRepository(),
                              pullRequest.getSourceBranch(),
                              pullRequest.getTargetRepository(),
                              pullRequest.getTargetBranch(),
                              status);
  List<PullRequest> finalPullRequests = metadata.getPullRequests(elem -> elem.getId() != id);
  finalPullRequests.add(finalPullRequest);
  GitMetadata storableMetadata = new GitMetadataImpl(metadata.getName(),
                            metadata.getOrigin(),
                            metadata.getForks(),
                            finalPullRequests);
  this.metadataStore.write(storableMetadata.getName(),
               storableMetadata);
}
origin: kiegroup/appformer

protected void changePullRequestStatus(final String repository,
                    final long id,
                    final PullRequestStatus status) {
  checkNotEmpty("repository",
         repository);
  checkNotNull("status",
         status);
  GitMetadata metadata = getRepositoryMetadata(repository);
  PullRequest pullRequest = metadata.getPullRequest(id);
  PullRequestImpl finalPullRequest = new PullRequestImpl(pullRequest.getId(),
                              pullRequest.getSourceSpace(),
                              pullRequest.getSourceRepository(),
                              pullRequest.getSourceBranch(),
                              pullRequest.getTargetSpace(),
                              pullRequest.getTargetRepository(),
                              pullRequest.getTargetBranch(),
                              status);
  List<PullRequest> finalPullRequests = metadata.getPullRequests(elem -> elem.getId() != id);
  finalPullRequests.add(finalPullRequest);
  GitMetadata storableMetadata = new GitMetadataImpl(metadata.getName(),
                            metadata.getOrigin(),
                            metadata.getForks(),
                            finalPullRequests);
  this.metadataStore.write(storableMetadata.getName(),
               storableMetadata);
}
org.guvnor.structure.repositoriesPullRequestgetSourceRepository

Javadoc

Returns the source repository.

Popular methods of PullRequest

  • getId
  • getStatus
  • getTargetBranch
  • getTargetRepository
  • getSourceBranch
  • getSourceSpace
  • getTargetSpace

Popular in Java

  • Reading from database using SQL prepared statement
  • findViewById (Activity)
  • getSharedPreferences (Context)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • Menu (java.awt)
  • BufferedInputStream (java.io)
    Wraps an existing InputStream and buffers the input. Expensive interaction with the underlying input
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • JFileChooser (javax.swing)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now