In this instance the jarFile is being passed to the factory. It should be the callers responsibility to close that outside of this factory.