Package com._1c.g5.v8.dt.common
Class Comparators
- java.lang.Object
-
- com._1c.g5.v8.dt.common.Comparators
-
public class Comparators extends Object
Static utility methods pertaining toComparator
instances.
-
-
Field Summary
Fields Modifier and Type Field Description static Comparator<org.eclipse.core.runtime.IConfigurationElement>
ORDER
Returns aComparator
that compareIConfigurationElement
elements using"order"
attribute and ascending order.static Comparator<org.eclipse.core.runtime.IConfigurationElement>
PRIORITY
Returns aComparator
that compareIConfigurationElement
elements using"priority"
attribute and descending order.
-
Constructor Summary
Constructors Constructor Description Comparators()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Comparator<org.eclipse.core.runtime.IConfigurationElement>
configComparator(String attribute, boolean order)
Returns aComparator
that compareIConfigurationElement
elements using specifiedattribute
andorder
.static <T extends org.eclipse.emf.ecore.EObject>
Comparator<T>intFeatureComparator(org.eclipse.emf.ecore.EStructuralFeature feature)
static <T extends org.eclipse.emf.ecore.EObject>
Comparator<T>strFeatureComparator(org.eclipse.emf.ecore.EStructuralFeature feature)
-
-
-
Field Detail
-
PRIORITY
public static Comparator<org.eclipse.core.runtime.IConfigurationElement> PRIORITY
Returns aComparator
that compareIConfigurationElement
elements using"priority"
attribute and descending order.Compared elements MUST to have the
"priority"
attribute containing decimal number.- See Also:
configComparator(String, boolean)
-
ORDER
public static Comparator<org.eclipse.core.runtime.IConfigurationElement> ORDER
Returns aComparator
that compareIConfigurationElement
elements using"order"
attribute and ascending order.Compared elements MUST to have the
"order"
attribute containing decimal number.- See Also:
configComparator(String, boolean)
-
-
Method Detail
-
configComparator
public static Comparator<org.eclipse.core.runtime.IConfigurationElement> configComparator(String attribute, boolean order)
Returns aComparator
that compareIConfigurationElement
elements using specifiedattribute
andorder
.Compared elements MUST to have the specified
attribute
containing decimal number.- Parameters:
attribute
- - attribute of the IConfigurationElement elementorder
- - ascending iftrue
, descending otherwise- Returns:
- the Comparator of the
IConfigurationElement
elements
-
intFeatureComparator
public static <T extends org.eclipse.emf.ecore.EObject> Comparator<T> intFeatureComparator(org.eclipse.emf.ecore.EStructuralFeature feature)
-
strFeatureComparator
public static <T extends org.eclipse.emf.ecore.EObject> Comparator<T> strFeatureComparator(org.eclipse.emf.ecore.EStructuralFeature feature)
-
-