Skip to content

Instantly share code, notes, and snippets.

Battery about to die

Okke Timm okket

Battery about to die
Block or report user

Report or block okket

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View QuickLook.swift
// Custom QuickLook objects in Playground, see
import UIKit
@objc class BezierCircle {
var color : UIColor
var path : UIBezierPath
var radius : Double
init (_ radius : Double, _ color : UIColor = UIColor.redColor()) {
View Reflections.swift
import Foundation
func typestring(x : Any) -> String
if let obj = x as? NSObject {
return NSStringFromClass((x as NSObject).dynamicType)
// Native Swift
switch x {
okket / AVAudioEngine.swift
Last active Dec 27, 2017
AVAudioEngine in Playground
View AVAudioEngine.swift
// AVAudioEngine Playground - requires OS X 10.10
import Cocoa
import AVFoundation
// Keep playground running
import XCPlayground
XCPSetExecutionShouldContinueIndefinitely(continueIndefinitely: true)
// Setup engine and node instances
var engine = AVAudioEngine()
You can’t perform that action at this time.