aboutsummaryrefslogtreecommitdiff
path: root/str-utils2-api.html
diff options
context:
space:
mode:
authorTom Faulhaber <git_net@infolace.com>2009-08-28 09:58:38 -0700
committerTom Faulhaber <git_net@infolace.com>2009-08-28 09:58:38 -0700
commit73376744cfdb2e64291732fb91f2e62b29bb1d6a (patch)
treec402f204084ac139fab90945251467768393c206 /str-utils2-api.html
parent1391798c6a1684bd1f554e39f223c8f70acd0825 (diff)
Updated documentation for commit 4b4f6ab5bcab58c4219eb50395bd366daea3ecc3
Diffstat (limited to 'str-utils2-api.html')
-rw-r--r--str-utils2-api.html75
1 files changed, 45 insertions, 30 deletions
diff --git a/str-utils2-api.html b/str-utils2-api.html
index 0e11a2d6..fff760b2 100644
--- a/str-utils2-api.html
+++ b/str-utils2-api.html
@@ -66,6 +66,8 @@ namespace.
</div><div style="margin-left: 1em;" class="toc-entry">
<a href="#str-utils2/docodepoints">docodepoints</a>
</div><div style="margin-left: 1em;" class="toc-entry">
+ <a href="#str-utils2/drop">drop</a>
+ </div><div style="margin-left: 1em;" class="toc-entry">
<a href="#str-utils2/escape">escape</a>
</div><div style="margin-left: 1em;" class="toc-entry">
<a href="#str-utils2/get">get</a>
@@ -145,7 +147,7 @@ Some ideas are borrowed from
<pre id="var-usage">Usage: (blank? s)
</pre>
<pre id="var-docstr">True if s is nil, empty, or contains only whitespace.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L102" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L102" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -158,7 +160,7 @@ if n is greater than the length of s.
Note the argument order is the opposite of clojure.core/butlast;
this is to keep the string as the first argument for use with -&gt;</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L127" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L128" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -168,7 +170,7 @@ this is to keep the string as the first argument for use with -&gt;</pre>
</pre>
<pre id="var-docstr">Converts first character of the string to upper-case, all other
characters to lower-case.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L282" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L285" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -178,7 +180,7 @@ characters to lower-case.</pre>
</pre>
<pre id="var-docstr">Removes all trailing newline \n or return \r characters from
string. Note: String.trim() is similar and faster.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L255" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L258" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -188,7 +190,7 @@ string. Note: String.trim() is similar and faster.</pre>
</pre>
<pre id="var-docstr">Removes the last character of string, does nothing on a zero-length
string.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L246" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L249" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -198,7 +200,7 @@ string.</pre>
</pre>
<pre id="var-docstr">Returns a sequence of integer Unicode code points in s. Handles
Unicode supplementary characters (above U+FFFF) correctly.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L77" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L77" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -207,7 +209,7 @@ Unicode supplementary characters (above U+FFFF) correctly.</pre>
<pre id="var-usage">Usage: (contains? s substring)
</pre>
<pre id="var-docstr">True if s contains the substring.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L361" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L364" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -220,7 +222,7 @@ Unicode supplementary characters (above U+FFFF) correctly.</pre>
Repeatedly executes body, with name bound to each character in
string. Does NOT handle Unicode supplementary characters (above
U+FFFF).</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L37" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L37" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -233,7 +235,20 @@ U+FFFF).</pre>
Repeatedly executes body, with name bound to the integer code point
of each Unicode character in the string. Handles Unicode
supplementary characters (above U+FFFF) correctly.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L53" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L53" id="var-source">Source</a>
+</div><div id="var-entry">
+ <br />
+ <hr />
+ <h2 id="str-utils2/drop">drop</h2>
+ <span id="var-type">function</span><br />
+ <pre id="var-usage">Usage: (drop s n)
+</pre>
+ <pre id="var-docstr">Drops first n characters from s. Returns an empty string if n is
+greater than the length of s.
+
+Note the argument order is the opposite of clojure.core/drop; this
+is to keep the string as the first argument for use with -&gt;</pre>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L117" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -244,7 +259,7 @@ supplementary characters (above U+FFFF) correctly.</pre>
<pre id="var-docstr">Returns a new String by applying cmap (a function or a map) to each
character in s. If cmap returns nil, the original character is
added to the output unchanged.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L90" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L90" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -253,7 +268,7 @@ added to the output unchanged.</pre>
<pre id="var-usage">Usage: (get s i)
</pre>
<pre id="var-docstr">Gets the i'th character in string.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L366" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L369" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -263,7 +278,7 @@ added to the output unchanged.</pre>
</pre>
<pre id="var-docstr">Filters elements of coll by a regular expression. The String
representation (with str) of each element is tested with re-find.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L314" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L317" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -273,7 +288,7 @@ representation (with str) of each element is tested with re-find.</pre>
</pre>
<pre id="var-docstr">Returns a string of all elements in coll, separated by
separator. Like Perl's join.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L240" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L243" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -282,7 +297,7 @@ separator. Like Perl's join.</pre>
<pre id="var-usage">Usage: (lower-case s)
</pre>
<pre id="var-docstr">Converts string to all lower-case.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L345" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L348" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -291,7 +306,7 @@ separator. Like Perl's join.</pre>
<pre id="var-usage">Usage: (ltrim s)
</pre>
<pre id="var-docstr">Removes whitespace from the left side of string.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L291" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L294" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -301,7 +316,7 @@ separator. Like Perl's join.</pre>
</pre>
<pre id="var-docstr">Apply f to each element of coll, concatenate all results into a
String.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L307" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L310" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -318,7 +333,7 @@ first argument to f.
Example: (str-utils2/partial str-utils2/take 2)
;;=&gt; (fn [s] (str-utils2/take s 2))</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L320" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L323" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -334,7 +349,7 @@ string matches.
For example: (partition "abc123def" #"[a-z]+")
returns: ("" "abc" "123" "def")</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L219" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L222" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -343,7 +358,7 @@ returns: ("" "abc" "123" "def")</pre>
<pre id="var-usage">Usage: (repeat s n)
</pre>
<pre id="var-docstr">Returns a new String containing s repeated n times.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L145" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L146" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -361,7 +376,7 @@ Allowed argument types for pattern and replacement are:
4. regex Pattern and function
(Calls function with re-groups of each match, uses return
value as replacement.)</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L155" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L156" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -376,7 +391,7 @@ Allowed argument types for pattern and replacement are:
2. regex Pattern and String
(Uses java.util.regex.Matcher.replaceAll)
3. regex Pattern and function</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L190" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L192" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -385,7 +400,7 @@ Allowed argument types for pattern and replacement are:
<pre id="var-usage">Usage: (reverse s)
</pre>
<pre id="var-docstr">Returns s with its characters reversed.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L150" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L151" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -394,7 +409,7 @@ Allowed argument types for pattern and replacement are:
<pre id="var-usage">Usage: (rtrim s)
</pre>
<pre id="var-docstr">Removes whitespace from the right side of string.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L296" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L299" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -405,7 +420,7 @@ Allowed argument types for pattern and replacement are:
</pre>
<pre id="var-docstr">Splits string on a regular expression. Optional argument limit is
the maximum number of splits.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L350" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L353" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -414,7 +429,7 @@ the maximum number of splits.</pre>
<pre id="var-usage">Usage: (split-lines s)
</pre>
<pre id="var-docstr">Splits s on \n or \r\n.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L301" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L304" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -426,7 +441,7 @@ the maximum number of splits.</pre>
Handles Unicode supplementary characters correctly. Uses the
locale-sensitive String.toUpperCase() and String.toLowerCase()
methods.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L264" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L267" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -435,7 +450,7 @@ methods.</pre>
<pre id="var-usage">Usage: (tail s n)
</pre>
<pre id="var-docstr">Returns the last n characters of s.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L138" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L139" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -447,7 +462,7 @@ methods.</pre>
Note the argument order is the opposite of clojure.core/take; this
is to keep the string as the first argument for use with -&gt;</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L107" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L107" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -456,7 +471,7 @@ is to keep the string as the first argument for use with -&gt;</pre>
<pre id="var-usage">Usage: (trim s)
</pre>
<pre id="var-docstr">Removes whitespace from both ends of string.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L356" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L359" id="var-source">Source</a>
</div><div id="var-entry">
<br />
<hr />
@@ -465,7 +480,7 @@ is to keep the string as the first argument for use with -&gt;</pre>
<pre id="var-usage">Usage: (upper-case s)
</pre>
<pre id="var-docstr">Converts string to all upper-case.</pre>
- <a href="http://github.com/richhickey/clojure-contrib/blob/ef69dc58760232c75b55e91d405116aa5ed03d51/src/clojure/contrib/str_utils2.clj#L340" id="var-source">Source</a>
+ <a href="http://github.com/richhickey/clojure-contrib/blob/4b4f6ab5bcab58c4219eb50395bd366daea3ecc3/src/clojure/contrib/str_utils2.clj#L343" id="var-source">Source</a>
</div>