| 1 |
|
package org.kuali.student.common.ui.server.screenreport.jasper; |
| 2 |
|
|
| 3 |
|
import java.util.Collection; |
| 4 |
|
|
| 5 |
|
import net.sf.jasperreports.engine.JRException; |
| 6 |
|
import net.sf.jasperreports.engine.JRField; |
| 7 |
|
import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource; |
| 8 |
|
|
| 9 |
|
|
| 10 |
|
|
| 11 |
|
|
| 12 |
|
|
| 13 |
|
|
| 14 |
|
|
| 15 |
|
@author |
| 16 |
|
|
| 17 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (9) |
Complexity: 3 |
Complexity Density: 0.6 |
|
| 18 |
|
public class KSCollectionDataSource extends JRBeanCollectionDataSource { |
| 19 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 20 |
48
|
public KSCollectionDataSource(Collection beanCollection) {... |
| 21 |
48
|
super(beanCollection); |
| 22 |
|
} |
| 23 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (6) |
Complexity: 2 |
Complexity Density: 0.5 |
|
| 24 |
328
|
protected Object getFieldValue(Object bean, JRField field) throws JRException {... |
| 25 |
328
|
Object object = getBeanProperty(bean, getPropertyName(field)); |
| 26 |
|
|
| 27 |
328
|
if ("subset".equals(field.getName())) { |
| 28 |
44
|
return new KSCollectionDataSource((Collection) object); |
| 29 |
|
} |
| 30 |
284
|
return object; |
| 31 |
|
} |
| 32 |
|
|
| 33 |
|
} |