Ignore:
Timestamp:
Oct 5, 2011, 12:49:48 AM (10 years ago)
Author:
Peter
Message:

deprecate seed functions. closes #674

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/random/random.h

    r2268 r2578  
    66/*
    77  Copyright (C) 2005, 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
    8   Copyright (C) 2009, 2010 Peter Johansson
     8  Copyright (C) 2009, 2010, 2011 Peter Johansson
    99
    1010  This file is part of the yat library, http://dev.thep.lu.se/yat
     
    2525
    2626#include "yat/statistics/Histogram.h"
     27#include "yat/utility/deprecate.h"
    2728
    2829#include <boost/concept_check.hpp>
     
    3940namespace random {
    4041
    41   //forward declarion
     42  //forward declaration
    4243  class RNG_state;
    4344
     
    242243    /// (cf. GSL documentation).
    243244    ///
    244     /// @see seed_from_devurandom, RNG::seed_from_devurandom, RNG::seed
    245     ///
    246     void seed(unsigned long s) const;
     245    /// \deprecated Provided for backward compatibility with the 0.7
     246    /// API. Use RNG::instance()->seed(s) instead.
     247    ///
     248    void seed(unsigned long s) const YAT_DEPRECATE;
    247249
    248250    ///
     
    251253    /// @return The seed acquired from /dev/urandom.
    252254    ///
    253     /// @see seed, RNG::seed_from_devurandom, RNG::seed
    254     ///
    255     unsigned long seed_from_devurandom(void);
     255    /// \deprecated Provided for backward compatibility with the 0.7
     256    /// API. Use RNG::instance()->seed(s) instead.
     257    ///
     258    unsigned long seed_from_devurandom(void) YAT_DEPRECATE;
    256259
    257260    ///
     
    444447    /// (cf. GSL documentation).
    445448    ///
    446     /// @see seed_from_devurandom, RNG::seed_from_devurandom, RNG::seed
    447     ///
    448     void seed(unsigned long s) const;
     449    /// \deprecated Provided for backward compatibility with the 0.7
     450    /// API. Use RNG::instance()->seed(s) instead.
     451    ///
     452    void seed(unsigned long s) const YAT_DEPRECATE;
    449453
    450454    ///
     
    453457    /// @return The seed acquired from /dev/urandom.
    454458    ///
    455     /// @see seed, RNG::seed_from_devurandom, RNG::seed
    456     ///
    457     unsigned long seed_from_devurandom(void)
    458     { return rng_->seed_from_devurandom(); }
     459    /// \deprecated Provided for backward compatibility with the 0.7
     460    /// API. Use RNG::instance()->seed(s) instead.
     461    ///
     462    unsigned long seed_from_devurandom(void) YAT_DEPRECATE;
    459463
    460464    ///
Note: See TracChangeset for help on using the changeset viewer.