Class PresentSpotRequestsAndInstances
- java.lang.Object
-
- org.jclouds.ec2.compute.functions.PresentInstances
-
- org.jclouds.aws.ec2.compute.functions.PresentSpotRequestsAndInstances
-
- All Implemented Interfaces:
com.google.common.base.Function<Set<RegionAndName>,Set<RunningInstance>>
,Function<Set<RegionAndName>,Set<RunningInstance>>
@Singleton public class PresentSpotRequestsAndInstances extends PresentInstances
returns either the instances present in the list, or spot instances, if they ids start withsir-
. Makes a single rest call per aggregate on region.
-
-
Field Summary
-
Fields inherited from class org.jclouds.ec2.compute.functions.PresentInstances
logger
-
-
Constructor Summary
Constructors Constructor Description PresentSpotRequestsAndInstances(AWSEC2Api client, com.google.common.base.Function<SpotInstanceRequest,AWSRunningInstance> spotConverter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<RunningInstance>
apply(Set<RegionAndName> regionAndIds)
protected Set<RunningInstance>
getSpots(Set<RegionAndName> regionAndIds)
String
toString()
-
-
-
Constructor Detail
-
PresentSpotRequestsAndInstances
@Inject public PresentSpotRequestsAndInstances(AWSEC2Api client, com.google.common.base.Function<SpotInstanceRequest,AWSRunningInstance> spotConverter)
-
-
Method Detail
-
apply
public Set<RunningInstance> apply(Set<RegionAndName> regionAndIds)
- Specified by:
apply
in interfacecom.google.common.base.Function<Set<RegionAndName>,Set<RunningInstance>>
- Specified by:
apply
in interfaceFunction<Set<RegionAndName>,Set<RunningInstance>>
- Overrides:
apply
in classPresentInstances
-
getSpots
protected Set<RunningInstance> getSpots(Set<RegionAndName> regionAndIds)
-
toString
public String toString()
- Overrides:
toString
in classPresentInstances
-
-