Completed
Push — master ( 6469e6...2d0d7d )
by Ryan
58s
created

traceroutedb.Config.__missing__()   A

Complexity

Conditions 1

Size

Total Lines 2

Duplication

Lines 0
Ratio 0 %
Metric Value
cc 1
dl 0
loc 2
rs 10
1
2
class Config(dict):
3
4
    def __init__(self):
5
        dict.__init__(self)
6
7
    def __getattr__(self, key):
8
        try:
9
            return self[key]
10
        except KeyError:
11
            raise AttributeError
12
13
    def __setattr__(self, key, value):
14
        self[key] = value
15
16
    def __delattr__(self, key):
17
        del self[key]
18
19
    def __repr__(self):
20
        return '<Config ' + dict.__repr__(self) + '>'
21