com.elasticpath.service.tax.impl
Class TaxCategoryServiceImpl

java.lang.Object
  extended by com.elasticpath.service.impl.AbstractEpServiceImpl
      extended by com.elasticpath.service.impl.AbstractEpPersistenceServiceImpl
          extended by com.elasticpath.service.tax.impl.TaxCategoryServiceImpl
All Implemented Interfaces:
EpPersistenceService, EpService, TaxCategoryService

public class TaxCategoryServiceImpl
extends AbstractEpPersistenceServiceImpl
implements TaxCategoryService

The default implementation of the TaxCategoryService.


Constructor Summary
TaxCategoryServiceImpl()
           
 
Method Summary
 TaxCategory add(TaxCategory taxCategory)
          Adds the given taxCategory.
 TaxCategory get(long taxCategoryUid)
          Get the taxCategory with the given UID.
 java.lang.Object getObject(long uid)
          Generic load method for all persistable domain models.
 java.util.List getTaxCategoryInUseUidList()
          Get the list of uids of TaxCategory used to configure the existing TaxJurisdiction.
 java.util.List list()
          List all taxCategorys stored in the database.
 TaxCategory load(long taxCategoryUid)
          Load the taxCategory with the given UID.
 void remove(TaxCategory taxCategory)
          Delete the taxCategory.
 void update(TaxCategory taxCategory)
          Updates the given taxCategory.
 
Methods inherited from class com.elasticpath.service.impl.AbstractEpPersistenceServiceImpl
getPersistenceEngine, setPersistenceEngine
 
Methods inherited from class com.elasticpath.service.impl.AbstractEpServiceImpl
getElasticPath, setElasticPath
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.elasticpath.service.EpPersistenceService
getPersistenceEngine, setPersistenceEngine
 
Methods inherited from interface com.elasticpath.service.EpService
getElasticPath, setElasticPath
 

Constructor Detail

TaxCategoryServiceImpl

public TaxCategoryServiceImpl()
Method Detail

add

public TaxCategory add(TaxCategory taxCategory)
                throws EpServiceException
Adds the given taxCategory.

Specified by:
add in interface TaxCategoryService
Parameters:
taxCategory - the taxCategory to add
Returns:
the persisted instance of taxCategory
Throws:
EpServiceException - - in case of any errors

get

public TaxCategory get(long taxCategoryUid)
                throws EpServiceException
Get the taxCategory with the given UID. Return null if no matching record exists.

Specified by:
get in interface TaxCategoryService
Parameters:
taxCategoryUid - the taxCategory UID
Returns:
the taxCategory if UID exists, otherwise null
Throws:
EpServiceException - - in case of any errors

getObject

public java.lang.Object getObject(long uid)
                           throws EpServiceException
Generic load method for all persistable domain models.

Specified by:
getObject in interface EpPersistenceService
Parameters:
uid - the persisted instance uid
Returns:
the persisted instance if exists, otherwise null
Throws:
EpServiceException - - in case of any errors

getTaxCategoryInUseUidList

public java.util.List getTaxCategoryInUseUidList()
Get the list of uids of TaxCategory used to configure the existing TaxJurisdiction.

Specified by:
getTaxCategoryInUseUidList in interface TaxCategoryService
Returns:
the list of uids of TaxCategorys in use.

list

public java.util.List list()
                    throws EpServiceException
List all taxCategorys stored in the database.

Specified by:
list in interface TaxCategoryService
Returns:
a list of taxCategorys
Throws:
EpServiceException - - in case of any errors

load

public TaxCategory load(long taxCategoryUid)
                 throws EpServiceException
Load the taxCategory with the given UID. Throw an unrecoverable exception if there is no matching database row.

Specified by:
load in interface TaxCategoryService
Parameters:
taxCategoryUid - the taxCategory UID
Returns:
the taxCategory if UID exists, otherwise null
Throws:
EpServiceException - - in case of any errors

remove

public void remove(TaxCategory taxCategory)
            throws EpServiceException
Delete the taxCategory.

Specified by:
remove in interface TaxCategoryService
Parameters:
taxCategory - the taxCategory to remove
Throws:
EpServiceException - - in case of any errors

update

public void update(TaxCategory taxCategory)
            throws EpServiceException
Updates the given taxCategory.

Specified by:
update in interface TaxCategoryService
Parameters:
taxCategory - the taxCategory to update
Throws:
EpServiceException - - in case of any errors