Skip to content

Commit

Permalink
Checkstyle
Browse files Browse the repository at this point in the history
  • Loading branch information
craigtaverner authored and burqen committed Jun 28, 2018
1 parent c8a99c4 commit 0cac8fb
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
Expand Up @@ -197,7 +197,7 @@ static class PartAccessor extends NativeSchemaIndexAccessor<SpatialSchemaKey, Na
IndexSamplingConfig samplingConfig, IndexSamplingConfig samplingConfig,
SpaceFillingCurveConfiguration searchConfiguration ) throws IOException SpaceFillingCurveConfiguration searchConfiguration ) throws IOException
{ {
super( pageCache, fs, fileLayout.spatialFile.indexFile, fileLayout.layout, recoveryCleanupWorkCollector, monitor, descriptor, indexId, samplingConfig ); super( pageCache, fs, fileLayout.getIndexFile(), fileLayout.layout, recoveryCleanupWorkCollector, monitor, descriptor, indexId, samplingConfig );
this.layout = fileLayout.layout; this.layout = fileLayout.layout;
this.descriptor = descriptor; this.descriptor = descriptor;
this.samplingConfig = samplingConfig; this.samplingConfig = samplingConfig;
Expand Down Expand Up @@ -248,16 +248,16 @@ static class PartFactory implements Factory<PartAccessor>
@Override @Override
public PartAccessor newSpatial( CoordinateReferenceSystem crs ) throws IOException public PartAccessor newSpatial( CoordinateReferenceSystem crs ) throws IOException
{ {
SpatialIndexFiles.SpatialFile indexFile = spatialIndexFiles.forCrs( crs ); SpatialIndexFiles.SpatialFile spatialFile = spatialIndexFiles.forCrs( crs );
if ( !fs.fileExists( indexFile.indexFile ) ) if ( !fs.fileExists( spatialFile.indexFile ) )
{ {
SpatialIndexFiles.SpatialFileLayout fileLayout = indexFile.getLayoutForNewIndex(); SpatialIndexFiles.SpatialFileLayout fileLayout = spatialFile.getLayoutForNewIndex();
createEmptyIndex( fileLayout ); createEmptyIndex( fileLayout );
return createPartAccessor( fileLayout ); return createPartAccessor( fileLayout );
} }
else else
{ {
return createPartAccessor( indexFile.getLayoutForExistingIndex( pageCache ) ); return createPartAccessor( spatialFile.getLayoutForExistingIndex( pageCache ) );
} }
} }


Expand Down
Expand Up @@ -133,5 +133,10 @@ static class SpatialFileLayout
this.settings = settings; this.settings = settings;
this.layout = new SpatialLayout( spatialFile.crs, settings.curve() ); this.layout = new SpatialLayout( spatialFile.crs, settings.curve() );
} }

public File getIndexFile()
{
return spatialFile.indexFile;
}
} }
} }
Expand Up @@ -157,7 +157,7 @@ static class PartPopulator extends NativeSchemaIndexPopulator<SpatialSchemaKey,
IndexProvider.Monitor monitor, SchemaIndexDescriptor descriptor, long indexId, IndexSamplingConfig samplingConfig, IndexProvider.Monitor monitor, SchemaIndexDescriptor descriptor, long indexId, IndexSamplingConfig samplingConfig,
SpaceFillingCurveConfiguration configuration ) SpaceFillingCurveConfiguration configuration )
{ {
super( pageCache, fs, fileLayout.spatialFile.indexFile, fileLayout.layout, monitor, descriptor, indexId, samplingConfig ); super( pageCache, fs, fileLayout.getIndexFile(), fileLayout.layout, monitor, descriptor, indexId, samplingConfig );
this.configuration = configuration; this.configuration = configuration;
this.settings = fileLayout.settings; this.settings = fileLayout.settings;
} }
Expand Down

0 comments on commit 0cac8fb

Please sign in to comment.