java.lang.Object | ||
↳ | java.beans.PropertyEditorSupport | |
↳ | org.springframework.core.io.ResourceEditor |
java.beans.PropertyEditor 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
.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a new instance of the
ResourceEditor class
using a DefaultResourceLoader and DefaultEnvironment . | |||||||||||
This constructor is deprecated.
as of Spring 3.1 in favor of
ResourceEditor(ResourceLoader, PropertyResolver)
| |||||||||||
Create a new instance of the
ResourceEditor class
using the given ResourceLoader and PropertyResolver . | |||||||||||
This constructor is deprecated.
as of Spring 3.1 in favor of
ResourceEditor(ResourceLoader, PropertyResolver, boolean)
| |||||||||||
Create a new instance of the
ResourceEditor class
using the given ResourceLoader . |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Resolve the given path, replacing placeholders with corresponding
property values from the
environment if necessary. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.beans.PropertyEditorSupport
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
java.beans.PropertyEditor
|
Create a new instance of the ResourceEditor
class
using a DefaultResourceLoader
and DefaultEnvironment
.
This constructor is deprecated.
as of Spring 3.1 in favor of
ResourceEditor(ResourceLoader, PropertyResolver)
Create a new instance of the ResourceEditor
class
using the given ResourceLoader
and a DefaultEnvironment
.
resourceLoader | the ResourceLoader to use |
---|
Create a new instance of the ResourceEditor
class
using the given ResourceLoader
and PropertyResolver
.
resourceLoader | the ResourceLoader to use |
---|---|
propertyResolver | the PropertyResolver to use
|
This constructor is deprecated.
as of Spring 3.1 in favor of
ResourceEditor(ResourceLoader, PropertyResolver, boolean)
Create a new instance of the ResourceEditor
class
using the given ResourceLoader
.
resourceLoader | the ResourceLoader to use |
---|---|
ignoreUnresolvablePlaceholders | whether to ignore unresolvable placeholders if no corresponding property could be found |
Create a new instance of the ResourceEditor
class
using the given ResourceLoader
.
resourceLoader | the ResourceLoader to use |
---|---|
propertyResolver | the PropertyResolver to use |
ignoreUnresolvablePlaceholders | whether to ignore unresolvable placeholders
if no corresponding property could be found in the given propertyResolver
|
Resolve the given path, replacing placeholders with corresponding
property values from the environment
if necessary.
path | the original file path |
---|