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
trait Similarity { | |
def isSimilar(x: Any): Boolean | |
def isNotSimilar(x: Any): Boolean = !isSimilar(x) | |
} | |
class TestClass(val member: Boolean) extends Similarity { | |
// method implementation with cast | |
def isSimilar(x: Any) = { x.asInstanceOf[TestClass].member == member } | |
} |
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
#!/usr/bin/env ruby | |
require 'rubygems' | |
require 'rexml/document' | |
require 'trollop' | |
@options = Trollop::options do | |
version "parseitems.rb 0.1 (c) 2010 Sven Pfleiderer" | |
banner <<-EOS | |
This is a simple, script which takes an xml file with items and generates a wiki table with the given content |
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
# init | |
git init | |
# add files | |
git add . | |
# commit files | |
git commit -m 'add file' | |
# create branch and check it out |
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
http://julien51.github.com/socket-sub/maps | |
http://saber-tooth-moose-lion.no.de/ | |
http://rallarpojken.no.de/ | |
http://rumpetroll.com/ |
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 Db = require('mongodb').Db, | |
Connection = require('mongodb').Connection, | |
Server = require('mongodb').Server, | |
GridStore = require('mongodb').GridStore, | |
Step = require('step'), | |
Sys = require('sys'), | |
Fs = require('fs'); | |
var database; |
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
\documentclass[11pt,titlepage,a4paper,english]{article} | |
\usepackage[onehalfspacing]{setspace} | |
\usepackage[utf8]{inputenc} | |
\usepackage{babel} | |
\usepackage{underscore} | |
\usepackage{caption} | |
\usepackage{listings} | |
\usepackage{amsfonts} | |
\usepackage{amssymb} | |
\usepackage{graphicx} |
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
require 'rubygems' | |
require 'socket' | |
include Socket::Constants | |
class ChatServer | |
def initialize | |
@reading = Array.new | |
@writing = Array.new | |
@clients = Hash.new |
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
<?xml version="1.0" ?><manifest android:versionCode="1" android:versionName="1" package="com.mwaysolutions.barcodeexample" xmlns:android="http://schemas.android.com/apk/res/android"> | |
<uses-sdk android:minSdkVersion="4"/> | |
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:smallScreens="true"/> | |
<!-- TI_MANIFEST --> | |
<application android:debuggable="false" android:icon="@drawable/appicon" android:label="Barcode Example" android:name="BarcodeExampleApplication"> | |
<activity android:configChanges="keyboardHidden|orientation" android:label="Barcode Example" android:name=".BarcodeExampleActivity" android:theme="@style/Theme.Titanium"> | |
<intent-filter> | |
<action android:name="android.intent.action.MAIN"/> |
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
" Map Command-# to switch tabs | |
map <D-0> 0gt | |
imap <D-0> <Esc>0gt | |
map <D-1> 1gt | |
imap <D-1> <Esc>1gt | |
map <D-2> 2gt | |
imap <D-2> <Esc>2gt | |
map <D-3> 3gt | |
imap <D-3> <Esc>3gt | |
map <D-4> 4gt |
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 http = require("http"); | |
var TIMEOUT_VALUE = 2020; | |
var options = { | |
host: 'localhost', | |
port: 3000, | |
path: '/', | |
method: 'GET' | |
}; |
OlderNewer