Class DefaultModuleDescriptorOrderingsFactory
java.lang.Object
com.atlassian.jira.plugin.util.orderings.DefaultModuleDescriptorOrderingsFactory
- All Implemented Interfaces:
ModuleDescriptors.Orderings
public class DefaultModuleDescriptorOrderingsFactory
extends Object
implements ModuleDescriptors.Orderings
- Since:
- v4.4
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultModuleDescriptorOrderingsFactory
(com.atlassian.plugin.metadata.PluginMetadataManager pluginMetadataManager) -
Method Summary
Modifier and TypeMethodDescriptioncom.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor>
byOrigin()
Creates an ordering instance that orders module descriptors according to the "origin" of the plugin they come from.com.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor>
natural()
Creates an Ordering instance that orders module descriptors according to their "natural" order.com.google.common.collect.Ordering<com.atlassian.plugin.web.descriptors.WeightedDescriptor>
Creates an Ordering instance that orders weighted module descriptors according to their weight.
-
Constructor Details
-
DefaultModuleDescriptorOrderingsFactory
public DefaultModuleDescriptorOrderingsFactory(com.atlassian.plugin.metadata.PluginMetadataManager pluginMetadataManager)
-
-
Method Details
-
byOrigin
public com.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor> byOrigin()Description copied from interface:ModuleDescriptors.Orderings
Creates an ordering instance that orders module descriptors according to the "origin" of the plugin they come from.- Specified by:
byOrigin
in interfaceModuleDescriptors.Orderings
- Returns:
- An ordering instance that orders module descriptors according to the "origin" of the plugin they come from.
- See Also:
-
natural
public com.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor> natural()Description copied from interface:ModuleDescriptors.Orderings
Creates an Ordering instance that orders module descriptors according to their "natural" order.Natural order is based on the module descriptor's
complete key
- Specified by:
natural
in interfaceModuleDescriptors.Orderings
- Returns:
- An Ordering instance that orders module descriptors according to their "natural" order.
-
weightedDescriptorComparator
public com.google.common.collect.Ordering<com.atlassian.plugin.web.descriptors.WeightedDescriptor> weightedDescriptorComparator()Description copied from interface:ModuleDescriptors.Orderings
Creates an Ordering instance that orders weighted module descriptors according to their weight.- Specified by:
weightedDescriptorComparator
in interfaceModuleDescriptors.Orderings
- Returns:
- An ordering instance that orders module descriptors according to their weight.
- See Also:
-
WeightedDescriptorComparator
-