DataSourceResolver classPathResolver = new DataSourceClassPathResolver("/images", false);
DataSourceResolver[] dataSourceResolvers = new DataSourceResolver[] { urlResolver, classPathResolver };
DataSourceResolver dataSourceResolver = new DataSourceCompositeResolver(dataSourceResolvers, true);
// resolve using HTTP
assertTrue(toByteArray(dataSourceResolver.resolve("/images/feather-small.gif")).length > 0);
// resolve using class path
assertTrue(toByteArray(dataSourceResolver.resolve("/contentTypeTest.gif")).length > 0);
}