This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Unbox | |
import Foundation | |
extension Unboxable { | |
func safeUnbox(unboxer: Unboxer,key :String )->String{ | |
do{ | |
return try unboxer.unbox(key: key) as String | |
}catch{ | |
return "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
content//: Playground - noun: a place where people can play | |
import UIKit | |
import Foundation | |
var str = "Hello, @playground.something more" | |
//(?<=\\s|^|\\b)(?:[-'.%$#&/]\\b|\\b[-'.%$#&/]|[A-Za-z0-9]|\\([A-Za-z0-9]+\\))+(?=\\s|$|\\b) | |
let range = NSMakeRange(0, str.characters.count) | |
var regex = try! NSRegularExpression(pattern: "@(?<=\\s|^|\\b)(?:[-'.%$#&/]\\b|\\b[-'.%$#&/]|[A-Za-z0-9]|\\([A-Za-z0-9]+\\))+(?=\\s|$|\\b)", options: .caseInsensitive) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
content <key>NSExtension</key> | |
<dict> | |
<key>NSExtensionAttributes</key> | |
<dict> | |
<key>NSExtensionActivationRule</key> | |
<string>SUBQUERY ( | |
extensionItems, | |
$extensionItem, | |
SUBQUERY ( | |
$extensionItem.attachments, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// DebugPrint.swift | |
// | |
// Created by Javier Loucim on 10/22/16. | |
// Copyright © 2016 Javier Loucim. All rights reserved. | |
// | |
import Foundation | |
func print(_ message:String , separator: String = " ", terminator: String = "\n", functionName: String = #function, fileName: String = #file, lineNumber: Int = #line) { |
NewerOlder