Passed
Pull Request — dev (#836)
by Uwe
03:17 queued 01:53
created

solph.components._source.Source.__init__()   A

Complexity

Conditions 1

Size

Total Lines 3
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
nop 3
1
# -*- coding: utf-8 -*-
2
3
"""
4
solph version of oemof.network.Source
5
6
SPDX-FileCopyrightText: Uwe Krien <[email protected]>
7
SPDX-FileCopyrightText: Simon Hilpert
8
SPDX-FileCopyrightText: Cord Kaldemeyer
9
SPDX-FileCopyrightText: Stephan Günther
10
SPDX-FileCopyrightText: Birgit Schachler
11
12
SPDX-License-Identifier: MIT
13
14
"""
15
16
from oemof.network import network as on
17
18
from oemof.solph._helpers import check_node_object_for_missing_attribute
19
20
21
class Source(on.Source):
22
    """An object with one output flow."""
23
24
    def __init__(self, *args, **kwargs):
25
        super().__init__(*args, **kwargs)
26
        check_node_object_for_missing_attribute(self, "outputs")
27
28
    def constraint_group(self):
29
        pass
30