Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/akpw/VisualBinaryTrees

Visual Binary Trees with Swift 3 Playgrounds
https://github.com/akpw/VisualBinaryTrees

Last synced: about 1 month ago
JSON representation

Visual Binary Trees with Swift 3 Playgrounds

Awesome Lists containing this project

README

        

Visual Binary Trees with Swift 3 Playgrounds
============

![Language](https://img.shields.io/badge/language-Swift3-orange.svg)
![License](https://img.shields.io/badge/License-GNU%20GPL-blue.svg)

![obj-c](http://www.akpdev.com/images/tree4.png)

## Blogs
* [Visual Binary Trees with Swift 3 Playgrounds: Introduction](http://www.akpdev.com/articles/2016/08/26/BinaryTreesPlayground.html)
* [Part I: QuickLook-able Binary Tree with Pluggable Traversals](http://www.akpdev.com/articles/2016/08/27/BinaryTreesPlayground-Part-I.html)
* [Part II: The Drawing Architecture, Customization, and Tree Layouts](http://www.akpdev.com/articles/2016/09/08/BinaryTreesPlayground-Part-II.html)

## Features
* Effortless visualization of arbitrary Binary Trees, along with their (pluggable) traversals
* Works with trees implemented both as reference types and as Swift enums
* By default, builds Optimal Tree Layout in O(n) time
* Supports multiple tree layouts and various drawing configurations
* A standalone playground with practical examples, ready to run in Xcode and in [Swift Playgrounds for iPad](https://www.apple.com/swift/playgrounds/)
* Written in latest Swift 3 / Xcode 8

## TODOs
* A version as an embeddable framework under MIT license
- [ ] TBD

## Docs
[Initial docs][docsLink], generated with [jazzy](https://github.com/realm/jazzy) and hosted by [GitHub Pages](https://pages.github.com).

## Usage

1) Download or Clone the repository

```bash
$ git clone https://github.com/akpw/VisualBinaryTrees
```

3) Open the playground in Xcode
```bash
$ cd VisualBinaryTrees
$ open VisualBinaryTrees.playground -a Xcode-beta.app
```

4) Optionally, you can also switch to the `VisualBinaryTreeApp` folder and open & run the included sample app:

```bash
$ cd VisualBinaryTreeApp
$ open VisualBinaryTree.xcodeproj -a Xcode-beta.app
```

# Requirements

* latest Xcode 8
* iOS9 (requires iOS10 to run in the Swift Playgrounds for iPad)

[docsLink]:https://akpw.github.io//VisualBinaryTrees/index.html