Ignore:
Timestamp:
Apr 30, 2007, 11:54:25 PM (14 years ago)
Author:
Peter Johansson
Message:

turned Configuration class into a singleton

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/Configuration.h

    r229 r264  
    2525*/
    2626
    27 #include <fstream>
     27#include <iostream>
    2828#include <map>
    2929#include <string>
     
    3535  {
    3636  public:
    37     ///
    38     /// Creates a Config object with default settings.
    39     ///
    40     /// @brief Default Constructor
    41     ///
    42     Configuration(void);
     37    static Configuration* instance(void);
    4338
    4439    ///
    45     /// @brief Stream Constructor
     40    /// @brief load deafult configuration
    4641    ///
    47     Configuration(std::istream&);
     42    void load(void);
     43
     44    ///
     45    /// @brief load configuration from stream
     46    ///
     47    void load(std::istream&);
    4848
    4949    ///
     
    5454
    5555  private:
     56    ///
     57    /// Creates a Config object with default settings.
     58    ///
     59    /// @brief Default Constructor
     60    ///
     61    Configuration(void);
     62
     63    void clear(void);
     64
    5665    void set_default(void);
     66
     67    static Configuration* instance_;
    5768
    5869    std::map<std::string, std::string> copyright_alias_;
Note: See TracChangeset for help on using the changeset viewer.