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
@Grab('org.jfree:jfreechart:1.0.14') | |
import java.awt.* | |
import java.awt.geom.* | |
import java.io.* | |
import java.text.* | |
import org.jfree.chart.* | |
import org.jfree.chart.annotations.* | |
import org.jfree.chart.axis.* | |
import org.jfree.chart.block.* | |
import org.jfree.chart.labels.* |
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
// see: http://jsfiddle.net/DBA4Q/ | |
@import 'nib' | |
bookmark(color, width) | |
width width | |
height (width * 2) | |
background linear-gradient(top, lighten(color, 35%) 5%, color 12%) | |
position relative |
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
qs = require 'querystring' | |
diagram = """ | |
title Foo bar baz | |
a -> b: do b.m() | |
b -> c: do c.m() | |
""" | |
baseUrl = "http://www.websequencediagrams.com/cgi-bin/cdraw" |
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 CoffeeScript = require('coffee-script'); // make sure that coffee-script version is >= 1.5.0 | |
var assets = require('connect-assets')({ | |
jsCompilers: { | |
litcoffee: { | |
match: /\.js$/, | |
compileSync: function (sourcePath, source) { | |
return CoffeeScript.compile(source, { filename: sourcePath, literate: true }); | |
} | |
} |
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
assert = require 'assert' | |
reverse = (str) -> | |
(str.split '').reverse().join '' | |
format = (num) -> | |
reverse (reverse num.toString()).replace /\d{3}(?=\d)/g, '$& ' | |
assert '1' is format 1 | |
assert '10' is format 10 |
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
console.log "bonjour jeanne" | |
console.log "jaime mon amie jeanne-mangue" | |
console.log 2+7 | |
console.log 6+18 | |
console.log "jaime mon petit frère Louis" |
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
@Grab('org.codehaus.groovy.modules:groovyws:0.5.2') | |
import groovyx.net.ws.* | |
// Define a simple service with a single method that sums two numbers. | |
class MathService { | |
double add (double x, double y) { x + y } | |
} | |
// Start a server that exposes the service as a SOAP endpoint. |
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
age=4 | |
nom="jeanne" | |
console.log "bonjour mon nom est #{nom} et j'ai #{age} ans." | |
nom="louis" | |
age=2 | |
console.log "bonjour mon nom est #{nom} et j'ai #{age} ans." |
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
folders = [ | |
{id:1, parentId:2, childrenId:[]} | |
{id:2, parentId:null, childrenId:[]} | |
{id:3, parentId:2, childrenId:[]} | |
{id:4, parentId:5, childrenId:[]} | |
{id:5, parentId:3, childrenId:[]} | |
{id:6, parentId:5, childrenId:[]} | |
{id:7, parentId:999, childrenId:[]} | |
{id:8, parentId:7, childrenId:[]} | |
] |
OlderNewer