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
class EnhancedVertex { | |
static void setOrRemoveProperty(final Vertex self, final String property, final def value) { | |
if (value == null) self.removeProperty(property) else self.setProperty(property, value) | |
} | |
} | |
g = TinkerGraphFactory.createTinkerGraph() | |
use (EnhancedVertex) { | |
marko = g.v(1) |
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
#! /bin/bash | |
# | |
# overview -- searches through all Java, Python, and Scala files in the current | |
# directory and all subdirectories and lists some basic stats about | |
# each file | |
if [ "$1" == "--help" ] | |
then | |
cat <<-HERE >&2 | |
usage: overview [--help] |
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
package com.timjstewart | |
import scala.concurrent._ | |
import rx.lang.scala._ | |
object Main extends App { | |
override def main(args: Array[String]): Unit = { | |
def observable(n: Int) = Observable[Int] { |