Package com.hybris.cis.service.impl
Class DefaultCisClientTaxService
- java.lang.Object
-
- com.hybris.cis.service.impl.DefaultCisClientTaxService
-
- All Implemented Interfaces:
CisClientService,CisClientTaxService
public class DefaultCisClientTaxService extends java.lang.Object implements CisClientTaxService
Default implementation forCisClientTaxService
-
-
Constructor Summary
Constructors Constructor Description DefaultCisClientTaxService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CisTaxDocadjust(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation, CisOrder order)Adjusts a previously submitted or invoiced tax document.com.hybris.charon.RawResponse<java.lang.String>cancel(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation)Cancels a previously submitted or invoiced tax document.com.hybris.charon.RawResponse<java.lang.String>exists(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation)Checks if a tax document exists.protected TaxClientgetTaxClient()CisTaxDocinvoice(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)Creates an invoice based on the provided order details.booleanping(java.lang.String xCisClientRef, java.lang.String tenantId)Checks if service is functioning and connecting with current credentials.CisTaxDocpost(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)Submits taxes for the given order.CisTaxDocquote(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)Returns a tax quote for the order.voidsetTaxClient(TaxClient taxClient)
-
-
-
Method Detail
-
ping
public boolean ping(java.lang.String xCisClientRef, java.lang.String tenantId)Description copied from interface:CisClientServiceChecks if service is functioning and connecting with current credentials.- Specified by:
pingin interfaceCisClientService- Parameters:
xCisClientRef- client ref to pass in the headertenantId- tenantId to pass in the header- Returns:
- flag if the service is accessible or not
-
quote
public CisTaxDoc quote(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
Description copied from interface:CisClientTaxServiceReturns a tax quote for the order.- Specified by:
quotein interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the headerorder- The order details to get the quote for- Returns:
- A tax document
-
post
public CisTaxDoc post(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
Description copied from interface:CisClientTaxServiceSubmits taxes for the given order.
Taxes can be posted when the order is placed, which will create a persisted tax document for later reference.
- Specified by:
postin interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the headerorder- The order details to post taxes for- Returns:
- A tax document
-
invoice
public CisTaxDoc invoice(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
Description copied from interface:CisClientTaxServiceCreates an invoice based on the provided order details.
Invoiced orders can be adjusted or cancelled.
- Specified by:
invoicein interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the headerorder- The order details to invoice taxes for- Returns:
- A tax document
-
cancel
public com.hybris.charon.RawResponse<java.lang.String> cancel(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation)Description copied from interface:CisClientTaxServiceCancels a previously submitted or invoiced tax document.
- Specified by:
cancelin interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the headerdocumentLocation- The location URI of the document (can be relative or absolute)
-
adjust
public CisTaxDoc adjust(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation, CisOrder order)
Description copied from interface:CisClientTaxServiceAdjusts a previously submitted or invoiced tax document.
- Specified by:
adjustin interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the headerdocumentLocation- The location URI of the document to adjustorder- CisOrder with lineitems to be cancelled- Returns:
- A tax document
-
exists
public com.hybris.charon.RawResponse<java.lang.String> exists(java.lang.String xClientRef, java.lang.String tenantId, java.net.URI documentLocation)Description copied from interface:CisClientTaxServiceChecks if a tax document exists.
- Specified by:
existsin interfaceCisClientTaxService- Parameters:
xClientRef- client ref to pass in the headertenantId- tenantId to pass in the header
-
getTaxClient
protected TaxClient getTaxClient()
-
setTaxClient
public void setTaxClient(TaxClient taxClient)
-
-