This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<style> | |
.world {padding:50px; position:relative;} | |
.floor{width:calc(200px * 3); height:calc(60px * 3); border:1px solid #EEF; position:relative; margin:0; padding:0; line-height:calc(6px * 3); overflow:visible; vertical-align:top;} | |
.floor-bg{width: calc((147px + 2px) * 3); | |
height: calc(60px * 3); border:1px solid black; position:absolute; margin:0; padding:0; overflow:visible;} | |
.row{ overflow:visible; display:block; height:calc(6px * 3); text-align:left; clear:both;} |
This file contains hidden or 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
(defun current-heap-size-megs (&key (spaces '(:static :dynamic :read-only)) | |
&aux (total-mem 0) (total-cnt 0)) | |
(iter (for s in spaces) | |
(iter (for (mem cnt type) in (sb-vm::type-breakdown s)) | |
(incf total-mem mem) | |
(incf total-cnt cnt))) | |
(values (ceiling (/ total-mem (expt 2 20))) | |
total-cnt)) | |
(defun gc-till-heap-available ( &key |
This file contains hidden or 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 pool = { | |
create: create, | |
release: release, | |
acquire: acquire, | |
useItem: useItem, | |
runTest: runTest, | |
items: [], | |
checkedOut: [], | |
waiting: [], | |
idx: 0 |
This file contains hidden or 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
// This is the code that replaced all the code below this function: | |
protected override IDictionary<int, Dictionary<string, string>> GroupAndFlatten(IEnumerable<PassengerImport> imports) { | |
var paxImports = imports.GroupBy(x => x.PassengerId); | |
var paxes = new Dictionary<int,Dictionary<string,string>>(); | |
foreach(var row in imports){ | |
var paxid = row.PassengerId; | |
if (!paxes.ContainsKey(paxid)) paxes[paxid] = new Dictionary<string,string>(); | |
var paxHash = paxes[paxid]; | |
if(paxHash.ContainsKey(row.Key)) paxHash[row.Key] += " "+ row.Value; | |
else paxHash[row.Key] = row.Value; |
This file contains hidden or 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
// Only want one JSPackager in existance, so lets only create | |
// one if we need to | |
if (typeof(JSPackager) == "undefined") window.JSPackager = { | |
// the head tag of the document | |
_head : document.getElementsByTagName('head')[0], | |
// a script tag to clone | |
_script : (function(){ | |
var s = document.createElement('script'); | |
s.setAttribute('type','text/javascript'); | |
// defer doesnt seem to work with this scheme and so we defer manually in removeLoadedDeps |
This file contains hidden or 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
class ThreadedStreamWriter (Thread): | |
def __init__(self, target): | |
self.target = target | |
self.output_stream = BytesIO() | |
self.output_thread = Thread(target=self.target, args=(self.output_stream,)) | |
self.output_thread.start() | |
class TeeEndPoint(EndPoint): | |
"Base class to inherit from for endpoints." |
This file contains hidden or 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
;; -*- lisp -*- | |
(eval-when (:compile-toplevel :load-toplevel :execute) | |
(unless (find-package :clsql-helper.system) | |
(defpackage :clsql-helper.system | |
(:use :common-lisp :asdf)))) | |
(in-package clsql-helper.system) | |
(eval-when (:compile-toplevel :load-toplevel :execute) |