Package com.atlassian.bamboo.buildqueue
Class RemoteAgentAuthentications
java.lang.Object
com.atlassian.bamboo.buildqueue.RemoteAgentAuthentications
Utilities related to remote agent authentications.
- Since:
- 3.4
-
Method Summary
Modifier and TypeMethodDescriptionstatic Function<RemoteAgentAuthentication,String> ipStringToSet(@NotNull String ip) static com.google.common.base.Predicate<RemoteAgentAuthentication>static com.google.common.base.Predicate<RemoteAgentAuthentication>static com.google.common.base.Predicate<RemoteAgentAuthentication>Predicate checking if given authentication matches the ip.static com.google.common.base.Predicate<RemoteAgentAuthentication>Predicate checking if an authentication matches given uuid.static com.google.common.base.Predicate<RemoteAgentAuthentication>A combination ofmatching(String)andmatching(java.util.UUID).static com.google.common.base.Predicate<RemoteAgentAuthentication>matchingUuidOf(@NotNull Iterable<RemoteAgentAuthentication> authentications) toEntity(RemoteAgentAuthenticationDao agentAuthenticationDao)
-
Method Details
-
getUuidAsString
-
matching
public static com.google.common.base.Predicate<RemoteAgentAuthentication> matching(@NotNull @NotNull String requestIps) Predicate checking if given authentication matches the ip.
For authentication pending approval this must be full match (equals), otherwise wildcard match will be attempted.
- Parameters:
requestIps- coma separated list of IP addresses to match- Returns:
- predicate returning
true, if the verified authentication matches ip
-
matching
public static com.google.common.base.Predicate<RemoteAgentAuthentication> matching(@NotNull @NotNull UUID uuid) Predicate checking if an authentication matches given uuid. The UUID must be strictly equal for this predicate to returntrue.- Parameters:
uuid- UUID to check against- Returns:
- predicate checking if an authentication's UUID matches given uuid
-
matching
public static com.google.common.base.Predicate<RemoteAgentAuthentication> matching(@NotNull @NotNull UUID uuid, @NotNull @NotNull String ip) A combination ofmatching(String)andmatching(java.util.UUID).- Parameters:
uuid- UUID to match againstip- coma separated list of IP addresses to match- Returns:
- predicate matching remote agent authentications against given uuid and ip
- See Also:
-
matchingUuidOf
public static com.google.common.base.Predicate<RemoteAgentAuthentication> matchingUuidOf(@NotNull @NotNull Iterable<RemoteAgentAuthentication> authentications) -
isApproved
-
isPending
-
fromEntity
public static Function<RemoteAgentAuthenticationEntity,ImmutableRemoteAgentAuthentication> fromEntity() -
fromEntityJdk
public static Function<RemoteAgentAuthenticationEntity,ImmutableRemoteAgentAuthentication> fromEntityJdk() -
toEntity
public static Function<RemoteAgentAuthentication,RemoteAgentAuthenticationEntity> toEntity(RemoteAgentAuthenticationDao agentAuthenticationDao) -
ipStringToSet
-