[virtualcommons-svn] SF.net SVN: virtualcommons:[351] mentalmodels/trunk/src/main
Status: Beta
Brought to you by:
alllee
From: <see...@us...> - 2009-10-30 22:46:26
|
Revision: 351 http://virtualcommons.svn.sourceforge.net/virtualcommons/?rev=351&view=rev Author: seematalele Date: 2009-10-30 22:46:20 +0000 (Fri, 30 Oct 2009) Log Message: ----------- 1) Created Many to Many relationship between DayByDayDecisions and Student with DayByDayOtherStudentDecisions entity. 2) Created HibernateDayByDayOtherStudentDecisionsDao.java, added in applicationContext.xml and hibernate.cfg.xml 3) Tested calculateHarvest method in DayByDayDecisionsService.java. Working for 3 students. 4) Changed the init-mme.sql to reflect the changes in database schema. 5) Changed the MessageHandler to send the first block only. Bugs - Lazy initialization exception for Block.QuestionGroup, when first block is sent to the client but subsequent blocks are sent successfully. Modified Paths: -------------- mentalmodels/trunk/src/main/db/init-mme.sql mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayDecisions.java mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/DayByDayDecisionsService.java mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java mentalmodels/trunk/src/main/webapp/WEB-INF/applicationContext.xml mentalmodels/trunk/src/main/webapp/WEB-INF/hibernate.cfg.xml Added Paths: ----------- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/dao/HibernateDayByDayOtherStudentDecisionsDao.java mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayOtherStudentDecisions.java Modified: mentalmodels/trunk/src/main/db/init-mme.sql =================================================================== --- mentalmodels/trunk/src/main/db/init-mme.sql 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/db/init-mme.sql 2009-10-30 22:46:20 UTC (rev 351) @@ -209,6 +209,23 @@ -- Table structure for table `day_by_day_decision` -- +DROP TABLE IF EXISTS `day_by_day_decision`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `day_by_day_decision` ( + `id` bigint(20) NOT NULL AUTO_INCREMENT, + `dayNumber` int(11) NOT NULL, + `earnings` double DEFAULT NULL, + `money` double DEFAULT NULL, + `location_id` bigint(20) NOT NULL, + `student_id` bigint(20) NOT NULL, + PRIMARY KEY (`id`), + KEY `FK5B92B164224FD013` (`location_id`), + KEY `FK5B92B164992B5A41` (`student_id`), + CONSTRAINT `FK5B92B164992B5A41` FOREIGN KEY (`student_id`) REFERENCES `student` (`id`), + CONSTRAINT `FK5B92B164224FD013` FOREIGN KEY (`location_id`) REFERENCES `location` (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +/*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `day_by_day_decision` @@ -220,30 +237,31 @@ UNLOCK TABLES; -- --- Table structure for table `day_by_day_decision_student` +-- Table structure for table `day_by_day_decision_otherstudent` -- -DROP TABLE IF EXISTS `day_by_day_decision_student`; +DROP TABLE IF EXISTS `day_by_day_decision_otherstudent`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; -CREATE TABLE `day_by_day_decision_student` ( - `day_by_day_decision_id` bigint(20) NOT NULL, - `otherStudents_id` bigint(20) NOT NULL, - UNIQUE KEY `otherStudents_id` (`otherStudents_id`), - KEY `FK19B3660EED8740B` (`day_by_day_decision_id`), - KEY `FK19B366031A9F4B4` (`otherStudents_id`), - CONSTRAINT `FK19B366031A9F4B4` FOREIGN KEY (`otherStudents_id`) REFERENCES `student` (`id`), - CONSTRAINT `FK19B3660EED8740B` FOREIGN KEY (`day_by_day_decision_id`) REFERENCES `day_by_day_decision` (`id`) +CREATE TABLE `day_by_day_decision_otherstudent` ( + `id` bigint(20) NOT NULL AUTO_INCREMENT, + `dayByDayDecision_id` bigint(20) NOT NULL, + `otherStudent_id` bigint(20) NOT NULL, + PRIMARY KEY (`id`), + KEY `FK5751A40675FB192A` (`dayByDayDecision_id`), + KEY `FK5751A40623F64551` (`otherStudent_id`), + CONSTRAINT `FK5751A40623F64551` FOREIGN KEY (`otherStudent_id`) REFERENCES `student` (`id`), + CONSTRAINT `FK5751A40675FB192A` FOREIGN KEY (`dayByDayDecision_id`) REFERENCES `day_by_day_decision` (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- --- Dumping data for table `day_by_day_decision_student` +-- Dumping data for table `day_by_day_decision_otherstudent` -- -LOCK TABLES `day_by_day_decision_student` WRITE; -/*!40000 ALTER TABLE `day_by_day_decision_student` DISABLE KEYS */; -/*!40000 ALTER TABLE `day_by_day_decision_student` ENABLE KEYS */; +LOCK TABLES `day_by_day_decision_otherstudent` WRITE; +/*!40000 ALTER TABLE `day_by_day_decision_otherstudent` DISABLE KEYS */; +/*!40000 ALTER TABLE `day_by_day_decision_otherstudent` ENABLE KEYS */; UNLOCK TABLES; -- @@ -858,4 +876,4 @@ /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; --- Dump completed on 2009-10-19 22:05:41 +-- Dump completed on 2009-10-30 22:37:53 Added: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/dao/HibernateDayByDayOtherStudentDecisionsDao.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/dao/HibernateDayByDayOtherStudentDecisionsDao.java (rev 0) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/dao/HibernateDayByDayOtherStudentDecisionsDao.java 2009-10-30 22:46:20 UTC (rev 351) @@ -0,0 +1,11 @@ +package edu.asu.commons.mme.dao; + +import edu.asu.commons.mme.entity.DayByDayOtherStudentDecisions; + +public class HibernateDayByDayOtherStudentDecisionsDao extends HibernateDao<DayByDayOtherStudentDecisions> { + + public HibernateDayByDayOtherStudentDecisionsDao() { + super(DayByDayOtherStudentDecisions.class); + } + +} Modified: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayDecisions.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayDecisions.java 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayDecisions.java 2009-10-30 22:46:20 UTC (rev 351) @@ -1,20 +1,16 @@ package edu.asu.commons.mme.entity; import java.io.Serializable; -import java.util.List; import javax.persistence.Column; import javax.persistence.Entity; -import javax.persistence.FetchType; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; import javax.persistence.Table; -import org.hibernate.annotations.CollectionOfElements; - @Entity @Table(name="day_by_day_decision") public class DayByDayDecisions implements Serializable { @@ -43,8 +39,9 @@ @JoinColumn(nullable=false) private Student student; + /*@OneToMany(mappedBy = "dayByDayDecision") @CollectionOfElements(fetch = FetchType.EAGER) - private List<Student> otherStudents; + private List<DayByDayOtherStudentDecisions> dayByDayOtherStudentDecisions;*/ public void setId(Long id) { this.id = id; @@ -93,12 +90,13 @@ return dayNumber; } - public void setOtherStudents(List<Student> otherStudents) { - this.otherStudents = otherStudents; + /*public void setDayByDayOtherStudentDecisions( + List<DayByDayOtherStudentDecisions> dayByDayOtherStudentDecisions) { + this.dayByDayOtherStudentDecisions = dayByDayOtherStudentDecisions; } - public List<Student> getOtherStudents() { - return otherStudents; - } + public List<DayByDayOtherStudentDecisions> getDayByDayOtherStudentDecisions() { + return dayByDayOtherStudentDecisions; + }*/ } Added: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayOtherStudentDecisions.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayOtherStudentDecisions.java (rev 0) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/entity/DayByDayOtherStudentDecisions.java 2009-10-30 22:46:20 UTC (rev 351) @@ -0,0 +1,59 @@ +package edu.asu.commons.mme.entity; + +import java.io.Serializable; +import java.util.List; + +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.ManyToOne; +import javax.persistence.OneToMany; +import javax.persistence.Table; + +@Entity +@Table(name="day_by_day_decision_otherStudent") +public class DayByDayOtherStudentDecisions implements Serializable { + + /** + * + */ + private static final long serialVersionUID = 7785433507972115797L; + + @Id + @GeneratedValue + private Long id; + + @ManyToOne + @JoinColumn(nullable = false) + private DayByDayDecisions dayByDayDecision; + + @ManyToOne + @JoinColumn(nullable = false) + private Student otherStudent; + + public void setId(Long id) { + this.id = id; + } + + public Long getId() { + return id; + } + + public void setDayByDayDecision(DayByDayDecisions dayByDayDecision) { + this.dayByDayDecision = dayByDayDecision; + } + + public DayByDayDecisions getDayByDayDecision() { + return dayByDayDecision; + } + + public void setOtherStudent(Student otherStudent) { + this.otherStudent = otherStudent; + } + + public Student getOtherStudent() { + return otherStudent; + } + +} Modified: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/DayByDayDecisionsService.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/DayByDayDecisionsService.java 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/DayByDayDecisionsService.java 2009-10-30 22:46:20 UTC (rev 351) @@ -10,12 +10,14 @@ import org.springframework.transaction.annotation.Transactional; import edu.asu.commons.mme.dao.HibernateDayByDayDecisionsDao; +import edu.asu.commons.mme.dao.HibernateDayByDayOtherStudentDecisionsDao; import edu.asu.commons.mme.dao.HibernateGameDao; import edu.asu.commons.mme.dao.HibernateGroupDao; import edu.asu.commons.mme.dao.HibernateGroupLocationDao; import edu.asu.commons.mme.dao.HibernateLocationDao; import edu.asu.commons.mme.dao.HibernateStudentDao; import edu.asu.commons.mme.entity.DayByDayDecisions; +import edu.asu.commons.mme.entity.DayByDayOtherStudentDecisions; import edu.asu.commons.mme.entity.Game; import edu.asu.commons.mme.entity.Group; import edu.asu.commons.mme.entity.GroupLocation; @@ -74,35 +76,39 @@ public class DayByDayDecisionsService extends Service.Base<DayByDayDecisions, HibernateDayByDayDecisionsDao> { - HibernateGameDao gameDao; + private HibernateGameDao gameDao; + private HibernateLocationDao locationDao; + private HibernateStudentDao studentDao; + private HibernateGroupLocationDao groupLocationDao; + private HibernateGroupDao groupDao; + private HibernateDayByDayOtherStudentDecisionsDao dayByDayOtherStudentDecisionsDao; + private double totalFishLeaving; + + static final String groupsWithinGame = "select distinct student.group from Student student where student.game =:current_game_id "; + static final String studentDecisionsForGame = "SELECT d FROM DayByDayDecisions d, Student s where s.game =:game and s=d.student"; + static final String getgroupLocation = "SELECT g FROM GroupLocation g where g.group =:group and g.location =:location"; + public void setGameDao(HibernateGameDao gameDao) { this.gameDao = gameDao; } - - HibernateLocationDao locationDao; + public void setLocationDao(HibernateLocationDao locationDao) { this.locationDao = locationDao; } - HibernateStudentDao studentDao; public void setStudentDao(HibernateStudentDao studentDao) { this.studentDao = studentDao; } - HibernateGroupLocationDao groupLocationDao; public void setGroupLocationDao(HibernateGroupLocationDao groupLocationDao) { this.groupLocationDao = groupLocationDao; } - HibernateGroupDao groupDao; - public void setGroupDao(HibernateGroupDao groupDao) { this.groupDao = groupDao; } - private double totalFishLeaving; - public double getTotalFishLeaving() { return totalFishLeaving; } @@ -111,10 +117,11 @@ this.totalFishLeaving = totalFishLeaving; } - static final String groupsWithinGame = "select distinct student.group from Student student where student.game =:current_game_id "; - static final String studentDecisionsForGame = "SELECT d FROM DayByDayDecisions d, Student s where s.game =:game and s=d.student"; - static final String groupLocation = "SELECT * FROM mme.group_location g where g.group =:group and g.location =:location;"; - + public void setDayByDayOtherStudentDecisionsDao( + HibernateDayByDayOtherStudentDecisionsDao dayByDayOtherStudentDecisionsDao) { + this.dayByDayOtherStudentDecisionsDao = dayByDayOtherStudentDecisionsDao; + } + public List<DayByDayDecisions> saveStudentDecision(DayByDayDecisions studentDecision,Game game) { getLogger().debug("Student Id: " + studentDecision.getStudent().getId() + @@ -173,7 +180,6 @@ DayByDayDecisions studentDecision = new DayByDayDecisions(); List<DayByDayDecisions> bay1Students = new ArrayList<DayByDayDecisions>(); - //Bay1Service bay1 = new Bay1Service(); // List<DayByDayDecisions> bay2Students = new ArrayList<DayByDayDecisions>(); // List<DayByDayDecisions> bay3Students = new ArrayList<DayByDayDecisions>(); @@ -261,13 +267,6 @@ * 5) New population at each bay */ - - // bay1.executeStrategy(); - - //print bay1 map for testing - - - /*Iterator<Long> keys = bay1StudentMap.keySet().iterator(); while(keys.hasNext()) { @@ -282,7 +281,7 @@ }*/ - calculateHarvest(bay1StudentMap,"Bay1"); + calculateHarvest(bay1StudentMap,"Bay1", game); /**calculateHarvest(bay2StudentMap,"Bay2"); calculateHarvest(bay3StudentMap,"Bay3"); calculateHarvest(harborStudentMap,"Harbor"); @@ -299,18 +298,22 @@ - public void calculateHarvest(Map<Long, List<DayByDayDecisions>> bay1StudentMap,String locationName) + public void calculateHarvest(Map<Long, List<DayByDayDecisions>> bay1StudentMap,String locationName, Game game) { // TODO Auto-generated method stub - double maxFishCapacity = 5.0; + double maxFishCapacity = 0.0; double amountPerAgent = 0.0; double actualPopulation = 0.0; double growth = 0.0; double fishLeaving = 0.0; Long groupId; + DayByDayOtherStudentDecisions otherStudents; + + maxFishCapacity = game.getGameConfig().getMaxFishHarvest(); + getLogger().debug("maxFishCapacity is : " + maxFishCapacity); List<DayByDayDecisions> groupStudentDecisions = new ArrayList<DayByDayDecisions>(); - getLogger().debug("bay1StudentMap size is : " + bay1StudentMap.size() + "location name is : " + locationName); + /*getLogger().debug("bay1StudentMap size is : " + bay1StudentMap.size() + "location name is : " + locationName); Iterator<Long> keys1 = bay1StudentMap.keySet().iterator(); while(keys1.hasNext()) { @@ -322,7 +325,7 @@ getLogger().info("decision is: " + decision.getDayNumber() + "location number: " + decision.getLocation().getLocationName()); } - } + }*/ try { Iterator<Long> keys = bay1StudentMap.keySet().iterator(); @@ -335,22 +338,30 @@ Group group = groupDao.find(groupId); GroupLocation groupLocation = new GroupLocation(); - groupLocation.setLocation(location); + /*groupLocation.setLocation(location); groupLocation.setGroup(group); - List<GroupLocation> groupLocations = groupLocationDao.findByExample(groupLocation); + List<GroupLocation> groupLocations = groupLocationDao.findByExample(groupLocation);*/ - getLogger().debug("groupLocations size is: " + groupLocations.size()); + Query query = groupLocationDao.getCurrentSession().createQuery(getgroupLocation); + query.setEntity("location", location); + query.setEntity("group", group); + Iterator i = query.list().iterator(); + while(i.hasNext()) + { + groupLocation = (GroupLocation)i.next(); + getLogger().debug("groupLocation id is: " + groupLocation.getId()); + } - if(groupLocations.size()== 1) + /*if(groupLocations.size()== 1) { groupLocation = groupLocations.get(0); } else { //Error, should result only one result - } + }*/ //get current population actualPopulation = groupLocation.getCurrentPopulation(); @@ -381,35 +392,44 @@ groupLocation.setFishLeaving(fishLeaving); - //4) Population after diffusion actualPopulation = actualPopulation + growth - fishLeaving; getLogger().info("Fish population at " + locationName + " after diffusion is: " + actualPopulation); groupLocationDao.save(groupLocation); - + List<DayByDayDecisions> tempStudentDecisions = new ArrayList<DayByDayDecisions>(); + tempStudentDecisions = groupStudentDecisions; for(DayByDayDecisions dayByDayDecision : groupStudentDecisions) { - //set earning dayByDayDecision.setEarnings(amountPerAgent); //set money - dayByDayDecision.setMoney(0.0); + + dayByDayDecision.setMoney(game.getMoney() * amountPerAgent); //set other students - List<Student> otherStudents = new ArrayList<Student>(); + //List<Student> otherStudents = new ArrayList<Student>(); + + Long currentStudentId = dayByDayDecision.getStudent().getId(); - for(DayByDayDecisions students:groupStudentDecisions) + getLogger().debug("For student id is: " + currentStudentId); + + for(DayByDayDecisions students:tempStudentDecisions) { + getLogger().debug("temp student id is: " + students.getStudent().getId()); + if(students.getStudent().getId() != currentStudentId) { - otherStudents.add(students.getStudent()); + getLogger().debug("other student id is: " + students.getStudent().getId()); + otherStudents = new DayByDayOtherStudentDecisions(); + otherStudents.setDayByDayDecision(dayByDayDecision); + otherStudents.setOtherStudent(students.getStudent()); + dayByDayOtherStudentDecisionsDao.save(otherStudents); + } } - dayByDayDecision.setOtherStudents(otherStudents); - //Group group = dayByDayDecisions.getStudent().getGroup(); getDao().save(dayByDayDecision); } Modified: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java 2009-10-30 22:46:20 UTC (rev 351) @@ -143,7 +143,7 @@ { assignGroups(game); getLogger().debug("system has assigned groups. "); - pushBlock(game); + //pushBlock(game); flag = true; } else @@ -191,6 +191,7 @@ { getLogger().debug("game state is NOT null..."); block = newGameState.getCurrentBlock(); + initializeCurrentBlock(block); msgHandler.sendBlock(block,newGameState); } @@ -626,7 +627,7 @@ Game newGame = saveGameState(currentBlock,currentRound,game); getLogger().debug("question group sizes is : " + newGame.getCurrentBlock().getQuestionGroups().size()); //initializeCurrentBlock(newGame.getCurrentBlock()); - initializeGame(newGame); + //initializeGame(newGame); getLogger().debug("Module is " + newGame.getCurrentBlock().getModule().getId() + "Block sent to the server is: " + currentBlock.getDescription()); return newGame; } @@ -747,12 +748,6 @@ GameConfig gameconfig = game.getGameConfig(); Hibernate.initialize(gameconfig); - /*for(Location location:gameconfig.getLocations()) - { - Hibernate.initialize(location); - - }*/ - Round round = game.getCurrentRound(); Hibernate.initialize(round); /*for(GameRound gameRound:round.getGameRounds()) @@ -766,8 +761,6 @@ e.printStackTrace(); } //Hibernate.initialize(gameconfig.getGameRounds()); - - } private void initializeModule(Module module) @@ -809,10 +802,11 @@ } } - @SuppressWarnings("unused") + private void initializeCurrentBlock(Block block) { Hibernate.initialize(block); + Hibernate.initialize(block.getQuestionGroups()); Iterator<QuestionGroup> iteratorquestionGrp = block.getQuestionGroups().iterator(); { while(iteratorquestionGrp.hasNext()) Modified: mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java =================================================================== --- mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java 2009-10-30 22:46:20 UTC (rev 351) @@ -75,7 +75,7 @@ msg.setTimestamp(System.currentTimeMillis()); msg.setBody(block); AcknowledgeMessage ack = msgBroker.routeMessageToService(msg, null); - if(block!=null) + /*if(block!=null) { //int duration = block.getDuration(); @@ -97,8 +97,8 @@ { System.out.println("Game is Over..." + msg); } +*/ - /*AcknowledgeMessage ack = msgBroker.routeMessageToService(msg, null); logger.info("Ack received from client for message " + msg + "is : " + ack); */ Modified: mentalmodels/trunk/src/main/webapp/WEB-INF/applicationContext.xml =================================================================== --- mentalmodels/trunk/src/main/webapp/WEB-INF/applicationContext.xml 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/webapp/WEB-INF/applicationContext.xml 2009-10-30 22:46:20 UTC (rev 351) @@ -25,6 +25,7 @@ http://www.springframework.org/schema/security/spring-security-2.0.4.xsd"> + <!-- Flex related information started --> <flex:message-broker> <flex:message-service @@ -113,6 +114,9 @@ <property name='sessionFactory' ref='sessionFactory'/> </bean> + <bean id='dayByDayOtherStudentDecisionsDao' class='edu.asu.commons.mme.dao.HibernateDayByDayOtherStudentDecisionsDao'> + <property name='sessionFactory' ref='sessionFactory'/> + </bean> <!-- spring managed service layer --> <bean id='gameService' class='edu.asu.commons.mme.service.GameService'> @@ -139,7 +143,9 @@ <property name='groupDao' ref='groupDao'/> <property name='gameDao' ref='gameDao'/> <property name='groupLocationDao' ref='groupLocationDao'/> + <property name='dayByDayOtherStudentDecisionsDao' ref='dayByDayOtherStudentDecisionsDao'/> + </bean> <bean id='roundService' class='edu.asu.commons.mme.service.RoundService'> Modified: mentalmodels/trunk/src/main/webapp/WEB-INF/hibernate.cfg.xml =================================================================== --- mentalmodels/trunk/src/main/webapp/WEB-INF/hibernate.cfg.xml 2009-10-30 22:18:42 UTC (rev 350) +++ mentalmodels/trunk/src/main/webapp/WEB-INF/hibernate.cfg.xml 2009-10-30 22:46:20 UTC (rev 351) @@ -7,21 +7,18 @@ "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd"> <hibernate-configuration> <session-factory> + <mapping class='edu.asu.commons.mme.entity.GameConfig'/> <mapping class='edu.asu.commons.mme.entity.Game'/> - <mapping class='edu.asu.commons.mme.entity.Round'/> + <mapping class='edu.asu.commons.mme.entity.Round'/> <mapping class='edu.asu.commons.mme.entity.GameRound'/> <mapping class='edu.asu.commons.mme.entity.Location'/> - <!-- - <mapping class='edu.asu.commons.mme.entity.RoundLocation'/> - --> <mapping class='edu.asu.commons.mme.entity.Communication'/> <mapping class='edu.asu.commons.mme.entity.Group'/> <mapping class='edu.asu.commons.mme.entity.Student'/> <mapping class='edu.asu.commons.mme.entity.GroupLocation'/> - <mapping class='edu.asu.commons.mme.entity.StudentRoundConfig'/> <mapping class='edu.asu.commons.mme.entity.StudentStrategy'/> <mapping class='edu.asu.commons.mme.entity.DayOutput'/> @@ -41,9 +38,10 @@ <mapping class='edu.asu.commons.mme.entity.ModuleRoundConfig'/> <mapping class='edu.asu.commons.mme.entity.InformationWindow'/> <mapping class='edu.asu.commons.mme.entity.BlockInformationWindow'/> + <mapping class='edu.asu.commons.mme.entity.DayByDayDecisions'/> + <mapping class='edu.asu.commons.mme.entity.DayByDayOtherStudentDecisions'/> - </session-factory> </hibernate-configuration> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |