cdm/src/main/java/ucar/nc2/ft/point/standard/TableAnalyzer.java
static public TableConfigurer getTableConfigurer(FeatureType wantFeatureType, NetcdfDataset ds) throws IOException {
    String convUsed = null;

    // search for the Conventions attribute
    String convName = ds.findAttValueIgnoreCase(null, CDM.CONVENTIONS, null);
    if (convName == null)
      convName = ds.findAttValueIgnoreCase(null, "Convention", null);

    // now search for TableConfigurer using that Convention
    Configurator anal = null;
    if (convName != null) {
      convName = convName.trim();

      // search for Convention parsing class
      anal = matchConfigurator(convName);
      if (anal != null) {
        convUsed = convName;
        if (debug) System.out.println("  TableConfigurer found using convName "+convName);
      }

      // now search for comma or semicolon or / delimited list
      if (anal == null) {
        List<String> names = new ArrayList<>();

        if ((convName.indexOf(',') > 0) || (convName.indexOf(';') > 0)) {
          StringTokenizer stoke = new StringTokenizer(convName, ",;");
          while (stoke.hasMoreTokens()) {
            String name = stoke.nextToken();
            names.add(name.trim());
          }
        } else if ((convName.indexOf('/') > 0)) {
          StringTokenizer stoke = new StringTokenizer(convName, "/");
          while (stoke.hasMoreTokens()) {
            String name = stoke.nextToken();
            names.add(name.trim());
          }
        }

        if (names.size() > 0) {
          // search the registered conventions, in order
          for (Configurator conv : conventionList) {
            for (String name : names) {
              if (name.equalsIgnoreCase(conv.convName)) {
                anal = conv;
                convUsed = name;
                if (debug) System.out.println("  TableConfigurer found using convName "+convName);
              }
            }
            if (anal != null) break;
          }
        }
      }
    }

    // search for ones that dont use Convention attribute, in order added.
    // call method isMine() using reflection.
    if (anal == null) {
      for (Configurator conv : conventionList) {
        Class c = conv.confClass;
        Method isMineMethod;

        try {
          isMineMethod = c.getMethod("isMine", new Class[]{FeatureType.class, NetcdfDataset.class});
        } catch (NoSuchMethodException ex) {
          continue;
        }

        try {
          Boolean result = (Boolean) isMineMethod.invoke(conv.confInstance, wantFeatureType, ds);
          if (debug) System.out.println("  TableConfigurer.isMine "+c.getName()+ " result = " + result);
          if (result) {
            anal = conv;
            convUsed = conv.convName;
            break;
          }
        } catch (Exception ex) {
          System.out.println("ERROR: Class " + c.getName() + " Exception invoking isMine method%n" + ex);
        }
      }
    }

    // Instantiate a new TableConfigurer object
    TableConfigurer tc = null;
    if (anal != null) {
      try {
        tc = (TableConfigurer) anal.confClass.newInstance();
        tc.setConvName( convName);
        tc.setConvUsed( convUsed);
      } catch (InstantiationException | IllegalAccessException e) {
        log.error("TableConfigurer create failed", e);
      }
    }

    return tc;
  }
static public TableConfigurer getTableConfigurer(FeatureType wantFeatureType, NetcdfDataset ds) throws IOException {
    String convUsed = null;

    // search for the Conventions attribute
    String convName = ds.findAttValueIgnoreCase(null, CDM.CONVENTIONS, null);
    if (convName == null)
      convName = ds.findAttValueIgnoreCase(null, "Convention", null);

    // now search for TableConfigurer using that Convention
    Configurator anal = null;
    if (convName != null) {
      convName = convName.trim();

      // search for Convention parsing class
      anal = matchConfigurator(convName);
      if (anal != null) {
        convUsed = convName;
        if (debug) System.out.println("  TableConfigurer found using convName "+convName);
      }

      // now search for comma or semicolon or / delimited list
      if (anal == null) {
        List<String> names = new ArrayList<>();

        if ((convName.indexOf(',') > 0) || (convName.indexOf(';') > 0)) {
          StringTokenizer stoke = new StringTokenizer(convName, ",;");
          while (stoke.hasMoreTokens()) {
            String name = stoke.nextToken();
            names.add(name.trim());
          }
        } else if ((convName.indexOf('/') > 0)) {
          StringTokenizer stoke = new StringTokenizer(convName, "/");
          while (stoke.hasMoreTokens()) {
            String name = stoke.nextToken();
            names.add(name.trim());
          }
        }

        if (names.size() > 0) {
          // search the registered conventions, in order
          for (Configurator conv : conventionList) {
            for (String name : names) {
              if (name.equalsIgnoreCase(conv.convName)) {
                anal = conv;
                convUsed = name;
                if (debug) System.out.println("  TableConfigurer found using convName "+convName);
              }
            }
            if (anal != null) break;
          }
        }
      }
    }

    // search for ones that dont use Convention attribute, in order added.
    // call method isMine() using reflection.
    if (anal == null) {
      for (Configurator conv : conventionList) {
        Class c = conv.confClass;
        Method isMineMethod;

        try {
          isMineMethod = c.getMethod("isMine", new Class[]{FeatureType.class, NetcdfDataset.class});
        } catch (NoSuchMethodException ex) {
          continue;
        }

        try {
          Boolean result = (Boolean) isMineMethod.invoke(conv.confInstance, wantFeatureType, ds);
          if (debug) System.out.println("  TableConfigurer.isMine "+c.getName()+ " result = " + result);
          if (result) {
            anal = conv;
            convUsed = conv.convName;
            break;
          }
        } catch (Exception ex) {
          System.out.println("ERROR: Class " + c.getName() + " Exception invoking isMine method%n" + ex);
        }
      }
    }

    // Instantiate a new TableConfigurer object
    TableConfigurer tc = null;
    if (anal != null) {
      try {
        tc = (TableConfigurer) anal.confClass.newInstance();
        tc.setConvName( convName);
        tc.setConvUsed( convUsed);
      } catch (InstantiationException | IllegalAccessException e) {
        log.error("TableConfigurer create failed", e);
      }
    }

    return tc;
  }
