관리-도구
편집 파일: tokenizer.cpython-36.pyc
3 �b�W�G � @ s� d Z ddlmZ ddlZddlZddlZddlZddlm Z m Z mZ dddddddd�ZddiZ dZdZd Zd ZdZdZd ZG dd� dejj�ZG dd� de�ZG dd� de�ZdS )zTokenize DNS master file format� )�StringION� )�long� text_type�binary_typeT)� � � �;�(�)�"r � � � � � c @ s e Zd ZdZdS )�UngetBufferFullzDAn attempt was made to unget a token when the unget buffer was full.N)�__name__� __module__�__qualname__�__doc__� r r �/usr/lib/python3.6/tokenizer.pyr . s r c @ s� e Zd ZdZd%dd�Zdd� Zdd � Zd d� Zdd � Zdd� Z dd� Z dd� Zdd� Zdd� Z dd� Zdd� Zdd� Zdd� Zd d!� Zd"d#� Zd$S )&�Tokenz�A DNS master file format token. @ivar ttype: The token type @type ttype: int @ivar value: The token value @type value: string @ivar has_escape: Does the token value contain escapes? @type has_escape: bool � Fc C s || _ || _|| _dS )a Initialize a token instance. @param ttype: The token type @type ttype: int @param value: The token value @type value: string @param has_escape: Does the token value contain escapes? @type has_escape: bool N)�ttype�value� has_escape)�selfr r r r r r �__init__? s zToken.__init__c C s | j tkS )N)r �EOF)r r r r �is_eofM s zToken.is_eofc C s | j tkS )N)r �EOL)r r r r �is_eolP s zToken.is_eolc C s | j tkS )N)r � WHITESPACE)r r r r � is_whitespaceS s zToken.is_whitespacec C s | j tkS )N)r � IDENTIFIER)r r r r � is_identifierV s zToken.is_identifierc C s | j tkS )N)r � QUOTED_STRING)r r r r �is_quoted_stringY s zToken.is_quoted_stringc C s | j tkS )N)r �COMMENT)r r r r � is_comment\ s zToken.is_commentc C s | j tkS )N)r � DELIMITER)r r r r �is_delimiter_ s zToken.is_delimiterc C s | j tkp| j tkS )N)r r# r! )r r r r � is_eol_or_eofb s zToken.is_eol_or_eofc C s&