Add Strategy Pattern to handleMessage

according to issue #10