structured_data._match.patterns.compound_match   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 5
dl 0
loc 17
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A CompoundMatch.destructure() 0 8 1
1
"""Abstract base class for advanced match classes."""
2
3
4
class CompoundMatch:
5
    """Abstract base class for advanced match classes."""
6
7
    __slots__ = ()
8
9
    def destructure(self, value):
10
        """Given a value, return a sequence of values extracted from the match.
11
12
        Usually has special-case behavior when ``value is self``, possibly as
13
        part of a broader conditional that happens to be true in that specific
14
        case as well.
15
        """
16
        raise NotImplementedError
17