INNER CODE UNIT · Python

diff_linenum

mpenning/ciscoconfparse · ciscoconfparse/ccp_abc.py:53

    diff_linenum = -1
    _diff_word = ""  # diff_word: 'keep', 'remove', 'unchanged', 'add'
    _diff_side = ""  # diff_side: 'before', 'after' or ''

    # deprecating py2.foo metaclass syntax in version 1.6.8...
    # __metaclass__ = ABCMeta
    @logger.catch(reraise=True)
    def __init__(self, all_lines=None, line=DEFAULT_TEXT, comment_delimiter="!", **kwargs):
        """Accept an IOS line number and initialize family relationship attributes"""

        # Hack to accept old parameter names instead of finding all the places
        # where `all_text` and `text` are used and renaming attributes all
        # over the place
        if isinstance(kwargs.get("all_text", None), list):
            all_lines = kwargs.get("all_text")
        if isinstance(kwargs.get("text", None), str):
            line = kwargs.get("text")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…