Ejemplo n.º 1
0
    def process(self):
        """
        Process data
        :return: str
        """

        data = self._data.get('total').items()
        title = 'Statistics ({0})'.format(self._target)
        sys.writeln(tabulate(data, headers=[title, 'Summary'], tablefmt="psql"))
Ejemplo n.º 2
0
    def process(self):
        """
        Process data
        :return: str
        """

        data = self._data.get('total').items()
        title = 'Statistics ({0})'.format(self._target)
        sys.writeln(tabulate(data, headers=[title, 'Summary'], tablefmt="psql"))
Ejemplo n.º 3
0
    def message(msg, args=None, color='white'):
        """
        Simple colored message
        :param str msg: text message
        :param mixed args: additional arguments
        :param str color: color
        :return: None
        """

        if None is args:
            args = {}
        msg = colour.colored(msg.format(**args), color=color)
        sys.writeln(msg)
Ejemplo n.º 4
0
    def message(msg, args=None, color='white'):
        """
        Simple colored message
        :param str msg: text message
        :param mixed args: additional arguments
        :param str color: color
        :return: None
        """

        if None is args:
            args = {}
        msg = colour.colored(msg.format(**args), color=color)
        sys.writeln(msg)