'Evaluate an expression as it\'s received.'

def expressionReceived(self, sexp):

    if isinstance(sexp, list):
        command = sexp[0]
        if (not isinstance(command, str)):
            command = command.decode('utf8')
        methodName = ('proto_%s' % command)
        method = getattr(self, methodName, None)
        if method:
            method(*sexp[1:])
        else:
            self.sendCall('didNotUnderstand', command)
    else:
        raise ProtocolError('Non-list    expression    received.')
