Crate bbscope

Source

Structs§

BBCode
The main bbcode system. You create this to parse bbcode! Inexpensive clones, since fields are all reference counted.
BBCodeTagConfig
Configuration for tag generation. Generally not necessary, as you can just generate your own tags with more ease and more configuration than this, but this is useful for quick and common modifications to normal tag generation.
MatchInfo
Definition for a block level matcher. Should always be readonly, it is just a definition. Not necessarily a scoped element, could define eating garbage, passing normal text through, etc. It’s all up to the ‘match_type’
ScopeInfo
Information about a scoped tag with open and close elements. This gives you the power to craft many kinds of markup, not just bbcode, and have it understand scope

Enums§

BBCodeLinkTarget
The ways in which you can configure the default link ‘target’ behavior.
MatchType
This defines how scopes and whole blocks of text move into the output. Basically: is your matcher using scope or not? If using scope, you need to define an open and close MatchInfo. If not, just use the [Simple] option

Type Aliases§

EmitScope
The type for your emit closure which will take the open tag capture, body, and close tag capture and output whatever you want. used with
EmitSimple
The type for your emit closure when you’re doing basic regex replacement with MatchType::Simple