Last change
on this file since 1701 was
1701,
checked in by twagoo, 12 years ago
|
Added comments count to component/profile description model. Retrieved from database by doing a count on the comments table
|
File size:
778 bytes
|
Line | |
---|
1 | package clarin.cmdi.componentregistry.impl.database; |
---|
2 | |
---|
3 | import clarin.cmdi.componentregistry.model.ComponentDescription; |
---|
4 | import java.util.List; |
---|
5 | |
---|
6 | /** |
---|
7 | * |
---|
8 | * @author Twan Goosen <twan.goosen@mpi.nl> |
---|
9 | */ |
---|
10 | public class ComponentDescriptionDao extends AbstractDescriptionDao<ComponentDescription> { |
---|
11 | |
---|
12 | public ComponentDescriptionDao() { |
---|
13 | super(ComponentDescription.class); |
---|
14 | } |
---|
15 | |
---|
16 | @Override |
---|
17 | protected String getTableName() { |
---|
18 | return TABLE_COMPONENT_DESCRIPTION; |
---|
19 | } |
---|
20 | |
---|
21 | @Override |
---|
22 | protected String getCMDIdColumn() { |
---|
23 | return "component_id"; |
---|
24 | } |
---|
25 | |
---|
26 | @Override |
---|
27 | protected String getCommentsForeignKeyColumn() { |
---|
28 | return "component_description_id"; |
---|
29 | } |
---|
30 | |
---|
31 | public List<ComponentDescription> getPublicComponentDescriptions() { |
---|
32 | return getPublicDescriptions(); |
---|
33 | } |
---|
34 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.