Package com.atlassian.bamboo.buildqueue
Class ImmutableRemoteAgentAuthentication
java.lang.Object
com.atlassian.bamboo.buildqueue.ImmutableRemoteAgentAuthentication
- All Implemented Interfaces:
RemoteAgentAuthentication,BambooIdProvider,Comparable<RemoteAgentAuthentication>
public class ImmutableRemoteAgentAuthentication
extends Object
implements Comparable<RemoteAgentAuthentication>, RemoteAgentAuthentication
Immutable business object representing remote agent authentication request.
- Since:
- 3.4
-
Constructor Summary
ConstructorsConstructorDescriptionImmutableRemoteAgentAuthentication(@NotNull UUID uuid, @NotNull String ip) ImmutableRemoteAgentAuthentication(@NotNull UUID uuid, @NotNull String ip, boolean approved) -
Method Summary
Modifier and TypeMethodDescriptionintbooleanlonggetId()getIp()IP address of the agent requesting approval.getUuid()UUID of this authentication request.inthashCode()booleanWhether this request was approved, or is still pending approvalbooleanFor authentication pending approval this must be full match (equals), otherwise wildcard match will be attempted.booleanCheck if matches given uuid and ip.
-
Constructor Details
-
ImmutableRemoteAgentAuthentication
-
ImmutableRemoteAgentAuthentication
-
ImmutableRemoteAgentAuthentication
-
-
Method Details
-
getUuid
Description copied from interface:RemoteAgentAuthenticationUUID of this authentication request.- Specified by:
getUuidin interfaceRemoteAgentAuthentication- Returns:
- UUID
-
getIp
Description copied from interface:RemoteAgentAuthenticationIP address of the agent requesting approval. May contain multiple addresses (coma separated) if agent connects through proxy- Specified by:
getIpin interfaceRemoteAgentAuthentication- Returns:
- IP address of the remote agent
-
isApproved
public boolean isApproved()Description copied from interface:RemoteAgentAuthenticationWhether this request was approved, or is still pending approval- Specified by:
isApprovedin interfaceRemoteAgentAuthentication- Returns:
true, if this authentication request has been approved
-
getIpPatterns
- Specified by:
getIpPatternsin interfaceRemoteAgentAuthentication- Returns:
- list of IP patterns matched for authentication
-
matches
For authentication pending approval this must be full match (equals), otherwise wildcard match will be attempted.- Parameters:
ip- IP address to match- Returns:
true, if this authentication matches ip- See Also:
-
matches
Check if matches given uuid and ip. UUID must be exactly equal to this authentication's UUID and the ip must match as permatches(String).- Parameters:
uuid- UUIDip- IP- Returns:
true, if this authentication matches given uuid and ip- See Also:
-
compareTo
- Specified by:
compareToin interfaceComparable<RemoteAgentAuthentication>
-
equals
-
hashCode
public int hashCode() -
getId
public long getId()- Specified by:
getIdin interfaceBambooIdProvider
-