refactor for psr-0 standard and add phpunit test
fix compression and a little refactor
separate get node and get var