regex
Regex builder DSL with named groups, composition, and testing.
Load with: use regex
Quick example
use regex
result = rxlit("value")
prn(result)
Functions
Functions
rxlit(s)
Performs the operation. Takes s.
rxgrp(name, pat)
Performs the operation. Takes name, pat.
rxalt(pats)
Performs the operation. Takes pats.
rxseq(pats)
Performs the operation. Takes pats.
rxopt(pat)
Performs the operation. Takes pat.
rxstr(pat)
Performs the operation. Takes pat.
rxpls(pat)
Lists items. Takes pat.
rxrep(pat, n, m)
Performs the operation. Takes pat, n, m.
rxcls(chars)
Lists items. Takes chars.
rxncl(chars)
Closes or clears. Takes chars.
rxbol()
Performs the operation.
rxeol()
Performs the operation.
rxany()
Performs the operation.
rxdig()
Performs the operation.
rxndi()
Disconnects.
rxwrd()
Reads data.
rxnwr()
Writes data.
rxspc()
Performs the operation.
rxnsp()
Performs the operation.
rxbnd()
Performs the operation.
rxeml()
Performs the operation.
rxurl()
Performs the operation.
rxip4()
Performs the operation.
rxphn()
Performs the operation.
rxhex()
Executes.
rxuui()
Performs the operation.
rxbld(pat)
Performs the operation. Takes pat.
rxflg(b, flags)
Performs the operation. Takes b, flags.
rxstr2(b)
Performs the operation. Takes b.
rxtst(pat, s)
Sets a value or starts a process. Takes pat, s.
These are the public-facing names you call with use regex:
regex.lit(s)regex.grp(n, p)regex.alt(p)regex.seq(p)regex.opt(p)regex.str(p)regex.pls(p)regex.rep(p, n, m)regex.cls(c)regex.eml()regex.url()regex.ip4()regex.uid()regex.bld(p)regex.tst(p, s)
Notes
- Regular expression builder - compose patterns programmatically.