mirror of https://github.com/apache/jclouds.git
Deprecate duplicate getters
This commit is contained in:
parent
53da87cba0
commit
f2976c2169
|
@ -60,6 +60,7 @@ public interface Utils {
|
||||||
* </ul>
|
* </ul>
|
||||||
*/
|
*/
|
||||||
@Beta
|
@Beta
|
||||||
|
@Deprecated
|
||||||
Map<String, Credentials> getCredentialStore();
|
Map<String, Credentials> getCredentialStore();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -68,6 +69,7 @@ public interface Utils {
|
||||||
@Beta
|
@Beta
|
||||||
Map<String, Credentials> credentialStore();
|
Map<String, Credentials> credentialStore();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
Json getJson();
|
Json getJson();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -93,6 +95,7 @@ public interface Utils {
|
||||||
@Deprecated
|
@Deprecated
|
||||||
HttpAsyncClient asyncHttp();
|
HttpAsyncClient asyncHttp();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
HttpClient getHttpClient();
|
HttpClient getHttpClient();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -100,6 +103,7 @@ public interface Utils {
|
||||||
*/
|
*/
|
||||||
HttpClient http();
|
HttpClient http();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
Crypto getCrypto();
|
Crypto getCrypto();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -107,6 +111,7 @@ public interface Utils {
|
||||||
*/
|
*/
|
||||||
Crypto crypto();
|
Crypto crypto();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
DateService getDateService();
|
DateService getDateService();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -147,10 +152,12 @@ public interface Utils {
|
||||||
ListeningExecutorService ioExecutor();
|
ListeningExecutorService ioExecutor();
|
||||||
|
|
||||||
@Beta
|
@Beta
|
||||||
|
@Deprecated
|
||||||
EventBus getEventBus();
|
EventBus getEventBus();
|
||||||
|
|
||||||
EventBus eventBus();
|
EventBus eventBus();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
LoggerFactory getLoggerFactory();
|
LoggerFactory getLoggerFactory();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -160,6 +167,7 @@ public interface Utils {
|
||||||
|
|
||||||
|
|
||||||
@Beta
|
@Beta
|
||||||
|
@Deprecated
|
||||||
Injector getInjector();
|
Injector getInjector();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -168,6 +176,7 @@ public interface Utils {
|
||||||
@Beta
|
@Beta
|
||||||
Injector injector();
|
Injector injector();
|
||||||
|
|
||||||
|
@Deprecated
|
||||||
XMLParser getXml();
|
XMLParser getXml();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -22,7 +22,7 @@ public class GaeSocketOpenTest {
|
||||||
.modules(ImmutableSet.of(new GoogleAppEngineConfigurationModule()))
|
.modules(ImmutableSet.of(new GoogleAppEngineConfigurationModule()))
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
SocketOpen socketOpen = context.getUtils().getInjector().getInstance(SocketOpen.class);
|
SocketOpen socketOpen = context.utils().injector().getInstance(SocketOpen.class);
|
||||||
socketOpen.apply(HostAndPort.fromParts("localhost", 22));
|
socketOpen.apply(HostAndPort.fromParts("localhost", 22));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,11 +48,11 @@ public class AWSEC2ImageExtensionLiveTest extends BaseImageExtensionLiveTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected Iterable<? extends Image> listImages() {
|
protected Iterable<? extends Image> listImages() {
|
||||||
AWSEC2Client client = view.utils().getInjector().getInstance(AWSEC2Client.class);
|
AWSEC2Client client = view.utils().injector().getInstance(AWSEC2Client.class);
|
||||||
String[] parts = AWSUtils.parseHandle(imageId);
|
String[] parts = AWSUtils.parseHandle(imageId);
|
||||||
String region = parts[0];
|
String region = parts[0];
|
||||||
String imageId = parts[1];
|
String imageId = parts[1];
|
||||||
EC2ImageParser parser = view.utils().getInjector().getInstance(EC2ImageParser.class);
|
EC2ImageParser parser = view.utils().injector().getInstance(EC2ImageParser.class);
|
||||||
return transform(
|
return transform(
|
||||||
client.getAMIServices().describeImagesInRegion(region, new DescribeImagesOptions().imageIds(imageId)),
|
client.getAMIServices().describeImagesInRegion(region, new DescribeImagesOptions().imageIds(imageId)),
|
||||||
parser);
|
parser);
|
||||||
|
|
Loading…
Reference in New Issue