com.alibaba.dubbo.rpc.cluster.Merger Java Examples
The following examples show how to use
com.alibaba.dubbo.rpc.cluster.Merger.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: MergerFactory.java From dubbo-2.6.5 with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if (result == null && !type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #2
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if(result == null && ! type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #3
Source File: MergerFactory.java From dubbox-hystrix with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if(result == null && ! type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #4
Source File: MergerFactory.java From dubbo3 with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if(result == null && ! type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #5
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if(result == null && ! type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #6
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 6 votes |
public static <T> Merger<T> getMerger(Class<T> returnType) { Merger result; if (returnType.isArray()) { Class type = returnType.getComponentType(); result = mergerCache.get(type); if (result == null) { loadMergers(); result = mergerCache.get(type); } if(result == null && ! type.isPrimitive()) { result = ArrayMerger.INSTANCE; } } else { result = mergerCache.get(returnType); if (result == null) { loadMergers(); result = mergerCache.get(returnType); } } return result; }
Example #7
Source File: MergerFactory.java From dubbo-2.6.5 with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }
Example #8
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }
Example #9
Source File: MergerFactory.java From dubbox-hystrix with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }
Example #10
Source File: MergerFactory.java From dubbo3 with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }
Example #11
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }
Example #12
Source File: MergerFactory.java From dubbox with Apache License 2.0 | 5 votes |
static void loadMergers() { Set<String> names = ExtensionLoader.getExtensionLoader(Merger.class) .getSupportedExtensions(); for (String name : names) { Merger m = ExtensionLoader.getExtensionLoader(Merger.class).getExtension(name); mergerCache.putIfAbsent(ReflectUtils.getGenericClass(m.getClass()), m); } }