Commit 21ab756a authored by Jan Möbius's avatar Jan Möbius

More functions to get available property names

git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@100 fdac6126-5c0c-442c-9429-916003d36597
parent 8161142b
......@@ -64,4 +64,103 @@ void BaseKernel::property_stats(std::ostream& _ostr) const
}
}
void BaseKernel::vprop_stats( std::string& _string ) const
{
_string.clear();
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& vps = vprops_.properties();
for (it=vps.begin(); it!=vps.end(); ++it)
*it == NULL ? _string += "[deleted] \n" : _string += (*it)->name();
}
void BaseKernel::hprop_stats( std::string& _string ) const
{
_string.clear();
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& hps = hprops_.properties();
for (it=hps.begin(); it!=hps.end(); ++it)
*it == NULL ? _string += "[deleted] \n" : _string += (*it)->name();
}
void BaseKernel::eprop_stats( std::string& _string ) const
{
_string.clear();
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& eps = eprops_.properties();
for (it=eps.begin(); it!=eps.end(); ++it)
*it == NULL ? _string += "[deleted] \n" : _string += (*it)->name();
}
void BaseKernel::fprop_stats( std::string& _string ) const
{
_string.clear();
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& fps = fprops_.properties();
for (it=fps.begin(); it!=fps.end(); ++it)
*it == NULL ? _string += "[deleted] \n" : _string += (*it)->name();
}
void BaseKernel::mprop_stats( std::string& _string ) const
{
_string.clear();
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& mps = mprops_.properties();
for (it=mps.begin(); it!=mps.end(); ++it)
*it == NULL ? _string += "[deleted] \n" : _string += (*it)->name();
}
void BaseKernel::vprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& vps = vprops_.properties();
for (it=vps.begin(); it!=vps.end(); ++it)
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::hprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& hps = hprops_.properties();
for (it=hps.begin(); it!=hps.end(); ++it)
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::eprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& eps = eprops_.properties();
for (it=eps.begin(); it!=eps.end(); ++it)
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::fprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& fps = fprops_.properties();
for (it=fps.begin(); it!=fps.end(); ++it)
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
void BaseKernel::mprop_stats(std::ostream& _ostr ) const
{
PropertyContainer::Properties::const_iterator it;
const PropertyContainer::Properties& mps = mprops_.properties();
for (it=mps.begin(); it!=mps.end(); ++it)
*it == NULL ? (void)(_ostr << "[deleted]" << "\n") : (*it)->stats(_ostr);
}
}
......@@ -9,15 +9,15 @@
// License
//
// This library is free software; you can redistribute it and/or modify it
// under the terms of the GNU Lesser General Public License as published
// under the terms of the GNU Lesser General Public License as published
// by the Free Software Foundation, version 2.
//
// This library is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
//
......@@ -521,6 +521,18 @@ public:
void property_stats(std::ostream& _ostr = std::clog) const;
void vprop_stats( std::string& _string ) const;
void hprop_stats( std::string& _string ) const;
void eprop_stats( std::string& _string ) const;
void fprop_stats( std::string& _string ) const;
void mprop_stats( std::string& _string ) const;
void vprop_stats(std::ostream& _ostr = std::clog) const;
void hprop_stats(std::ostream& _ostr = std::clog) const;
void eprop_stats(std::ostream& _ostr = std::clog) const;
void fprop_stats(std::ostream& _ostr = std::clog) const;
void mprop_stats(std::ostream& _ostr = std::clog) const;
public:
typedef PropertyContainer::iterator prop_iterator;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment