Class DefaultCommercePriceService.PriceInformationComparator
java.lang.Object
de.hybris.platform.commerceservices.util.AbstractComparator<PriceInformation>
de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService.PriceInformationComparator
- All Implemented Interfaces:
Comparator<PriceInformation>
- Enclosing class:
- DefaultCommercePriceService
public static class DefaultCommercePriceService.PriceInformationComparator
extends AbstractComparator<PriceInformation>
Comparator to naturally order PriceInformation by price value ascending
-
Field Summary
FieldsModifier and TypeFieldDescriptionFields inherited from class de.hybris.platform.commerceservices.util.AbstractComparator
AFTER, BEFORE, EQUAL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected intcompareInstances(PriceInformation price1, PriceInformation price2) Implement method to perform the comparison.Methods inherited from class de.hybris.platform.commerceservices.util.AbstractComparator
compare, compareValues, compareValues, compareValues, compareValues, compareValues, instanceEqualsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
PriceInformationComparator
public PriceInformationComparator()
-
-
Method Details
-
compareInstances
Description copied from class:AbstractComparatorImplement method to perform the comparison. The instances passed are different and neither is null.- Specified by:
compareInstancesin classAbstractComparator<PriceInformation>- Parameters:
price1- first instanceprice2- second instance- Returns:
- return one of
AbstractComparator.BEFORE,AbstractComparator.EQUAL, orAbstractComparator.AFTER.
-