Added example

This commit is contained in:
Kevin Jahns
2014-08-05 05:00:22 +02:00
parent 6c34d97432
commit 7f6ea1e291
55 changed files with 1185 additions and 229 deletions

View File

@@ -142,7 +142,7 @@ only one will AddName operation will be executed.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -157,7 +157,7 @@ This result can be sent to other clients.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -118,7 +118,7 @@ of the Engine is empty.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -139,7 +139,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -228,7 +228,7 @@ other operations (it wont executed)</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -0,0 +1,230 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>Yatta! Documentation</title>
<script src='../javascript/application.js'></script>
<script src='../javascript/search.js'></script>
<link rel='stylesheet' href='../stylesheets/application.css' type='text/css'>
</head>
<body>
<div id='base' data-path='../'></div>
<div id='header'>
<div id='menu'>
<a href='../extra/README.md.html' title='Yatta!'>
Yatta!
</a>
&raquo;
<a href='../alphabetical_index.html' title='Index'>
Index
</a>
&raquo;
<span class='title'>ImmutableObject</span>
</div>
</div>
<div id='content'>
<h1>
Class:
ImmutableObject
</h1>
<table class='box'>
<tr>
<td>Defined in:</td>
<td>lib&#47;Types&#47;BasicTypes.coffee</td>
</tr>
<tr>
<td>Inherits:</td>
<td>
<a href='../class/Insert.html'>Insert</a>
</td>
</tr>
</table>
<h2>Overview</h2>
<div class='docstring'>
<p>Defines an object that is cannot be changed. You can use this to set an immutable string, or a number.</p>
</div>
<div class='tags'>
</div>
<h2>Instance Method Summary</h2>
<ul class='summary'>
<li>
<span class='signature'>
<a href='#val-dynamic'>
#
(String)
<b>val</b><span>()</span>
</a>
</span>
<span class='desc'>
</span>
</li>
<li>
<span class='signature'>
<a href='#_encode-dynamic'>
#
(void)
<b>_encode</b><span>()</span>
</a>
</span>
<span class='desc'>
</span>
</li>
</ul>
<h2>
<small>Inherited Method Summary</small>
<h3 class='inherited'>
Methods inherited from
<a href='../class/Insert.html'>Insert</a>
</h3>
<p class='inherited'>
<a href='../class/Insert.html#applyDelete-dynamic'>#applyDelete</a>
<a href='../class/Insert.html#isDeleted-dynamic'>#isDeleted</a>
<a href='../class/Insert.html#getDistanceToOrigin-dynamic'>#getDistanceToOrigin</a>
<a href='../class/Insert.html#update_sl-dynamic'>#update_sl</a>
<a href='../class/Insert.html#execute-dynamic'>#execute</a>
<a href='../class/Operation.html#getUid-dynamic'>#getUid</a>
<a href='../class/Operation.html#saveOperation-dynamic'>#saveOperation</a>
<a href='../class/Operation.html#validateSavedOperations-dynamic'>#validateSavedOperations</a>
</p>
</h2>
<h2>Constructor Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='constructor-dynamic'>
#
(void)
<b>constructor</b><span>(uid, content = &quot;&quot;, prev, next, origin)</span>
<br>
</p>
<div class='tags'>
<h3>Parameters:</h3>
<ul class='param'>
<li>
<span class='name'>uid</span>
<span class='type'>
(
<tt>Object</tt>
)
</span>
&mdash;
<span class='desc'>A unique identifier. If uid is undefined, a new uid will be created. </span>
</li>
<li>
<span class='name'>content</span>
<span class='type'>
(
<tt>Object</tt>
)
</span>
</li>
</ul>
</div>
</div>
</div>
<h2>Instance Method Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='val-dynamic'>
#
(String)
<b>val</b><span>()</span>
<br>
</p>
<div class='tags'>
<h3>Returns:</h3>
<ul class='return'>
<li>
<span class='type'></span>
(
<tt>String</tt>
)
&mdash;
<span class='desc'>The content of this operation. </span>
</li>
</ul>
</div>
</div>
<div class='method_details'>
<p class='signature' id='_encode-dynamic'>
#
(void)
<b>_encode</b><span>()</span>
<br>
</p>
</div>
</div>
</div>
<div id='footer'>
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>
2.0.9
&#10034;
Press H to see the keyboard shortcuts
&#10034;
<a href='http://twitter.com/netzpirat' target='_parent'>@netzpirat</a>
&#10034;
<a href='http://twitter.com/_inossidabile' target='_parent'>@_inossidabile</a>
</div>
<iframe id='search_frame'></iframe>
<div id='fuzzySearch'>
<input type='text'>
<ol></ol>
</div>
<div id='help'>
<p>
Quickly fuzzy find classes, mixins, methods, file:
</p>
<ul>
<li>
<span>T</span>
Open fuzzy finder dialog
</li>
</ul>
<p>
Control the navigation frame:
</p>
<ul>
<li>
<span>L</span>
Toggle list view
</li>
<li>
<span>C</span>
Show class list
</li>
<li>
<span>I</span>
Show mixin list
</li>
<li>
<span>F</span>
Show file list
</li>
<li>
<span>M</span>
Show method list
</li>
<li>
<span>E</span>
Show extras list
</li>
</ul>
<p>
You can focus and blur the search input:
</p>
<ul>
<li>
<span>S</span>
Focus search input
</li>
<li>
<span>Esc</span>
Blur search input
</li>
</ul>
</div>
</body>
</html>

