def validate_matched_parenthesis(cls, format_target):
        """ Adapted from https://stackoverflow.com/questions/6701853/parentheses-pairing-issue

        :param format_order:
        :return:
        """
        iparens = iter('(){}[]<>')
        parens = dict(zip(iparens, iparens))
        closing = parens.values()

        def balanced(astr):
            stack = []
            for c in astr:
                d = parens.get(c, None)
                if d:
                    stack.append(d)
                elif c in closing:
                    if not stack or c != stack.pop():
                        return False
            return not stack

        if format_target:
            if not balanced(format_target):
                raise exceptions.BalanceError("Format string has unmatching parentheses.")