org.apache.ivy.core.sort

Class CollectionOfModulesToSort

class CollectionOfModulesToSort extends Object

Wrap a collection of descriptores wrapped themself in ModuleInSort elements. It contains some dedicated function to retrieve module descriptors based on dependencies descriptors.
This class is designed to be used internally by the ModuleDescriptorSorter.
Constructor Summary
CollectionOfModulesToSort(Collection modulesToSort, VersionMatcher matcher, NonMatchingVersionReporter nonMatchingVersionReporter)
Method Summary
ModuleInSortgetModuleDescriptorDependency(DependencyDescriptor descriptor)
Find a matching module descriptor in the list of module to sort.
Iteratoriterator()
intsize()

Constructor Detail

CollectionOfModulesToSort

public CollectionOfModulesToSort(Collection modulesToSort, VersionMatcher matcher, NonMatchingVersionReporter nonMatchingVersionReporter)

Parameters: modulesToSort The collection of ModuleDescriptor to sort matcher The matcher to used to check if dependencyDescriptor match a module in this collection nonMatchingVersionReporter

Method Detail

getModuleDescriptorDependency

public ModuleInSort getModuleDescriptorDependency(DependencyDescriptor descriptor)
Find a matching module descriptor in the list of module to sort.

Parameters: descriptor

Returns: a ModuleDescriptor from the collection of module descriptors to sort. If none exists returns null.

iterator

public Iterator iterator()

size

public int size()