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 acceptance.giraffe.indexing; | |
import java.io.File; | |
import org.elasticsearch.action.admin.indices.create.CreateIndexRequest; | |
import org.elasticsearch.action.admin.indices.create.CreateIndexResponse; | |
import org.elasticsearch.action.search.SearchResponse; | |
import org.elasticsearch.action.search.SearchType; | |
import org.elasticsearch.client.Client; | |
import org.elasticsearch.cluster.metadata.IndexMetaData; |
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 acceptance.giraffe.indexing; | |
import java.util.SortedMap; | |
import java.util.TreeMap; | |
import org.junit.rules.MethodRule; | |
import org.junit.runners.model.FrameworkMethod; | |
import org.junit.runners.model.Statement; | |
public class Repeat implements MethodRule { |
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
import java.util.Comparator; | |
public class GenericsHell { | |
public static void compareSomeNumbers(Comparator<Integer> numberComparison) { | |
// ... elided ... | |
} | |
public static <T> Comparator<T> arbitraryOrder() { | |
return new Comparator<T>() { | |
@Override |
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
function setup() | |
seed = 1 | |
end | |
function draw() | |
background(136, 207, 224, 255) | |
noStroke() | |
fill(61, 109, 31, 255) | |
rect(0, 0, WIDTH, 128) |
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
function ZXMonospace() | |
return BitmapFont { | |
height = 8, | |
charSpacing = 0, | |
lineSpacing = 0, | |
["!"] = { | |
" ", | |
" X ", |
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
function ZXProportional() | |
return BitmapFont { | |
height = 8, | |
charSpacing = 1, | |
lineSpacing = 0, | |
["!"] = { | |
" ", | |
"X", |
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
|Key Press: | |
Playback |PAUSE |PLAY |FFWD |REW |STOP | |
----------+------+-------+--------+--------+------------ | |
paused |paused|fwd x 1|fwd x 2 |rew x 1 |show live tv | |
fwd x 1 |paused|fwd x 1|fwd x 2 |rew x 1 |show live tv | |
fwd x 2 |paused|fwd x 1|fwd x 6 |rew x 1 |show live tv | |
fwd x 6 |paused|fwd x 1|fwd x 12|rew x 1 |show live tv | |
fwd x 12 |paused|fwd x 1|fwd x 30|rew x 1 |show live tv | |
fwd x 30 |paused|fwd x 1|fwd x 30|rew x 1 |show live tv | |
rew x 1 |paused|fwd x 1|fwd x 2 |rew x 2 |show live tv |
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
def dicts(d): | |
keys, value_iters = zip(*d.items()) | |
return (dict(zip(keys,values)) for values in zip(*value_iters)) | |
def property(test_fn=None, tests=100): | |
def bind_parameters(test_fn): | |
arg_bindings = dicts(test_fn.__annotations__) | |
def bound_test_fn(): | |
for args in itertools.islice(arg_bindings, tests): |
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
@article{Deignan2005, | |
abstract = {With the benefit of hindsight, it is now possible to see that one of the most important themes in the study of language to emerge in the 20 th century was developed, not by linguists, but primarily by philosophers of language such as Wittgenstein and Grice and anthropologists such as Malinowski and Rosch. This theme involves, among other things, rejection of sharply defined category boundaries and adoption instead of systems of categories built by analogy around prototypes. Central and typical examples of linguistic categories are usually easy to identify, but boundaries between categories are fuzzy grey areas on a cline, rather than sharp divisions. Metaphor is the most prototypical example of linguistic analogy, so a corpus-based study of metaphor will be a theme of central interest. In the linguistic paradigm shift just mentioned, Aristotelian-Leibnizian theories of meaning requiring the satisfaction of necessary and sufficient conditions were rejected. Instead, meaning in |
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
private static class NoisyThreadingPolicy implements ThreadingPolicy | |
{ | |
private final Thread testThread = Thread.currentThread(); | |
@Override public Invokable synchroniseAccessTo(final Invokable mockObject) | |
{ | |
final StackTraceElement[] creationStack = stackTrace(); | |
return new Invokable() | |
{ |