Class ExpiringSAMLArtifactMapEntry
- java.lang.Object
-
- org.opensaml.saml.common.binding.artifact.BasicSAMLArtifactMapEntry
-
- org.opensaml.saml.common.binding.artifact.ExpiringSAMLArtifactMapEntry
-
- All Implemented Interfaces:
SAMLArtifactMap.SAMLArtifactMapEntry
public class ExpiringSAMLArtifactMapEntry extends BasicSAMLArtifactMapEntry
Extension ofBasicSAMLArtifactMapEntry
that tracks expiration.
-
-
Field Summary
Fields Modifier and Type Field Description private Instant
expiration
Expiration time.
-
Constructor Summary
Constructors Constructor Description ExpiringSAMLArtifactMapEntry(String samlArtifact, String issuerId, String relyingPartyId, SAMLObject samlMessage)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Instant
getExpiration()
Returns the expiration time.boolean
isValid()
Returns true iff the entry is valid as of now.boolean
isValid(Instant effectiveTime)
Returns true iff the entry is valid as of a specified time.void
setExpiration(Instant exp)
Sets the expiration time.-
Methods inherited from class org.opensaml.saml.common.binding.artifact.BasicSAMLArtifactMapEntry
getArtifact, getIssuerId, getRelyingPartyId, getSamlMessage
-
-
-
-
Field Detail
-
expiration
@Nullable private Instant expiration
Expiration time.
-
-
Constructor Detail
-
ExpiringSAMLArtifactMapEntry
public ExpiringSAMLArtifactMapEntry(@Nonnull @NotEmpty String samlArtifact, @Nonnull @NotEmpty String issuerId, @Nonnull @NotEmpty String relyingPartyId, @Nonnull SAMLObject samlMessage) throws org.opensaml.core.xml.io.MarshallingException, org.opensaml.core.xml.io.UnmarshallingException
Constructor.- Parameters:
samlArtifact
- artifact associated with the messageissuerId
- issuer of the artifactrelyingPartyId
- intended recipient of the artifactsamlMessage
- SAML message mapped to the artifact- Throws:
org.opensaml.core.xml.io.MarshallingException
- if an error occurs isolating a message from its parentorg.opensaml.core.xml.io.UnmarshallingException
- if an error occurs isolating a message from its parent
-
-
Method Detail
-
getExpiration
@Nullable public Instant getExpiration()
Returns the expiration time.- Returns:
- the expiration
-
setExpiration
public void setExpiration(@Nullable Instant exp)
Sets the expiration time.- Parameters:
exp
- the expiration
-
isValid
public boolean isValid()
Returns true iff the entry is valid as of now.- Returns:
- true iff the entry is valid as of now
-
isValid
public boolean isValid(@Nonnull Instant effectiveTime)
Returns true iff the entry is valid as of a specified time.- Parameters:
effectiveTime
- the time to evaluate validity against- Returns:
- true iff the entry is valid as of a specified time
-
-