All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.airepublic.http.common.pathmatcher.TemplatePathMatchComparator Maven / Gradle / Ivy

package com.airepublic.http.common.pathmatcher;

import java.util.Comparator;

/**
 * This Comparator implementation is thread-safe so only create a single instance.
 */
public class TemplatePathMatchComparator implements Comparator> {

    @Override
    public int compare(final TemplatePathMatch tpm1, final TemplatePathMatch tpm2) {
        return tpm1.getUriTemplate().getNormalizedPath().compareTo(tpm2.getUriTemplate().getNormalizedPath());
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy