More implementation for issue #46
Merge pull request #91 from jpav/master

More implementation for issue #46