[virtualcommons-svn] SF.net SVN: virtualcommons:[427] mentalmodels/trunk
Status: Beta
Brought to you by:
alllee
From: <see...@us...> - 2010-01-12 21:42:54
|
Revision: 427 http://virtualcommons.svn.sourceforge.net/virtualcommons/?rev=427&view=rev Author: seematalele Date: 2010-01-12 21:42:47 +0000 (Tue, 12 Jan 2010) Log Message: ----------- 1) Added communication question with question type = "communication"for communication round in init-mme.sql so that flex can use it for displaying communication component. 2) Error was coming while creating game, resolved that error. Now it is working fine. 3)Conflict resolution of CommunicationC.mxml. Bugs - 1) MessageHanlder is trying run timer for communication round. But getting error - "(JDBCExceptionReporter.java:101) ERROR org.hibernate.util.JDBCExceptionReporter - Lock wait timeout exceeded; try restarting transaction." Modified Paths: -------------- mentalmodels/trunk/flex/src/custom/CommunicationC.mxml mentalmodels/trunk/src/main/db/init-mme.sql mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java Modified: mentalmodels/trunk/flex/src/custom/CommunicationC.mxml =================================================================== --- mentalmodels/trunk/flex/src/custom/CommunicationC.mxml 2010-01-07 05:17:04 UTC (rev 426) +++ mentalmodels/trunk/flex/src/custom/CommunicationC.mxml 2010-01-12 21:42:47 UTC (rev 427) @@ -72,6 +72,8 @@ <mx:method name="sendCommunication" result="messageHandler(event)"/> </mx:RemoteObject> + + <mx:VBox id="vbxMessages" width="500" height="300" verticalScrollPolicy="on"/> <mx:HBox> <mx:TextInput id="txtMessage" width="500"/> Modified: mentalmodels/trunk/src/main/db/init-mme.sql =================================================================== --- mentalmodels/trunk/src/main/db/init-mme.sql 2010-01-07 05:17:04 UTC (rev 426) +++ mentalmodels/trunk/src/main/db/init-mme.sql 2010-01-12 21:42:47 UTC (rev 427) @@ -4,10 +4,6 @@ -- ------------------------------------------------------ -- Server version 5.1.33-community --- This file contains the refactored MME database. Foolowing records have been removed : - -- Forecasting questions - -- Blocks with "Editing strategy" description and their corresponding question groups, infromation windows and questions - /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; @@ -646,7 +642,7 @@ PRIMARY KEY (`id`), KEY `FKBA823BE6CA626674` (`question_group_id`), CONSTRAINT `FKBA823BE6CA626674` FOREIGN KEY (`question_group_id`) REFERENCES `question_group` (`id`) -) ENGINE=InnoDB AUTO_INCREMENT=154 DEFAULT CHARSET=latin1; +) ENGINE=InnoDB AUTO_INCREMENT=156 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -655,7 +651,7 @@ LOCK TABLES `question` WRITE; /*!40000 ALTER TABLE `question` DISABLE KEYS */; -INSERT INTO `question` VALUES (1,0,'Most important goal:',1,'categorical',10),(2,0,'Second most important goal:',2,'categorical',10),(3,0,'Third most important goal:',4,'categorical',10),(4,0,'Compared to the most important goal, this goal is',3,'psychometric',10),(7,0,'An example of a scale would be',1,'psychometric',11),(8,0,'<ul>\r<li>Why did you design the strategy the way you did? What did you consider and why do you think your strategy is an adequate solution?</li>\r<li>What actions do you expect from the other fishermen in your group? Why do you think, they might act this way?</li>\r<li>How do you think your strategy will work? Will the fish population grow or shrink in the different bays? What earnings do you expect?</li>\r</ul>\r',1,'text',12),(9,0,'Compared to the most important goal, this goal is',5,'psychometric',10),(10,0,'<b>Most important goal:</b>',1,'categorical',13),(11,0,'<b>Second most important goal:</b>',2,'categorical',13),(12,0,'Compared to the most important goal, this goal is',3,'psychometric',13),(13,0,'<b>Third most important goal:</b>',4,'categorical',13),(14,0,'Compared to the most important goal, this goal is',5,'psychometric',13),(15,0,'Over all, how much do like your group (i.e. the other players)?',1,'psychometric',14),(16,0,'How important is it for you what the others think about you and your behavior (i.e. your reputation in the group)?',2,'psychometric',14),(17,0,'How important is it for you that the others can reach their goals (i.e. the outcomes are fair)?',3,'psychometric',14),(18,0,'What do you think, how important is it for the others that you can reach your goals (i.e. the outcomes are fair)?',4,'psychometric',14),(19,0,'Do you perceive the group as a team or as competing players?',5,'psychometric',14),(20,0,'How much do you trust the others in your group?',1,'psychometric',15),(21,0,'How important is it for you that the others in your group can and do trust you?',2,'psychometric',15),(22,0,'How much do you think your group trying to coordinate their actions to reach better outcomes for all?',3,'psychometric',15),(23,1,'How much are you trying to follow rules or agreements that emerged from the communication?',4,'psychometric',15),(24,1,'How much do you think <i>the others</i> are trying to follow rules or agreements that emerged from the communica-tion?',5,'psychometric',15),(25,0,'Do you feel a sense of ‘commitment’ to act in the way you specified in your strategy?',1,'psychometric',16),(26,0,'Would you feel any discomfort or tension if you would act differently than you specified in your strategy?',2,'psychometric',16),(27,0,'Do you feel any sort of ‘social pressure’ to act in the way you specified in your strategy?',3,'psychometric',16),(28,0,'Would you feel guilt or shame if you had acted differently than you specified in your strategy?',4,'psychometric',16),(29,0,'Are you afraid of some sort of ‘punishment’ if you had acted differently as specified in your strategy?',5,'psychometric',16),(30,0,'How well did you understand the dynamics of the fish population?',1,'psychometric',17),(31,0,'Did the others in your group understand the dynamics better or worse than you?',2,'psychometric',17),(32,0,'How confident are you in having developed a strategy that leads to ‘good’ outcomes regarding your goals?',3,'psychometric',17),(33,0,'How much does your strategy depend on how the others in the group will act to reach the desired outcomes?',4,'psychometric',17),(34,0,'Would you classify your strategy as ‘safe’ in the sense of having acceptable but suboptimal results for sure, or rather as ‘risky’ in the sense of having the optimal results if everything runs like expected or very poor results otherwise?',5,'psychometric',17),(37,0,'',1,'strategydesign',9),(39,0,'',1,'daybydaydecisions',24),(40,0,'',1,'psychometric',27),(41,0,'… better understand the dynamics of the fish population.',1,'psychometric',29),(42,0,'… better understand the other fishermen in my group.',2,'psychometric',29),(43,0,'… better understand how to design the strategy.',3,'psychometric',29),(44,0,'… feel a ‘team spirit’ in the group.',4,'psychometric',29),(45,0,'… appraise the other fishermen in my group differently. Now I think about the others…',5,'psychometric',29),(46,0,'… better understand the dynamics of the fish population.',1,'psychometric',30),(47,0,'… better understand the other fishermen.',2,'psychometric',30),(48,0,'… better understand how to design the strategy.',3,'psychometric',30),(49,0,'… feel a ‘team spirit’ in the group.',4,'psychometric',30),(50,0,'… appraise the other fishermen in my group differently. Now I think about the others …',5,'psychometric',30),(51,0,'Did the communication have any form of reference to how to fish or design the strategy?',1,'categorical',31),(54,0,'',1,'psychometric',32),(55,0,'',2,'psychometric',32),(56,0,'',3,'psychometric',32),(57,0,'',4,'psychometric',32),(58,0,'',5,'psychometric',32),(59,0,'How clear is it to you, that you have to fish conforming to this rule, agreement or coordination attempt?',1,'psychometric',33),(60,0,'Do you think the other fishermen understood how they have to act according to this rule?<br>I think the others… ',2,'psychometric',33),(61,0,'Will you follow the rule, agreement, or coordination attempt that emerged from communication?<br>I will follow the rule…',3,'psychometric',33),(62,0,'Do you think, the other fishermen in you group will follow the rule, agreement, or coordination attempt?<br>\rI think, the others will… ',4,'psychometric',33),(63,0,'Considering the effects you expect for following the rule and your expectations of how the group will follow the rule, do you think the group will do better or worse due to the rule?',5,'psychometric',33),(64,0,'New understanding of fish dynamics',1,'text',34),(65,0,'New Expectations on how the others of the group will act',2,'text',34),(66,0,'Ideas for improving your strategy',3,'text',34),(67,0,'How interesting was the experiment for you?',1,'psychometric',35),(68,0,'How would you rate the effort you invested to design your strategy?',2,'psychometric',35),(69,0,'How difficult was it to understand the problem?',3,'psychometric',35),(70,0,'How difficult was it to find a good strategy?',4,'psychometric',35),(71,0,'How clear was it what you had to do?',5,'psychometric',35),(72,0,'How many times have you participated in problem solving experiments similar to this one?',1,'text',36),(73,0,'If you already participated in such experiments, when was the last time?',2,'categorical',36),(74,0,'Comments and Feedback',1,'text',37),(75,0,'',1,'strategydesign',40),(77,0,'',1,'daybydaydecisions',55),(78,0,'',1,'psychometric',58),(79,0,'',2,'psychometric',27),(80,0,'I feel the outcomes are:',3,'psychometric',27),(81,0,'',1,'psychometric',59),(82,0,'',2,'psychometric',59),(83,0,'',3,'psychometric',59),(84,0,'',4,'psychometric',59),(85,0,'',5,'psychometric',59),(86,0,'I did not understand the dynamics of the fish population well enough.',1,'psychometric',60),(87,0,'Some of the other fishermen did not understand the dynamics of the fish population well enough.',2,'psychometric',60),(88,0,'The actions of the others in my group did not help my strategy work well.',3,'psychometric',60),(89,0,'Some of the other fishermen acted too reluctantly (harvested too few).',4,'psychometric',60),(90,0,'Some of the other fishermen acted too aggressively (harvested too much).',5,'psychometric',60),(91,0,'The group was too uncoordinated',6,'psychometric',60),(92,0,'The group did not follow the rules or agreements that emerged from the communication enough.',7,'psychometric',60),(93,0,'The rules or agreements that emerged from the communication did not work out well.',8,'psychometric',60),(94,0,'What were the most important reasons for you to deviate from your strategy during the day-by-day decisions?<br>\rIf you did not deviate from your strategy then please write something like \"No difference\" in the text field.',1,'text',61),(95,0,'New understanding of fish dynamics',1,'text',62),(96,0,'New expectations on how the others of the group will act',2,'text',62),(97,0,'Ideas for improving your strategy',3,'text',62),(98,0,'',2,'psychometric',58),(99,0,'I feel the outcomes are:',3,'psychometric',58),(100,0,'',1,'psychometric',63),(101,0,'',2,'psychometric',63),(102,0,'',3,'psychometric',63),(103,0,'',4,'psychometric',63),(104,0,'',5,'psychometric',63),(105,0,'I did not understand the dynamics of the fish population well enough.',1,'psychometric',64),(106,0,'Some of the other fishermen did not understand the dynamics of the fish population well enough',2,'psychometric',64),(107,0,'The actions of the others in my group did not help my strategy work well.',3,'psychometric',64),(108,0,'Some of the other fishermen acted too reluctantly (harvested too few).',4,'psychometric',64),(109,0,'Some of the other fishermen acted too aggressively (harvested too much).',5,'psychometric',64),(110,0,'The group was too uncoordinated',6,'psychometric',64),(111,0,'The group did not follow the rules or agreements that emerged from the communication enough.',7,'psychometric',64),(112,0,'The rules or agreements that emerged from the communication did not work out well.',8,'psychometric',64),(113,0,'What were the most important reasons for you to deviate from your strategy during the day-by-day decisions?<br>\rIf you did not deviate from your strategy then please write something like \"No difference\" in the text field.',1,'text',65),(114,0,'New understanding of fish dynamics',1,'text',66),(115,0,'New expectations on how the others of the group will act',2,'text',66),(116,0,'Ideas for improving your strategy',3,'text',66),(117,0,'Describe in your own words what the rule, agreement, or other coordination attempt states. Describe how you and the others should act and what would happen if one does not act in this way.<br>\rIf you cannot identify any sort of coordination attempt in the communication, write \"no coordination\" in the field below.<br>\r(The information you write in this field will be available the next time you edit your strategy.)',2,'text',31),(118,0,'How often do you play strategy games (i.e. any games where you have to anticipate the moves of other players and plan your own moves ahead, like computer games, card games, board games, etc)?',3,'categorical',36),(120,0,'<ul>\r<li>Why did you design the strategy the way you did? What did you consider and why do you think your strategy is an adequate solution?</li>\r<li>What actions do you expect from the other fishermen in your group? Why do you think, they might act this way?</li>\r<li>How do you think your strategy will work? Will the fish population grow or shrink in the different bays? What earnings do you expect?</li>\r</ul>\r',1,'text',42),(121,0,'Most important goal:',1,'categorical',43),(122,0,'Second most important goal:',2,'categorical',43),(123,0,'Compared to the most important goal, this goal is',3,'psychometric',43),(124,0,'Third most important goal:',4,'categorical',43),(125,0,'Compared to the most important goal, this goal is',5,'psychometric',43),(126,0,'<b>Most important goal:</b>',1,'categorical',44),(127,0,'<b>Second most important goal:</b>',2,'categorical',44),(128,0,'Compared to the most important goal, this goal is',3,'psychometric',44),(129,0,'<b>Third most important goal:</b>',4,'categorical',44),(130,0,'Compared to the most important goal, this goal is',5,'psychometric',44),(131,0,'Over all, how much do like your group (i.e. the other players)?',1,'psychometric',45),(132,0,'How important is it for you what the others think about you and your behavior (i.e. your reputation in the group)?',2,'psychometric',45),(133,0,'How important is it for you that the others can reach their goals (i.e. the outcomes are fair)?',3,'psychometric',45),(134,0,'What do you think, how important is it for the others that you can reach your goals (i.e. the outcomes are fair)?',4,'psychometric',45),(135,0,'Do you perceive the group as a team or as competing players?',5,'psychometric',45),(136,0,'How much do you trust the others in your group?',1,'psychometric',46),(137,0,'How important is it for you that the others in your group can and do trust you?',2,'psychometric',46),(138,0,'How much do you think your group trying to coordinate their actions to reach better outcomes for all?',3,'psychometric',46),(139,0,'How much are you trying to follow rules or agreements that emerged from the communication?',4,'psychometric',46),(140,0,'How much do you think <i>the others</i> are trying to follow rules or agreements that emerged from the communica-tion?',5,'psychometric',46),(141,0,'Do you feel a sense of ‘commitment’ to act in the way you specified in your strategy?',1,'psychometric',47),(142,0,'Would you feel any discomfort or tension if you would act differently than you specified in your strategy?',2,'psychometric',47),(143,0,'Do you feel any sort of ‘social pressure’ to act in the way you specified in your strategy?',3,'psychometric',47),(144,0,'Would you feel guilt or shame if you had acted differently than you specified in your strategy?',4,'psychometric',47),(145,0,'Are you afraid of some sort of ‘punishment’ if you had acted differently as specified in your strategy?',5,'psychometric',47),(146,0,'How well did you understand the dynamics of the fish population?',1,'psychometric',48),(147,0,'Did the others in your group understand the dynamics better or worse than you?',2,'psychometric',48),(148,0,'How confident are you in having developed a strategy that leads to ‘good’ outcomes regarding your goals?',3,'psychometric',48),(149,0,'How much does your strategy depend on how the others in the group will act to reach the desired outcomes?',4,'psychometric',48),(150,0,'Would you classify your strategy as ‘safe’ in the sense of having acceptable but suboptimal results for sure, or rather as ‘risky’ in the sense of having the optimal results if everything runs like expected or very poor results otherwise?',5,'psychometric',48),(153,0,'',1,'daybydaydecisions',67); +INSERT INTO `question` VALUES (1,0,'Most important goal:',1,'categorical',10),(2,0,'Second most important goal:',2,'categorical',10),(3,0,'Third most important goal:',4,'categorical',10),(4,0,'Compared to the most important goal, this goal is',3,'psychometric',10),(7,0,'An example of a scale would be',1,'psychometric',11),(8,0,'<ul>\r<li>Why did you design the strategy the way you did? What did you consider and why do you think your strategy is an adequate solution?</li>\r<li>What actions do you expect from the other fishermen in your group? Why do you think, they might act this way?</li>\r<li>How do you think your strategy will work? Will the fish population grow or shrink in the different bays? What earnings do you expect?</li>\r</ul>\r',1,'text',12),(9,0,'Compared to the most important goal, this goal is',5,'psychometric',10),(10,0,'<b>Most important goal:</b>',1,'categorical',13),(11,0,'<b>Second most important goal:</b>',2,'categorical',13),(12,0,'Compared to the most important goal, this goal is',3,'psychometric',13),(13,0,'<b>Third most important goal:</b>',4,'categorical',13),(14,0,'Compared to the most important goal, this goal is',5,'psychometric',13),(15,0,'Over all, how much do like your group (i.e. the other players)?',1,'psychometric',14),(16,0,'How important is it for you what the others think about you and your behavior (i.e. your reputation in the group)?',2,'psychometric',14),(17,0,'How important is it for you that the others can reach their goals (i.e. the outcomes are fair)?',3,'psychometric',14),(18,0,'What do you think, how important is it for the others that you can reach your goals (i.e. the outcomes are fair)?',4,'psychometric',14),(19,0,'Do you perceive the group as a team or as competing players?',5,'psychometric',14),(20,0,'How much do you trust the others in your group?',1,'psychometric',15),(21,0,'How important is it for you that the others in your group can and do trust you?',2,'psychometric',15),(22,0,'How much do you think your group trying to coordinate their actions to reach better outcomes for all?',3,'psychometric',15),(23,1,'How much are you trying to follow rules or agreements that emerged from the communication?',4,'psychometric',15),(24,1,'How much do you think <i>the others</i> are trying to follow rules or agreements that emerged from the communica-tion?',5,'psychometric',15),(25,0,'Do you feel a sense of ‘commitment’ to act in the way you specified in your strategy?',1,'psychometric',16),(26,0,'Would you feel any discomfort or tension if you would act differently than you specified in your strategy?',2,'psychometric',16),(27,0,'Do you feel any sort of ‘social pressure’ to act in the way you specified in your strategy?',3,'psychometric',16),(28,0,'Would you feel guilt or shame if you had acted differently than you specified in your strategy?',4,'psychometric',16),(29,0,'Are you afraid of some sort of ‘punishment’ if you had acted differently as specified in your strategy?',5,'psychometric',16),(30,0,'How well did you understand the dynamics of the fish population?',1,'psychometric',17),(31,0,'Did the others in your group understand the dynamics better or worse than you?',2,'psychometric',17),(32,0,'How confident are you in having developed a strategy that leads to ‘good’ outcomes regarding your goals?',3,'psychometric',17),(33,0,'How much does your strategy depend on how the others in the group will act to reach the desired outcomes?',4,'psychometric',17),(34,0,'Would you classify your strategy as ‘safe’ in the sense of having acceptable but suboptimal results for sure, or rather as ‘risky’ in the sense of having the optimal results if everything runs like expected or very poor results otherwise?',5,'psychometric',17),(37,0,'',1,'daybydaydecisions',9),(39,0,'',1,'daybydaydecisions',24),(40,0,'',1,'psychometric',27),(41,0,'… better understand the dynamics of the fish population.',1,'psychometric',29),(42,0,'… better understand the other fishermen in my group.',2,'psychometric',29),(43,0,'… better understand how to design the strategy.',3,'psychometric',29),(44,0,'… feel a ‘team spirit’ in the group.',4,'psychometric',29),(45,0,'… appraise the other fishermen in my group differently. Now I think about the others…',5,'psychometric',29),(46,0,'… better understand the dynamics of the fish population.',1,'psychometric',30),(47,0,'… better understand the other fishermen.',2,'psychometric',30),(48,0,'… better understand how to design the strategy.',3,'psychometric',30),(49,0,'… feel a ‘team spirit’ in the group.',4,'psychometric',30),(50,0,'… appraise the other fishermen in my group differently. Now I think about the others …',5,'psychometric',30),(51,0,'Did the communication have any form of reference to how to fish or design the strategy?',1,'categorical',31),(54,0,'',1,'psychometric',32),(55,0,'',2,'psychometric',32),(56,0,'',3,'psychometric',32),(57,0,'',4,'psychometric',32),(58,0,'',5,'psychometric',32),(59,0,'How clear is it to you, that you have to fish conforming to this rule, agreement or coordination attempt?',1,'psychometric',33),(60,0,'Do you think the other fishermen understood how they have to act according to this rule?<br>I think the others… ',2,'psychometric',33),(61,0,'Will you follow the rule, agreement, or coordination attempt that emerged from communication?<br>I will follow the rule…',3,'psychometric',33),(62,0,'Do you think, the other fishermen in you group will follow the rule, agreement, or coordination attempt?<br>\rI think, the others will… ',4,'psychometric',33),(63,0,'Considering the effects you expect for following the rule and your expectations of how the group will follow the rule, do you think the group will do better or worse due to the rule?',5,'psychometric',33),(64,0,'New understanding of fish dynamics',1,'text',34),(65,0,'New Expectations on how the others of the group will act',2,'text',34),(66,0,'Ideas for improving your strategy',3,'text',34),(67,0,'How interesting was the experiment for you?',1,'psychometric',35),(68,0,'How would you rate the effort you invested to design your strategy?',2,'psychometric',35),(69,0,'How difficult was it to understand the problem?',3,'psychometric',35),(70,0,'How difficult was it to find a good strategy?',4,'psychometric',35),(71,0,'How clear was it what you had to do?',5,'psychometric',35),(72,0,'How many times have you participated in problem solving experiments similar to this one?',1,'text',36),(73,0,'If you already participated in such experiments, when was the last time?',2,'categorical',36),(74,0,'Comments and Feedback',1,'text',37),(75,0,'',1,'daybydaydecisions',40),(77,0,'',1,'daybydaydecisions',55),(78,0,'',1,'psychometric',58),(79,0,'',2,'psychometric',27),(80,0,'I feel the outcomes are:',3,'psychometric',27),(81,0,'',1,'psychometric',59),(82,0,'',2,'psychometric',59),(83,0,'',3,'psychometric',59),(84,0,'',4,'psychometric',59),(85,0,'',5,'psychometric',59),(86,0,'I did not understand the dynamics of the fish population well enough.',1,'psychometric',60),(87,0,'Some of the other fishermen did not understand the dynamics of the fish population well enough.',2,'psychometric',60),(88,0,'The actions of the others in my group did not help my strategy work well.',3,'psychometric',60),(89,0,'Some of the other fishermen acted too reluctantly (harvested too few).',4,'psychometric',60),(90,0,'Some of the other fishermen acted too aggressively (harvested too much).',5,'psychometric',60),(91,0,'The group was too uncoordinated',6,'psychometric',60),(92,0,'The group did not follow the rules or agreements that emerged from the communication enough.',7,'psychometric',60),(93,0,'The rules or agreements that emerged from the communication did not work out well.',8,'psychometric',60),(94,0,'What were the most important reasons for you to deviate from your strategy during the day-by-day decisions?<br>\rIf you did not deviate from your strategy then please write something like \"No difference\" in the text field.',1,'text',61),(95,0,'New understanding of fish dynamics',1,'text',62),(96,0,'New expectations on how the others of the group will act',2,'text',62),(97,0,'Ideas for improving your strategy',3,'text',62),(98,0,'',2,'psychometric',58),(99,0,'I feel the outcomes are:',3,'psychometric',58),(100,0,'',1,'psychometric',63),(101,0,'',2,'psychometric',63),(102,0,'',3,'psychometric',63),(103,0,'',4,'psychometric',63),(104,0,'',5,'psychometric',63),(105,0,'I did not understand the dynamics of the fish population well enough.',1,'psychometric',64),(106,0,'Some of the other fishermen did not understand the dynamics of the fish population well enough',2,'psychometric',64),(107,0,'The actions of the others in my group did not help my strategy work well.',3,'psychometric',64),(108,0,'Some of the other fishermen acted too reluctantly (harvested too few).',4,'psychometric',64),(109,0,'Some of the other fishermen acted too aggressively (harvested too much).',5,'psychometric',64),(110,0,'The group was too uncoordinated',6,'psychometric',64),(111,0,'The group did not follow the rules or agreements that emerged from the communication enough.',7,'psychometric',64),(112,0,'The rules or agreements that emerged from the communication did not work out well.',8,'psychometric',64),(113,0,'What were the most important reasons for you to deviate from your strategy during the day-by-day decisions?<br>\rIf you did not deviate from your strategy then please write something like \"No difference\" in the text field.',1,'text',65),(114,0,'New understanding of fish dynamics',1,'text',66),(115,0,'New expectations on how the others of the group will act',2,'text',66),(116,0,'Ideas for improving your strategy',3,'text',66),(117,0,'Describe in your own words what the rule, agreement, or other coordination attempt states. Describe how you and the others should act and what would happen if one does not act in this way.<br>\rIf you cannot identify any sort of coordination attempt in the communication, write \"no coordination\" in the field below.<br>\r(The information you write in this field will be available the next time you edit your strategy.)',2,'text',31),(118,0,'How often do you play strategy games (i.e. any games where you have to anticipate the moves of other players and plan your own moves ahead, like computer games, card games, board games, etc)?',3,'categorical',36),(120,0,'<ul>\r<li>Why did you design the strategy the way you did? What did you consider and why do you think your strategy is an adequate solution?</li>\r<li>What actions do you expect from the other fishermen in your group? Why do you think, they might act this way?</li>\r<li>How do you think your strategy will work? Will the fish population grow or shrink in the different bays? What earnings do you expect?</li>\r</ul>\r',1,'text',42),(121,0,'Most important goal:',1,'categorical',43),(122,0,'Second most important goal:',2,'categorical',43),(123,0,'Compared to the most important goal, this goal is',3,'psychometric',43),(124,0,'Third most important goal:',4,'categorical',43),(125,0,'Compared to the most important goal, this goal is',5,'psychometric',43),(126,0,'<b>Most important goal:</b>',1,'categorical',44),(127,0,'<b>Second most important goal:</b>',2,'categorical',44),(128,0,'Compared to the most important goal, this goal is',3,'psychometric',44),(129,0,'<b>Third most important goal:</b>',4,'categorical',44),(130,0,'Compared to the most important goal, this goal is',5,'psychometric',44),(131,0,'Over all, how much do like your group (i.e. the other players)?',1,'psychometric',45),(132,0,'How important is it for you what the others think about you and your behavior (i.e. your reputation in the group)?',2,'psychometric',45),(133,0,'How important is it for you that the others can reach their goals (i.e. the outcomes are fair)?',3,'psychometric',45),(134,0,'What do you think, how important is it for the others that you can reach your goals (i.e. the outcomes are fair)?',4,'psychometric',45),(135,0,'Do you perceive the group as a team or as competing players?',5,'psychometric',45),(136,0,'How much do you trust the others in your group?',1,'psychometric',46),(137,0,'How important is it for you that the others in your group can and do trust you?',2,'psychometric',46),(138,0,'How much do you think your group trying to coordinate their actions to reach better outcomes for all?',3,'psychometric',46),(139,0,'How much are you trying to follow rules or agreements that emerged from the communication?',4,'psychometric',46),(140,0,'How much do you think <i>the others</i> are trying to follow rules or agreements that emerged from the communica-tion?',5,'psychometric',46),(141,0,'Do you feel a sense of ‘commitment’ to act in the way you specified in your strategy?',1,'psychometric',47),(142,0,'Would you feel any discomfort or tension if you would act differently than you specified in your strategy?',2,'psychometric',47),(143,0,'Do you feel any sort of ‘social pressure’ to act in the way you specified in your strategy?',3,'psychometric',47),(144,0,'Would you feel guilt or shame if you had acted differently than you specified in your strategy?',4,'psychometric',47),(145,0,'Are you afraid of some sort of ‘punishment’ if you had acted differently as specified in your strategy?',5,'psychometric',47),(146,0,'How well did you understand the dynamics of the fish population?',1,'psychometric',48),(147,0,'Did the others in your group understand the dynamics better or worse than you?',2,'psychometric',48),(148,0,'How confident are you in having developed a strategy that leads to ‘good’ outcomes regarding your goals?',3,'psychometric',48),(149,0,'How much does your strategy depend on how the others in the group will act to reach the desired outcomes?',4,'psychometric',48),(150,0,'Would you classify your strategy as ‘safe’ in the sense of having acceptable but suboptimal results for sure, or rather as ‘risky’ in the sense of having the optimal results if everything runs like expected or very poor results otherwise?',5,'psychometric',48),(153,0,'',1,'daybydaydecisions',67),(155,1,'',1,'communication',28); /*!40000 ALTER TABLE `question` ENABLE KEYS */; UNLOCK TABLES; @@ -910,4 +906,4 @@ /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; --- Dump completed on 2009-11-30 19:23:38 +-- Dump completed on 2010-01-12 21:34:16 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 2010-01-07 05:17:04 UTC (rev 426) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/service/GameService.java 2010-01-12 21:42:47 UTC (rev 427) @@ -58,14 +58,14 @@ private int blockSeqNo; - + MessageHandler msgHandler; - + static final String roundNo = "SELECT gameRound.seqNo " + - "FROM GameRound gameRound, Game game " + - "where gameRound.gameConfig =:gameConfig and gameRound.round =:currentRound"; - - + "FROM GameRound gameRound, Game game " + + "where gameRound.gameConfig =:gameConfig and gameRound.round =:currentRound"; + + public GameService() { } @@ -94,41 +94,41 @@ public Game createGame(Game game) { - //getLogger().debug("game came from flex is : " + game.getGameCode()); + //getLogger().debug("game came from flex is : " + game.getGameCode()); - Game newGame = new Game(); - //currentGame = game; - try - { - newGame.setGameCode(game.getGameCode()); - newGame.setMoney(game.getMoney()); - newGame.setTimestamp(game.getTimestamp()); + Game newGame = new Game(); + //currentGame = game; + try + { + newGame.setGameCode(game.getGameCode()); + newGame.setMoney(game.getMoney()); + newGame.setTimestamp(game.getTimestamp()); - //FIXME: Currently using default GameConfiguration whose id is 1 - GameConfig gameConfig = gameConfigDao.find(1L); - newGame.setGameConfig(gameConfig); - getDao().save(newGame); - String str = newGame.getGameCode()+newGame.getId(); + //FIXME: Currently using default GameConfiguration whose id is 1 + GameConfig gameConfig = gameConfigDao.find(1L); + newGame.setGameConfig(gameConfig); + getDao().save(newGame); + String str = newGame.getGameCode()+newGame.getId(); - if(getDao().findAllByProperty("gameCode", str).size() != 0) - { - //getLogger().debug("in if loop "); - newGame = null; - } - else - { - newGame.setGameCode(str); - getDao().save(newGame); - getLogger().info("Created the game: " + newGame.getId()); - //setAllLocations(gameConfig); - initializeGame(newGame); - } - }catch(Exception e) - { - e.printStackTrace(); - } - getLogger().debug("current game from flex is: " + newGame.getId()); - return newGame; + if(getDao().findAllByProperty("gameCode", str).size() != 0) + { + //getLogger().debug("in if loop "); + newGame = null; + } + else + { + newGame.setGameCode(str); + getDao().save(newGame); + getLogger().info("Created the game: " + newGame.getId()); + //setAllLocations(gameConfig); + initializeGame(newGame); + } + }catch(Exception e) + { + e.printStackTrace(); + } + getLogger().debug("current game from flex is: " + newGame.getId()); + return newGame; } @@ -144,7 +144,7 @@ public boolean startGame(Game game) { boolean flag = false; - + if(isSufficientStudents(game)) { assignGroups(game); @@ -156,7 +156,7 @@ { flag = false; } - + return flag; } @@ -167,7 +167,7 @@ Game currentGame = getDao().find(game.getId()); if(getStudentDao().findAllByProperty("game", currentGame).size() > 0) flag = true; - + return flag; } @@ -184,32 +184,32 @@ int i=0; try { - i++; - newGameState = getBlock(game); - game = newGameState; - if(newGameState == null) - { - getLogger().debug("game state is null..."); - msgHandler.sendBlock(null); - } - else - { - getLogger().debug("game state is NOT null..."); - block = newGameState.getCurrentBlock(); - initializeGame(newGameState); - msgHandler.sendBlock(newGameState); - } - + i++; + newGameState = getBlock(game); + game = newGameState; + if(newGameState == null) + { + getLogger().debug("game state is null..."); + msgHandler.sendBlock(null); + } + else + { + getLogger().debug("game state is NOT null..."); + block = newGameState.getCurrentBlock(); + initializeGame(newGameState); + msgHandler.sendBlock(newGameState); + } + }catch (Exception e) { - getLogger().debug(e); + e.printStackTrace(); } } public void pushNextData(Game game) { // TODO Auto-generated method stub pushBlock(game); - + } - + public void assignGroups(Game currentGame) { @@ -324,10 +324,10 @@ grp.setNumber(++groupNo); groupDao.save(grp); getLogger().info("Group is created with id: " + grp.getId()); - + //set all location for the group setAllLocations(grp,groupSize); - + int studentNo = 1; int j = 0; for(int i = 0; i <= groupSize-1 ; i++) @@ -358,8 +358,8 @@ getLogger().info("in setAllLocations...group size is: " + groupSize); double maxCapacity = 0.0; double initCapacity = 0.0; - - + + List<Location> locations = new ArrayList<Location>(); locations = locationDao.findAll(); for(Location location:locations) @@ -369,13 +369,13 @@ groupLocation.setGroup(groupDao.find(grp.getId())); if(location.getLocationName().equalsIgnoreCase("bay1")) { - + groupLocation.setLocation(location); maxCapacity = 3.0*groupSize; - + groupLocation.setMaxCapacity(maxCapacity); initCapacity = maxCapacity/2; - + groupLocation.setInitialPopulation(initCapacity); //groupLocation.setCurrentPopulation(initCapacity); getLogger().info("initiali population set is: " + initCapacity); @@ -390,50 +390,50 @@ groupLocation.setMaxCapacity(maxCapacity); initCapacity = maxCapacity/2; - + groupLocation.setInitialPopulation(initCapacity); - /* groupLocation.setCurrentPopulation(initCapacity); + /* groupLocation.setCurrentPopulation(initCapacity); groupLocation.setFishLeaving(0.0); groupLocation.setFishReturned(0.0); -*/ + */ getLogger().info("initiali population set is: " + initCapacity); } if(location.getLocationName().equalsIgnoreCase("bay3")) { groupLocation.setLocation(location); maxCapacity = 10.0*groupSize; - + groupLocation.setMaxCapacity(maxCapacity); initCapacity = maxCapacity/2; - + groupLocation.setInitialPopulation(initCapacity); - + getLogger().info("initiali population set is: " + initCapacity); /*groupLocation.setCurrentPopulation(initCapacity); groupLocation.setFishLeaving(0.0); groupLocation.setFishReturned(0.0); -*/ + */ } if(location.getLocationName().equalsIgnoreCase("harbor")) { groupLocation.setLocation(location); maxCapacity = 0.0*groupSize; - + groupLocation.setMaxCapacity(maxCapacity); initCapacity = maxCapacity/2; - + groupLocation.setInitialPopulation(initCapacity); -/* groupLocation.setCurrentPopulation(initCapacity); + /* groupLocation.setCurrentPopulation(initCapacity); getLogger().info("initiali population set is: " + initCapacity); groupLocation.setFishLeaving(0.0); groupLocation.setFishReturned(0.0); -*/ + */ } //groupLocation.setDayByDayDecsion(null); groupLocationDao.save(groupLocation); getLogger().info("group location is created and id is: " + groupLocation.getId()); - + } } @@ -524,7 +524,7 @@ return locations; } -*/ + */ public Module getNextModule(int sequenceNo) { return getModule(sequenceNo); @@ -830,8 +830,8 @@ } } } - + Module module = block.getModule(); Hibernate.initialize(module); initializeModule(module); @@ -909,11 +909,11 @@ if(query.list().size() == 1) roundNo = (Integer) query.list().get(0); } - + return roundNo; } - + public boolean isGameFinished(Game game) { GameConfig gameConfig = game.getGameConfig(); List<GameRound> gameRounds = getGameRoundDao().findAllByProperty("gameConfig",game.getGameConfig()); @@ -1083,7 +1083,7 @@ private void initializeRound(Round round) { // TODO Auto-generated method stub Hibernate.initialize(round); - + } public void setBlockSeqNo(int blockSeqNo) { @@ -1183,5 +1183,5 @@ this.groupLocationDao = groupLocationDao; } - + } 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 2010-01-07 05:17:04 UTC (rev 426) +++ mentalmodels/trunk/src/main/java/edu/asu/commons/mme/utility/MessageHandler.java 2010-01-12 21:42:47 UTC (rev 427) @@ -89,13 +89,13 @@ { //int duration = game.getBlock().getDuration(); - /* if(game.getCurrentBlock().getDescription().equalsIgnoreCase("Day-by-day decisions game")) + /*if(game.getCurrentBlock().getDescription().equalsIgnoreCase("Day-by-day decisions game")) { //start 10 sec timer //i = max days hardcoded for(int i =0;i<30;i++) { - int duration = 11; + duration = 11; Timer timer = new Timer(); Long startTime = System.currentTimeMillis()/1000; System.out.println("Started time is : " + System.currentTimeMillis()/1000); @@ -114,8 +114,7 @@ send(studentDecisions); } } - else */ - if(game.getCurrentBlock().getDescription().equalsIgnoreCase("Communication")){ + else*/ if(game.getCurrentBlock().getDescription().equalsIgnoreCase("Communication")){ duration = game.getCurrentBlock().getDuration(); } else @@ -136,23 +135,23 @@ pushData.pushNextData(game); } - //} - else - { - System.out.println("Game is Over..." + msg); - } + //} + else + { + System.out.println("Game is Over..." + msg); + } - /*AcknowledgeMessage ack = msgBroker.routeMessageToService(msg, null); + /*AcknowledgeMessage ack = msgBroker.routeMessageToService(msg, null); logger.info("Ack received from client for message " + msg + "is : " + ack); - */ -} + */ + } -@Override -public void setApplicationContext(ApplicationContext applicationContext) -throws BeansException { - // TODO Auto-generated method stub - this.ctx = applicationContext; + @Override + public void setApplicationContext(ApplicationContext applicationContext) + throws BeansException { + // TODO Auto-generated method stub + this.ctx = applicationContext; + } } -} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |