public class MockProvider extends Object implements ServiceProvider
Modifier and Type | Field and Description |
---|---|
protected Map<Class<?>,Object> |
mocks |
protected ServiceProvider |
next |
Constructor and Description |
---|
MockProvider() |
Modifier and Type | Method and Description |
---|---|
void |
bind(Class<?> klass,
Object mock) |
void |
clearBindings() |
<T> T |
getService(Class<T> serviceClass)
Gets the service instance given its API class.
|
void |
installSelf() |
void |
uninstallSelf() |
public MockProvider()
public void clearBindings()
public void installSelf()
public void uninstallSelf()
public <T> T getService(Class<T> serviceClass)
ServiceProvider
getService
in interface ServiceProvider
Copyright © 2018 Nuxeo. All rights reserved.