/[projects]/queensgui/src/containervector.cpp
ViewVC logotype

Diff of /queensgui/src/containervector.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

queensgui/src/solutionvector.cpp revision 2 by torben, Thu Jul 19 22:26:42 2007 UTC queensgui/src/containervector.cpp revision 4 by torben, Thu Jul 19 23:44:01 2007 UTC
# Line 17  Line 17 
17   *   Free Software Foundation, Inc.,                                       *   *   Free Software Foundation, Inc.,                                       *
18   *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *   *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19   ***************************************************************************/   ***************************************************************************/
20  #include "solutionvector.h"  #include "containervector.h"
21    
22    
23    
24  SolutionVector::SolutionVector(GUIUpdate* update) : SolutionContainer(update)  ContainerVector::ContainerVector(GUIUpdate* update) : SolutionContainer(update)
25  {  {
26      total = -1;      total = -1;
27  }  }
28    
29    
30  SolutionVector::~SolutionVector()  ContainerVector::~ContainerVector()
31  {  {
32  }  }
33    
34  int SolutionVector::numSolutions()  int ContainerVector::numSolutions()
35  {  {
36          return solutions.size();          return solutions.size();
37  }  }
38    
39  int SolutionVector::totalSolutions()  int ContainerVector::totalSolutions()
40  {  {
41          return total;          return total;
42  }  }
43    
44    
45  void SolutionVector::uniqueSolutions()  void ContainerVector::uniqueSolutions()
46  {  {
47          for (int i=1;i<=4;i++) {          for (int i=1;i<=4;i++) {
48                  if (m_halt)                  if (m_halt)
# Line 52  void SolutionVector::uniqueSolutions() Line 52  void SolutionVector::uniqueSolutions()
52          }          }
53  }  }
54    
55  void SolutionVector::uniqueSolutionsWorker(int rot,bool mirror)  void ContainerVector::uniqueSolutionsWorker(int rot,bool mirror)
56  {  {
57          int match_count;          int match_count;
58    
# Line 89  void SolutionVector::uniqueSolutionsWork Line 89  void SolutionVector::uniqueSolutionsWork
89    
90    
91    
92  void SolutionVector::addSolution(Solution* sol)  void ContainerVector::addSolution(Solution* sol)
93  {  {
94      solutions.push_back(sol);        solutions.push_back(sol);  
95  }  }
96    
97  Solution* SolutionVector::solution(int index)  Solution* ContainerVector::solution(int index)
98  {  {
99      return solutions[index] ;      return solutions[index] ;
100  }  }

Legend:
Removed from v.2  
changed lines
  Added in v.4

  ViewVC Help
Powered by ViewVC 1.1.20