Added file with license information.
Some minor fixes, code cleanup, style and phpdoc changes.
Added composer.json file.