Class ResourceEditor

java.lang.Object
java.beans.PropertyEditorSupport
org.springframework.core.io.ResourceEditor
All Implemented Interfaces:
PropertyEditor

public class ResourceEditor extends PropertyEditorSupport
Editor for Resource descriptors, to automatically convert String locations e.g. file:C:/myfile.txt or classpath:myfile.txt to Resource properties instead of using a String location property.

The path may contain ${...} placeholders, to be resolved as Environment properties: e.g. ${user.dir}. Unresolvable placeholders are ignored by default.

Delegates to a ResourceLoader to do the heavy lifting, by default using a DefaultResourceLoader.

Since:
28.12.2003
Author:
Juergen Hoeller, Dave Syer, Chris Beams
See Also: