<!DOCTYPE html>
<html lang="en">
  <head>
    <title>  Reference</title>
    <link rel="stylesheet" type="text/css" href="css/jazzy.css" />
    <link rel="stylesheet" type="text/css" href="css/highlight.css" />
    <meta charset='utf-8'>
    <script src="js/jquery.min.js" defer></script>
    <script src="js/jazzy.js" defer></script>
  </head>
  <body>
    <a title="  Reference"></a>
    <header>
      <div class="content-wrapper">
        <p><a href="index.html"> Docs</a> (25% documented)</p>
        <p class="header-right"><a href=""><img src="img/gh.png"/>View on GitHub</a></p>
      </div>
    </header>
    <div class="content-wrapper">
      <p id="breadcrumbs">
        <a href="index.html"> Reference</a>
        <img id="carat" src="img/carat.png" />
          Reference
      </p>
    </div>
    <div class="content-wrapper">
      <nav class="sidebar">
        <ul class="nav-groups">
          <li class="nav-group-name">
          <a href="Classes.html">Classes</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Classes.html#/s:C9FutureKit5FTask">FTask</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes.html#/s:C9FutureKit15FTaskCompletion">FTaskCompletion</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/FTaskPromise.html">FTaskPromise</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/Future.html">Future</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/FutureBatchOf.html">FutureBatchOf</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/FutureNSError.html">FutureNSError</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/NSLockSynchronization.html">NSLockSynchronization</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/NSRecursiveLockSynchronization.html">NSRecursiveLockSynchronization</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/OSAtomicInt32.html">OSAtomicInt32</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/OSAtomicInt64.html">OSAtomicInt64</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/Promise.html">Promise</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/QueueBarrierSynchronization.html">QueueBarrierSynchronization</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/QueueSerialSynchronization.html">QueueSerialSynchronization</a>
              </li>
              <li class="nav-group-task">
                <a href="Classes/SynchronizationObject.html">SynchronizationObject</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
          <a href="Enums.html">Enums</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Enums/Completion.html">Completion</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums.html#/s:O9FutureKit15CompletionState">CompletionState</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums/Executor.html">Executor</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums.html#/s:O9FutureKit7FErrors">FErrors</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums.html#/s:O9FutureKit13FTaskExecutor">FTaskExecutor</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums/SerialOrConcurrent.html">SerialOrConcurrent</a>
              </li>
              <li class="nav-group-task">
                <a href="Enums.html#/s:O9FutureKit19SynchronizationType">SynchronizationType</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
          <a href="Extensions.html">Extensions</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Extensions.html#/s:C9FutureKit5FTask">FTask</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions/FTaskPromise.html">FTaskPromise</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions/Future.html">Future</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions.html#/c:objc(cs)NSObject">NSObject</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions/NSQualityOfService.html">NSQualityOfService</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions.html#/s:Sq">Optional</a>
              </li>
              <li class="nav-group-task">
                <a href="Extensions.html#/s:C9FutureKit14__ExampleClass">__ExampleClass</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
          <a href="Functions.html">Functions</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Functions.html#/s:F9FutureKit17toFutureAnyObjectUSs9AnyObject__FGCS_6FutureQ__GS1_PS0___">toFutureAnyObject(_:)</a>
              </li>
              <li class="nav-group-task">
                <a href="Functions.html#/s:F9FutureKit20toFutureAnyObjectOptUSs9AnyObject__FGCS_6FutureGSqQ___GS1_GSqPS0____">toFutureAnyObjectOpt(_:)</a>
              </li>
              <li class="nav-group-task">
                <a href="Functions.html#/s:F9FutureKit25warnOperationOnMainThreadFT_T_">warnOperationOnMainThread()</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
          <a href="Protocols.html">Protocols</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Protocols.html#/s:P9FutureKit14FutureProtocol">FutureProtocol</a>
              </li>
              <li class="nav-group-task">
                <a href="Protocols.html#/s:P9FutureKit23SynchronizationProtocol">SynchronizationProtocol</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
          <a href="Structs.html">Structs</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a href="Structs/GLOBAL_PARMS.html">GLOBAL_PARMS</a>
              </li>
            </ul>
          </li>
        </ul>
      </nav>
      <article class="main-content">
        <section>
          <section class="section">
            
            <a href='#futurekit_for_swift' class='anchor' aria-hidden=true><span class="header-anchor"></span></a><h1 id='futurekit_for_swift'>FutureKit for Swift</h1>

<p>A Swift based Future/Promises Library for IOS and OS X.   </p>

<p>FutureKit is a iOS implementation of Futures and Promises, but modified specifically for iOS/OSX programmers.</p>

<p>FutureKit sues Swift generic classes, to allow you to easily deal with asynchronous/multi-threaded issues when coding for iOS or OSX.</p>

<ul>
<li><p>is 100% Swift.  And supports Swift 1.2 and XCode 6.3.</p></li>
<li><p>is type safe.  It uses Swift Generics classes that can automatically infer the type you wish to return from asynchronous logic.  And supports all Swift types (Both &lsquo;Any&rsquo; types, and &#39;AnyObject/NSObject&rsquo; types!)</p></li>
<li><p>uses simple to understand methods (onComplete/onSuccess/onFail etc) that let&rsquo;s you simplify complex asynchronous operations into clear and simple to understand logic.</p></li>
<li><p>is highly composable, since any existing Future can be used to generate a new Future.  And Errors can be automatically passed through, simplifying error handling logic.</p></li>
<li><p>works well editing code within XCode 6.3 auto-completion.  The combination of type-inference and code-completion makes FutureKit coding fast and easy.</p></li>
<li><p>simplifies the use of Apple GCD by using Executors - a simple Swift enumeration that attracts the most common iOS/OSX Dispatch Queues (Main,Default,Background, etc).  Allowing you to guarantee that logic will always be executed in the context you want.  (You never have to worry about having to call the correct dispatch_async() function again).  </p></li>
<li><p>is highly tunable, allowing you to configure how the primary Executors (Immediate vs Async) execute, and what sort Thread Synchronization FutureKit will use (Barriers - Locks, etc).  Allowing you to tune FutureKit&rsquo;s logic to match what you need.  </p></li>
</ul>
<a href='#documentation' class='anchor' aria-hidden=true><span class="header-anchor"></span></a><h1 id='documentation'>Documentation</h1>

<p>FutureKit documentation is being written as XCode Playgrounds.  The best way to start is to open the FutureKit.workspace and then opening the Playground inside.  (If you open the Playgrounds outside of the workspace, then FutureKit module may not import correctly).
The XCode Playgrounds probably require XCode 6.3 (in order to see the Markup correctly)</p>

<p>If you are impatient, or not near your copy of XCode, you can try to read the first intro <q>raw</q> playground here:
<a href="https://github.com/FutureKit/FutureKit/blob/master/FutureKit-Future.playground/Contents.swift">https://github.com/FutureKit/FutureKit/blob/master/FutureKit-Future.playground/Contents.swift</a></p>

<p>There is also docs directory, that is generated using jazzy. <a href="https://github.com/realm/jazzy">https://github.com/realm/jazzy</a> and the embedded documentation.  The plan is to get as close to 100% as possible (We are at 20%!).  So currently there is a lot of missing documentation.</p>

          </section>
        </section>
        <section id="footer">
          <p>&copy; 2015 <a class="link" href="" target="_blank" rel="external"></a>. All rights reserved. (Last updated: 2015-04-19)</p>
          <p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.1.6</a>, a <a class="link" href="http://realm.io" target="_blank" rel="external">Realm</a> project.</p>
        </section>
      </article>
    </div>
  </body>
</div>
</html>
