def METHOD_NAME(self, tags):
    tags_with_negation = []
    for tag in tags:
        negated = tag.startswith('-')
        tag = tag.split(':')
        tag_with_negation = tag.pop(0)
        tags_with_negation.append(tag_with_negation)
        if tag:
            limit = int(tag[0])
            if negated:
                tag_without_negation = tag_with_negation[1:]
            else:
                tag_without_negation = tag_with_negation
            limited = tag_without_negation in self.limits
            if limited and self.limits[tag_without_negation] != limit:
                msg = "Inconsistent tag limits for {0}: {1:d} and {2:d}"
                msg = msg.format(tag_without_negation,
                                 self.limits[tag_without_negation], limit)
                raise Exception(msg)
            self.limits[tag_without_negation] = limit
    if tags_with_negation:
        self.ands.append(tags_with_negation)