úÎfÿaÖ<      !"#$%&'()*+,-./0123456789:;portable provisional0Julian Fleischer <julian.fleischer@fu-berlin.de> Trustworthy@<+Utility class for working with characters. =+Retrieve the value of the given character. >,Construct a character form the given value. BThe goal of this class is to offer the same interface for various  types of strings (?, @ , Haskell A , etc.). H If a certain type offers a native implementation for a given function,  5 uses it. If not, a default implementation is given. )All of these functions are prefixed with s to avoid nameclashes + with existing functions from the prelude. KThe complexity and efficiency of these functions depends on the underlying  string type being used. 0Check whether the given string is empty or not. null generalised. The empty string. B generalised. C, generalised. This function is undefined if  would return True. D, generalised. This function is undefined if  would return True. E, generalised. This function is undefined if  would return True. F, generalised. This function is undefined if  would return True. G generalised. H generalised. I generalised. J generalised. )Replace a substring with another string. ABreaks the string on the first occurence of the given substring. / strBreak "xx" "1x2xx3xx4" = ("1x2", "xx3xx4") Like  :, but the string to break on is excluded from the result. - strSplit "xx" "1x2xx3xx4" = ("1x2", "3xx4") JSplit a string into multiple fragments, separated by the given substring. 2 strSplitAll "xx" "1x2xx3xx4" = ["1x2", "3", "4"] 2Check if the string starts with the given string. 0Check if the string ends with the given string. <Concatenate all the strings in the list to a single string. ;Strips white space characters off both ends of the string. ;Appends the given character n times to the left, such that , the resulting string has the given length. ' strPadLeft '0' 8 "4711" == "00004711" <Appends the given character n times to the right, such that , the resulting string has the given length. ( strPadRight '0' 8 "4711" == "47110000" =Appends the given character n times to both sides, such that , the resulting string has the given length. ' strPadBoth '0' 8 "4711" == "00471100" 'Create a string from a Haskell String. OCreate a string from a Haskell String. If the string does not support unicode, , the Haskell String is encoded using UTF-8. *Convert the string into a Haskell String. )Convert the string into a list of bytes. The > class provides functions for working with arbitrary Strings. 7 It is basically the same interface as provided by the  class. G However, every input string is a Haskell String here, thus easing the F usage of different string types with native Haskell String literals.  For example  strAppend suffix& works with any string type for which  an instance of Str2 is defined. In order to maximize the ease of use 2 of this library, the functions are prefixed with str. KThe complexity and efficiency of these functions depends on the underlying  string type being used. BMinimal complete definition: It suffices to provide instances for  K and . 0Check whether the given string is empty or not. L generalised. B generalised. C, generalised. This function is undefined if  would return True. D, generalised. This function is undefined if  would return True. !E, generalised. This function is undefined if  would return True. "F, generalised. This function is undefined if  would return True. #G generalised. $H generalised. %)Replace a substring with another string. &ABreaks the string on the first occurence of the given substring. / strBreak "xx" "1x2xx3xx4" = ("1x2", "xx3xx4") 'Like &:, but the string to break on is excluded from the result. - strSplit "xx" "1x2xx3xx4" = ("1x2", "3xx4") (JSplit a string into multiple fragments, separated by the given substring. 2 strSplitAll "xx" "1x2xx3xx4" = ["1x2", "3", "4"] )concat generalised. *2Glue together multiple strings by a given Haskell A. $ strJoin x = concat . intersperse x +Appends the given Haskell A to the string. ++ generalised. , strAppend " world" "hello" = "hello world" ,;Strips white space characters off both ends of the string. -;Appends the given character n times to the left, such that , the resulting string has the given length. ' strPadLeft '0' 8 "4711" == "00004711" .<Appends the given character n times to the right, such that , the resulting string has the given length. ( strPadRight '0' 8 "4711" == "47110000" /=Appends the given character n times to both sides, such that , the resulting string has the given length. ' strPadBoth '0' 8 "4711" == "00471100" 0Reverse the string. 15Check if the given Haskell String equals the string. 2:Check if the string starts with the given Haskell String. 38Check if the string ends with the given Haskell String. 4'Create a string from a Haskell String. 5OCreate a string from a Haskell String. If the string does not support unicode, , the Haskell String is encoded using UTF-8. 6*Convert the string into a Haskell String. 7)Convert the string into a list of bytes. MReturns True6 exactly for space (0x20), and horizontal tab (0x09). NReturns True` exactly for space (0x20), horizontal tab (0x09), carriage return (0x0D), and line feed (0x0A). 8 Create a @! object form an ordinary Haskell A. 9Create a lazy O! object from an ordinary Haskell A. : Create a ?! object form an ordinary Haskell A. H This function will encode a String using the UTF-8 character encoding. ;Create a lazy P! object from an ordinary Haskell A. H This function will encode a String using the UTF-8 character encoding. U<=>  !"#$%Needle.  Replacement.  Haystack. Result: Haystack with Needle replaced by  Replacement. &'()*+,-./01The Haskell String.  The string. 234567MN89:;QRSTUVWXYZ[\]^_`abcd<  !"#$%&'()*+,-./0123456789:;<89:; !"#$%&'()*+,-./01234567 <=>  !"#$%&'()*+,-./01234567MN89:;QRSTUVWXYZ[\]^_`abcde      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIGJKGJLGJMGJNGJOGJPGJQGJRGJSTUVGJWXYDZFA[C\]^_`abcdefghijklmnop strings-1.0.2 Data.StringsStringssNullsEmptysLensHeadsLastsInitsTailsTakesDrop sTakeWhile sDropWhilesReplacesBreaksSplit sSplitAll sStartsWith sEndsWithsConcatsTrimsPadLeft sPadRightsPadBothsReverse sFromStringsFromUnicodeString sToStringsToWord8StrstrNullstrLenstrHeadstrLaststrInitstrTailstrTakestrDrop strReplacestrBreakstrSplit strSplitAll strConcatstrJoin strAppendstrTrim strPadLeft strPadRight strPadBoth strReversestrEq strStartsWith strEndsWith fromStringfromUnicodeStringtoStringtoWord8textlazyTextbytes lazyBytesCharsordchrbytestring-0.10.0.2Data.ByteString.Internal ByteString text-0.11.2.3Data.Text.InternalTextbaseGHC.BaseStringGHC.Listlengthheadlastinittailtakedrop takeWhile dropWhileghc-prim GHC.ClassesEqnullisSpace isWhiteSpaceData.Text.Lazy.InternalData.ByteString.Lazy.Internal$fCharsInteger $fCharsInt64 $fCharsInt32 $fCharsInt16 $fCharsInt8 $fCharsWord64 $fCharsWord32 $fCharsWord16 $fCharsWord8 $fCharsInt $fStrings[] $fStringsText$fStringsText0$fStringsByteString$fStringsByteString0$fStr[]$fStrByteString$fStrByteString0 $fStrText $fStrText0