static public TableConfigurer getTableConfigurer ( FeatureType wantFeatureType , NetcdfDataset ds ) throws IOException { String convUsed = null ; // search for the Conventions attribute
 String convName = ds . findAttValueIgnoreCase ( null , CDM . CONVENTIONS , null ) ; if ( convName == null ) convName = ds . findAttValueIgnoreCase ( null , "Convention" , null ) ; // now search for TableConfigurer using that Convention
 Configurator anal = null ; if ( convName != null ) { convName = convName . trim ( ) ; // search for Convention parsing class
 anal = matchConfigurator ( convName ) ; if ( anal != null ) { convUsed = convName ; if ( debug ) System . out . println ( "  TableConfigurer found using convName " + convName ) ; } // now search for comma or semicolon or / delimited list
 if ( anal == null ) { List < String > names = new ArrayList <> ( ) ; if ( ( convName . indexOf ( ' ' ) > 0 ) || ( convName . indexOf ( ' ' ) > 0 ) ) { StringTokenizer stoke = new StringTokenizer ( convName , ",;" ) ; while ( stoke . hasMoreTokens ( ) ) { String name = stoke . nextToken ( ) ; names . add ( name . trim ( ) ) ; } } else if ( ( convName . indexOf ( ' ' ) > 0 ) ) { StringTokenizer stoke = new StringTokenizer ( convName , "/" ) ; while ( stoke . hasMoreTokens ( ) ) { String name = stoke . nextToken ( ) ; names . add ( name . trim ( ) ) ; } } if ( names . size ( ) > 0 ) { // search the registered conventions, in order
 for ( Configurator conv : conventionList ) { for ( String name : names ) { if ( name . equalsIgnoreCase ( conv . convName ) ) { anal = conv ; convUsed = name ; if ( debug ) System . out . println ( "  TableConfigurer found using convName " + convName ) ; } } if ( anal != null ) break ; } } } } // search for ones that dont use Convention attribute, in order added.
 // call method isMine() using reflection.
 if ( anal == null ) { for ( Configurator conv : conventionList ) { Class c = conv . confClass ; Method isMineMethod ; try { isMineMethod = c . getMethod ( "isMine" , new Class [ ] { FeatureType . class , NetcdfDataset . class } ) ; } catch ( NoSuchMethodException ex ) { continue ; } try { Boolean result = ( Boolean ) isMineMethod . invoke ( conv . confInstance , wantFeatureType , ds ) ; if ( debug ) System . out . println ( "  TableConfigurer.isMine " + c . getName ( ) + " result = " + result ) ; if ( result ) { anal = conv ; convUsed = conv . convName ; break ; } } catch ( Exception ex ) { System . out . println ( "ERROR: Class " + c . getName ( ) + " Exception invoking isMine method%n" + ex ) ; } } } // Instantiate a new TableConfigurer object
 TableConfigurer tc = null ; if ( anal != null ) { try { tc = ( TableConfigurer ) anal . confClass . newInstance ( ) ; tc . setConvName ( convName ) ; tc . setConvUsed ( convUsed ) ; } catch ( InstantiationException | IllegalAccessException e ) { log . error ( "TableConfigurer create failed" , e ) ; } } return tc ; }
Find a TableConfigurer for this dataset, if there is one.

@param wantFeatureType want this FeatureType
@param ds for this dataset
@return TableConfigurer or null if not found
@throws IOException on read error
Find a TableConfigurer for this dataset if there is one .