| 构造器和说明 |
|---|
MockInvoker(URL url) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
destroy()
destroy.
|
Class<T> |
getInterface()
get service interface.
|
static Object |
getMockObject(String mockService,
Class serviceType) |
static Throwable |
getThrowable(String throwstr) |
URL |
getUrl()
get url.
|
Result |
invoke(Invocation invocation)
invoke.
|
boolean |
isAvailable()
is available.
|
static String |
normalizeMock(String mock)
Normalize mock string:
return => return null
fail => default
force => default
fail:throw/return foo => throw/return foo
force:throw/return foo => throw/return foo
|
static Object |
parseMockValue(String mock) |
static Object |
parseMockValue(String mock,
Type[] returnTypes) |
public MockInvoker(URL url)
public static Object parseMockValue(String mock, Type[] returnTypes) throws Exception
Exceptionpublic Result invoke(Invocation invocation) throws RpcException
Invokerinvoke 在接口中 Invoker<T>RpcExceptionpublic static String normalizeMock(String mock)
mock - mock stringpublic boolean isAvailable()
NodeisAvailable 在接口中 NodeCopyright © 2011–2019 The Apache Software Foundation. All rights reserved.