@Test public void testGetNames() { List<String> names = executionConfigurationManager.getNames(); assertTrue( names.contains( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ); assertTrue( names.contains( "Default Configuration" ) ); assertTrue( names.contains( "Spark Configuration" ) ); }
public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ) { return 1; } return o1.compareToIgnoreCase( o2 ); } ); return names; }
RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ) { return 1; } return o1.compareToIgnoreCase( o2 ); } ); return names; } }
RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ) { return 1; } return o1.compareToIgnoreCase( o2 ); } ); return names; } RunConfigurationManager( List<RunConfigurationProvider> runConfigurationProviders ); }
RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ) { return 1; } return o1.compareToIgnoreCase( o2 ); } ); return names; } RunConfigurationManager( List<RunConfigurationProvider> runConfigurationProviders ); @Override List<RunConfiguration> load(); @Override RunConfiguration load( String name ); @Override boolean save( RunConfiguration runConfiguration ); @Override boolean delete( String name ); @Override void deleteAll(); String[] getTypes(); List<String> getNames(); List<String> getNames( String type ); RunConfiguration getRunConfigurationByType( String type ); RunConfigurationExecutor getExecutor( String type ); List<RunConfigurationProvider> getRunConfigurationProviders( String type ); List<RunConfigurationProvider> getRunConfigurationProviders(); RunConfigurationProvider getDefaultRunConfigurationProvider(); void setDefaultRunConfigurationProvider(
    RunConfigurationProvider defaultRunConfigurationProvider ); }
RunConfigurationManager implements RunConfigurationService { public List<String> getNames() { List<String> names = new ArrayList<>(); for ( RunConfigurationProvider runConfigurationProvider : getRunConfigurationProviders() ) { names.addAll( runConfigurationProvider.getNames() ); } Collections.sort( names, ( o1, o2 ) -> { if ( o2.equals( DefaultRunConfigurationProvider.DEFAULT_CONFIG_NAME ) ) { return 1; } return o1.compareToIgnoreCase( o2 ); } ); return names; } RunConfigurationManager( List<RunConfigurationProvider> runConfigurationProviders ); @Override List<RunConfiguration> load(); @Override RunConfiguration load( String name ); @Override boolean save( RunConfiguration runConfiguration ); @Override boolean delete( String name ); @Override void deleteAll(); String[] getTypes(); List<String> getNames(); List<String> getNames( String type ); RunConfiguration getRunConfigurationByType( String type ); RunConfigurationExecutor getExecutor( String type ); List<RunConfigurationProvider> getRunConfigurationProviders( String type ); List<RunConfigurationProvider> getRunConfigurationProviders(); RunConfigurationProvider getDefaultRunConfigurationProvider(); void setDefaultRunConfigurationProvider(
    RunConfigurationProvider defaultRunConfigurationProvider );  }