Clover Coverage Report - KS LUM Impl 1.1.1-SNAPSHOT
Coverage timestamp: Wed Apr 20 2011 06:25:34 EST
../../../../../../img/srcFileCovDistChart6.png 44% of files have more coverage
26   208   26   1
0   137   1   26
26     1  
1    
 
  CluSet       Line # 46 26 0% 26 24 53.8% 0.53846157
 
  (44)
 
1    /**
2    * Copyright 2010 The Kuali Foundation Licensed under the
3    * Educational Community License, Version 2.0 (the "License"); you may
4    * not use this file except in compliance with the License. You may
5    * obtain a copy of the License at
6    *
7    * http://www.osedu.org/licenses/ECL-2.0
8    *
9    * Unless required by applicable law or agreed to in writing,
10    * software distributed under the License is distributed on an "AS IS"
11    * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
12    * or implied. See the License for the specific language governing
13    * permissions and limitations under the License.
14    */
15   
16    package org.kuali.student.lum.lu.entity;
17   
18    import java.util.ArrayList;
19    import java.util.Date;
20    import java.util.List;
21   
22    import javax.persistence.CascadeType;
23    import javax.persistence.Column;
24    import javax.persistence.Entity;
25    import javax.persistence.JoinColumn;
26    import javax.persistence.JoinTable;
27    import javax.persistence.ManyToMany;
28    import javax.persistence.ManyToOne;
29    import javax.persistence.NamedQueries;
30    import javax.persistence.NamedQuery;
31    import javax.persistence.OneToMany;
32    import javax.persistence.OneToOne;
33    import javax.persistence.Table;
34    import javax.persistence.Temporal;
35    import javax.persistence.TemporalType;
36   
37    import org.kuali.student.core.entity.AttributeOwner;
38    import org.kuali.student.core.entity.MetaEntity;
39   
40    @Entity
41    @Table(name = "KSLU_CLU_SET")
42    @NamedQueries( {
43    @NamedQuery(name = "CluSet.getCluSetInfoByIdList", query = "SELECT c FROM CluSet c WHERE c.id IN (:cluSetIdList)"),
44    @NamedQuery(name = "CluSet.isCluInCluSet", query = "SELECT COUNT(cluSet) FROM CluSet cluSet JOIN cluSet.cluVerIndIds cluVerIndIds WHERE cluSet.id = :cluSetId AND cluVerIndIds.cluVersionIndId = :cluId ")
45    })
 
