Class DefaultDestinationService<T extends AbstractDestinationModel>
- java.lang.Object
-
- de.hybris.platform.apiregistryservices.services.impl.DefaultDestinationService<T>
-
- Type Parameters:
T- the type parameter which extends theAbstractDestinationModeltype
- All Implemented Interfaces:
DestinationService
public class DefaultDestinationService<T extends AbstractDestinationModel> extends java.lang.Object implements DestinationService
Default implementation ofDestinationService
-
-
Constructor Summary
Constructors Constructor Description DefaultDestinationService()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.util.List<ExposedDestinationModel>getActiveExposedDestinationsByChannel(DestinationChannel channel)Deprecated, for removal: This API element is subject to removal in a future version.since 1905.java.util.List<ExposedDestinationModel>getActiveExposedDestinationsByClientId(java.lang.String clientId)Find the list of active destinations for specific clientIdjava.util.List<ExposedDestinationModel>getActiveExposedDestinationsByDestinationTargetId(java.lang.String destinationTargetId)Get the list of active exposed destinations for a specific destination targetjava.util.List<ConsumedDestinationModel>getAllConsumedDestinations()Get all consumed destinationsjava.util.ListgetAllDestinations()Get all destinationsTgetDestinationById(java.lang.String id)Deprecated, for removal: This API element is subject to removal in a future version.since 1905.AbstractDestinationModelgetDestinationByIdAndByDestinationTargetId(java.lang.String destinationId, java.lang.String destinationTargetId)Get the destination for a specific destination and a specific destination idprotected DestinationDao<T>getDestinationDao()java.util.List<T>getDestinationsByChannel(DestinationChannel channel)Deprecated, for removal: This API element is subject to removal in a future version.since 1905.java.util.List<T>getDestinationsByDestinationTargetId(java.lang.String destinationTargetId)Find destinations for specific destinationTargetprotected org.springframework.web.client.RestTemplategetRestTemplate(ConsumedDestinationModel consumedDestination)voidsetDestinationDao(DestinationDao<T> destinationDao)voidtestDestinationUrl(ConsumedDestinationModel consumedDestination)Testing the consumed destination url
-
-
-
Method Detail
-
getDestinationsByChannel
@Deprecated(since="1905", forRemoval=true) public java.util.List<T> getDestinationsByChannel(DestinationChannel channel)Deprecated, for removal: This API element is subject to removal in a future version.since 1905. UseDestinationService.getDestinationsByDestinationTargetId(String)Description copied from interface:DestinationServiceFind destinations for specific channel- Specified by:
getDestinationsByChannelin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
channel- the channel of the destination- Returns:
- List of destinations for the given channel
-
getDestinationsByDestinationTargetId
public java.util.List<T> getDestinationsByDestinationTargetId(java.lang.String destinationTargetId)
Description copied from interface:DestinationServiceFind destinations for specific destinationTarget- Specified by:
getDestinationsByDestinationTargetIdin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
destinationTargetId- the id of the DestinationTarget- Returns:
- List of destinations for the given DestinationTarget
-
getActiveExposedDestinationsByClientId
public java.util.List<ExposedDestinationModel> getActiveExposedDestinationsByClientId(java.lang.String clientId)
Description copied from interface:DestinationServiceFind the list of active destinations for specific clientId- Specified by:
getActiveExposedDestinationsByClientIdin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
clientId- The clientId of OAuthClientDetails- Returns:
- a List of Destinations by the ExposedOAuthCredential clientId
-
getActiveExposedDestinationsByChannel
@Deprecated(since="1905", forRemoval=true) public java.util.List<ExposedDestinationModel> getActiveExposedDestinationsByChannel(DestinationChannel channel)Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:DestinationServiceFind the list of destinations for specific channel- Specified by:
getActiveExposedDestinationsByChannelin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
channel- The channel assigned to Destinations- Returns:
- a List of Destinations by the credential
-
getActiveExposedDestinationsByDestinationTargetId
public java.util.List<ExposedDestinationModel> getActiveExposedDestinationsByDestinationTargetId(java.lang.String destinationTargetId)
Description copied from interface:DestinationServiceGet the list of active exposed destinations for a specific destination target- Specified by:
getActiveExposedDestinationsByDestinationTargetIdin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
destinationTargetId- id of the destination target- Returns:
- a list of exposed destinations
-
getDestinationByIdAndByDestinationTargetId
public AbstractDestinationModel getDestinationByIdAndByDestinationTargetId(java.lang.String destinationId, java.lang.String destinationTargetId)
Description copied from interface:DestinationServiceGet the destination for a specific destination and a specific destination id- Specified by:
getDestinationByIdAndByDestinationTargetIdin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
destinationId- id of the destinationdestinationTargetId- id of the destination target- Returns:
- a destination
-
getDestinationById
@Deprecated(since="1905", forRemoval=true) public T getDestinationById(java.lang.String id)Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:DestinationServiceSince 1905, the id attribute of the destination is not unique, therefore, this gets the first item of the destinations for specific id.- Specified by:
getDestinationByIdin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
id- the id of the destination- Returns:
- The destination for the given id
-
getAllDestinations
public java.util.List getAllDestinations()
Description copied from interface:DestinationServiceGet all destinations- Specified by:
getAllDestinationsin interfaceDestinationService<T extends AbstractDestinationModel>- Returns:
- the list of destinations
-
testDestinationUrl
public void testDestinationUrl(ConsumedDestinationModel consumedDestination) throws DestinationNotFoundException
Description copied from interface:DestinationServiceTesting the consumed destination url- Specified by:
testDestinationUrlin interfaceDestinationService<T extends AbstractDestinationModel>- Parameters:
consumedDestination- given consumedDestination model- Throws:
DestinationNotFoundException- will be thrown in case of any exception during testing the consumed destination url
-
getDestinationDao
protected DestinationDao<T> getDestinationDao()
-
setDestinationDao
public void setDestinationDao(DestinationDao<T> destinationDao)
-
getAllConsumedDestinations
public java.util.List<ConsumedDestinationModel> getAllConsumedDestinations()
Description copied from interface:DestinationServiceGet all consumed destinations- Specified by:
getAllConsumedDestinationsin interfaceDestinationService<T extends AbstractDestinationModel>- Returns:
- the list of consumed destinations
-
getRestTemplate
protected org.springframework.web.client.RestTemplate getRestTemplate(ConsumedDestinationModel consumedDestination) throws CredentialException
- Throws:
CredentialException
-
-