Move real code to methods which operate on java.io.File only.