Experiments with very small pie charts and tables with dots whose size represents a quantity.
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
geocoder = new google.maps.Geocoder | |
geocoder.geocode {address: "Margrethepladsen 4, 8000, DK"}, (results, status) => | |
if status is google.maps.GeocoderStatus.OK | |
console.log "(#{results[0].geometry.location.lng()}, #{results[0].geometry.location.lat()})" | |
else | |
alert "Unable to query service for address \"#{location}\"" |
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 geocoder; | |
var _this = this; | |
geocoder = new google.maps.Geocoder; | |
geocoder.geocode({ | |
address: "Margrethepladsen 4, 8000, DK" | |
}, function(results, status) { | |
if (status === google.maps.GeocoderStatus.OK) { | |
return console.log("(" + (results[0].geometry.location.lng()) + ", " + (results[0].geometry.location.lat()) + ")"); |
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 geocoder; | |
geocoder = new google.maps.Geocoder; | |
geocoder.geocode({ | |
address: "Margrethepladsen 4, 8000, DK" | |
}, function(results, status) { | |
if (status === google.maps.GeocoderStatus.OK) { | |
return console.log("(" + (results[0].geometry.location.lng()) + ", " + (results[0].geometry.location.lat()) + ")"); | |
} else { |
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
Vagrant::Config.run do |config| | |
config.vm.box = "lucid32" | |
config.vm.host_name = "apache" | |
config.vm.network :hostonly, "192.168.0.101" | |
config.vm.provision :chef_solo do |chef| | |
chef.cookbooks_path = "cookbooks" | |
chef.add_recipe "apt" | |
chef.add_recipe "apache2" |
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
import java.util.Arrays; | |
public class Car { | |
private int maxSpeed; | |
private Wheel[] wheels; | |
public Car(int maxSpeed, Wheel[] wheels) { | |
this.maxSpeed = maxSpeed; | |
this.wheels = wheels; |
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
(ns swing | |
(:import [javax.swing JFrame JLabel JButton] | |
[java.awt.event WindowListener])) | |
(defn swing [] | |
(let [frame (JFrame. "Fund manager") | |
label (JLabel. "Exit on close")] | |
(doto frame | |
(.add label) | |
(.setDefaultCloseOperation JFrame/EXIT_ON_CLOSE) |
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
(use '[datomic.api :only [q db] :as d]) | |
(def uri "datomic:mem://schema-test") | |
(d/delete-database uri) | |
(d/create-database uri) | |
(def conn (d/connect uri)) | |
(def schema-tx |
Example of how rolling deploys might have been easy on Datomic databases, had Datomic supported change of schema in db snapshots. The example will not work, but illustrates how easy it would have been to operate on a new schema on an old database by performing migration in-memory when needed.
Mouseover to repel nodes. Weee, nodes!