|
__escapes(...)
sub(repl, string[, count = 0]) --> newstring
Return the string obtained by replacing the leftmost non-overlapping
occurrences of pattern in string by the replacement repl. |
source code
|
|
|
__unicodes(...)
sub(repl, string[, count = 0]) --> newstring
Return the string obtained by replacing the leftmost non-overlapping
occurrences of pattern in string by the replacement repl. |
source code
|
|
|
|
|
_splitNamespacesOff(self,
text_namespaces_tuple)
returns tuple (text, dict-of-namespaces) or if no namespaces are
in cssText returns (cssText, {}) |
source code
|
|
|
_tokenize2(self,
textortokens)
returns tokens of textortokens which may already be tokens in which
case simply returns input |
source code
|
|
|
_nexttoken(self,
tokenizer,
default=None)
returns next token in generator tokenizer or the default value |
source code
|
|
|
_type(self,
token)
returns type of Tokenizer token |
source code
|
|
|
_tokenvalue(self,
token,
normalize=False)
returns value of Tokenizer token |
source code
|
|
|
_stringtokenvalue(self,
token)
for STRING returns the actual content without surrounding "" or ''
and without respective escapes, e.g.: |
source code
|
|
|
_uritokenvalue(self,
token)
for URI returns the actual content without surrounding url()
or url(""), url('') and without respective escapes, e.g.: |
source code
|
|
|
_tokensupto2(self,
tokenizer,
starttoken=None,
blockstartonly=False,
blockendonly=False,
mediaendonly=False,
importmediaqueryendonly=False,
mediaqueryendonly=False,
semicolon=False,
propertynameendonly=False,
propertyvalueendonly=False,
propertypriorityendonly=False,
selectorattendonly=False,
funcendonly=False,
listseponly=False,
separateEnd=False)
returns tokens upto end of atrule and end index
end is defined by parameters, might be ; } ) or other |
source code
|
|
|
_valuestr(self,
t)
returns string value of t (t may be a string, a list of token tuples
or a single tuple in format (type, value, line, col). |
source code
|
|
|
|
|
_parse(self,
expected,
seq,
tokenizer,
productions,
default=None,
new=None)
(seq, tokenizer, token) |
source code
|
|
Inherited from object :
__delattr__ ,
__getattribute__ ,
__hash__ ,
__init__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__str__
|