replace predicate fn with case statement.
Merge branch 'master' of github.com:edgenet/hydra
Merge pull request #32 from mknoszlig/master

Problem: ensure state predicate fn is not well-suited for multi dispatch depending on state