Polishing
This commit is contained in:
parent
326154270f
commit
bfa30913fb
|
@ -116,7 +116,6 @@ class GroovyBeanDefinitionReaderTests extends GroovyTestCase {
|
|||
|
||||
def p = appCtx.getBean("person")
|
||||
assertTrue(p instanceof AdvisedPerson)
|
||||
assertNotNull p
|
||||
}
|
||||
|
||||
void testUseSpringNamespaceAsMethod() {
|
||||
|
@ -872,23 +871,26 @@ return appCtx
|
|||
assertEquals "homer", marge.bean3.person
|
||||
assertEquals "lisa", marge.bean3.bean1.person
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
class HolyGrailQuest {
|
||||
void start() { println "lets begin" }
|
||||
}
|
||||
class KnightOfTheRoundTable {
|
||||
String name
|
||||
String leader
|
||||
KnightOfTheRoundTable(String n) {
|
||||
this.name = n
|
||||
}
|
||||
HolyGrailQuest quest
|
||||
|
||||
void embarkOnQuest() {
|
||||
quest.start()
|
||||
}
|
||||
class KnightOfTheRoundTable {
|
||||
String name
|
||||
String leader
|
||||
|
||||
KnightOfTheRoundTable(String n) {
|
||||
this.name = n
|
||||
}
|
||||
|
||||
HolyGrailQuest quest
|
||||
|
||||
void embarkOnQuest() {
|
||||
quest.start()
|
||||
}
|
||||
}
|
||||
|
||||
// simple bean
|
||||
|
@ -898,6 +900,7 @@ class Bean1 {
|
|||
Properties props
|
||||
List children
|
||||
}
|
||||
|
||||
// bean referencing other bean
|
||||
class Bean2 {
|
||||
int age
|
||||
|
@ -908,6 +911,7 @@ class Bean2 {
|
|||
List children
|
||||
Bean1 parent
|
||||
}
|
||||
|
||||
// bean with constructor args
|
||||
class Bean3 {
|
||||
Bean3(String person, Bean1 bean1) {
|
||||
|
@ -918,6 +922,7 @@ class Bean3 {
|
|||
Bean1 bean1
|
||||
int age
|
||||
}
|
||||
|
||||
// bean with factory method
|
||||
class Bean4 {
|
||||
private Bean4() {}
|
||||
|
@ -926,6 +931,7 @@ class Bean4 {
|
|||
}
|
||||
String person
|
||||
}
|
||||
|
||||
// bean with List-valued constructor arg
|
||||
class Bean5 {
|
||||
Bean5(List<Bean1> people) {
|
||||
|
@ -933,6 +939,7 @@ class Bean5 {
|
|||
}
|
||||
List<Bean1> people
|
||||
}
|
||||
|
||||
// bean with Map-valued constructor arg
|
||||
class Bean6 {
|
||||
Bean6(Map<String, Bean1> peopleByName) {
|
||||
|
@ -940,18 +947,21 @@ class Bean6 {
|
|||
}
|
||||
Map<String, Bean1> peopleByName
|
||||
}
|
||||
|
||||
// a factory bean
|
||||
class Bean1Factory {
|
||||
Bean1 newInstance() {
|
||||
return new Bean1()
|
||||
}
|
||||
}
|
||||
class ScopeTest {}
|
||||
|
||||
class ScopeTest {
|
||||
}
|
||||
|
||||
class TestScope implements Scope {
|
||||
|
||||
int instanceCount
|
||||
|
||||
|
||||
public Object remove(String name) {
|
||||
// do nothing
|
||||
}
|
||||
|
@ -966,27 +976,29 @@ class TestScope implements Scope {
|
|||
public Object get(String name, ObjectFactory<?> objectFactory) {
|
||||
instanceCount++
|
||||
objectFactory.getObject()
|
||||
|
||||
}
|
||||
|
||||
public Object resolveContextualObject(String s) {
|
||||
return null; // noop
|
||||
}
|
||||
}
|
||||
|
||||
class BirthdayCardSender {
|
||||
List peopleSentCards = []
|
||||
public void onBirthday(AdvisedPerson person) {
|
||||
peopleSentCards << person
|
||||
}
|
||||
List peopleSentCards = []
|
||||
|
||||
public void onBirthday(AdvisedPerson person) {
|
||||
peopleSentCards << person
|
||||
}
|
||||
}
|
||||
|
||||
@Component(value = "person")
|
||||
public class AdvisedPerson {
|
||||
int age;
|
||||
String name;
|
||||
int age;
|
||||
String name;
|
||||
|
||||
public void birthday() {
|
||||
++age;
|
||||
}
|
||||
public void birthday() {
|
||||
++age;
|
||||
}
|
||||
}
|
||||
|
||||
class SomeClass {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -56,8 +56,7 @@ import java.util.concurrent.locks.ReentrantLock;
|
|||
* @author Phillip Webb
|
||||
* @since 3.2
|
||||
*/
|
||||
public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implements
|
||||
ConcurrentMap<K, V> {
|
||||
public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implements ConcurrentMap<K, V> {
|
||||
|
||||
private static final int DEFAULT_INITIAL_CAPACITY = 16;
|
||||
|
||||
|
@ -82,6 +81,9 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
*/
|
||||
private final float loadFactor;
|
||||
|
||||
/**
|
||||
* The reference type: SOFT or WEAK.
|
||||
*/
|
||||
private final ReferenceType referenceType;
|
||||
|
||||
/**
|
||||
|
@ -99,8 +101,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* Create a new {@code ConcurrentReferenceHashMap} instance.
|
||||
*/
|
||||
public ConcurrentReferenceHashMap() {
|
||||
this(DEFAULT_INITIAL_CAPACITY, DEFAULT_LOAD_FACTOR, DEFAULT_CONCURRENCY_LEVEL,
|
||||
DEFAULT_REFERENCE_TYPE);
|
||||
this(DEFAULT_INITIAL_CAPACITY, DEFAULT_LOAD_FACTOR, DEFAULT_CONCURRENCY_LEVEL, DEFAULT_REFERENCE_TYPE);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -108,8 +109,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* @param initialCapacity the initial capacity of the map
|
||||
*/
|
||||
public ConcurrentReferenceHashMap(int initialCapacity) {
|
||||
this(initialCapacity, DEFAULT_LOAD_FACTOR, DEFAULT_CONCURRENCY_LEVEL,
|
||||
DEFAULT_REFERENCE_TYPE);
|
||||
this(initialCapacity, DEFAULT_LOAD_FACTOR, DEFAULT_CONCURRENCY_LEVEL, DEFAULT_REFERENCE_TYPE);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -119,45 +119,44 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* exceeds this value resize will be attempted
|
||||
*/
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, float loadFactor) {
|
||||
this(initialCapacity, loadFactor, DEFAULT_CONCURRENCY_LEVEL,
|
||||
DEFAULT_REFERENCE_TYPE);
|
||||
this(initialCapacity, loadFactor, DEFAULT_CONCURRENCY_LEVEL, DEFAULT_REFERENCE_TYPE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new {@code ConcurrentReferenceHashMap} instance.
|
||||
* @param initialCapacity the initial capacity of the map
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently write
|
||||
* to the map
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently
|
||||
* write to the map
|
||||
*/
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, int concurrencyLevel) {
|
||||
this(initialCapacity, DEFAULT_LOAD_FACTOR, concurrencyLevel,
|
||||
DEFAULT_REFERENCE_TYPE);
|
||||
this(initialCapacity, DEFAULT_LOAD_FACTOR, concurrencyLevel, DEFAULT_REFERENCE_TYPE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new {@code ConcurrentReferenceHashMap} instance.
|
||||
* @param initialCapacity the initial capacity of the map
|
||||
* @param loadFactor the load factor. When the average number of references per table
|
||||
* exceeds this value resize will be attempted
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently write
|
||||
* to the map
|
||||
* @param loadFactor the load factor. When the average number of references per
|
||||
* table exceeds this value, resize will be attempted.
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently
|
||||
* write to the map
|
||||
*/
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, float loadFactor,
|
||||
int concurrencyLevel) {
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, float loadFactor, int concurrencyLevel) {
|
||||
this(initialCapacity, loadFactor, concurrencyLevel, DEFAULT_REFERENCE_TYPE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new {@code ConcurrentReferenceHashMap} instance.
|
||||
* @param initialCapacity the initial capacity of the map
|
||||
* @param loadFactor the load factor. When the average number of references per table
|
||||
* exceeds this value resize will be attempted
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently write
|
||||
* to the map
|
||||
* @param loadFactor the load factor. When the average number of references per
|
||||
* table exceeds this value, resize will be attempted.
|
||||
* @param concurrencyLevel the expected number of threads that will concurrently
|
||||
* write to the map
|
||||
* @param referenceType the reference type used for entries
|
||||
*/
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, float loadFactor,
|
||||
int concurrencyLevel, ReferenceType referenceType) {
|
||||
@SuppressWarnings("unchecked")
|
||||
public ConcurrentReferenceHashMap(int initialCapacity, float loadFactor, int concurrencyLevel,
|
||||
ReferenceType referenceType) {
|
||||
|
||||
Assert.isTrue(concurrencyLevel > 0, "ConcurrencyLevel must be positive");
|
||||
Assert.isTrue(initialCapacity >= 0, "InitialCapacity must not be negative");
|
||||
Assert.isTrue(loadFactor > 0f, "LoadFactor must be positive");
|
||||
|
@ -167,17 +166,12 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
int size = 1 << this.shift;
|
||||
this.referenceType = referenceType;
|
||||
int roundedUpSegmentCapactity = (int) ((initialCapacity + size - 1L) / size);
|
||||
this.segments = createSegmentsArray(size);
|
||||
this.segments = (Segment[]) Array.newInstance(Segment.class, size);
|
||||
for (int i = 0; i < this.segments.length; i++) {
|
||||
this.segments[i] = new Segment(roundedUpSegmentCapactity);
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private Segment[] createSegmentsArray(int size) {
|
||||
return (Segment[]) Array.newInstance(Segment.class, size);
|
||||
}
|
||||
|
||||
|
||||
protected final float getLoadFactor() {
|
||||
return this.loadFactor;
|
||||
|
@ -222,7 +216,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
public V get(Object key) {
|
||||
Reference<K, V> reference = getReference(key, Restructure.WHEN_NECESSARY);
|
||||
Entry<K, V> entry = (reference == null ? null : reference.get());
|
||||
return (entry == null ? null : entry.getValue());
|
||||
return (entry != null ? entry.getValue() : null);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -392,7 +386,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
/**
|
||||
* Use {@link WeakReference}s.
|
||||
*/
|
||||
WEAK;
|
||||
WEAK
|
||||
}
|
||||
|
||||
|
||||
|
@ -425,7 +419,6 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
*/
|
||||
private int resizeThreshold;
|
||||
|
||||
|
||||
public Segment(int initialCapacity) {
|
||||
this.referenceManager = createReferenceManager();
|
||||
this.initialSize = 1 << calculateShift(initialCapacity, MAXIMUM_SEGMENT_SIZE);
|
||||
|
@ -456,17 +449,13 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* @return the result of the operation
|
||||
*/
|
||||
public <T> T doTask(final int hash, final Object key, final Task<T> task) {
|
||||
|
||||
boolean resize = task.hasOption(TaskOption.RESIZE);
|
||||
|
||||
if (task.hasOption(TaskOption.RESTRUCTURE_BEFORE)) {
|
||||
restructureIfNecessary(resize);
|
||||
}
|
||||
|
||||
if (task.hasOption(TaskOption.SKIP_IF_EMPTY) && (this.count == 0)) {
|
||||
return task.execute(null, null, null);
|
||||
}
|
||||
|
||||
lock();
|
||||
try {
|
||||
final int index = getIndex(hash, this.references);
|
||||
|
@ -484,7 +473,8 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
}
|
||||
};
|
||||
return task.execute(reference, entry, entries);
|
||||
} finally {
|
||||
}
|
||||
finally {
|
||||
unlock();
|
||||
if (task.hasOption(TaskOption.RESTRUCTURE_AFTER)) {
|
||||
restructureIfNecessary(resize);
|
||||
|
@ -573,8 +563,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
}
|
||||
}
|
||||
|
||||
private Reference<K, V> findInChain(Reference<K, V> reference, Object key,
|
||||
int hash) {
|
||||
private Reference<K, V> findInChain(Reference<K, V> reference, Object key, int hash) {
|
||||
while (reference != null) {
|
||||
if (reference.getHash() == hash) {
|
||||
Entry<K, V> entry = reference.get();
|
||||
|
@ -759,6 +748,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* Various options supported by a {@link Task}.
|
||||
*/
|
||||
private static enum TaskOption {
|
||||
|
||||
RESTRUCTURE_BEFORE, RESTRUCTURE_AFTER, SKIP_IF_EMPTY, RESIZE
|
||||
}
|
||||
|
||||
|
@ -790,8 +780,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
public boolean contains(Object o) {
|
||||
if (o != null && o instanceof Map.Entry<?, ?>) {
|
||||
Map.Entry<?, ?> entry = (java.util.Map.Entry<?, ?>) o;
|
||||
Reference<K, V> reference = ConcurrentReferenceHashMap.this.getReference(
|
||||
entry.getKey(), Restructure.NEVER);
|
||||
Reference<K, V> reference = ConcurrentReferenceHashMap.this.getReference(entry.getKey(), Restructure.NEVER);
|
||||
Entry<K, V> other = (reference == null ? null : reference.get());
|
||||
if (other != null) {
|
||||
return ObjectUtils.nullSafeEquals(entry.getValue(), other.getValue());
|
||||
|
@ -804,8 +793,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
public boolean remove(Object o) {
|
||||
if (o instanceof Map.Entry<?, ?>) {
|
||||
Map.Entry<?, ?> entry = (Map.Entry<?, ?>) o;
|
||||
return ConcurrentReferenceHashMap.this.remove(entry.getKey(),
|
||||
entry.getValue());
|
||||
return ConcurrentReferenceHashMap.this.remove(entry.getKey(), entry.getValue());
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
@ -926,8 +914,7 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
* @param next the next reference in the chain or {@code null}
|
||||
* @return a new {@link Reference}
|
||||
*/
|
||||
public Reference<K, V> createReference(Entry<K, V> entry, int hash,
|
||||
Reference<K, V> next) {
|
||||
public Reference<K, V> createReference(Entry<K, V> entry, int hash, Reference<K, V> next) {
|
||||
if (ConcurrentReferenceHashMap.this.referenceType == ReferenceType.WEAK) {
|
||||
return new WeakEntryReference<K, V>(entry, hash, next, this.queue);
|
||||
}
|
||||
|
@ -951,15 +938,13 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
/**
|
||||
* Internal {@link Reference} implementation for {@link SoftReference}s.
|
||||
*/
|
||||
private static final class SoftEntryReference<K, V> extends
|
||||
SoftReference<Entry<K, V>> implements Reference<K, V> {
|
||||
private static final class SoftEntryReference<K, V> extends SoftReference<Entry<K, V>> implements Reference<K, V> {
|
||||
|
||||
private final int hash;
|
||||
|
||||
private final Reference<K, V> nextReference;
|
||||
|
||||
public SoftEntryReference(Entry<K, V> entry, int hash, Reference<K, V> next,
|
||||
ReferenceQueue<Entry<K, V>> queue) {
|
||||
public SoftEntryReference(Entry<K, V> entry, int hash, Reference<K, V> next, ReferenceQueue<Entry<K, V>> queue) {
|
||||
super(entry, queue);
|
||||
this.hash = hash;
|
||||
this.nextReference = next;
|
||||
|
@ -986,15 +971,13 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
/**
|
||||
* Internal {@link Reference} implementation for {@link WeakReference}s.
|
||||
*/
|
||||
private static final class WeakEntryReference<K, V> extends
|
||||
WeakReference<Entry<K, V>> implements Reference<K, V> {
|
||||
private static final class WeakEntryReference<K, V> extends WeakReference<Entry<K, V>> implements Reference<K, V> {
|
||||
|
||||
private final int hash;
|
||||
|
||||
private final Reference<K, V> nextReference;
|
||||
|
||||
public WeakEntryReference(Entry<K, V> entry, int hash, Reference<K, V> next,
|
||||
ReferenceQueue<Entry<K, V>> queue) {
|
||||
public WeakEntryReference(Entry<K, V> entry, int hash, Reference<K, V> next, ReferenceQueue<Entry<K, V>> queue) {
|
||||
super(entry, queue);
|
||||
this.hash = hash;
|
||||
this.nextReference = next;
|
||||
|
@ -1016,4 +999,5 @@ public class ConcurrentReferenceHashMap<K, V> extends AbstractMap<K, V> implemen
|
|||
clear();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -25,7 +25,6 @@ import java.util.Iterator;
|
|||
import java.util.LinkedHashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
||||
import org.springframework.util.AntPathMatcher;
|
||||
|
@ -54,6 +53,7 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
|
||||
private final List<String> fileExtensions = new ArrayList<String>();
|
||||
|
||||
|
||||
/**
|
||||
* Creates a new instance with the given URL patterns.
|
||||
* Each pattern that is not empty and does not start with "/" is prepended with "/".
|
||||
|
@ -66,7 +66,6 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
/**
|
||||
* Additional constructor with flags for using suffix pattern (.*) and
|
||||
* trailing slash matches.
|
||||
*
|
||||
* @param patterns the URL patterns to use; if 0, the condition will match to every request.
|
||||
* @param urlPathHelper for determining the lookup path of a request
|
||||
* @param pathMatcher for path matching with patterns
|
||||
|
@ -118,8 +117,9 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
private static List<String> asList(String... patterns) {
|
||||
return patterns != null ? Arrays.asList(patterns) : Collections.<String>emptyList();
|
||||
return (patterns != null ? Arrays.asList(patterns) : Collections.<String>emptyList());
|
||||
}
|
||||
|
||||
private static Set<String> prependLeadingSlash(Collection<String> patterns) {
|
||||
|
@ -187,7 +187,6 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
* Checks if any of the patterns match the given request and returns an instance
|
||||
* that is guaranteed to contain matching patterns, sorted via
|
||||
* {@link PathMatcher#getPatternComparator(String)}.
|
||||
*
|
||||
* <p>A matching pattern is obtained by making checks in the following order:
|
||||
* <ul>
|
||||
* <li>Direct match
|
||||
|
@ -195,12 +194,10 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
* <li>Pattern match
|
||||
* <li>Pattern match with "/" appended if the pattern doesn't already end in "/"
|
||||
* </ul>
|
||||
*
|
||||
* @param request the current request
|
||||
*
|
||||
* @return the same instance if the condition contains no patterns;
|
||||
* or a new condition with sorted matching patterns;
|
||||
* or {@code null} if no patterns match.
|
||||
* or a new condition with sorted matching patterns;
|
||||
* or {@code null} if no patterns match.
|
||||
*/
|
||||
@Override
|
||||
public PatternsRequestCondition getMatchingCondition(HttpServletRequest request) {
|
||||
|
@ -209,9 +206,8 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
}
|
||||
|
||||
String lookupPath = this.pathHelper.getLookupPathForRequest(request);
|
||||
|
||||
List<String> matches = new ArrayList<String>();
|
||||
for (String pattern : patterns) {
|
||||
for (String pattern : this.patterns) {
|
||||
String match = getMatchingPattern(pattern, lookupPath);
|
||||
if (match != null) {
|
||||
matches.add(match);
|
||||
|
@ -259,7 +255,6 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
* {@link PathMatcher#getPatternComparator(String)}. If all compared
|
||||
* patterns match equally, but one instance has more patterns, it is
|
||||
* considered a closer match.
|
||||
*
|
||||
* <p>It is assumed that both instances have been obtained via
|
||||
* {@link #getMatchingCondition(HttpServletRequest)} to ensure they
|
||||
* contain only patterns that match the request and are sorted with
|
||||
|
@ -270,7 +265,7 @@ public final class PatternsRequestCondition extends AbstractRequestCondition<Pat
|
|||
String lookupPath = this.pathHelper.getLookupPathForRequest(request);
|
||||
Comparator<String> patternComparator = this.pathMatcher.getPatternComparator(lookupPath);
|
||||
|
||||
Iterator<String> iterator = patterns.iterator();
|
||||
Iterator<String> iterator = this.patterns.iterator();
|
||||
Iterator<String> iteratorOther = other.patterns.iterator();
|
||||
while (iterator.hasNext() && iteratorOther.hasNext()) {
|
||||
int result = patternComparator.compare(iterator.next(), iteratorOther.next());
|
||||
|
|
Loading…
Reference in New Issue