ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/proj/trunk/VTBFileUtil2/IndividualClient.cxx
(Generate patch)

Comparing trunk/VTBFileUtil2/IndividualClient.cxx (file contents):
Revision 277 by douglas, 2003-08-24T00:31:45-07:00 vs.
Revision 284 by douglas, 2003-09-01T23:05:56-07:00

# Line 2 | Line 2
2   //
3   // Douglas Thrift
4   //
5 < // $Id: IndividualClient.cxx,v 1.8 2003/08/24 07:31:45 douglas Exp $
5 > // $Id: IndividualClient.cxx,v 1.9 2003/09/02 06:05:56 douglas Exp $
6  
7   #include "IndividualClient.h"
8  
9 + IndividualClient::IndividualClient(unsigned number, const string& name)
10 + {
11 +        setNumber(number);
12 +        setName(name);
13 + }
14 +
15 + IndividualClient::IndividualClient(const string& file)
16 + {
17 +        setFile(file);
18 + }
19 +
20   unsigned IndividualClient::getNumber(void)
21   {
22          if (number == 0 && file != "")
# Line 82 | Line 93 | void IndividualClient::setFile(const str
93          this->file = file;
94          number = 0;
95          name = "";
96 +
97 +        if (file != "") demunge();
98 + }
99 +
100 + bool IndividualClient::operator<(const IndividualClient& data) const
101 + {
102 +        if (number == data.number)
103 +        {
104 +                return mcLess(name, data.name);
105 +        }
106 +
107 +        return number < data.number;
108 + }
109 +
110 + bool IndividualClient::operator>(const IndividualClient& data) const
111 + {
112 +        if (number == data.number)
113 +        {
114 +                return mcGreater(name, data.name);
115 +        }
116 +
117 +        return number > data.number;
118   }
119  
120   string IndividualClient::extension = "pdf";
# Line 133 | Line 166 | void IndividualClient::demunge(void)
166                          capitalize(word, 3);
167                  }
168                  else if (word.length() > word.find_first_of("\'-") + 1 &&
169 <                        word.find_first_not_of("\'-") != string::npos)
169 >                        word.find_first_of("\'-") != string::npos)
170                  {
171                          capitalize(word, word.find_first_of("\'-") + 1);
172                  }
173 +                else if (word == "lefevre")
174 +                {
175 +                        capitalize(word, 2);
176 +                }
177                  else if (word.length() > 1)
178                  {
179                          if (!isalpha(word[0]))
# Line 144 | Line 181 | void IndividualClient::demunge(void)
181                                  capitalize(word, 1);
182                          }
183                  }
147                else if (word == "lefevre")
148                {
149                        capitalize(word, 2);
150                }
184  
185                  capitalize(word);
186  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines