类 LastModifiedResourceComparator
- java.lang.Object
- org.springframework.batch.support.LastModifiedResourceComparator
- 所有已实现的接口:
java.util.Comparator<org.springframework.core.io.Resource>
public class LastModifiedResourceComparator extends java.lang.Object implements java.util.Comparator<org.springframework.core.io.Resource>
Comparator to sort resources by the file last modified time.- 作者:
- Dave Syer
构造器概要
构造器 构造器 说明 LastModifiedResourceComparator()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 int
compare(org.springframework.core.io.Resource r1, org.springframework.core.io.Resource r2)
Compare the two resources by last modified time, so that a sorted list of resources will have oldest first.
构造器详细资料
LastModifiedResourceComparator
public LastModifiedResourceComparator()
方法详细资料
compare
public int compare(org.springframework.core.io.Resource r1, org.springframework.core.io.Resource r2)
Compare the two resources by last modified time, so that a sorted list of resources will have oldest first.- 指定者:
compare
在接口中java.util.Comparator<org.springframework.core.io.Resource>
- 抛出:
java.lang.IllegalArgumentException
- if one of the resources doesn't exist or its last modified date cannot be determined- 另请参阅:
Comparator.compare(Object, Object)