coding style & phpdoc fixes
phpdoc
extracted getType
moved to kernel, renamed to App
typehint fix
uses App
simplified randomizer
better regexp
increased key usage
uses App instead old Moss