Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Text.Regex.Do.Type.Do
- newtype GroupReplacer b = GroupReplacer (MatchArray -> ReplaceAcc b -> ReplaceAcc b)
- data ReplaceAcc b = ReplaceAcc {}
- data Pattern a = Pattern a
- data Body b = Body b
- data Replacement r = Replacement r
- type PosLen = (MatchOffset, MatchLength)
- newtype Utf8_ a = Utf8_ a
- class Enc enc where
- class Enc' f enc where
Documentation
newtype GroupReplacer b Source
see Text.Regex.Do.Pcre.ReplaceOpen defaultReplacer
for example implementation
Constructors
GroupReplacer (MatchArray -> ReplaceAcc b -> ReplaceAcc b) |
Instances
Enc enc => Enc' GroupReplacer enc Source | |
ReplaceOpen [] GroupReplacer Source | |
ReplaceOpen Maybe GroupReplacer Source | |
Replace' All Utf8_ ByteString GroupReplacer Source |
|
Replace' Once Utf8_ ByteString GroupReplacer Source |
Needle
Constructors
Pattern a |
Instances
Functor Pattern Source | |
Applicative Pattern Source | |
(Regex a, Hint all, Replace' all a repl b) => Replace (all (Pattern a)) (repl b) (Body b) b Source | full typed arg
|
Replace' all enc b repl => Replace (all (Pattern (enc b))) (repl (enc b)) (Body (enc b)) b Source | full typed arg
|
Haystack
Constructors
Body b |
Instances
Functor Body Source | |
Applicative Body Source | |
(Regex a, Hint all, Replace' all a repl b) => Replace (all (Pattern a)) (repl b) (Body b) b Source | full typed arg
|
Replace' all enc b repl => Replace (all (Pattern (enc b))) (repl (enc b)) (Body (enc b)) b Source | full typed arg
|
data Replacement r Source
Constructors
Replacement r |
Instances
type PosLen = (MatchOffset, MatchLength) Source
Offset, Length
Constructors
Utf8_ a | values |
Instances
Functor Utf8_ Source | |
Applicative Utf8_ Source | does not do any codec. Plain wrap / unwrap newtype |
Enc Utf8_ Source | |
MatchHint PosLen_ Utf8_ String Source | |
MatchHint PosLen_ Utf8_ ByteString Source | |
MatchHint PosLen' Utf8_ String Source |
[(13,2)] |
MatchHint PosLen' Utf8_ ByteString Source | |
MatchHint All Utf8_ String Source | |
MatchHint All Utf8_ ByteString Source | |
MatchHint Once Utf8_ String Source |
["all"] |
MatchHint Once Utf8_ ByteString Source | |
MatchHint Test Utf8_ String Source | |
MatchHint Test Utf8_ ByteString Source |
True |
Replace' All Utf8_ String Replacement Source | |
Replace' All Utf8_ ByteString Replacement Source | |
Replace' All Utf8_ ByteString GroupReplacer Source |
|
Replace' Once Utf8_ String Replacement Source | |
Replace' Once Utf8_ ByteString Replacement Source | |
Replace' Once Utf8_ ByteString GroupReplacer Source | |
Rx_ a b => Match Utf8_ a b Bool Source | test. Note that a and b may be different types e.g.
True |
Rx_ a b => Match Utf8_ a b [[PosLen]] Source | match all |
Rx_ a b => Match Utf8_ a b [PosLen] Source | match once
[(13,2)] |
Rx_ a b => Match Utf8_ a b [[b]] Source | match all
[["well"],["well"]] |
Rx_ a b => Match Utf8_ a b [b] Source | match once precompiled regex as pattern
|
Eq a => Eq (Utf8_ a) Source | |
Ord a => Ord (Utf8_ a) Source | |
Regex a => Regex (Utf8_ a) Source | |
Extract' (Utf8_ ByteString) Source |
does not do any codec. Plain wrap / unwrap newtype