@Override
  public CatalogBuilder makeCatalog(String match, String reqPath, URI catURI) throws IOException {
    StateGrib localState = (StateGrib) checkState();
    if (localState == null) return null; // not ready yet maybe
    if (localState.gribCollection == null) return null; // not ready yet maybe

    try {

      // case 0
      if ((match == null) || (match.length() == 0)) {
        return makeCatalogTop(catURI, localState);  // top catalog : uses state.top previously made in checkState()
      }

      // case 1
      if (localState.gribCollection instanceof PartitionCollectionImmutable) {
        String[] paths = match.split("/");
        PartitionCollectionImmutable pc = (PartitionCollectionImmutable) localState.gribCollection;
        return makeCatalogFromPartition(pc, paths, 0, catURI);
      }

    } catch (Exception e) {
      e.printStackTrace();
      logger.error("Error making catalog for " + configPath, e);
    }

    return null;
  }
@Override
  public CatalogBuilder makeCatalog(String match, String reqPath, URI catURI) throws IOException {
    StateGrib localState = (StateGrib) checkState();
    if (localState == null) return null; 
    if (localState.gribCollection == null) return null; 

    try {

      
      if ((match == null) || (match.length() == 0)) {
        return makeCatalogTop(catURI, localState);  
      }

      
      if (localState.gribCollection instanceof PartitionCollectionImmutable) {
        String[] paths = match.split("/");
        PartitionCollectionImmutable pc = (PartitionCollectionImmutable) localState.gribCollection;
        return makeCatalogFromPartition(pc, paths, 0, catURI);
      }

    } catch (Exception e) {
      e.printStackTrace();
      logger.error("Error making catalog for " + configPath, e);
    }

    return null;
  }
@ Override public CatalogBuilder makeCatalog ( String match , String reqPath , URI catURI ) throws IOException { StateGrib localState = ( StateGrib ) checkState ( ) ; if ( localState == null ) return null ; // not ready yet maybe if ( localState . gribCollection == null ) return null ; // not ready yet maybe try { // case 0 if ( ( match == null ) || ( match . length ( ) == 0 ) ) { return makeCatalogTop ( catURI , localState ) ; // top catalog : uses state.top previously made in checkState() } // case 1 if ( localState . gribCollection instanceof PartitionCollectionImmutable ) { String [ ] paths = match . split ( "/" ) ; PartitionCollectionImmutable pc = ( PartitionCollectionImmutable ) localState . gribCollection ; return makeCatalogFromPartition ( pc , paths , 0 , catURI ) ; } } catch ( Exception e ) { e . printStackTrace ( ) ; logger . error ( "Error making catalog for " + configPath , e ) ; } return null ; }
see top javadoc for possible URLs
see top javadoc for possible URLs