class documentation

class DelegatingLexer(Lexer):

Known subclasses: pygments.lexers.asm.CObjdumpLexer, pygments.lexers.asm.CppObjdumpLexer, pygments.lexers.asm.DObjdumpLexer, pygments.lexers.dotnet.CSharpAspxLexer, pygments.lexers.dotnet.VbNetAspxLexer, pygments.lexers.email.EmailLexer, pygments.lexers.markup.MozPreprocCssLexer, pygments.lexers.markup.MozPreprocJavascriptLexer, pygments.lexers.markup.MozPreprocXulLexer, pygments.lexers.parsers.AntlrActionScriptLexer, pygments.lexers.parsers.AntlrCppLexer, pygments.lexers.parsers.AntlrCSharpLexer, pygments.lexers.parsers.AntlrJavaLexer, pygments.lexers.parsers.AntlrObjectiveCLexer, pygments.lexers.parsers.AntlrPerlLexer, pygments.lexers.parsers.AntlrPythonLexer, pygments.lexers.parsers.AntlrRubyLexer, pygments.lexers.parsers.RagelCLexer, pygments.lexers.parsers.RagelCppLexer, pygments.lexers.parsers.RagelDLexer, pygments.lexers.parsers.RagelJavaLexer, pygments.lexers.parsers.RagelObjectiveCLexer, pygments.lexers.parsers.RagelRubyLexer, pygments.lexers.parsers.TreetopLexer, pygments.lexers.slash.SlashLexer, pygments.lexers.templates.Angular2HtmlLexer, pygments.lexers.templates.CheetahHtmlLexer, pygments.lexers.templates.CheetahJavascriptLexer, pygments.lexers.templates.CheetahXmlLexer, pygments.lexers.templates.ColdfusionCFCLexer, pygments.lexers.templates.ColdfusionHtmlLexer, pygments.lexers.templates.CssDjangoLexer, pygments.lexers.templates.CssErbLexer, pygments.lexers.templates.CssGenshiLexer, pygments.lexers.templates.CssPhpLexer, pygments.lexers.templates.CssSmartyLexer, pygments.lexers.templates.EvoqueHtmlLexer, pygments.lexers.templates.EvoqueXmlLexer, pygments.lexers.templates.GenshiLexer, pygments.lexers.templates.HandlebarsHtmlLexer, pygments.lexers.templates.HtmlDjangoLexer, pygments.lexers.templates.HtmlGenshiLexer, pygments.lexers.templates.HtmlPhpLexer, pygments.lexers.templates.HtmlSmartyLexer, pygments.lexers.templates.JavascriptDjangoLexer, pygments.lexers.templates.JavascriptErbLexer, pygments.lexers.templates.JavascriptGenshiLexer, pygments.lexers.templates.JavascriptPhpLexer, pygments.lexers.templates.JavascriptSmartyLexer, pygments.lexers.templates.JspLexer, pygments.lexers.templates.LassoCssLexer, pygments.lexers.templates.LassoHtmlLexer, pygments.lexers.templates.LassoJavascriptLexer, pygments.lexers.templates.LassoXmlLexer, pygments.lexers.templates.MakoCssLexer, pygments.lexers.templates.MakoHtmlLexer, pygments.lexers.templates.MakoJavascriptLexer, pygments.lexers.templates.MakoXmlLexer, pygments.lexers.templates.MyghtyCssLexer, pygments.lexers.templates.MyghtyHtmlLexer, pygments.lexers.templates.MyghtyJavascriptLexer, pygments.lexers.templates.MyghtyXmlLexer, pygments.lexers.templates.RhtmlLexer, pygments.lexers.templates.SspLexer, pygments.lexers.templates.TeaTemplateLexer, pygments.lexers.templates.TwigHtmlLexer, pygments.lexers.templates.VelocityHtmlLexer, pygments.lexers.templates.VelocityXmlLexer, pygments.lexers.templates.XmlDjangoLexer, pygments.lexers.templates.XmlErbLexer, pygments.lexers.templates.XmlPhpLexer, pygments.lexers.templates.XmlSmartyLexer, pygments.lexers.templates.YamlJinjaLexer

View In Hierarchy

This lexer takes two lexer as arguments. A root lexer and a language lexer. First everything is scanned using the language lexer, afterwards all Other tokens are lexed using the root lexer.

The lexers from the template lexer package use this base lexer.

Method __init__ Undocumented
Method get​_tokens​_unprocessed Return an iterable of (index, tokentype, value) pairs where "index" is the starting position of the token within the input text.
Instance Variable language​_lexer Undocumented
Instance Variable needle Undocumented
Instance Variable root​_lexer Undocumented

Inherited from Lexer:

