10. April 2015

PHP’s traits vs. ruby’s modules: Battle of the mix-ins

A mixin is a class-like language construct meant to add functionality to another class. They are not meant to stand on their own, and generally speaking they cannot. Mixins can be used to give different classes the same interface. Mixins can be compared to multiple inheritence in what they let you accomplish, but they don’t work the same way. Rather than inheriting from multiple classes, you mix them in. (Hence the obvious name.)

more

14. February 2015

A Whitespace + Punctuation Tokenizer

In my previous post, I discussed some tokenization techniques and mentioned that a whitespace-only tokenizer will make tokens that are sub-optimal for indexing. I also mentioned that a simple solution to this is created a whitespace + punctuation tokenizer.

more

14. February 2015

Android Game Development

Wanting to expand my horizons a little, I decided to give android game development a try. I quickly prototyped a game in canvas + js called protect your thing to give myself an idea of how it would work on the android platform. This was a natural prototyping choice for me because I’ve been working with JS code daily for at least a decade now, and I love playing with canvas. (I frequently will whip up a little graphic in canvas reminiscent of my early QBasic coding days, but flavoured by the years of studying mathematics that followed).

more

31. January 2015

Basic Concepts of a Search Index

Introduction

A text index is a way to store information about textual data to improve ease of retrieval. The basic idea is to store the information in such a way that it is possible to retrieve what you are looking for without doing a full scan of the data. A text index will do this by storing information about each indexed word separately. So where in the raw text you might have a text field with the contents “this is a description”, a full text index would store information about each individual word separately, so it would store a form of “this”, “is”, “a”, and “description”.

more

05. September 2014

Canvas Spinny

This will make a nice semi transparent spinner for you.

more