'Return True if stream is valid.'

@classmethod
def detect(cls, stream):

    try:
        csv.Sniffer().sniff(stream, delimiters=cls.delimiter)
        return True
    except (csv.Error, TypeError):
        return False
