@Test public void testGetsStacks() throws Exception { Collection<StackInfo> stacks = stackManager.getStacks(); assertEquals(20, stacks.size()); }
public Collection<StackInfo> getStacks(String name) { Collection<StackInfo> stacks = new HashSet<StackInfo>(); for (StackInfo stack: stackMap.values()) { if (stack.getName().equals(name)) { stacks.add(stack); } } return stacks; }
StackManager { public Collection<StackInfo> getStacks(String name) { Collection<StackInfo> stacks = new HashSet<StackInfo>(); for (StackInfo stack: stackMap.values()) { if (stack.getName().equals(name)) { stacks.add(stack); } } return stacks; } }
StackManager { public Collection<StackInfo> getStacks(String name) { Collection<StackInfo> stacks = new HashSet<StackInfo>(); for (StackInfo stack: stackMap.values()) { if (stack.getName().equals(name)) { stacks.add(stack); } } return stacks; } @AssistedInject  StackManager(@Assisted("stackRoot") File stackRoot,
      @Assisted("commonServicesRoot") @Nullable File commonServicesRoot,
      @Assisted("extensionRoot") @Nullable File extensionRoot,
      @Assisted OsFamily osFamily, @Assisted boolean validate,
      MetainfoDAO metaInfoDAO, ActionMetadata actionMetadata, StackDAO stackDao,
      ExtensionDAO extensionDao, ExtensionLinkDAO linkDao); }
StackManager { public Collection<StackInfo> getStacks(String name) { Collection<StackInfo> stacks = new HashSet<StackInfo>(); for (StackInfo stack: stackMap.values()) { if (stack.getName().equals(name)) { stacks.add(stack); } } return stacks; } @AssistedInject  StackManager(@Assisted("stackRoot") File stackRoot,
      @Assisted("commonServicesRoot") @Nullable File commonServicesRoot,
      @Assisted("extensionRoot") @Nullable File extensionRoot,
      @Assisted OsFamily osFamily, @Assisted boolean validate,
      MetainfoDAO metaInfoDAO, ActionMetadata actionMetadata, StackDAO stackDao,
      ExtensionDAO extensionDao, ExtensionLinkDAO linkDao); StackInfo getStack(String name, String version); Collection<StackInfo> getStacks(String name); Collection<StackInfo> getStacks(); ExtensionInfo getExtension(String name, String version); Collection<ExtensionInfo> getExtensions(String name); Collection<ExtensionInfo> getExtensions(); boolean haveAllRepoUrlsBeenResolved(); static Validator getPropertySchemaValidator(); static void validateAllPropertyXmlsInFolderRecursively(File stackRoot, Validator validator); void linkStackToExtension(StackInfo stack, ExtensionInfo extension); void unlinkStackAndExtension(StackInfo stack, ExtensionInfo extension); }
StackManager { public Collection<StackInfo> getStacks(String name) { Collection<StackInfo> stacks = new HashSet<StackInfo>(); for (StackInfo stack: stackMap.values()) { if (stack.getName().equals(name)) { stacks.add(stack); } } return stacks; } @AssistedInject  StackManager(@Assisted("stackRoot") File stackRoot,
      @Assisted("commonServicesRoot") @Nullable File commonServicesRoot,
      @Assisted("extensionRoot") @Nullable File extensionRoot,
      @Assisted OsFamily osFamily, @Assisted boolean validate,
      MetainfoDAO metaInfoDAO, ActionMetadata actionMetadata, StackDAO stackDao,
      ExtensionDAO extensionDao, ExtensionLinkDAO linkDao); StackInfo getStack(String name, String version); Collection<StackInfo> getStacks(String name); Collection<StackInfo> getStacks(); ExtensionInfo getExtension(String name, String version); Collection<ExtensionInfo> getExtensions(String name); Collection<ExtensionInfo> getExtensions(); boolean haveAllRepoUrlsBeenResolved(); static Validator getPropertySchemaValidator(); static void validateAllPropertyXmlsInFolderRecursively(File stackRoot, Validator validator); void linkStackToExtension(StackInfo stack, ExtensionInfo extension); void unlinkStackAndExtension(StackInfo stack, ExtensionInfo extension); static final String PROPERTY_SCHEMA_PATH; static String PATH_DELIMITER; static final String COMMON_SERVICES; static final String EXTENSIONS; static final String METAINFO_FILE_NAME; }