@Test public void getDescriptors() { Set<IMacroDescriptor> descriptors = macroFactory.getDescriptors(); assertEquals(Sets.newHashSet(descriptor, groovyDescriptor), descriptors); }
public Set<IMacroDescriptor> getDescriptors() { waitForRunning(); Function<IMacro, IMacroDescriptor> function = new Function<IMacro, IMacroDescriptor>() { @Override public IMacroDescriptor apply(IMacro macro) { return macro.getDescriptor(); } }; return Sets.newHashSet(Collections2.transform(macros.values(), function)); }
MacroFactory implements Lifecycle { public Set<IMacroDescriptor> getDescriptors() { waitForRunning(); Function<IMacro, IMacroDescriptor> function = new Function<IMacro, IMacroDescriptor>() { @Override public IMacroDescriptor apply(IMacro macro) { return macro.getDescriptor(); } }; return Sets.newHashSet(Collections2.transform(macros.values(), function)); } }
MacroFactory implements Lifecycle { public Set<IMacroDescriptor> getDescriptors() { waitForRunning(); Function<IMacro, IMacroDescriptor> function = new Function<IMacro, IMacroDescriptor>() { @Override public IMacroDescriptor apply(IMacro macro) { return macro.getDescriptor(); } }; return Sets.newHashSet(Collections2.transform(macros.values(), function)); }  }
MacroFactory implements Lifecycle { public Set<IMacroDescriptor> getDescriptors() { waitForRunning(); Function<IMacro, IMacroDescriptor> function = new Function<IMacro, IMacroDescriptor>() { @Override public IMacroDescriptor apply(IMacro macro) { return macro.getDescriptor(); } }; return Sets.newHashSet(Collections2.transform(macros.values(), function)); }  @Override void start(); @Override void stop(); @Override boolean isRunning(); IMacro get(String macroName); Set<IMacroDescriptor> getDescriptors(); List<String> listGroovyMacros(); String getGroovyMacroCode(String name); List<CompilationMessage> verifyGroovyMacro(String code); void saveGroovyMacro(String name, String code); void deleteGroovyMacro(String name); Object getData(String macroName, String request, Map<String, String[]> parameterMap, Authentication authentication); }
MacroFactory implements Lifecycle { public Set<IMacroDescriptor> getDescriptors() { waitForRunning(); Function<IMacro, IMacroDescriptor> function = new Function<IMacro, IMacroDescriptor>() { @Override public IMacroDescriptor apply(IMacro macro) { return macro.getDescriptor(); } }; return Sets.newHashSet(Collections2.transform(macros.values(), function)); }  @Override void start(); @Override void stop(); @Override boolean isRunning(); IMacro get(String macroName); Set<IMacroDescriptor> getDescriptors(); List<String> listGroovyMacros(); String getGroovyMacroCode(String name); List<CompilationMessage> verifyGroovyMacro(String code); void saveGroovyMacro(String name, String code); void deleteGroovyMacro(String name); Object getData(String macroName, String request, Map<String, String[]> parameterMap, Authentication authentication);  }