added return values code, refactored a bit
fixed predicates, all tests now pass
made methods non global
optimize publish, make it not call children channels
get rid of tableAppend