类 UrlUtils
- java.lang.Object
-
- org.apache.dubbo.common.utils.UrlUtils
-
public class UrlUtils extends Object
-
-
构造器概要
构造器 构造器 说明 UrlUtils()
-
方法概要
所有方法 静态方法 具体方法 修饰符和类型 方法 说明 static List<URL>classifyUrls(List<URL> urls, Predicate<URL> predicate)static Map<String,Map<String,String>>convertRegister(Map<String,Map<String,String>> register)static Map<String,String>convertSubscribe(Map<String,String> subscribe)static URLgetEmptyUrl(String service, String category)static booleanhasServiceDiscoveryRegistryProtocol(URL url)static booleanhasServiceDiscoveryRegistryTypeKey(Map<String,String> parameters)The specified parameters ofURLis service discovery registry type or notstatic booleanhasServiceDiscoveryRegistryTypeKey(URL url)The specifiedURLis service discovery registry type or notstatic booleanisConfigurator(URL url)static booleanisConsumer(URL url)static booleanisMatch(URL consumerUrl, URL providerUrl)static booleanisMatchCategory(String category, String categories)static booleanisMatchGlobPattern(String pattern, String value)static booleanisMatchGlobPattern(String pattern, String value, URL param)static booleanisProvider(URL url)static booleanisRegistry(URL url)static booleanisRoute(URL url)static booleanisServiceDiscoveryURL(URL url)static booleanisServiceKeyMatch(URL pattern, URL value)static String[]parseServiceKey(String serviceKey)static URLparseURL(String address, Map<String,String> defaults)static List<URL>parseURLs(String address, Map<String,String> defaults)static List<String>revertForbid(List<String> forbid, Set<URL> subscribed)static Map<String,Map<String,String>>revertNotify(Map<String,Map<String,String>> notify)static Map<String,Map<String,String>>revertRegister(Map<String,Map<String,String>> register)static Map<String,String>revertSubscribe(Map<String,String> subscribe)static URLvalueOf(String url)NOTICE: This method allocate too much objects, we can useURLStrParser.parseDecodedStr(String)instead.
-
-
-
方法详细资料
-
convertRegister
public static Map<String,Map<String,String>> convertRegister(Map<String,Map<String,String>> register)
-
revertRegister
public static Map<String,Map<String,String>> revertRegister(Map<String,Map<String,String>> register)
-
revertNotify
public static Map<String,Map<String,String>> revertNotify(Map<String,Map<String,String>> notify)
-
isMatchGlobPattern
public static boolean isMatchGlobPattern(String pattern, String value, URL param)
-
isConfigurator
public static boolean isConfigurator(URL url)
-
isRoute
public static boolean isRoute(URL url)
-
isProvider
public static boolean isProvider(URL url)
-
isRegistry
public static boolean isRegistry(URL url)
-
hasServiceDiscoveryRegistryTypeKey
public static boolean hasServiceDiscoveryRegistryTypeKey(URL url)
The specifiedURLis service discovery registry type or not- 参数:
url- theURLconnects to the registry- 返回:
- If it is, return
true, orfalse - 从以下版本开始:
- 2.7.5
-
hasServiceDiscoveryRegistryProtocol
public static boolean hasServiceDiscoveryRegistryProtocol(URL url)
-
isServiceDiscoveryURL
public static boolean isServiceDiscoveryURL(URL url)
-
hasServiceDiscoveryRegistryTypeKey
public static boolean hasServiceDiscoveryRegistryTypeKey(Map<String,String> parameters)
The specified parameters ofURLis service discovery registry type or not- 参数:
parameters- the parameters ofURLthat connects to the registry- 返回:
- If it is, return
true, orfalse - 从以下版本开始:
- 2.7.5
-
parseServiceKey
public static String[] parseServiceKey(String serviceKey)
- 参数:
serviceKey- , {group}/{interfaceName}:{version}- 返回:
- [group, interfaceName, version]
-
valueOf
public static URL valueOf(String url)
NOTICE: This method allocate too much objects, we can useURLStrParser.parseDecodedStr(String)instead.Parse url string
- 参数:
url- URL string- 返回:
- URL instance
- 另请参阅:
URL
-
isConsumer
public static boolean isConsumer(URL url)
-
-