From 8197322b257af7ebf266af11ff73b5471927b750 Mon Sep 17 00:00:00 2001 From: Svjatoslav Agejenko Date: Sun, 16 Sep 2018 01:14:19 +0300 Subject: [PATCH] Rename wildcard matcher to glob matcher. --- .../svjatoslav/commons/network/navigation/NavigationItem.java | 4 ++-- .../commons/string/{WildCardMatcher.java => GlobMatcher.java} | 2 +- .../string/{WildCardMatcherTest.java => GlobMatcherTest.java} | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) rename src/main/java/eu/svjatoslav/commons/string/{WildCardMatcher.java => GlobMatcher.java} (99%) rename src/test/java/eu/svjatoslav/commons/string/{WildCardMatcherTest.java => GlobMatcherTest.java} (91%) diff --git a/src/main/java/eu/svjatoslav/commons/network/navigation/NavigationItem.java b/src/main/java/eu/svjatoslav/commons/network/navigation/NavigationItem.java index 0359440..8944931 100755 --- a/src/main/java/eu/svjatoslav/commons/network/navigation/NavigationItem.java +++ b/src/main/java/eu/svjatoslav/commons/network/navigation/NavigationItem.java @@ -9,7 +9,7 @@ package eu.svjatoslav.commons.network.navigation; -import eu.svjatoslav.commons.string.WildCardMatcher; +import eu.svjatoslav.commons.string.GlobMatcher; import java.util.ArrayList; import java.util.List; @@ -67,7 +67,7 @@ public class NavigationItem { } public boolean matchesUrl(final String url) { - return WildCardMatcher.match(url, pattern); + return GlobMatcher.match(url, pattern); } public NavigationItem getDefaultNavigationItem() { diff --git a/src/main/java/eu/svjatoslav/commons/string/WildCardMatcher.java b/src/main/java/eu/svjatoslav/commons/string/GlobMatcher.java similarity index 99% rename from src/main/java/eu/svjatoslav/commons/string/WildCardMatcher.java rename to src/main/java/eu/svjatoslav/commons/string/GlobMatcher.java index 9fe2bb5..b27f1f0 100755 --- a/src/main/java/eu/svjatoslav/commons/string/WildCardMatcher.java +++ b/src/main/java/eu/svjatoslav/commons/string/GlobMatcher.java @@ -9,7 +9,7 @@ package eu.svjatoslav.commons.string; -public class WildCardMatcher { +public class GlobMatcher { /** * Allow only for * in wildcards diff --git a/src/test/java/eu/svjatoslav/commons/string/WildCardMatcherTest.java b/src/test/java/eu/svjatoslav/commons/string/GlobMatcherTest.java similarity index 91% rename from src/test/java/eu/svjatoslav/commons/string/WildCardMatcherTest.java rename to src/test/java/eu/svjatoslav/commons/string/GlobMatcherTest.java index ce2f2f6..e2713de 100755 --- a/src/test/java/eu/svjatoslav/commons/string/WildCardMatcherTest.java +++ b/src/test/java/eu/svjatoslav/commons/string/GlobMatcherTest.java @@ -13,13 +13,13 @@ import org.junit.Test; import static org.junit.Assert.fail; -public class WildCardMatcherTest { +public class GlobMatcherTest { private static void testWildcard(final String string, final String pattern, final boolean expectedResult) { - final boolean result = WildCardMatcher.match(string, pattern); + final boolean result = GlobMatcher.match(string, pattern); if (result != expectedResult) fail("Wildcard match failed."); -- 2.20.1