Revert "Added trim support"

This reverts commit e6207cc95d6cca472e8fedb2e20185d2049dd0be.
Replaced File instance with FileInterface