Class DefaultEntityStatementRetriever
java.lang.Object
com.nimbusds.openid.connect.sdk.federation.trust.DefaultEntityStatementRetriever
- All Implemented Interfaces:
EntityStatementRetriever
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe default HTTP connect timeout in milliseconds.static final intThe default HTTP read timeout in milliseconds. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new entity statement retriever using the default HTTP timeout settings.DefaultEntityStatementRetriever(int httpConnectTimeoutMs, int httpReadTimeoutMs) Creates a new entity statement retriever. -
Method Summary
Modifier and TypeMethodDescriptionfetchEntityStatement(URI federationAPIEndpoint, EntityID issuer, EntityID subject) Fetches an entity statement from a federation API endpoint.Fetches an entity's self-issued statement from its federation entity configuration endpoint.intReturns the configured HTTP connect timeout.intReturns the configured HTTP read timeout.Returns the running list of the recorded HTTP requests.
-
Field Details
-
DEFAULT_HTTP_CONNECT_TIMEOUT_MS
The default HTTP connect timeout in milliseconds.- See Also:
-
DEFAULT_HTTP_READ_TIMEOUT_MS
The default HTTP read timeout in milliseconds.- See Also:
-
-
Constructor Details
-
DefaultEntityStatementRetriever
public DefaultEntityStatementRetriever()Creates a new entity statement retriever using the default HTTP timeout settings. -
DefaultEntityStatementRetriever
Creates a new entity statement retriever.- Parameters:
httpConnectTimeoutMs- The HTTP connect timeout in milliseconds, zero means timeout determined by the underlying HTTP client.httpReadTimeoutMs- The HTTP read timeout in milliseconds, zero means timeout determined by the underlying HTTP client.
-
-
Method Details
-
getHTTPConnectTimeout
Returns the configured HTTP connect timeout.- Returns:
- The configured HTTP connect timeout in milliseconds, zero means timeout determined by the underlying HTTP client.
-
getHTTPReadTimeout
Returns the configured HTTP read timeout.- Returns:
- The configured HTTP read timeout in milliseconds, zero means timeout determined by the underlying HTTP client.
-
fetchSelfIssuedEntityStatement
Description copied from interface:EntityStatementRetrieverFetches an entity's self-issued statement from its federation entity configuration endpoint.- Specified by:
fetchSelfIssuedEntityStatementin interfaceEntityStatementRetriever- Parameters:
target- The entity ID. Must not benull.- Returns:
- The entity statement.
- Throws:
ResolveException- If fetching failed.
-
fetchEntityStatement
public EntityStatement fetchEntityStatement(URI federationAPIEndpoint, EntityID issuer, EntityID subject) throws ResolveException Description copied from interface:EntityStatementRetrieverFetches an entity statement from a federation API endpoint.- Specified by:
fetchEntityStatementin interfaceEntityStatementRetriever- Parameters:
federationAPIEndpoint- The federation API endpoint. Must not benull.issuer- The entity statement issuer, typically the ID of the entity operating the endpoint. Must not benull.subject- The entity statement subject. Must not benull.- Returns:
- The entity statement.
- Throws:
ResolveException- If fetching failed.
-
getRecordedRequests
Returns the running list of the recorded HTTP requests.- Returns:
- The HTTP request URIs (with query parameters), empty if none.
-