Class DefaultCisClientTaxService

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CisTaxDoc adjust​(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 TaxClient getTaxClient()  
      CisTaxDoc invoice​(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
      Creates an invoice based on the provided order details.
      boolean ping​(java.lang.String xCisClientRef, java.lang.String tenantId)
      Checks if service is functioning and connecting with current credentials.
      CisTaxDoc post​(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
      Submits taxes for the given order.
      CisTaxDoc quote​(java.lang.String xClientRef, java.lang.String tenantId, CisOrder order)
      Returns a tax quote for the order.
      void setTaxClient​(TaxClient taxClient)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultCisClientTaxService

        public DefaultCisClientTaxService()
    • Method Detail

      • ping

        public boolean ping​(java.lang.String xCisClientRef,
                            java.lang.String tenantId)
        Description copied from interface: CisClientService
        Checks if service is functioning and connecting with current credentials.
        Specified by:
        ping in interface CisClientService
        Parameters:
        xCisClientRef - client ref to pass in the header
        tenantId - 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: CisClientTaxService
        Returns a tax quote for the order.
        Specified by:
        quote in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
        order - 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: CisClientTaxService

        Submits 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:
        post in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
        order - 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: CisClientTaxService

        Creates an invoice based on the provided order details.

        Invoiced orders can be adjusted or cancelled.

        Specified by:
        invoice in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
        order - 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: CisClientTaxService

        Cancels a previously submitted or invoiced tax document.

        Specified by:
        cancel in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
        documentLocation - 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: CisClientTaxService

        Adjusts a previously submitted or invoiced tax document.

        Specified by:
        adjust in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
        documentLocation - The location URI of the document to adjust
        order - 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: CisClientTaxService

        Checks if a tax document exists.

        Specified by:
        exists in interface CisClientTaxService
        Parameters:
        xClientRef - client ref to pass in the header
        tenantId - tenantId to pass in the header
      • getTaxClient

        protected TaxClient getTaxClient()
      • setTaxClient

        public void setTaxClient​(TaxClient taxClient)