integrated changes from main repository for upcoming 1.2.5 release

This commit is contained in:
Guenter Obiltschnig
2006-10-12 15:08:28 +00:00
parent 41ee6e0ffa
commit 89111b52b3
26 changed files with 283 additions and 171 deletions

View File

@@ -1,7 +1,7 @@
//
// Option.cpp
//
// $Id: //poco/1.2/Util/src/Option.cpp#1 $
// $Id: //poco/1.2/Util/src/Option.cpp#2 $
//
// Library: Util
// Package: Options
@@ -238,6 +238,15 @@ bool Option::matchesShort(const std::string& option) const
bool Option::matchesFull(const std::string& option) const
{
std::string::size_type pos = option.find_first_of(":=");
std::string::size_type len = pos == std::string::npos ? option.length() : pos;
return len == _fullName.length()
&& icompare(option, 0, len, _fullName, 0, len) == 0;
}
bool Option::matchesPartial(const std::string& option) const
{
std::string::size_type pos = option.find_first_of(":=");
std::string::size_type len = pos == std::string::npos ? option.length() : pos;