// We can now construct the baseURL from this string.
File file2Parse = new File(new StringBuffer(base).append(".wld")
.toString());
if (file2Parse.exists()) {
final WorldFileReader reader = new WorldFileReader(file2Parse);
raster2Model = reader.getTransform();
} else {
// looking for another extension
final Set<String> ext=WorldImageFormat.getWorldExtension(extension);
final Iterator<String> it=ext.iterator();
if(!it.hasNext())
throw new DataSourceException("Unable to parse extension "+extension);
do{
file2Parse = new File(new StringBuffer(base).append((String)it.next()
).toString());
}while(!file2Parse.exists()&&it.hasNext());
if (file2Parse.exists()) {
// parse world file
final WorldFileReader reader = new WorldFileReader(file2Parse);
raster2Model = reader.getTransform();
metaFile = false;
} else {
// looking for a meta file
file2Parse = new File(new StringBuffer(base).append(".meta")
.toString());