2 * Copyright (C) 2009 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.api
.service
;
12 import java
.util
.List
;
14 import org
.apache
.log4j
.Logger
;
15 import org
.springframework
.beans
.factory
.annotation
.Autowired
;
16 import org
.springframework
.stereotype
.Service
;
17 import org
.springframework
.transaction
.annotation
.Transactional
;
19 import eu
.etaxonomy
.cdm
.common
.monitor
.IProgressMonitor
;
20 import eu
.etaxonomy
.cdm
.model
.common
.TermVocabulary
;
21 import eu
.etaxonomy
.cdm
.model
.occurrence
.Collection
;
22 import eu
.etaxonomy
.cdm
.model
.taxon
.Classification
;
23 import eu
.etaxonomy
.cdm
.persistence
.dao
.occurrence
.ICollectionDao
;
24 import eu
.etaxonomy
.cdm
.strategy
.cache
.common
.IIdentifiableEntityCacheStrategy
;
27 @Transactional(readOnly
= true)
28 public class CollectionServiceImpl
extends IdentifiableServiceBase
<Collection
, ICollectionDao
> implements ICollectionService
{
30 static private final Logger logger
= Logger
.getLogger(CollectionServiceImpl
.class);
34 protected void setDao(ICollectionDao dao
) {
41 * @see eu.etaxonomy.cdm.api.service.IIdentifiableEntityService#updateTitleCache(java.lang.Integer, eu.etaxonomy.cdm.strategy.cache.common.IIdentifiableEntityCacheStrategy)
44 @Transactional(readOnly
= false)
45 public void updateTitleCache(Class
<?
extends Collection
> clazz
, Integer stepSize
, IIdentifiableEntityCacheStrategy
<Collection
> cacheStrategy
, IProgressMonitor monitor
) {
47 clazz
= Collection
.class;
49 super.updateTitleCacheImpl(clazz
, stepSize
, cacheStrategy
, monitor
);
54 public List
<Collection
> searchByCode(String code
) {
55 return this.dao
.getCollectionByCode(code
);