46    public class CluSet extends MetaEntity implements AttributeOwner<CluSetAttribute> {
47   
48    @Column(name = "NAME")
49    private String name;
50   
51    @ManyToOne(cascade=CascadeType.ALL)
52    @JoinColumn(name = "RT_DESCR_ID")
53    private LuRichText descr;
54   
55    @Temporal(TemporalType.TIMESTAMP)
56    @Column(name = "EFF_DT")
57    private Date effectiveDate;
58   
59    @Temporal(TemporalType.TIMESTAMP)
60    @Column(name = "EXPIR_DT")
61    private Date expirationDate;
62   
63    @ManyToMany
64    @JoinTable(name = "KSLU_CLU_SET_JN_CLU_SET", joinColumns = @JoinColumn(name = "CLU_SET_PARENT_ID"), inverseJoinColumns = @JoinColumn(name = "CLU_SET_CHILD_ID"))
65    private List<CluSet> cluSets = new ArrayList<CluSet>();
66   
67    // @ManyToMany
68    // @JoinTable(name = "KSLU_CLU_SET_JN_CLU", joinColumns = @JoinColumn(name = "CLU_SET_ID"), inverseJoinColumns = @JoinColumn(name = "CLU_ID"))
69    // private List<Clu> clus = new ArrayList<Clu>();
70   
71    @OneToMany(mappedBy="cluSet",cascade=CascadeType.ALL)
72    private List<CluSetJoinVersionIndClu> cluVerIndIds = new ArrayList<CluSetJoinVersionIndClu>();
73   
74    @OneToMany(cascade = CascadeType.ALL, mappedBy = "owner")
75    private List<CluSetAttribute> attributes = new ArrayList<CluSetAttribute>();
76   
77    @Column(name="TYPE")
78    private String type;
79   
80    @Column(name = "ST")
81    private String state;
82   
83    @Column(name = "ADMIN_ORG_ID")
84    private String adminOrg;
85   
86    @OneToOne(cascade=CascadeType.ALL)
87    @JoinColumn(name="MEM_QUERY_ID")
88    private MembershipQuery membershipQuery;
89   
90    @Column(name = "REUSABLE")
91    private Boolean isReusable;
92   
93    @Column(name = "REFERENCEABLE")
94    private Boolean isReferenceable;
95   
96    // public List<Clu> getClus() {
97    // return clus;
98    // }
99    //
100    // public void setClus(List<Clu> clus) {
101    // this.clus = clus;
102    // }
103   
 
104  92 toggle public String getName() {
105  92 return name;
106    }
107   
 
108  0 toggle public void setName(String name) {
109  0 this.name = name;
110    }
111   
 
112  92 toggle public LuRichText getDescr() {
113  92 return descr;
114    }
115   
 
116  0 toggle public void setDescr(LuRichText descr) {
117  0 this.descr = descr;
118    }
119   
 
120  92 toggle public Date getEffectiveDate() {
121  92 return effectiveDate;
122    }
123   
 
124  0 toggle public void setEffectiveDate(Date effectiveDate) {
125  0 this.effectiveDate = effectiveDate;
126    }
127   
 
128  92 toggle public Date getExpirationDate() {
129  92 return expirationDate;
130    }
131   
 
132  0 toggle public void setExpirationDate(Date expirationDate) {
133  0 this.expirationDate = expirationDate;
134    }
135   
 
136  276 toggle public List<CluSet> getCluSets() {
137  276 return cluSets;
138    }
139   
 
140  0 toggle public void setCluSets(List<CluSet> cluSets) {
141  0 this.cluSets = cluSets;
142    }
143   
 
144  92 toggle public List<CluSetAttribute> getAttributes() {
145  92 return attributes;
146    }
147   
 
148  0 toggle public void setAttributes(List<CluSetAttribute> attributes) {
149  0 this.attributes = attributes;
150    }
151   
 
152  92 toggle public String getType() {
153  92 return type;
154    }
155   
 
156  0 toggle public void setType(String type) {
157  0 this.type = type;
158    }
159   
 
160  92 toggle public String getState() {
161  92 return state;
162    }
163   
 
164  0 toggle public void setState(String state) {
165  0 this.state = state;
166    }
167   
 
168  92 toggle public String getAdminOrg() {
169  92 return adminOrg;
170    }
171   
 
172  0 toggle public void setAdminOrg(String adminOrg) {
173  0 this.adminOrg = adminOrg;
174    }
175   
 
176  99 toggle public MembershipQuery getMembershipQuery() {
177  99 return membershipQuery;
178    }
179   
 
180  1 toggle public void setMembershipQuery(MembershipQuery membershipQuery) {
181  1 this.membershipQuery = membershipQuery;
182    }
183   
 
184  184 toggle public Boolean getIsReusable() {
185  184 return isReusable;
186    }
187   
 
188  0 toggle public void setIsReusable(Boolean isReusable) {
189  0 this.isReusable = isReusable;
190    }
191   
 
192  184 toggle public Boolean getIsReferenceable() {
193  184 return isReferenceable;
194    }
195   
 
196  0 toggle public void setIsReferenceable(Boolean isReferenceable) {
197  0 this.isReferenceable = isReferenceable;
198    }
199   
 
200  184 toggle public List<CluSetJoinVersionIndClu> getCluVerIndIds() {
201  184 return cluVerIndIds;
202    }
203   
 
204  0 toggle public void setCluVerIndIds(List<CluSetJoinVersionIndClu> cluVerIndIds) {
205  0 this.cluVerIndIds = cluVerIndIds;
206    }
207   
208    }