1 // Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
2 // Copyright (C) 2010 Winch Gate Property Limited
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
23 CRecord::CRecord(std::vector
<IValue
*> &)
29 /* std::vector<IValue *>::iterator it_val = _Values.begin();
30 while ( it_val != _Values.end() )
32 IValue *val = *it_val;
39 void CRecord::addValue(IValue
*value
)
41 _Values
.push_back( value
);
44 void CRecord::addValue(std::string
&str
)
46 _Values
.push_back( new CValue
<std::string
>(str
) );
49 void CRecord::addValue(bool b
)
51 _Values
.push_back( new CValue
<bool>(b
) );
54 void CRecord::addValue(int val
)
56 _Values
.push_back( new CValue
<int>(val
) );
59 const std::vector
<IValue
*> &CRecord::getValues()
64 const IValue
*CRecord::operator[](int index
)
66 return _Values
[index
];
71 return (int)_Values
.size();