View File

@@ -256,7 +256,7 @@ TODO (Unused)</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -168,7 +168,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -286,7 +286,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

195
doc/class/JsonWrapper.html Normal file
View File

@@ -0,0 +1,195 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>Yatta! Documentation</title>
<script src='../javascript/application.js'></script>
<script src='../javascript/search.js'></script>
<link rel='stylesheet' href='../stylesheets/application.css' type='text/css'>
</head>
<body>
<div id='base' data-path='../'></div>
<div id='header'>
<div id='menu'>
<a href='../extra/README.md.html' title='Yatta!'>
Yatta!
</a>
&raquo;
<a href='../alphabetical_index.html' title='Index'>
Index
</a>
&raquo;
<span class='title'>JsonWrapper</span>
</div>
</div>
<div id='content'>
<h1>
Class:
JsonWrapper
</h1>
<table class='box'>
<tr>
<td>Defined in:</td>
<td>lib&#47;Types&#47;JsonTypes.coffee</td>
</tr>
</table>
<h2>Overview</h2>
<div class='docstring'>
<div class='note'>
<strong>Note:</strong>
You can only overwrite existing values! Setting a new property won&#39;t have any effect!
</div>
<p>A JsonWrapper was intended to be a convenient wrapper for the JsonType.
But it can make things more difficult than they are.</p><p>It creates Javascripts -getter and -setter methods for each property that JsonType maintains.</p><p>In order to set a new property you have to overwrite an existing property.
Therefore the JsonWrapper supports a special feature that should make things more convenient
(we can argue about that, use the JsonType if you don&#39;t like it ;).
If you overwrite an object property of the JsonWrapper with a new object, it will result in a merged version of the objects.
Let w.p the property that is to be overwritten and o the new value. E.g. w.p = o</p><ul>
<li>The result has all properties of o</li>
<li>The result has all properties of w.p if they don&#39;t occur under the same property-name in o.</li>
</ul>
<div class='examples'>
<h3>Examples:</h3>
<h4>
create a JsonWrapper
</h4>
<pre><code class='coffeescript'># You get a JsonWrapper from a JsonType by calling
w = yatta.value</code></pre>
<h4>
Getter Example
</h4>
<pre><code class='coffeescript'># you can access the x property of yatta by calling
w.x
# instead of
yatta.val(&#39;x&#39;)</code></pre>
<h4>
Setter Example
</h4>
<pre><code class='coffeescript'># you can set an existing x property of yatta by calling
w.x = &quot;text&quot;
# instead of
yatta.val(&#39;x&#39;, &quot;text&quot;)</code></pre>
<h4>
Conflict Example
</h4>
<pre><code class='coffeescript'>yatta.value = {a : &quot;string&quot;}
w = yatta.value
console.log(w) # {a : &quot;string&quot;}
w.a = {a : {b : &quot;string&quot;}}
console.log(w) # {a : {b : &quot;String&quot;}}
w.a = {a : {c : 4}}
console.log(w) # {a : {b : &quot;String&quot;, c : 4}}</code></pre>
<h4>
Common Pitfalls
</h4>
<pre><code class='coffeescript'>w = yatta.value
# Setting a new property
w.newProperty = &quot;Awesome&quot;
console.log(w.newProperty == &quot;Awesome&quot;) # false, w.newProperty is undefined
# overwrite the w object
w = {newProperty : &quot;Awesome&quot;}
console.log(w.newProperty == &quot;Awesome&quot;) # true!, but ..
console.log(yatta.value.newProperty == &quot;Awesome&quot;) # false, you are only allowed to set properties!
# The solution
yatta.value = {newProperty : &quot;Awesome&quot;}
console.log(w.newProperty == &quot;Awesome&quot;) # true!</code></pre>
</div>
</div>
<div class='tags'>
<h3>See also:</h3>
<ul class='see'>
<li>
<a href='../class/JsonType.html'>JsonType</a>
</li>
<li>
<a href='getter'>https:&#47;&#47;developer.mozilla.org&#47;en-US&#47;docs&#47;Web&#47;JavaScript&#47;Reference&#47;Global_Objects&#47;Object&#47;defineProperty</a>
</li>
</ul>
</div>
<h2>Constructor Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='constructor-dynamic'>
#
(void)
<b>constructor</b><span>(jsonType)</span>
<br>
</p>
</div>
</div>
</div>
<div id='footer'>
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>
2.0.9
&#10034;
Press H to see the keyboard shortcuts
&#10034;
<a href='http://twitter.com/netzpirat' target='_parent'>@netzpirat</a>
&#10034;
<a href='http://twitter.com/_inossidabile' target='_parent'>@_inossidabile</a>
</div>
<iframe id='search_frame'></iframe>
<div id='fuzzySearch'>
<input type='text'>
<ol></ol>
</div>
<div id='help'>
<p>
Quickly fuzzy find classes, mixins, methods, file:
</p>
<ul>
<li>
<span>T</span>
Open fuzzy finder dialog
</li>
</ul>
<p>
Control the navigation frame:
</p>
<ul>
<li>
<span>L</span>
Toggle list view
</li>
<li>
<span>C</span>
Show class list
</li>
<li>
<span>I</span>
Show mixin list
</li>
<li>
<span>F</span>
Show file list
</li>
<li>
<span>M</span>
Show method list
</li>
<li>
<span>E</span>
Show extras list
</li>
</ul>
<p>
You can focus and blur the search input:
</p>
<ul>
<li>
<span>S</span>
Focus search input
</li>
<li>
<span>Esc</span>
Blur search input
</li>
</ul>
</div>
</body>
</html>

View File

@@ -127,17 +127,6 @@ Known values that are supported:</p><ul>
<span class='desc'>
</span>
</li>
<li>
<span class='signature'>
<a href='#value-dynamic'>
#
(void)
<b>value</b><span>()</span>
</a>
</span>
<span class='desc'>
</span>
</li>
</ul>
<h2>Constructor Details</h2>
<div class='methods'>
@@ -256,28 +245,12 @@ JsonYatta was initialized (Depending on the HistoryBuffer implementation).</p>
<a href='JsonType.val'>JsonType.val</a>
</li>
</ul>
</div>
</div>
<div class='method_details'>
<p class='signature' id='value-dynamic'>
#
(void)
<b>value</b><span>()</span>
<br>
</p>
<div class='tags'>
<h3>See also:</h3>
<ul class='see'>
<li>
<a href='JsonType.value'>JsonType.value</a>
</li>
</ul>
</div>
</div>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -208,7 +208,7 @@ Doesn&#39;t return left-right delimiter.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -99,7 +99,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -284,7 +284,7 @@ an easy way to refer to these operations via an uid or object reference.</p><p>F
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -189,7 +189,7 @@ Each Replaceable holds a value that is now replaceable.</p><p>The Word-type has
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -191,7 +191,7 @@ This result can be send to other clients.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -219,7 +219,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -53,7 +53,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -173,7 +173,7 @@ This result can be send to other clients.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -239,7 +239,7 @@
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -241,7 +241,7 @@ to provide replace functionality.</p>
</div>
</div>
<div id='footer'>
August 04, 14 23:05:04 by
August 05, 14 05:00:00 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>

View File

@@ -0,0 +1,207 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='UTF-8'>
<title>Yatta! Documentation</title>
<script src='../javascript/application.js'></script>
<script src='../javascript/search.js'></script>
<link rel='stylesheet' href='../stylesheets/application.css' type='text/css'>
</head>
<body>
<div id='base' data-path='../'></div>
<div id='header'>
<div id='menu'>
<a href='../extra/README.md.html' title='Yatta!'>
Yatta!
</a>
&raquo;
<a href='../alphabetical_index.html' title='Index'>
Index
</a>
&raquo;
<span class='title'>WordImmutable</span>
</div>
</div>
<div id='content'>
<h1>
Class:
WordImmutable
</h1>
<table class='box'>
<tr>
<td>Defined in:</td>
<td>lib&#47;Types&#47;TextTypes.coffee</td>
</tr>
<tr>
<td>Inherits:</td>
<td>
types.Insert
</td>
</tr>
</table>
<h2>Instance Method Summary</h2>
<ul class='summary'>
<li>
<span class='signature'>
<a href='#val-dynamic'>
#
(String)
<b>val</b><span>()</span>
</a>
</span>
<span class='desc'>
</span>
</li>
<li>
<span class='signature'>
<a href='#toJson-dynamic'>
#
(void)
<b>toJson</b><span>()</span>
</a>
</span>
<span class='desc'>
</span>
</li>
</ul>
<h2>Constructor Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='constructor-dynamic'>
#
(void)
<b>constructor</b><span>(uid, content = &quot;&quot;, prev, next, origin)</span>
<br>
</p>
<div class='tags'>
<h3>Parameters:</h3>
<ul class='param'>
<li>
<span class='name'>uid</span>
<span class='type'>
(
<tt>Object</tt>
)
</span>
&mdash;
<span class='desc'>A unique identifier. If uid is undefined, a new uid will be created. </span>
</li>
<li>
<span class='name'>content</span>
<span class='type'>
(
<tt>String</tt>
)
</span>
</li>
</ul>
</div>
</div>
</div>
<h2>Instance Method Details</h2>
<div class='methods'>
<div class='method_details'>
<p class='signature' id='val-dynamic'>
#
(String)
<b>val</b><span>()</span>
<br>
</p>
<div class='tags'>
<h3>Returns:</h3>
<ul class='return'>
<li>
<span class='type'></span>
(
<tt>String</tt>
)
&mdash;
<span class='desc'>The content of this operation. </span>
</li>
</ul>
</div>
</div>
<div class='method_details'>
<p class='signature' id='toJson-dynamic'>
#
(void)
<b>toJson</b><span>()</span>
<br>
</p>
</div>
</div>
</div>
<div id='footer'>
August 04, 14 16:39:02 by
<a href='https://github.com/coffeedoc/codo' title='CoffeeScript API documentation generator'>
Codo
</a>
2.0.9
&#10034;
Press H to see the keyboard shortcuts
&#10034;
<a href='http://twitter.com/netzpirat' target='_parent'>@netzpirat</a>
&#10034;
<a href='http://twitter.com/_inossidabile' target='_parent'>@_inossidabile</a>
</div>
<iframe id='search_frame'></iframe>
<div id='fuzzySearch'>
<input type='text'>
<ol></ol>
</div>
<div id='help'>
<p>
Quickly fuzzy find classes, mixins, methods, file:
</p>
<ul>
<li>
<span>T</span>
Open fuzzy finder dialog
</li>
</ul>
<p>
Control the navigation frame:
</p>
<ul>
<li>
<span>L</span>
Toggle list view
</li>
<li>
<span>C</span>
Show class list
</li>
<li>
<span>I</span>
Show mixin list
</li>
<li>
<span>F</span>
Show file list
</li>
<li>
<span>M</span>
Show method list
</li>
<li>
<span>E</span>
Show extras list
</li>
</ul>
<p>
You can focus and blur the search input:
</p>
<ul>
<li>
<span>S</span>
Focus search input
</li>
<li>
<span>Esc</span>
Blur search input
</li>
</ul>
</div>
</body>
</html>