Method toFiles implementation
merge