libmoost
/home/mhx/git/github/libmoost/include/moost/service/option_validator.hpp File Reference
#include <string>
#include <boost/program_options.hpp>
#include <boost/noncopyable.hpp>
#include <boost/filesystem.hpp>
#include <boost/shared_ptr.hpp>
#include <boost/regex.hpp>
#include "../utils/foreach.hpp"
#include "../utils/assert.hpp"
Include dependency graph for option_validator.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  moost::service::validator::base
class  moost::service::validator::typed_base< T >
class  moost::service::validator::cfile
class  moost::service::validator::cnumber< T >
class  moost::service::validator::cregex
class  moost::service::option_validator

Namespaces

namespace  moost
 

Creates a unique temporary directory; removed on scope exit.


namespace  moost::service
namespace  moost::service::validator

Typedefs

typedef std::map< std::string,
std::string > 
moost::service::validator::constraints_map_t

Functions

boost::shared_ptr< base > moost::service::validator::file (const std::string &file, bool must_exist=true)
template<typename T >
boost::shared_ptr< base > moost::service::validator::number (const T &num, const T &min=std::numeric_limits< T >::min(), const T &max=std::numeric_limits< T >::max())
boost::shared_ptr< base > moost::service::validator::regex (const std::string &text, const std::string &regex, boost::smatch *results=0, boost::regex_constants::match_flag_type match_flags=boost::regex_constants::match_default)

Detailed Description

Copyright © 2008-2013 Last.fm Limited

This file is part of libmoost.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Definition in file option_validator.hpp.