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 Alamofire | |
import SwiftyJSON | |
extension Request { | |
public static func SwiftyJSONResponseSerializer( | |
options options: NSJSONReadingOptions = .AllowFragments) | |
-> ResponseSerializer<JSON, NSError> | |
{ | |
return ResponseSerializer { _, _, data, error in | |
guard error == nil else { return .Failure(error!) } |
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
var setupEllipsis = function(container, itemIndex, itemCount, maxItemCount) { | |
// Make everything visible | |
var hidden = container.all('li.hidden'); | |
hidden.removeClass('hidden'); | |
var ellipsis = container.all('li.ellipsis'); | |
ellipsis.removeClass('ellipsis'); | |
// Get the bounding box data for the selected item | |
var activePage = container.one('li.pageNum-'+itemIndex); |
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
<?php | |
require_once 'SimpleIteratorNodeClasses.php'; | |
class TryingToBeCleverNode extends SimpleNode { | |
public function getDepthOfDeepestChild () { | |
$max_depth = 'N/A'; |