Method analyse​_text No summary
Method get​_tokens Return an iterable of (tokentype, value) pairs generated from text. If unfiltered is set to True, the filtering mechanism is bypassed even if filters are defined.
Class Variable alias​_filenames Undocumented
Class Variable aliases Undocumented
Class Variable filenames Undocumented
Class Variable mimetypes Undocumented
Class Variable name Undocumented
Method __repr__ Undocumented
Method add​_filter Add a new stream filter to this lexer.
Class Variable priority Undocumented
Instance Variable encoding Undocumented
Instance Variable ensurenl Undocumented
Instance Variable filters Undocumented
Instance Variable options Undocumented
Instance Variable stripall Undocumented
Instance Variable stripnl Undocumented
Instance Variable tabsize Undocumented
def __init__(self, _root_lexer, _language_lexer, _needle=Other, **options):
overridden in pygments.lexers.asm.CObjdumpLexer, pygments.lexers.asm.CppObjdumpLexer, pygments.lexers.asm.DObjdumpLexer, pygments.lexers.dotnet.CSharpAspxLexer, pygments.lexers.dotnet.VbNetAspxLexer, pygments.lexers.email.EmailLexer, pygments.lexers.markup.MozPreprocCssLexer, pygments.lexers.markup.MozPreprocJavascriptLexer, pygments.lexers.markup.MozPreprocXulLexer, pygments.lexers.parsers.AntlrActionScriptLexer, pygments.lexers.parsers.AntlrCppLexer, pygments.lexers.parsers.AntlrCSharpLexer, pygments.lexers.parsers.AntlrJavaLexer, pygments.lexers.parsers.AntlrObjectiveCLexer, pygments.lexers.parsers.AntlrPerlLexer, pygments.lexers.parsers.AntlrPythonLexer, pygments.lexers.parsers.AntlrRubyLexer, pygments.lexers.parsers.RagelCLexer, pygments.lexers.parsers.RagelCppLexer, pygments.lexers.parsers.RagelDLexer, pygments.lexers.parsers.RagelJavaLexer, pygments.lexers.parsers.RagelObjectiveCLexer, pygments.lexers.parsers.RagelRubyLexer, pygments.lexers.parsers.TreetopLexer, pygments.lexers.slash.SlashLexer, pygments.lexers.templates.Angular2HtmlLexer, pygments.lexers.templates.CheetahHtmlLexer, pygments.lexers.templates.CheetahJavascriptLexer, pygments.lexers.templates.CheetahXmlLexer, pygments.lexers.templates.ColdfusionCFCLexer, pygments.lexers.templates.ColdfusionHtmlLexer, pygments.lexers.templates.CssDjangoLexer, pygments.lexers.templates.CssErbLexer, pygments.lexers.templates.CssGenshiLexer, pygments.lexers.templates.CssPhpLexer, pygments.lexers.templates.CssSmartyLexer, pygments.lexers.templates.EvoqueHtmlLexer, pygments.lexers.templates.EvoqueXmlLexer, pygments.lexers.templates.GenshiLexer, pygments.lexers.templates.HandlebarsHtmlLexer, pygments.lexers.templates.HtmlDjangoLexer, pygments.lexers.templates.HtmlGenshiLexer, pygments.lexers.templates.HtmlPhpLexer, pygments.lexers.templates.HtmlSmartyLexer, pygments.lexers.templates.JavascriptDjangoLexer, pygments.lexers.templates.JavascriptErbLexer, pygments.lexers.templates.JavascriptGenshiLexer, pygments.lexers.templates.JavascriptPhpLexer, pygments.lexers.templates.JavascriptSmartyLexer, pygments.lexers.templates.JspLexer, pygments.lexers.templates.LassoCssLexer, pygments.lexers.templates.LassoHtmlLexer, pygments.lexers.templates.LassoJavascriptLexer, pygments.lexers.templates.LassoXmlLexer, pygments.lexers.templates.MakoCssLexer, pygments.lexers.templates.MakoHtmlLexer, pygments.lexers.templates.MakoJavascriptLexer, pygments.lexers.templates.MakoXmlLexer, pygments.lexers.templates.MyghtyCssLexer, pygments.lexers.templates.MyghtyHtmlLexer, pygments.lexers.templates.MyghtyJavascriptLexer, pygments.lexers.templates.MyghtyXmlLexer, pygments.lexers.templates.RhtmlLexer, pygments.lexers.templates.SspLexer, pygments.lexers.templates.TeaTemplateLexer, pygments.lexers.templates.TwigHtmlLexer, pygments.lexers.templates.VelocityHtmlLexer, pygments.lexers.templates.VelocityXmlLexer, pygments.lexers.templates.XmlDjangoLexer, pygments.lexers.templates.XmlErbLexer, pygments.lexers.templates.XmlPhpLexer, pygments.lexers.templates.XmlSmartyLexer, pygments.lexers.templates.YamlJinjaLexer

Undocumented

def get_tokens_unprocessed(self, text):

Return an iterable of (index, tokentype, value) pairs where "index" is the starting position of the token within the input text.

In subclasses, implement this method as a generator to maximize effectiveness.

language_lexer =

Undocumented

needle =

Undocumented

root_lexer =

Undocumented