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.
Passed
Push — master ( fbdd84...45bad2 )
by P.R.
04:28
created

Message   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 52
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 52
rs 10
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A message_type() 0 8 1
A send_message() 0 10 1
A __init__() 0 17 1
1
"""
2
Enarksh
3
4
Copyright 2013-2016 Set Based IT Consultancy
5
6
Licence MIT
7
"""
8
import abc
9
10
11
class Message(metaclass=abc.ABCMeta):
12
    """
13
    Class for messages exchanged between the processes of Enarksh.
14
    """
15
16
    # ------------------------------------------------------------------------------------------------------------------
17
    message_controller = None
18
    """
19
    The message controller.
20
21
    :type: None|enarksh.message.MessageController.MessageController
22
    """
23
24
    # ------------------------------------------------------------------------------------------------------------------
25
    def __init__(self, message_type):
26
        """
27
        Object constructor.
28
        """
29
        self._message_type = message_type
30
        """
31
        The type of the message.
32
33
        :type: str
34
        """
35
36
        self.message_source = None
37
        """
38
        For incoming messages will be set by the message controller. The name of the source of the message.
39
40
        :type: str
41
        """
42
    # ------------------------------------------------------------------------------------------------------------------
43
    @property
44
    def message_type(self):
45
        """
46
        Returns the message type of this message.
47
48
        :rtype: str
49
        """
50
        return self._message_type
51
52
    # ------------------------------------------------------------------------------------------------------------------
53
    @abc.abstractmethod
54
    def send_message(self, end_point):
55
        """
56
        Sends the message to an end point.
57
58
        :param str end_point: The end point.
59
60
        :rtype: None|enarksh.message.Message.Message
61
        """
62
        raise NotImplementedError()
63
64
# ----------------------------------------------------------------------------------------------------------------------
65