|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Person | Line # 30 | 8 | 0% | 8 | 0 | 100% |
1.0
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
| (15) | |||
| Result | |||
|
0.875
|
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByExample
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByExample
|
1 PASS | |
|
0.8125
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testUpdate
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testUpdate
|
1 PASS | |
|
0.6875
|
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindById
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindById
|
1 PASS | |
|
0.6875
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindByExample
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindByExample
|
1 PASS | |
|
0.6875
|
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByName
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByName
|
1 PASS | |
|
0.6875
|
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByAge
org.perfectjpattern.jee.integration.dao.TestSpringGenericDao.testFindByAge
|
1 PASS | |
|
0.6875
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testCreate
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testCreate
|
1 PASS | |
|
0.625
|
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testUpdate
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testUpdate
|
1 PASS | |
|
0.5625
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testDelete
org.perfectjpattern.jee.integration.dao.TestHibernateGenericDao.testDelete
|
1 PASS | |
|
0.4375
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testContains
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testContains
|
1 PASS | |
|
0.375
|
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testDelete
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testDelete
|
1 PASS | |
|
0.375
|
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testCreate
org.perfectjpattern.jee.integration.dao.TestJpaGenericDao.testCreate
|
1 PASS | |
|
0.375
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindAll
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindAll
|
1 PASS | |
|
0.25
|
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindById
org.perfectjpattern.jee.integration.dao.TestHibernateGenericReadOnlyDao.testFindById
|
1 PASS | |
|
0.25
|
org.perfectjpattern.jee.integration.dao.TestJpaGenericReadOnlyDao.testFindById
org.perfectjpattern.jee.integration.dao.TestJpaGenericReadOnlyDao.testFindById
|
1 PASS | |
| 1 | //---------------------------------------------------------------------- | |
| 2 | // | |
| 3 | // PerfectJPattern: "Design patterns are good but components are better!" | |
| 4 | // Person.java Copyright (c) 2009 Giovanni Azua Garcia | |
| 5 | // bravegag@hotmail.com | |
| 6 | // | |
| 7 | // This program is free software; you can redistribute it and/or | |
| 8 | // modify it under the terms of the GNU General Public License | |
| 9 | // as published by the Free Software Foundation; either version 3 | |
| 10 | // of the License, or (at your option) any later version. | |
| 11 | // | |
| 12 | // This program is distributed in the hope that it will be useful, | |
| 13 | // but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 14 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 15 | // GNU General Public License for more details. | |
| 16 | // | |
| 17 | // You should have received a copy of the GNU General Public License | |
| 18 | // along with this program; if not, see <http://www.gnu.org/licenses/>. | |
| 19 | // | |
| 20 | //---------------------------------------------------------------------- | |
| 21 | package org.perfectjpattern.example.datamodel; | |
| 22 | ||
| 23 | /** | |
| 24 | * Person Data Model type | |
| 25 | * | |
| 26 | * @author <a href="mailto:bravegag@hotmail.com">Giovanni Azua</a> | |
| 27 | * @version $Revision: 1.0 $ $Date: Nov 30, 2007 6:30:38 PM $ | |
| 28 | */ | |
| 29 | public | |
| 30 | class Person | |
| 31 | { | |
| 32 | //------------------------------------------------------------------------ | |
| 33 | // public | |
| 34 | //------------------------------------------------------------------------ | |
| 35 | 20 |
public |
| 36 | Person() | |
| 37 | { | |
| 38 | // do nothing | |
| 39 | } | |
| 40 | ||
| 41 | //------------------------------------------------------------------------ | |
| 42 | 20 |
public |
| 43 | Person(String aName, int anAge) | |
| 44 | { | |
| 45 | 20 | theName = aName; |
| 46 | 20 | theAge = anAge; |
| 47 | } | |
| 48 | ||
| 49 | //------------------------------------------------------------------------ | |
| 50 | /** | |
| 51 | * Returns the id | |
| 52 | * | |
| 53 | * @return the id | |
| 54 | */ | |
| 55 | 138 |
public Long |
| 56 | getId() | |
| 57 | { | |
| 58 | 138 | return theId; |
| 59 | } | |
| 60 | ||
| 61 | //------------------------------------------------------------------------ | |
| 62 | /** | |
| 63 | * Sets the id of the person | |
| 64 | * | |
| 65 | * @param anId the id to set | |
| 66 | */ | |
| 67 | 17 |
public void |
| 68 | setId(Long anId) | |
| 69 | { | |
| 70 | 17 | theId = anId; |
| 71 | } | |
| 72 | ||
| 73 | //------------------------------------------------------------------------ | |
| 74 | /** | |
| 75 | * Returns the name | |
| 76 | * | |
| 77 | * @return the name | |
| 78 | */ | |
| 79 | 165 |
public String |
| 80 | getName() | |
| 81 | { | |
| 82 | 165 | return theName; |
| 83 | } | |
| 84 | ||
| 85 | //------------------------------------------------------------------------ | |
| 86 | /** | |
| 87 | * Sets the name of the person | |
| 88 | * | |
| 89 | * @param anName the name to set | |
| 90 | */ | |
| 91 | 3 |
public void |
| 92 | setName(String anName) | |
| 93 | { | |
| 94 | 3 | theName = anName; |
| 95 | } | |
| 96 | ||
| 97 | //------------------------------------------------------------------------ | |
| 98 | /** | |
| 99 | * Returns the age | |
| 100 | * | |
| 101 | * @return the age | |
| 102 | */ | |
| 103 | 163 |
public int |
| 104 | getAge() | |
| 105 | { | |
| 106 | 163 | return theAge; |
| 107 | } | |
| 108 | ||
| 109 | //------------------------------------------------------------------------ | |
| 110 | /** | |
| 111 | * Sets the age of the person | |
| 112 | * | |
| 113 | * @param anAge the age to set | |
| 114 | */ | |
| 115 | 7 |
public void |
| 116 | setAge(int anAge) | |
| 117 | { | |
| 118 | 7 | theAge = anAge; |
| 119 | } | |
| 120 | ||
| 121 | //------------------------------------------------------------------------ | |
| 122 | // members | |
| 123 | //------------------------------------------------------------------------ | |
| 124 | private Long theId; | |
| 125 | private String theName; | |
| 126 | private int theAge; | |
| 127 | } | |
|
||||||||||||