x
Yes
No
Do you want to visit DriveHQ English website?
首页
产品服务
价格
免费试用
下载客户端
关于我们
云文件服务
|
云备份服务
|
FTP服务
|
企业邮箱服务
|
网站托管
|
客户端软件
云文件服务
云备份服务
FTP服务
企业级邮箱服务
网站托管
客户端软件
nondet_random.hpp - Hosted on DriveHQ Cloud IT Platform
返回上层目录
上传
下载
共享
发布
新建文件夹
新建文件
复制
剪切
删除
粘贴
评论
升级服务
路径: \\game3dprogramming\materials\GameFactory\GameFactoryDemo\references\boost_1_35_0\boost\nondet_random.hpp
旋转
特效
属性
历史版本
/* boost nondet_random.hpp header file * * Copyright Jens Maurer 2000 * Distributed under the Boost Software License, Version 1.0. (See * accompanying file LICENSE_1_0.txt or copy at * http://www.boost.org/LICENSE_1_0.txt) * * $Id: nondet_random.hpp 24096 2004-07-27 03:43:34Z dgregor $ * * Revision history * 2000-02-18 Portability fixes (thanks to Beman Dawes) */ // See http://www.boost.org/libs/random for documentation. #ifndef BOOST_NONDET_RANDOM_HPP #define BOOST_NONDET_RANDOM_HPP #include
// std::abs #include
// std::min #include
#include
#include
// noncopyable #include
// compile-time integral limits namespace boost { // use some OS service to generate non-deterministic random numbers class random_device : private noncopyable { public: typedef unsigned int result_type; BOOST_STATIC_CONSTANT(bool, has_fixed_range = true); BOOST_STATIC_CONSTANT(result_type, min_value = integer_traits
::const_min); BOOST_STATIC_CONSTANT(result_type, max_value = integer_traits
::const_max); result_type min BOOST_PREVENT_MACRO_SUBSTITUTION () const { return min_value; } result_type max BOOST_PREVENT_MACRO_SUBSTITUTION () const { return max_value; } explicit random_device(const std::string& token = default_token); ~random_device(); double entropy() const; unsigned int operator()(); private: static const char * const default_token; /* * std:5.3.5/5 [expr.delete]: "If the object being deleted has incomplete * class type at the point of deletion and the complete class has a * non-trivial destructor [...], the behavior is undefined". * This disallows the use of scoped_ptr<> with pimpl-like classes * having a non-trivial destructor. */ class impl; impl * pimpl; }; // TODO: put Schneier's Yarrow-160 algorithm here. } // namespace boost #endif /* BOOST_NONDET_RANDOM_HPP */
nondet_random.hpp
网页地址
文件地址
上一页
62/113
下一页
下载
( 2 KB )
Comments
Total ratings:
0
Average rating:
无评论
of 10
Would you like to comment?
Join now
, or
Logon
if you are already a member.