/
Data-Sequence-Lens.html
15 lines (15 loc) · 7.09 KB
/
Data-Sequence-Lens.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Sequence.Lens</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Sequence-Lens.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/Data-Sequence-Lens.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">lens-3.6: Lenses, Folds and Traversals</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Portability</th><td>portable</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Maintainer</th><td>Edward Kmett <ekmett@gmail.com></td></tr><tr><th>Safe Haskell</th><td>Safe-Inferred</td></tr></table><p class="caption">Data.Sequence.Lens</p></div><div id="description"><p class="caption">Description</p><div class="doc empty"> </div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:ordinal">ordinal</a> :: Int -> <a href="Control-Lens-IndexedLens.html#t:SimpleIndexedLens">SimpleIndexedLens</a> Int (Seq a) a</li><li class="src short"><a href="#v:viewL">viewL</a> :: <a href="Control-Lens-Iso.html#t:Iso">Iso</a> (Seq a) (Seq b) (ViewL a) (ViewL b)</li><li class="src short"><a href="#v:viewR">viewR</a> :: <a href="Control-Lens-Iso.html#t:Iso">Iso</a> (Seq a) (Seq b) (ViewR a) (ViewR b)</li><li class="src short"><a href="#v:_head">_head</a> :: <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a</li><li class="src short"><a href="#v:_tail">_tail</a> :: <a href="Control-Lens-Traversal.html#t:SimpleTraversal">SimpleTraversal</a> (Seq a) (Seq a)</li><li class="src short"><a href="#v:_last">_last</a> :: <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a</li><li class="src short"><a href="#v:_init">_init</a> :: <a href="Control-Lens-Traversal.html#t:SimpleTraversal">SimpleTraversal</a> (Seq a) (Seq a)</li><li class="src short"><a href="#v:sliced">sliced</a> :: Int -> Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a</li><li class="src short"><a href="#v:slicedTo">slicedTo</a> :: Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a</li><li class="src short"><a href="#v:slicedFrom">slicedFrom</a> :: Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:ordinal" class="def">ordinal</a> :: Int -> <a href="Control-Lens-IndexedLens.html#t:SimpleIndexedLens">SimpleIndexedLens</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#ordinal" class="link">Source</a></p><div class="doc"><p>A <code><a href="Control-Lens-Type.html#t:Lens">Lens</a></code> that can access the <code>n</code>th element of a <code>Seq</code>.
</p><p>Note: This is only a legal lens if there is already such an element!
</p></div></div><div class="top"><p class="src"><a name="v:viewL" class="def">viewL</a> :: <a href="Control-Lens-Iso.html#t:Iso">Iso</a> (Seq a) (Seq b) (ViewL a) (ViewL b)<a href="src/Data-Sequence-Lens.html#viewL" class="link">Source</a></p><div class="doc"><p>A <code>Seq</code> is isomorphic to a <code>ViewL</code>
</p><pre><code>viewl</code> m = m <code><a href="Control-Lens-Getter.html#v:-94-.">^.</a></code> <code><a href="Data-Sequence-Lens.html#v:viewL">viewL</a></code></pre></div></div><div class="top"><p class="src"><a name="v:viewR" class="def">viewR</a> :: <a href="Control-Lens-Iso.html#t:Iso">Iso</a> (Seq a) (Seq b) (ViewR a) (ViewR b)<a href="src/Data-Sequence-Lens.html#viewR" class="link">Source</a></p><div class="doc"><p>A <code>Seq</code> is isomorphic to a <code>ViewR</code>
</p><pre><code>viewr</code> m = m <code><a href="Control-Lens-Getter.html#v:-94-.">^.</a></code> <code><a href="Data-Sequence-Lens.html#v:viewR">viewR</a></code></pre></div></div><div class="top"><p class="src"><a name="v:_head" class="def">_head</a> :: <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#_head" class="link">Source</a></p><div class="doc"><p>Traverse the head of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:_tail" class="def">_tail</a> :: <a href="Control-Lens-Traversal.html#t:SimpleTraversal">SimpleTraversal</a> (Seq a) (Seq a)<a href="src/Data-Sequence-Lens.html#_tail" class="link">Source</a></p><div class="doc"><p>Traverse the tail of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:_last" class="def">_last</a> :: <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#_last" class="link">Source</a></p><div class="doc"><p>Traverse the last element of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:_init" class="def">_init</a> :: <a href="Control-Lens-Traversal.html#t:SimpleTraversal">SimpleTraversal</a> (Seq a) (Seq a)<a href="src/Data-Sequence-Lens.html#_init" class="link">Source</a></p><div class="doc"><p>Traverse all but the last element of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:sliced" class="def">sliced</a> :: Int -> Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#sliced" class="link">Source</a></p><div class="doc"><p>Travere all the elements numbered from <code>i</code> to <code>j</code> of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:slicedTo" class="def">slicedTo</a> :: Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#slicedTo" class="link">Source</a></p><div class="doc"><p>Traverse the first <code>n</code> elements of a <code>Seq</code>
</p></div></div><div class="top"><p class="src"><a name="v:slicedFrom" class="def">slicedFrom</a> :: Int -> <a href="Control-Lens-IndexedTraversal.html#t:SimpleIndexedTraversal">SimpleIndexedTraversal</a> Int (Seq a) a<a href="src/Data-Sequence-Lens.html#slicedFrom" class="link">Source</a></p><div class="doc"><p>Traverse all but the first <code>n</code> elements of a <code>Seq</code>
</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.13.1</p></div></body></html>