oneOf package:split

A splitting strategy that splits on any one of the given elements.
>>> split (oneOf ",;") "hi;there,world"
["hi",";","there",",","world"]
>>> split (oneOf "xyz") "aazbxyzcxd"
["aa","z","b","x","","y","","z","c","x","d"]
Split into chunks terminated by one of the given elements. Equivalent to split . dropFinalBlank . dropDelims . oneOf.
>>> endByOneOf ";," "foo;bar,baz;"
["foo","bar","baz"]
Make a strategy that splits a list into chunks that all end with one of the given elements, except possibly the last. Equivalent to dropFinalBlank . keepDelimsR . oneOf.
>>> split (condense $ endsWithOneOf ".,?! ") "Hi, there!  How are you?"
["Hi, ","there!  ","How ","are ","you?"]
Split on any of the given elements. Equivalent to split . dropDelims . oneOf.
>>> splitOneOf ";.," "foo,bar;baz.glurk"
["foo","bar","baz","glurk"]
Make a strategy that splits a list into chunks that all start with one of the given elements (except possibly the first). Equivalent to dropInitBlank . keepDelimsL . oneOf. example:
>>> split (startsWithOneOf ['A'..'Z']) "ACamelCaseIdentifier"
["A","Camel","Case","Identifier"]