def add(self, elem, replace=False):
        """Add a requirement.

        :param elem: a string or :class:`Requirement` instance.
        :param replace: if `True`, packages in the set with the same name will
            be removed first.
        """
        if isinstance(elem, text_type):
            elem = Requirement.coerce(elem)
        if replace and elem in self:
            self.remove(elem)
        super(Requirements, self).add(elem)
def limitStrLessThen128Char(self, strStr=None):
        if len(strStr) > 128:
            logging.info("limit str less then 128 char")
            return strStr[:127] + u"_"
        else:
            return strStr