ProPeler
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
usr
/
lib
/
python3
/
dist-packages
/
twisted
/
web
/
__pycache__
/
Filename :
template.cpython-38.pyc
back
Copy
U W[�D � y @ s� d Z ddlmZmZ ddddddd d ddd dddddgZddlZddlmZ ddlm Z ddl mZmZ ddl mZmZ ddlmZ ddlmZmZmZmZmZ ddlmZ ddlmZ dZdZe� ZG dd� de�Z G d d!� d!ej!ej"�Z#d"d#� Z$e e�G d$d� de��Z%e e�G d%d� de��Z&e e�G d&d� de��Z'e(d'd(d)d*d+d,d-d.d/d0d1d2d3d4d5d6d7d8d9d:d;d<d=d>d?d@dAdBdCdDdEdFdGdHdIdJdKdLdMdNdOdPdQdRdSdTdUdVdWdXdYdZd[d\d]d^d_d`dadbdcdddedfdgdhdidjdkdldmdndodpdqdrdsdtdudvdwdxdydzd{d|d}d~dd�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�gx�Z)G d�d�� d�e�Z*e*� Z+d�d�d�Z,dd�l-m.Z.m/Z/ dd�l0m1Z1m2Z2 ddl3Z4dS )�a0 HTML rendering for twisted.web. @var VALID_HTML_TAG_NAMES: A list of recognized HTML tag names, used by the L{tag} object. @var TEMPLATE_NAMESPACE: The XML namespace used to identify attributes and elements used by the templating system, which should be removed from the final output document. @var tags: A convenience object which can produce L{Tag} objects on demand via attribute access. For example: C{tags.div} is equivalent to C{Tag("div")}. Tags not specified in L{VALID_HTML_TAG_NAMES} will result in an L{AttributeError}. � )�division�absolute_import�TEMPLATE_NAMESPACE�VALID_HTML_TAG_NAMES�Element� TagLoader� XMLString�XMLFile�renderer�flatten� flattenString�tags�Comment�CDATA�Tag�slot�CharRef� renderElementN)�OrderedDict)�implementer)�make_parser�handler)�NativeStringIO�items)�FilePath)r r r r r )�ITemplateLoader)�Loggerz4http://twistedmatrix.com/ns/twisted.web.template/0.1� c @ s4 e Zd ZdZddd�Zddd�Zdd� Zd d � ZdS ) � _NSContextzL A mapping from XML namespaces onto their prefixes in the document. Nc C s* || _ |dk rt|j�| _n ddi| _dS )ze Pull out the parent's namespaces, if there's no parent then default to XML. Nz$http://www.w3.org/XML/1998/namespaceZxml)�parentr �nss)�selfr � r"