Class RepositoryAccessStrategy

java.lang.Object
hudson.model.AbstractDescribableImpl<RepositoryAccessStrategy>
org.jenkinsci.plugins.github_branch_source.app_credentials.RepositoryAccessStrategy
All Implemented Interfaces:
Describable<RepositoryAccessStrategy>, Serializable
Direct Known Subclasses:
AccessInferredOwner, AccessInferredRepository, AccessSpecifiedRepositories

public abstract class RepositoryAccessStrategy extends AbstractDescribableImpl<RepositoryAccessStrategy> implements Serializable
Controls the repositories available to installation access tokens generated by GitHubAppCredentials.
See Also:
  • Constructor Details

    • RepositoryAccessStrategy

      public RepositoryAccessStrategy()
  • Method Details

    • forContext

      @CheckForNull public abstract AccessibleRepositories forContext(GitHubAppUsageContext context)
      Get the AccessibleRepositories to use when generating installation access tokens for the inferred contextual owner and repository.

      Called when the credential is used in a context where an owner and repository can be inferred.

      Returns:
      null if the accessible repositories are unknown, or if no repositories are accessible in the specified context