Package com.atlassian.bamboo.credentials
Interface CredentialsAccessor
- All Known Subinterfaces:
CredentialsManager
- All Known Implementing Classes:
CredentialsManagerImpl,RemoteCredentialsAccessor
public interface CredentialsAccessor
-
Method Summary
Modifier and TypeMethodDescription@NotNull Iterable<CredentialsData>Deprecated.since 8.2 this method does not return project Credentials, so the name is confusing.@NotNull Iterable<CredentialsData>getAllCredentials(@NotNull String pluginKey) Deprecated.since 8.2 this method does not return project Credentials, so the name is confusing.@NotNull Iterable<CredentialsData>getAllCredentialsByPluginKey(@NotNull String pluginKey) @Nullable CredentialsDatagetCredentials(long id) Gets the Shared Credentials by id@Nullable CredentialsDatagetCredentialsByName(String name) Find global shared credentials by namegetCredentialsByNameAndProjectId(String name, long projectId) Find shared credentials by name and project id@Nullable CredentialsDataFind shared credentials byBambooEntityOid@NotNull Iterable<CredentialsData>getGlobalCredentials(@NotNull String pluginKey) @Nullable CredentialsDatagetProjectCredentials(long id, long projectId) Gets the Shared Credentials by id and projectId@NotNull Iterable<CredentialsData>getProjectCredentials(@NotNull Long projectId) @NotNull Iterable<CredentialsData>getProjectCredentialsByPluginKey(@NotNull Long projectId, String pluginKey) booleanhasAnyCredentials(@NotNull String pluginKey)
-
Method Details
-
getCredentials
Gets the Shared Credentials by id- Parameters:
id-- Returns:
- Returns the object representation of the credentials
-
getProjectCredentials
Gets the Shared Credentials by id and projectId- Parameters:
id-- Returns:
- Returns the object representation of the credentials
-
getCredentialsByOid
Find shared credentials byBambooEntityOid- Parameters:
oid-- Returns:
- Since:
- 5.15
-
getCredentialsByName
Find global shared credentials by name- Parameters:
name-- Returns:
- Since:
- 5.15
-
getCredentialsByNameAndProjectId
Find shared credentials by name and project id- Parameters:
name-projectId-- Returns:
-
getAllCredentials
Deprecated.since 8.2 this method does not return project Credentials, so the name is confusing. usegetGlobalCredentials()- Returns:
- A list of all global credentials
-
getGlobalCredentials
Iterable<CredentialsData> getGlobalCredentials()- Returns:
- A list of all global credentials
-
getProjectCredentials
- Parameters:
projectId-- Returns:
- A list of all project credentials in project associated with given projectId
-
getAllCredentials
@Deprecated @NotNull @NotNull Iterable<CredentialsData> getAllCredentials(@NotNull @NotNull String pluginKey) Deprecated.since 8.2 this method does not return project Credentials, so the name is confusing. usegetGlobalCredentials()- Returns:
- A list of global credentials that match the given plugin key
-
getGlobalCredentials
@NotNull @NotNull Iterable<CredentialsData> getGlobalCredentials(@NotNull @NotNull String pluginKey) - Returns:
- A list of global credentials that match the given plugin key
-
getAllCredentialsByPluginKey
@NotNull @NotNull Iterable<CredentialsData> getAllCredentialsByPluginKey(@NotNull @NotNull String pluginKey) - Returns:
- A list of all (global and project) credentials that match the given plugin key
-
getProjectCredentialsByPluginKey
@NotNull @NotNull Iterable<CredentialsData> getProjectCredentialsByPluginKey(@NotNull @NotNull Long projectId, String pluginKey) - Parameters:
projectId-pluginKey-- Returns:
- a collection of project credentials that match the given plugin key
-
hasAnyCredentials
- Returns:
- True if there are global credentials that match the given plugin key
-