Also please add some unit test for this method.