| Home >> All >> org >> springframework >> core >> [ io Javadoc ] |
| | org.springframework.core.io.support.* (3) |
org.springframework.core.io: Javadoc index of package org.springframework.core.io.
Package Samples:
org.springframework.core.io.support: Generic abstraction for (file-based) resources, used throughout the framework.
Classes:
PathMatchingResourcePatternResolver: ResourcePatternResolver implementation that applies Ant-style path matching, using Spring's PathMatcher class. Locations can either be suitable for ResourceLoader.getResource (URLs like "file:C:/context.xml", pseudo-URLs like "classpath:/context.xml", relative file paths like "/WEB-INF/context.xml"), or Ant-style patterns like "/WEB-INF/*-context.xml". In the pattern case, the location has to be resolvable to java.io.File or to a "jar:" URL (leading to a java.net.JarURLConnection ) to allow for searching though the specified directory tree. In particular, this is not guaranteed to work with a WAR ...
ResourcePatternResolver: Strategy interface for resolving a location pattern (for example, an Ant-style path pattern) into Resource objects. This is an extension to the base ResourceLoader interface. A passed-in ResourceLoader (for example, an ApplicationContext passed in via ResourceLoaderAware when running in a context) can be checked whether it implements this extended interface too. Can be used with any sort of location pattern (e.g. "/WEB-INF/*-context.xml"): Input patterns have to match the strategy implementation. This interface just specifies the conversion method rather than a specific pattern format. This interface ...
ResourceLoader: Interface to be implemented by objects that can load resources. An ApplicationContext is required to provide this functionality, plus extended ResourcePatternResolver support. DefaultResourceLoader is a standalone implementation that is usable outside an ApplicationContext, also used by ResourceEditor. Bean properties of type Resource and Resource array can be populated from Strings when running in an ApplicationContext, using the particular context's resource loading strategy.
InputStreamResource: Resource implementation for a given InputStream. Should only be used if no specific Resource implementation is applicable. In contrast to other Resource implementations, this is a descriptor for an already opened resource - therefore returning true on isOpen(). Do not use it if you need to keep the resource descriptor somewhere, or if you need to read a stream multiple times.
ResourceEditor: 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 system properties: e.g. ${user.dir}. Delegates to a ResourceLoader, by default a DefaultResourceLoader.
ResourceArrayPropertyEditor: Editor for Resource descriptor arrays, to automatically convert String location patterns (e.g. "file:C:/my*.txt" or "classpath*:myfile.txt") to Resource array properties. The path may contain ${...} placeholders, to be resolved as system properties: e.g. ${user.dir}. Delegates to a ResourcePatternResolver, by default a PathMatchingResourcePatternResolver.
ClassPathResource: Resource implementation for class path resources. Uses either the thread context class loader, a given ClassLoader or a given Class for loading resources. Supports resolution as java.io.File if the class path resource resides in the file system, but not for resources in a JAR. Always supports resolution as URL.
Resource: Interface for a resource descriptor that abstracts from the actual type of resource, like file or class path resource. An InputStream can be opened for every resource if it exists in physical form, but a URL or File handle can just be returned for certain resources. The actual behavior is implementation-specific.
FileSystemResourceLoader: ResourceLoader implementation that resolves paths as file system resources rather than as class path resources (DefaultResourceLoader's strategy). FileSystemXmlApplicationContext is a full-fledged ApplicationContext implementation that provides the same resource path resolution strategy.
AbstractResource: Convenience base class for Resource implementations, pre-implementing typical behavior. The "exists" method will check whether a File or InputStream can be opened; "isOpen" will always return false; "getURL" and "getFile" throw an exception; and "toString" will return the description.
DefaultResourceLoader: Default implementation of the ResourceLoader interface. Used by ResourceEditor, but also suitable for standalone usage. Will return an UrlResource if the location value is a URL, and a ClassPathResource if it is a non-URL path or a "classpath:" pseudo-URL.
AbstractPathResolvingPropertyEditor: Abstract base class for PropertyEditors that need to resolve placeholders in paths. A path may contain ${...} placeholders, to be resolved as system properties: e.g. ${user.dir}.
UrlResource: Resource implementation for java.net.URL locators. Obviously supports resolution as URL, and also as File in case of the "file:" protocol.
InputStreamSource: Simple interface for objects that are sources for java.io.InputStreams. Base interface for Spring's Resource interface.
FileSystemResource: Resource implementation for java.io.File handles. Obviously supports resolution as File, and also as URL.
| Home | Contact Us | Privacy Policy | Terms of Service |