Feature-complete implementation

Implementation remains untested

Signed-off-by: Marcel Oomens <Marcel.Oomens@cromido.org>