1
|
/**
|
2
|
* Copyright (C) 2007 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
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.
|
8
|
*/
|
9
|
package eu.etaxonomy.cdm.api.service;
|
10
|
|
11
|
import java.util.List;
|
12
|
|
13
|
import org.springframework.beans.factory.annotation.Autowired;
|
14
|
import org.springframework.stereotype.Service;
|
15
|
import org.springframework.transaction.annotation.Transactional;
|
16
|
|
17
|
import eu.etaxonomy.cdm.model.validation.EntityConstraintViolation;
|
18
|
import eu.etaxonomy.cdm.model.validation.Severity;
|
19
|
import eu.etaxonomy.cdm.persistence.dao.validation.IEntityConstraintViolationDao;
|
20
|
|
21
|
/**
|
22
|
*
|
23
|
* @author ayco_holleman
|
24
|
* @since 15 jan. 2015
|
25
|
*
|
26
|
*/
|
27
|
@Service
|
28
|
@Transactional(readOnly = true)
|
29
|
public class EntityConstraintViolationServiceImpl extends ServiceBase<EntityConstraintViolation, IEntityConstraintViolationDao> implements
|
30
|
IEntityConstraintViolationService {
|
31
|
|
32
|
@Autowired
|
33
|
private IEntityConstraintViolationDao dao;
|
34
|
|
35
|
|
36
|
@Override
|
37
|
protected void setDao(IEntityConstraintViolationDao dao){
|
38
|
this.dao = dao;
|
39
|
}
|
40
|
|
41
|
|
42
|
@Override
|
43
|
public List<EntityConstraintViolation> getConstraintViolations(){
|
44
|
return dao.getConstraintViolations();
|
45
|
}
|
46
|
|
47
|
|
48
|
@Override
|
49
|
public List<EntityConstraintViolation> getConstraintViolations(String validatedEntityClass){
|
50
|
return dao.getConstraintViolations(validatedEntityClass);
|
51
|
}
|
52
|
|
53
|
|
54
|
@Override
|
55
|
public List<EntityConstraintViolation> getConstraintViolations(String validatedEntityClass, Severity severity){
|
56
|
return dao.getConstraintViolations(validatedEntityClass, severity);
|
57
|
}
|
58
|
|
59
|
|
60
|
@Override
|
61
|
public List<EntityConstraintViolation> getConstraintViolations(Severity severity){
|
62
|
return dao.getConstraintViolations(severity);
|
63
|
}
|
64
|
|
65
|
}
|