Implemented the refactoring "Create and implement a new interface".

This commit implements a refactoring and one automated test for it.

This commit belongs to issue #20.