// featuretyepinfo and layerinfo
DataStore dataStore = (DataStore) store.getDataStore(new NullProgressListener());
String featureTypeName = coverageName != null ? coverageName : storeName;
SimpleFeatureSource featureSource = dataStore.getFeatureSource(featureTypeName);
featureType = builder.buildFeatureType(featureSource);
featureType.setName(layerName);
featureType.setTitle(layerName);
builder.setupBounds(featureType, featureSource);
// dimensions
boolean foundTime = enableDimensions(featureType, coverageName, reader);