| Server IP : 35.80.110.71 / Your IP : 216.73.216.52 Web Server : Apache/2.4.58 (Ubuntu) System : Linux ip-172-31-21-44 6.17.0-1019-aws #19~24.04.1-Ubuntu SMP Tue Jun 23 18:53:06 UTC 2026 x86_64 User : ubuntu ( 1000) PHP Version : 8.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/css_parser/css/__pycache__/ |
Upload File : |
�
��3e]- � �t � d Z ddlmZmZmZmZ dgZdZdZddl m
Z
ddlZddlZ
G d � de
j � Zy)
zNCSSNamespaceRule currently implements http://dev.w3.org/csswg/css3-namespace/
� )�unicode_literals�division�absolute_import�print_function�CSSNamespaceRule�restructuredtextz$Id$� )�cssruleNc �� � � e Zd ZdZ d� fd� Zd� Zd� Zd� Z� fd�Z e eed�� Z
d � Z e d
� ed�� Zd
� Z
dd�Z e d� ed�� Z e d� d�� Z e d� � Z� xZS )r a�
Represents an @namespace rule within a CSS style sheet.
The @namespace at-rule declares a namespace prefix and associates
it with a given namespace (a string). This namespace prefix can then be
used in namespace-qualified names such as those described in the
Selectors Module [SELECT] or the Values and Units module [CSS3VAL].
Dealing with these rules directly is not needed anymore, easier is
the use of :attr:`css_parser.css.CSSStyleSheet.namespaces`.
Format::
namespace
: NAMESPACE_SYM S* [namespace_prefix S*]? [STRING|URI] S* ';' S*
;
namespace_prefix
: IDENT
;
c �` �� t t | � ||�� d| _ d| _ d| _ |rh|| _ || _ | j � }|j | j d� |j | j d� | j |� n |�|| _ |r|| _ || _
y)a�
:Parameters:
namespaceURI
The namespace URI (a simple string!) which is bound to the
given prefix. If no prefix is set
(``CSSNamespaceRule.prefix==''``) the namespace defined by
namespaceURI is set as the default namespace
prefix
The prefix used in the stylesheet for the given
``CSSNamespaceRule.uri``.
cssText
if no namespaceURI is given cssText must be given to set
a namespaceURI as this is readonly later on
parentStyleSheet
sheet where this rule belongs to
Do not use as positional but as keyword parameters only!
If readonly allows setting of properties in constructor only
format namespace::
namespace
: NAMESPACE_SYM S* [namespace_prefix S*]? [STRING|URI] S* ';' S*
;
namespace_prefix
: IDENT
;
)�
parentRule�parentStyleSheetz
@namespace� N�prefix�namespaceURI)�superr �__init__�
_atkeyword�_prefix�
_namespaceURIr r �_tempSeq�append�_setSeq�cssText�_parentStyleSheet� _readonly) �selfr r r r
r �readonly�tempseq� __class__s ��A/usr/lib/python3/dist-packages/css_parser/css/cssnamespacerule.pyr zCSSNamespaceRule.__init__$ s� �� �>