| Constructor and Description |
|---|
MockInvoker(URL url) |
| Modifier and Type | Method and Description |
|---|---|
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 in interface Invoker<T>RpcExceptionpublic static String normalizeMock(String mock)
mock - mock stringpublic boolean isAvailable()
NodeisAvailable in interface Nodepublic void destroy()
NodeCopyright © 2011–2020 The Apache Software Foundation. All rights reserved.