summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/PropertiesI.h
blob: 651ac559543a946a7929e3e7a303137eab6ea015 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// **********************************************************************
//
// Copyright (c) 2001
// MutableRealms, Inc.
// Huntsville, AL, USA
//
// All Rights Reserved
//
// **********************************************************************

#ifndef ICE_PROPERTIES_I_H
#define ICE_PROPERTIES_I_H

#include <Ice/Properties.h>
#include <map>

namespace Ice
{

class ICE_API PropertiesI : public Properties
{
public:
    
    virtual std::string getProperty(const std::string&);
    virtual void setProperty(const std::string&, const std::string&);
    virtual PropertiesPtr clone();

private:

    PropertiesI(int&, char*[]);
    PropertiesI(int&, char*[], const std::string& file);
    friend ICE_API PropertiesPtr createProperties(int&, char*[]);
    friend ICE_API PropertiesPtr createPropertiesFromFile(int&, char*[], const std::string&);

    void parseArgs(int&, char*[]);
    void load(const std::string&);
    void parse(std::istream&);
    void parseLine(const std::string&);

    std::map<std::string, std::string> _properties;
};

}

#endif