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.

maak_attribuut_groep_koppeling()   A
last analyzed

Complexity

Conditions 3

Size

Total Lines 24
Code Lines 10

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 3

Importance

Changes 0
Metric Value
cc 3
eloc 10
nop 5
dl 0
loc 24
ccs 4
cts 4
cp 1
crap 3
rs 9.9
c 0
b 0
f 0
1
from kerapu.boom.attribuut.Attribuut import Attribuut
2
from kerapu.boom.attribuut_groep_koppeling.AttribuutGroepKoppeling import AttribuutGroepKoppeling
3
from kerapu.boom.attribuut_groep_koppeling.AttribuutGroepKoppeling2 import AttribuutGroepKoppeling2
4 1
5 1
6 1
def maak_attribuut_groep_koppeling(attribute_groep_id: int,
7
                                   attribuut: Attribuut,
8
                                   attribuut_toets_wijze: int,
9 1
                                   onder_toets_waarde: int,
10
                                   boven_toets_waarde: int) -> AttribuutGroepKoppeling:
11
    """
12
    Fabriek voor het maken van attribuutgroepkoppelingen.
13
14
    :param int attribute_groep_id: Het ID van de koppeling.
15
    :param Attribuut attribuut: Het attribuut van de koppeling.
16
    :param int attribuut_toets_wijze: De attribuuttoetswijze.
17
    :param int onder_toets_waarde: De ondergrens.
18
    :param int boven_toets_waarde: De bovengrens.
19
20
    :rtype: AttribuutGroepKoppeling
21
    """
22
    if attribuut_toets_wijze == 1:
23
        # Attribuuttoetswijze 1 wordt thans niet gebruikt in de grouper.
24
        raise NotImplementedError("Attribuuttoetswijze %d is niet geïmplementeerd." % attribuut_toets_wijze)
25 1
26
    if attribuut_toets_wijze == 2:
27
        return AttribuutGroepKoppeling2(attribute_groep_id, attribuut, onder_toets_waarde, boven_toets_waarde)
28
29 1
    raise RuntimeError("Onbekende attribuuttoetswijze %d." % attribuut_toets_wijze)
30 1
31
# ----------------------------------------------------------------------------------------------------------------------
32