GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

kerapu.boom.attribuut_groep_koppeling.AttribuutGroepKoppeling2   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 49
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 16
dl 0
loc 49
ccs 10
cts 10
cp 1
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A AttribuutGroepKoppeling2.__init__() 0 22 1
A AttribuutGroepKoppeling2.test() 0 11 1
1
from kerapu.boom.attribuut.Attribuut import Attribuut
2
from kerapu.boom.attribuut_groep_koppeling.AttribuutGroepKoppeling import AttribuutGroepKoppeling
3
from kerapu.lbz.Subtraject import Subtraject
4 1
5 1
6 1
class AttribuutGroepKoppeling2(AttribuutGroepKoppeling):
7
    """
8
    Klasse voor attribuutgroepkoppelingen met filtertoetswijze 2 (tussen onder- en bovengrens).
9 1
    """
10
11
    # ------------------------------------------------------------------------------------------------------------------
12
    def __init__(self,
13
                 attribute_groep_id: int,
14
                 attribuut: Attribuut,
15 1
                 onder_toets_waarde: int,
16
                 boven_toets_waarde: int):
17
        """
18
        Object constructor.
19
20
        :param int attribute_groep_id: Het ID van deze koppeling.
21
        :param Attribuut attribuut: Het attribuut van deze koppeling.
22
        :param int onder_toets_waarde: De ondergrens.
23
        :param int boven_toets_waarde: De bovengrens.
24
        """
25
        AttribuutGroepKoppeling.__init__(self, attribute_groep_id, attribuut)
26
27
        self._onder_toets_waarde: int = onder_toets_waarde
28 1
        """
29
        De ondergrens om deze koppeling the laten vuren.
30 1
        """
31
32
        self._boven_toets_waarde: int = boven_toets_waarde
33
        """
34
        De bovengrens om deze koppeling the laten vuren.
35
        """
36
37 1
    # ------------------------------------------------------------------------------------------------------------------
38 1
    def test(self, subtraject: Subtraject) -> bool:
39
        """
40
        Test of een subtraject voldoet aan een attribuutgroepkoppeling.
41
42
        :param Subtraject subtraject: Het subtraject.
43
44
        :rtype: bool
45 1
        """
46
        aantal = self._attribuut.tel(subtraject)
47
48
        return self._onder_toets_waarde <= aantal <= self._boven_toets_waarde
49
50
# ----------------------------------------------------------------------------------------------------------------------
51