Interface ApplicationService<P extends Application>
-
- Type Parameters:
P
- The projection domain type
- All Known Implementing Classes:
DefaultApplicationService
public interface ApplicationService<P extends Application>
Perform CRUD operations using theApplication
projection domain.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description P
create(P payload)
void
delete(String id)
List<P>
findApplicationsForCustomerContext(String customerContextId)
Returns the application, or applications for a particular customer context.List<P>
findApplicationsForTenant(String tenantId)
Returns the application or applications for a particular tenant.Optional<P>
findById(String id)
List<P>
findByIdIn(Collection<String> ids)
Optional<P>
readByIdentifier(String identifierType, String identifierValue)
P
replace(String id, P payload)
P
save(P payload)
-
-
-
Method Detail
-
findByIdIn
List<P> findByIdIn(Collection<String> ids)
-
delete
void delete(String id)
-
findApplicationsForCustomerContext
List<P> findApplicationsForCustomerContext(String customerContextId)
Returns the application, or applications for a particular customer context. If no applications exist for the customer context, the list returned will be empty.Note that the primary usage for this call is assigning newly created customers to the correct
authorization server
viaAuthorizedClient
. In the case that this returns a list with multiple Applications, these applications should all share the same authorization server, so it is safe to simply use the value at index 0.- Parameters:
customerContextId
- The customer context ID.- Returns:
- A list of
Applications
or an empty list if no applications are found for this customer context. - See Also:
AuthorizedClientService.findApplicationClient(String, String)
,AuthorizedClient.getServerId()
-
findApplicationsForTenant
List<P> findApplicationsForTenant(String tenantId)
Returns the application or applications for a particular tenant. If no applications exist for the supplied tenant id, the list returned will be empty.- Parameters:
tenantId
- The tenant ID- Returns:
- A list of applications for the supplied tenant ID.
-
-